dotfiles/modules/home/common/terminal/shell/zsh/default.nix
Christopher Mühl 53b8448159 Make common modules compatible for nix-darwin
TODO: Determine why nushell config is populated twice
2025-08-06 23:14:38 +02:00

49 lines
1,017 B
Nix

{
pkgs,
config,
...
}: {
imports = [
./antigen.nix
];
programs.zoxide.enableZshIntegration = true;
programs.zsh = {
enable = true;
oh-my-zsh.enable = true;
shellAliases = config.home.shellAliases;
# Add our own binaries to the PATH variable
initContent = ''
# Load Antigen as our package manager.
# The .antigenrc file is copied via the fixtures.nix
source ${pkgs.antigen.outPath}/share/antigen/antigen.zsh
antigen init ~/.antigenrc
export PATH="$HOME/code/hausgold/snippets/bin:$PATH"
export PATH="$HOME/.bun/bin:$HOME/.npm/bin:$PATH"
art()
{
if [ -f "./vendor/bin/sail" ];
then
./vendor/bin/sail artisan "$@"
else
php artisan "$@"
fi
}
sail()
{
if [ -f "./vendor/bin/sail" ];
then
./vendor/bin/sail "$@"
else
echo "Sail is not installed. Run 'composer require laravel/sail' to install it."
fi
}
'';
};
}