From 58ccc983cc24d0fb4067c8a8b22e3534cd7732f9 Mon Sep 17 00:00:00 2001 From: Frank Terbeck Date: Wed, 30 Nov 2011 22:21:30 +0100 Subject: [PATCH] zshrc: Remove smart-compress Signed-off-by: Frank Terbeck --- doc/grmlzshrc.t2t | 5 ----- etc/zsh/zshrc | 21 --------------------- 2 files changed, 26 deletions(-) diff --git a/doc/grmlzshrc.t2t b/doc/grmlzshrc.t2t index c43dc23..446f9cb 100644 --- a/doc/grmlzshrc.t2t +++ b/doc/grmlzshrc.t2t @@ -602,11 +602,6 @@ ending. simple-extract will not delete the original archive (even on .gz,.bz2 or : **sll()** Prints details of symlinks given as arguments. -: **smartcompress()** -Compresses/archives the file given as first parameter. Takes an optional -second argument, which denotes the compression/archive type as typical -filename extension; defaults to "tar.gz". - : **ssl-cert-fingerprints** Prints the SHA512, SHA256, SHA1 and MD5 digest of a x509 certificate. First and only parameter must be a file containing a certificate. Use diff --git a/etc/zsh/zshrc b/etc/zsh/zshrc index b43a99d..0cf0f9b 100644 --- a/etc/zsh/zshrc +++ b/etc/zsh/zshrc @@ -2536,27 +2536,6 @@ _simple_extract() compdef _simple_extract simple-extract alias se=simple-extract -# Usage: smartcompress () -#f5# Smart archive creator -smartcompress() { - emulate -L zsh - if [[ -n $2 ]] ; then - case $2 in - tgz | tar.gz) tar -zcvf$1.$2 $1 ;; - tbz2 | tar.bz2) tar -jcvf$1.$2 $1 ;; - tar.Z) tar -Zcvf$1.$2 $1 ;; - tar) tar -cvf$1.$2 $1 ;; - gz | gzip) gzip $1 ;; - bz2 | bzip2) bzip2 $1 ;; - *) - echo "Error: $2 is not a valid compression type" - ;; - esac - else - smartcompress $1 tar.gz - fi -} - # Usage: show-archive #f5# List an archive's content show-archive() { -- 2.1.4