Add zsh-lookup sub-system
[grml-etc-core.git] / etc / zsh / zshrc
index e17dd9e..da60016 100644 (file)
 # Global Order: zshenv, zprofile, zshrc, zlogin
 ################################################################################
 
+# USAGE
+# If you are using this file as your ~/.zshrc file, please use ~/.zshrc.pre
+# and ~/.zshrc.local for your own customisations. The former file is read
+# before ~/.zshrc, the latter is read after it. Also, consider reading the
+# refcard and the reference manual for this setup, both available from:
+#     <http://grml.org/zsh/>
+
 # Contributing:
 # If you want to help to improve grml's zsh setup, clone the grml-etc-core
 # repository from git.grml.org:
@@ -1988,6 +1995,10 @@ else
     zstyle ':vcs_info:(sv[nk]|bzr):*' branchformat "%b${RED}:${YELLOW}%r"
 fi
 
+if [[ -o restricted ]]; then
+    zstyle ':vcs_info:*' enable false
+fi
+
 # }}}
 
 # command not found handling {{{
@@ -2986,7 +2997,7 @@ ipv6-tunnel() {
 
 # run dhclient for wireless device
 iwclient() {
-    salias dhclient "$(wavemon -d | awk '/device/{print $2}')"
+    sudo dhclient "$(wavemon -d | awk '/device/{print $3}')"
 }
 
 # spawn a minimally set up mksh - useful if you want to umount /usr/.
@@ -3132,6 +3143,7 @@ if (( GRML_ALWAYS_LOAD_ALL == 0 )) && (( $EUID == 0 )) ; then
     return 0
 fi
 
+zrcautoload lookupinit && lookupinit
 
 # variables {{{
 
@@ -3369,7 +3381,7 @@ bk() {
 #f5# Copied diff
 cdiff() {
     emulate -L zsh
-    diff -crd "$*" | egrep -v "^Only in |^Binary files "
+    diff -crd "$@" | egrep -v "^Only in |^Binary files "
 }
 #f5# cd to directoy and list files
 cl() {