summary refs log tree commit diff stats
path: root/tag-zsh
diff options
context:
space:
mode:
authorAlan Pearce2016-09-25 14:04:20 +0200
committerAlan Pearce2016-09-25 14:04:20 +0200
commitea425580408e9a01b0b05e98acb1177e7176b750 (patch)
tree901906b01c42c1a3ea6ed0e0813221e0b2e23309 /tag-zsh
parent33a879120f966608107829cd94daa16aaf53eee4 (diff)
downloadnixfiles-ea425580408e9a01b0b05e98acb1177e7176b750.tar.lz
nixfiles-ea425580408e9a01b0b05e98acb1177e7176b750.tar.zst
nixfiles-ea425580408e9a01b0b05e98acb1177e7176b750.zip
zsh: Add ds (directory size) function
Shows size of subfolders, largest at the bottom. Easy to explore with.
Diffstat (limited to 'tag-zsh')
-rw-r--r--tag-zsh/config/zsh/zshrc4
1 files changed, 4 insertions, 0 deletions
diff --git a/tag-zsh/config/zsh/zshrc b/tag-zsh/config/zsh/zshrc
index 08ba28c2..b4db1f42 100644
--- a/tag-zsh/config/zsh/zshrc
+++ b/tag-zsh/config/zsh/zshrc
@@ -87,6 +87,10 @@ bindkey '\e^b' backward-argument
 bindkey '\e^f' forward-argument
 bindkey '\e^k' kill-argument
 
+ds () {
+	du -hd1 $1 | sort -h
+}
+
 zle -C hist-complete complete-word _generic
 zstyle ':completion:hist-complete:*' completer _history
 bindkey '\e	' hist-complete