zshrc: Remove smart-compress
[grml-etc-core.git] / etc / zsh / zshrc
index 7861495..0cf0f9b 100644 (file)
@@ -272,7 +272,6 @@ setopt hash_list_all        # Whenever a command completion is attempted, make s
 setopt completeinword       # not just at the end
 setopt nohup                # and don't kill them, either
 setopt auto_pushd           # make cd push the old directory onto the directory stack.
-setopt nonomatch            # try to avoid the 'zsh: no matches found...'
 setopt nobeep               # avoid "beep"ing
 setopt pushd_ignore_dups    # don't push the same dir twice.
 setopt noglobdots           # * shouldn't match dotfiles. ever.
@@ -1428,16 +1427,6 @@ if [[ -x /sbin/kexec ]] && [[ -r /proc/cmdline ]] ; then
     alias "$(uname -r)-reboot"="kexec -l --initrd=/boot/initrd.img-"$(uname -r)" --command-line=\"$(cat /proc/cmdline)\" /boot/vmlinuz-"$(uname -r)""
 fi
 
-alias cp='nocorrect cp'         # no spelling correction on cp
-alias mkdir='nocorrect mkdir'   # no spelling correction on mkdir
-alias mv='nocorrect mv'         # no spelling correction on mv
-alias rm='nocorrect rm'         # no spelling correction on rm
-
-#a1# Execute \kbd{rmdir}
-alias rd='rmdir'
-#a1# Execute \kbd{mkdir}
-alias md='mkdir'
-
 # see http://www.cl.cam.ac.uk/~mgk25/unicode.html#term for details
 alias term2iso="echo 'Setting terminal to iso mode' ; print -n '\e%@'"
 alias term2utf="echo 'Setting terminal to utf-8 mode'; print -n '\e%G'"
@@ -1462,31 +1451,12 @@ iso2utf() {
     fi
 }
 
-# I like clean prompt, so provide simple way to get that
-check_com 0 || alias 0='return 0'
-
-# for really lazy people like mika:
-check_com S &>/dev/null || alias S='screen'
-check_com s &>/dev/null || alias s='ssh'
-
 # especially for roadwarriors using GNU screen and ssh:
 if ! check_com asc &>/dev/null ; then
   asc() { autossh -t "$@" 'screen -RdU' }
   compdef asc=ssh
 fi
 
-# get top 10 shell commands:
-alias top10='print -l ${(o)history%% *} | uniq -c | sort -nr | head -n 10'
-
-# truecrypt; use e.g. via 'truec /dev/ice /mnt/ice' or 'truec -i'
-if check_com -c truecrypt ; then
-    if isutfenv ; then
-        alias truec='truecrypt --mount-options "rw,sync,dirsync,users,uid=1000,gid=users,umask=077,utf8" '
-    else
-        alias truec='truecrypt --mount-options "rw,sync,dirsync,users,uid=1000,gid=users,umask=077" '
-    fi
-fi
-
 #f1# Hints for the use of zsh on grml
 zsh-help() {
     print "$bg[white]$fg[black]
@@ -2225,14 +2195,6 @@ fi
 # set terminal property (used e.g. by msgid-chooser)
 export COLORTERM="yes"
 
-#m# v QTDIR \kbd{/usr/share/qt[34]}\quad [for non-root only]
-[[ -d /usr/share/qt3 ]] && export QTDIR=/usr/share/qt3
-[[ -d /usr/share/qt4 ]] && export QTDIR=/usr/share/qt4
-
-# support running 'jikes *.java && jamvm HelloWorld' OOTB:
-#v# [for non-root only]
-[[ -f /usr/share/classpath/glibj.zip ]] && export JIKESPATH=/usr/share/classpath/glibj.zip
-
 # aliases
 
 # general
@@ -2241,12 +2203,6 @@ alias da='du -sch'
 #a2# Execute \kbd{jobs -l}
 alias j='jobs -l'
 
-# compile stuff
-#a2# Execute \kbd{./configure}
-alias CO="./configure"
-#a2# Execute \kbd{./configure --help}
-alias CH="./configure --help"
-
 # listing stuff
 #a2# Execute \kbd{ls -lSrah}
 alias dir="ls -lSrah"
@@ -2286,9 +2242,6 @@ alias insecscp='scp -o "StrictHostKeyChecking=no" -o "UserKnownHostsFile=/dev/nu
 # simple webserver
 check_com -c python && alias http="python -m SimpleHTTPServer"
 
-# Use 'g' instead of 'git':
-check_com g || alias g='git'
-
 # work around non utf8 capable software in utf environment via $LANG and luit
 if check_com isutfenv && check_com luit ; then
     if check_com -c mrxvt ; then
@@ -2583,27 +2536,6 @@ _simple_extract()
 compdef _simple_extract simple-extract
 alias se=simple-extract
 
-# Usage: smartcompress <file> (<type>)
-#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 <archive>
 #f5# List an archive's content
 show-archive() {