diff options
Diffstat (limited to 'user/modules')
-rw-r--r-- | user/modules/zsh.nix | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/user/modules/zsh.nix b/user/modules/zsh.nix index adbcaad0..9544f86f 100644 --- a/user/modules/zsh.nix +++ b/user/modules/zsh.nix @@ -1,5 +1,10 @@ { config, pkgs, ... }: +let + inherit (pkgs) stdenv; + lsOptions = if stdenv.isDarwin then "-p" else "-v --group-directories-first"; + lsIsoDate = if stdenv.isDarwin then "" else "--time-style=long-iso"; +in { home.file = { ".rm_recycle_home".text = ""; # use trash automatically in home directory @@ -49,6 +54,34 @@ ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE = "fg=7"; }; + shellAliases = { + l = "ls ${lsOptions} -Bp"; + l1="ls ${lsOptions} -1"; + ls="ls ${lsOptions} -hF"; + la="ls ${lsOptions} -hA"; + ll="ls ${lsOptions} ${lsIsoDate} -hl"; + lal="ll -A"; + lla="lal"; + llr="ll -t"; + + https = "http --default-scheme https"; + kns = "kubens"; + kx = "kubectx"; + ava = "pnpx ava"; + avt = "pnpx ava --tap"; + avat = "pnpx ava --tap"; + pino = "pino-pretty"; + mocha = "pnpx mocha"; + prettier = "pnpx prettier"; + standard = "pnpx standard"; + tsc = "pnpx tsc"; + tslint = "pnpx tslint"; + tsnode = "pnpx ts-node"; + wprop = "xprop | egrep '^WM_(CLASS|NAME|WINDOW_ROLE|TYPE)'"; + + watch = "watch "; # enable watch with aliases + }; + # move to envExtra after 19.09 initExtra = '' case $OSTYPE in |