2021-04-11 18:00:14 +02:00
|
|
|
{ pkgs, ... }:
|
2021-04-10 14:46:40 +02:00
|
|
|
{
|
|
|
|
programs.zsh = {
|
|
|
|
enable = true;
|
|
|
|
zplug = {
|
|
|
|
enable = true;
|
|
|
|
plugins = [
|
|
|
|
{ name = "romkatv/powerlevel10k"; tags = [ "as:theme" "depth:1" ]; }
|
2021-04-10 14:50:48 +02:00
|
|
|
{ name = "chisui/zsh-nix-shell"; }
|
2021-04-10 14:46:40 +02:00
|
|
|
];
|
|
|
|
};
|
|
|
|
initExtraFirst = ''
|
2021-04-16 11:03:26 +02:00
|
|
|
if [ -z "$TMUX" ] && [[ $- == *i* ]]
|
|
|
|
then
|
2021-09-07 18:53:22 +02:00
|
|
|
tmux
|
2021-04-16 11:03:26 +02:00
|
|
|
if [ ! -f /tmp/dontdie ]
|
2021-04-11 18:04:01 +02:00
|
|
|
then
|
2021-04-16 11:03:26 +02:00
|
|
|
exit
|
2021-04-11 18:04:01 +02:00
|
|
|
fi
|
2021-04-16 11:03:26 +02:00
|
|
|
rm /tmp/dontdie
|
|
|
|
fi
|
2021-04-10 21:12:06 +02:00
|
|
|
|
2021-04-16 11:03:26 +02:00
|
|
|
${builtins.readFile ./p10k.zsh.initfirst}
|
2021-04-10 14:46:40 +02:00
|
|
|
'';
|
|
|
|
initExtra = ''
|
2021-04-11 18:04:01 +02:00
|
|
|
source "${pkgs.fzf}/share/fzf/key-bindings.zsh"
|
|
|
|
source "${pkgs.fzf}/share/fzf/completion.zsh"
|
2021-04-11 18:00:14 +02:00
|
|
|
|
2021-04-11 18:04:01 +02:00
|
|
|
${builtins.readFile ./p10k.zsh}
|
2021-04-10 14:46:40 +02:00
|
|
|
'';
|
|
|
|
};
|
2021-04-13 09:03:00 +02:00
|
|
|
programs.direnv.enableZshIntegration = true;
|
2021-04-10 14:46:40 +02:00
|
|
|
}
|