df function tabularised; idea from #grml on irc.ipv6.freenode.net
authorThorsten Glaser <tg@mirbsd.org>
Wed, 30 Mar 2011 20:48:19 +0000 (20:48 +0000)
committerThorsten Glaser <tg@mirbsd.org>
Wed, 30 Mar 2011 20:48:19 +0000 (20:48 +0000)
bash-ksh/profile-funcs

index 74cd88f..5c2d970 100644 (file)
@@ -15,6 +15,12 @@ bye() {                      # cu ;-)
        logout
 }
 
+# print disc free stats in a more handy format
+# for wider terminals than 80c, but deals well with LVM
+df() {
+       command df -P "$@" | sed 's/Mounted on/Mountpoint/' | column -t
+}
+
 ggs() {                        # Google Search
        ${BROWSER:-lynx} "http://www.google.com/search?hl=la&num=100&safe=off&q=$*"
 }