about summary refs log tree commit diff stats
path: root/nix-conf
diff options
context:
space:
mode:
authorDavid Morgan <djm_uk@protonmail.com>2022-12-02 12:21:36 +0000
committerDavid Morgan <djm_uk@protonmail.com>2022-12-02 12:21:36 +0000
commitf65bef69e3d1d201dbb0e8baafec4438c78d5293 (patch)
treedf9a04d196abf27f796b815e4593efc41b5f9e2f /nix-conf
parenta5035cbb1dafa255afcd0896af4ee320f6ddf9b3 (diff)
downloaddotfiles-f65bef69e3d1d201dbb0e8baafec4438c78d5293.tar.gz
Add tre (plus tree alias)
Diffstat (limited to 'nix-conf')
-rw-r--r--nix-conf/home/includes/common.nix1
-rw-r--r--nix-conf/home/includes/zsh.nix3
2 files changed, 4 insertions, 0 deletions
diff --git a/nix-conf/home/includes/common.nix b/nix-conf/home/includes/common.nix
index 09bbc48..e1f8fac 100644
--- a/nix-conf/home/includes/common.nix
+++ b/nix-conf/home/includes/common.nix
@@ -58,6 +58,7 @@ in
     rlwrap
     sd
     tealdeer
+    tre-command
     ugrep
     uni
     w3m
diff --git a/nix-conf/home/includes/zsh.nix b/nix-conf/home/includes/zsh.nix
index f9a3896..59e8d13 100644
--- a/nix-conf/home/includes/zsh.nix
+++ b/nix-conf/home/includes/zsh.nix
@@ -50,6 +50,7 @@
       cp = "cp -iv";
       mv = "mv -iv";
       mkdir = "mkdir -v";
+      tree = "exa --tree";
 
       pp = "pushbullet push \"Pixel\" link \"\${1}\" \"\${1}\"";
 
@@ -134,6 +135,8 @@
 
       function generate () { gopass generate -s -p $1 $((RANDOM % 14 + 45)) }
 
+      tre () { command tre "$@" -e && source "/tmp/tre_aliases_$USER" 2>/dev/null; }
+
       function gcd () {
         if [ $# -eq 0 ] ; then
           echo "Number of days must be specified" >&2