dotfiles/modules/home/cli/shell/nushell/default.nix

29 lines
527 B
Nix
Raw Normal View History

2025-04-16 12:26:02 -05:00
{ flake, config, ... }:
2025-03-31 23:58:34 -05:00
let
2025-04-16 12:26:02 -05:00
2025-03-31 23:58:34 -05:00
inherit (flake.config.people) user0;
2025-04-16 12:26:02 -05:00
user = config.home.username;
keyLogic =
if user == user0 then
"$env.ANTHROPIC_API_KEY = (open /home/${user0}/.config/zed/claude-api-key)"
else
"";
2025-03-31 23:58:34 -05:00
in
2025-03-29 23:08:26 -05:00
{
programs.nushell = {
enable = true;
configFile.text = ''
sleep 7ms
$env.config = {show_banner: false}
2025-04-16 12:26:02 -05:00
${keyLogic}
2025-03-29 23:08:26 -05:00
'';
shellAliases = {
y = "yy";
lg = "lazygit";
yt = "yt-dlp --embed-chapters";
ze = "zellij";
};
};
}