2024-06-27 20:37:20 +02:00
|
|
|
{
|
|
|
|
# initial version
|
|
|
|
home.stateVersion = "22.11";
|
|
|
|
|
2024-06-27 23:19:37 +02:00
|
|
|
# ZSH with good config
|
2024-06-27 20:37:20 +02:00
|
|
|
programs.zsh = {
|
2024-06-27 23:19:37 +02:00
|
|
|
# ZSH on
|
2024-06-27 20:37:20 +02:00
|
|
|
enable = true;
|
2024-06-27 23:19:37 +02:00
|
|
|
|
|
|
|
# we want completion
|
2024-06-27 20:37:20 +02:00
|
|
|
enableCompletion = true;
|
2024-06-27 23:19:37 +02:00
|
|
|
|
|
|
|
# we want suggestions of already typed stuff
|
2024-06-27 20:37:20 +02:00
|
|
|
autosuggestion.enable = true;
|
2024-06-27 23:19:37 +02:00
|
|
|
|
|
|
|
# we want nice command highlighting
|
2024-06-27 20:37:20 +02:00
|
|
|
syntaxHighlighting.enable = true;
|
|
|
|
|
2024-06-27 23:19:37 +02:00
|
|
|
# better history
|
|
|
|
history = {
|
|
|
|
# save timestamps
|
|
|
|
extended = true;
|
|
|
|
|
|
|
|
# kill dupes over full history
|
|
|
|
ignoreAllDups = true;
|
|
|
|
|
|
|
|
# don't share history between sessions
|
|
|
|
share = false;
|
|
|
|
};
|
|
|
|
|
2024-06-27 20:37:20 +02:00
|
|
|
# aliases
|
|
|
|
shellAliases = {
|
|
|
|
# system build/update/cleanup
|
|
|
|
update = "sudo TMPDIR=/var/cache/nix nixos-rebuild boot";
|
|
|
|
upgrade = "sudo TMPDIR=/var/cache/nix nixos-rebuild boot --upgrade";
|
|
|
|
updatenow = "sudo TMPDIR=/var/cache/nix nixos-rebuild switch";
|
|
|
|
upgradenow = "sudo TMPDIR=/var/cache/nix nixos-rebuild switch --upgrade";
|
|
|
|
gc = "sudo nix-collect-garbage --delete-older-than 7d";
|
|
|
|
verify = "sudo nix --extra-experimental-features nix-command store verify --all";
|
|
|
|
optimize = "sudo nix --extra-experimental-features nix-command store optimise";
|
|
|
|
|
|
|
|
# overwrite some tools
|
|
|
|
cat = "bat";
|
|
|
|
ls = "lsd";
|
2024-06-30 18:26:28 +02:00
|
|
|
la = "lsd -ahl";
|
2024-06-27 20:37:20 +02:00
|
|
|
|
|
|
|
# ssh around in the local network
|
|
|
|
mac = "ssh mac.fritz.box";
|
|
|
|
macroot = "ssh root@mac.fritz.box";
|
|
|
|
mini = "ssh mini.fritz.box";
|
|
|
|
miniroot = "ssh root@mini.fritz.box";
|
|
|
|
neko = "ssh neko.fritz.box";
|
|
|
|
nekoroot = "ssh root@neko.fritz.box";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
# nice prompt
|
|
|
|
programs.oh-my-posh = {
|
|
|
|
enable = true;
|
2024-06-30 16:26:25 +02:00
|
|
|
useTheme = "tokyo";
|
2024-06-27 20:37:20 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
# nice cd
|
|
|
|
programs.zoxide = {
|
|
|
|
enable = true;
|
|
|
|
options = [ "--cmd" "cd" ];
|
|
|
|
};
|
|
|
|
|
2024-06-27 22:55:47 +02:00
|
|
|
# integrate fuzzy search
|
|
|
|
programs.fzf = {
|
|
|
|
enable = true;
|
|
|
|
};
|
|
|
|
|
2024-06-27 20:37:20 +02:00
|
|
|
# enable keychain, we use the main user key
|
|
|
|
programs.keychain = {
|
|
|
|
enable = true;
|
|
|
|
keys = [ "/home/cullmann/.ssh/id_ed25519" ];
|
|
|
|
};
|
|
|
|
|
|
|
|
# https://github.com/nix-community/nix-direnv
|
|
|
|
programs.direnv = {
|
|
|
|
enable = true;
|
|
|
|
nix-direnv.enable = true;
|
|
|
|
};
|
|
|
|
}
|