diff options
| author | Simen A. W. Olsen <hello@simenandre.no> | 2026-03-21 19:21:15 +0100 |
|---|---|---|
| committer | Simen A. W. Olsen <hello@simenandre.no> | 2026-03-21 19:21:15 +0100 |
| commit | e24043a06675a6fedcccc775fe3d285e0bf3a4b1 (patch) | |
| tree | d25f6d6ecafd310aea823c03b569e7f05c1a5ff6 | |
| parent | 6c3ddf6a5dea41939b6d33a82e0043ddc732641a (diff) | |
| download | dotfiles-e24043a06675a6fedcccc775fe3d285e0bf3a4b1.tar.gz dotfiles-e24043a06675a6fedcccc775fe3d285e0bf3a4b1.zip | |
fix(zsh): add robustness checks and platform-specific aliases; add SSH key
| -rw-r--r-- | modules/home/zsh.nix | 8 | ||||
| -rw-r--r-- | modules/nixos/default.nix | 1 |
2 files changed, 7 insertions, 2 deletions
diff --git a/modules/home/zsh.nix b/modules/home/zsh.nix index 1b24133..50a3fcf 100644 --- a/modules/home/zsh.nix +++ b/modules/home/zsh.nix @@ -61,7 +61,7 @@ fi done - eval "$(twm --print-zsh-completion)" + command -v twm &>/dev/null && eval "$(twm --print-zsh-completion)" bindkey '^I^I' autosuggest-accept ''; @@ -75,13 +75,17 @@ alias git-clean-branches="git for-each-ref --format '%(refname:short)' refs/heads | grep -v 'master\|main' | xargs git branch -D" alias :q='exit' alias ls='ls --color' + '' + (if pkgs.stdenv.isDarwin then '' alias tailscale='/Applications/Tailscale.app/Contents/MacOS/Tailscale' + '' else "") + '' # Generic / Random / Utility alias rg="rg --hidden --glob '!.git' --glob '!node_modules'" alias r='cd $REPOS/github.com/' alias c='clear' + '' + (if pkgs.stdenv.isDarwin then '' alias afk='pmset displaysleepnow' + '' else "") + '' alias dl="cd ~/Downloads" alias l='ls -l' alias todo='nt' @@ -91,7 +95,7 @@ alias tre="tree -I '.git|node_modules'" alias timeliste="open 'https://tripletex.no/execute/updateHourlist?contextId=11208568'" alias t="open 'https://tripletex.no/execute/updateHourlist?contextId=11208568'" - alias fork-cleaner="fork-cleaner --token $(cat ~/.secrets/github-token)" + alias fork-cleaner="fork-cleaner --token \$(cat ~/.secrets/github-token 2>/dev/null)" alias vi="nvim" alias vim="nvim" alias v="nvim" diff --git a/modules/nixos/default.nix b/modules/nixos/default.nix index a52e023..50f4c42 100644 --- a/modules/nixos/default.nix +++ b/modules/nixos/default.nix @@ -28,6 +28,7 @@ shell = pkgs.zsh; openssh.authorizedKeys.keys = [ "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIDDXfT23Ne7Rl/rdiqrLf4vWfQqgUCo26+NcL41PVSag" + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJwHftCdnV/pscQ4qCK/biIBsKk/G0A3hLVI1o62CJF4 so@bjerk.io" ]; }; programs.zsh.enable = true; |
