mirror of
https://github.com/thegeneralist01/config.git
synced 2026-05-30 08:37:01 +02:00
use zsh as login shell on Linux, exec nu for interactive SSH
Set thegeneralist-central's user shell to zsh (matching macOS pattern). Drop the isDarwin guard on .zshrc generation so all hosts get the SSH_TTY-gated nu exec — non-interactive SSH (Codex etc.) stays in zsh, real interactive sessions still land in nu. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
b68229b94a
commit
c72bd220d3
2 changed files with 5 additions and 6 deletions
|
|
@ -52,7 +52,7 @@
|
||||||
"scanner"
|
"scanner"
|
||||||
"docker"
|
"docker"
|
||||||
];
|
];
|
||||||
shell = pkgs.nushell;
|
shell = pkgs.zsh;
|
||||||
home = "/home/thegeneralist";
|
home = "/home/thegeneralist";
|
||||||
homeMode = "0750";
|
homeMode = "0750";
|
||||||
linger = true;
|
linger = true;
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,6 @@ let
|
||||||
flatten
|
flatten
|
||||||
getAttr
|
getAttr
|
||||||
mapAttrsToList
|
mapAttrsToList
|
||||||
mkIf
|
|
||||||
mkOption
|
mkOption
|
||||||
sortOn
|
sortOn
|
||||||
toInt
|
toInt
|
||||||
|
|
@ -64,7 +63,7 @@ in
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
(mkIf config.isDarwin (
|
(
|
||||||
homeArgs:
|
homeArgs:
|
||||||
let
|
let
|
||||||
config' = homeArgs.config;
|
config' = homeArgs.config;
|
||||||
|
|
@ -72,15 +71,15 @@ in
|
||||||
{
|
{
|
||||||
home.file.".zshrc".text = # zsh
|
home.file.".zshrc".text = # zsh
|
||||||
''
|
''
|
||||||
export PATH="/run/current-system/sw/bin:/nix/var/nix/profiles/default/bin:/etc/profiles/per-user/$USER/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin''${PATH:+:}''${PATH}"
|
export PATH="$HOME/.local/bin:/run/current-system/sw/bin:/nix/var/nix/profiles/default/bin:/etc/profiles/per-user/$USER/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin''${PATH:+:}''${PATH}"
|
||||||
source ${config'.home.sessionVariablesPackage}/etc/profile.d/hm-session-vars.sh
|
source ${config'.home.sessionVariablesPackage}/etc/profile.d/hm-session-vars.sh
|
||||||
|
|
||||||
if [ -z "$INTELLIJ_ENVIRONMENT_READER" ] && [ -z "$skip" ]; then
|
if [ -z "$INTELLIJ_ENVIRONMENT_READER" ] && [ -z "$skip" ] && [ -n "$SSH_TTY" ]; then
|
||||||
SHELL='${lib.getExe <| lib.head config'.shellsByPriority}' exec "$SHELL"
|
SHELL='${lib.getExe <| lib.head config'.shellsByPriority}' exec "$SHELL"
|
||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
}
|
}
|
||||||
))
|
)
|
||||||
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue