dotfiles/modules/home/cli/shell/nushell/default.nix
2025-04-16 12:26:02 -05:00

28 lines
527 B
Nix
Executable file

{ flake, config, ... }:
let
inherit (flake.config.people) user0;
user = config.home.username;
keyLogic =
if user == user0 then
"$env.ANTHROPIC_API_KEY = (open /home/${user0}/.config/zed/claude-api-key)"
else
"";
in
{
programs.nushell = {
enable = true;
configFile.text = ''
sleep 7ms
$env.config = {show_banner: false}
${keyLogic}
'';
shellAliases = {
y = "yy";
lg = "lazygit";
yt = "yt-dlp --embed-chapters";
ze = "zellij";
};
};
}