aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--_zshrc7
1 files changed, 7 insertions, 0 deletions
diff --git a/_zshrc b/_zshrc
index ca2af45..adf59e7 100644
--- a/_zshrc
+++ b/_zshrc
@@ -252,6 +252,13 @@ cdiff() {
diff -u "$@" | cpatch
}
+## Uncompress zlib data
+# Credit: https://unix.stackexchange.com/a/49066
+zlibd() {
+ # Prepend the gzip magic number and compress method.
+ { printf '\x1f\x8b\x08\x00\x00\x00\x00\x00'; cat "$@"; } | gzip -dc
+}
+
#
# Terminal settings
#