summary refs log tree commit diff stats
path: root/tag-zsh/config/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/config/zsh
parent33a879120f966608107829cd94daa16aaf53eee4 (diff)
downloaddotfiles-ea425580408e9a01b0b05e98acb1177e7176b750.tar.lz
dotfiles-ea425580408e9a01b0b05e98acb1177e7176b750.tar.zst
dotfiles-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/config/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 08ba28c..b4db1f4 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