<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -8,9 +8,9 @@ require(&quot;naughty&quot;)
 -- {{{ Variable definitions
 -- Themes define colours, icons, and wallpapers
 -- The default is a dark theme
- theme_path = &quot;/usr/share/awesome/themes/default/theme&quot;
+theme_path = &quot;/usr/share/awesome/themes/default/theme.lua&quot;
 -- Uncommment this for a lighter theme
--- theme_path = &quot;/usr/share/awesome/themes/sky/theme&quot;
+-- theme_path = &quot;/usr/share/awesome/themes/sky/theme.lua&quot;
 
 -- Actually load theme
 beautiful.init(theme_path)
@@ -64,7 +64,7 @@ floatapps =
 -- Use the screen and tags indices.
 apptags =
 {
-    [&quot;Gran Paradiso&quot;] = { screen = 1, tag = 2 },
+    [&quot;Navigator&quot;] = { screen = 1, tag = 2 },
     [&quot;Opera&quot;] = { screen = 1, tag = 2 },
     [&quot;main.tcl&quot;] = { screen = 1, tag = 2 },
     [&quot;Toplevel&quot;] = { screen = 1, tag = 3 },
@@ -100,7 +100,7 @@ end
 -- Create a textbox widget
 mytextbox = widget({ type = &quot;textbox&quot;, align = &quot;right&quot; })
 -- Set the default text in textbox
-mytextbox.text = &quot;&lt;b&gt;&lt;small&gt; &quot; .. AWESOME_RELEASE .. &quot; &lt;/small&gt;&lt;/b&gt;&quot;
+mytextbox.text = &quot;&lt;b&gt;&lt;small&gt; &quot; .. awesome.release .. &quot; &lt;/small&gt;&lt;/b&gt;&quot;
 
 -- Create a laucher widget and a main menu
 -- myawesomemenu = {
@@ -162,7 +162,7 @@ mytasklist.buttons = awful.util.table.join(
 
 for s = 1, screen.count() do
     -- Create a promptbox for each screen
-    mypromptbox[s] = widget({ type = &quot;textbox&quot;, align = &quot;left&quot; })
+    mypromptbox[s] = awful.widget.prompt({ align = &quot;left&quot; })
     -- Create an imagebox widget which will contains an icon indicating which layout we're using.
     -- We need one layoutbox per screen.
     mylayoutbox[s] = widget({ type = &quot;imagebox&quot;, align = &quot;right&quot; })
@@ -172,12 +172,12 @@ for s = 1, screen.count() do
                            awful.button({ }, 4, function () awful.layout.inc(layouts, 1) end),
                            awful.button({ }, 5, function () awful.layout.inc(layouts, -1) end)))
     -- Create a taglist widget
-    mytaglist[s] = awful.widget.taglist.new(s, awful.widget.taglist.label.all, mytaglist.buttons)
+    mytaglist[s] = awful.widget.taglist(s, awful.widget.taglist.label.all, mytaglist.buttons)
 
     -- Create a tasklist widget
-    mytasklist[s] = awful.widget.tasklist.new(function(c)
-                                                  return awful.widget.tasklist.label.currenttags(c, s)
-                                              end, mytasklist.buttons)
+    mytasklist[s] = awful.widget.tasklist(function(c)
+                                              return awful.widget.tasklist.label.currenttags(c, s)
+                                          end, mytasklist.buttons)
 
     -- Create the wibox
     mywibox[s] = wibox({ position = &quot;top&quot;, height = 16, fg = beautiful.fg_normal, bg = beautiful.bg_normal })
@@ -217,6 +217,7 @@ globalkeys = awful.util.table.join(
             awful.client.focus.byidx(-1)
             if client.focus then client.focus:raise() end
         end),
+    awful.key({ modkey,           }, &quot;w&quot;, function () mymainmenu:show(true)        end),
 
     -- Layout manipulation
     awful.key({ modkey, &quot;Shift&quot;   }, &quot;j&quot;, function () awful.client.swap.byidx(  1) end),
@@ -247,18 +248,12 @@ globalkeys = awful.util.table.join(
     awful.key({ modkey, &quot;Shift&quot;   }, &quot;space&quot;, function () awful.layout.inc(layouts, -1) end),
 
     -- Prompt
-    awful.key({ modkey }, &quot;r&quot;,
-              function ()
-                  awful.prompt.run({ prompt = &quot;Run: &quot; },
-                  mypromptbox[mouse.screen],
-                  awful.util.spawn, awful.completion.shell,
-                  awful.util.getdir(&quot;cache&quot;) .. &quot;/history&quot;)
-              end),
+    awful.key({ modkey },            &quot;r&quot;,     function () mypromptbox[mouse.screen]:run() end),
 
     awful.key({ modkey }, &quot;x&quot;,
               function ()
                   awful.prompt.run({ prompt = &quot;Run Lua code: &quot; },
-                  mypromptbox[mouse.screen],
+                  mypromptbox[mouse.screen].widget,
                   awful.util.eval, nil,
                   awful.util.getdir(&quot;cache&quot;) .. &quot;/history_eval&quot;)
               end)
@@ -287,33 +282,34 @@ for s = 1, screen.count() do
 end
 
 for i = 1, keynumber do
-    table.foreach(awful.key({ modkey }, i,
+    globalkeys = awful.util.table.join(globalkeys,
+        awful.key({ modkey }, i,
                   function ()
                         local screen = mouse.screen
                         if tags[screen][i] then
                             awful.tag.viewonly(tags[screen][i])
                         end
-                  end), function(_, k) table.insert(globalkeys, k) end)
-    table.foreach(awful.key({ modkey, &quot;Control&quot; }, i,
+                  end),
+        awful.key({ modkey, &quot;Control&quot; }, i,
                   function ()
                       local screen = mouse.screen
                       if tags[screen][i] then
                           tags[screen][i].selected = not tags[screen][i].selected
                       end
-                  end), function(_, k) table.insert(globalkeys, k) end)
-    table.foreach(awful.key({ modkey, &quot;Shift&quot; }, i,
+                  end),
+        awful.key({ modkey, &quot;Shift&quot; }, i,
                   function ()
                       if client.focus and tags[client.focus.screen][i] then
                           awful.client.movetotag(tags[client.focus.screen][i])
                       end
-                  end), function(_, k) table.insert(globalkeys, k) end)
-    table.foreach(awful.key({ modkey, &quot;Control&quot;, &quot;Shift&quot; }, i,
+                  end),
+        awful.key({ modkey, &quot;Control&quot;, &quot;Shift&quot; }, i,
                   function ()
                       if client.focus and tags[client.focus.screen][i] then
                           awful.client.toggletag(tags[client.focus.screen][i])
                       end
-                  end), function(_, k) table.insert(globalkeys, k) end)
-    table.foreach(awful.key({ modkey, &quot;Shift&quot; }, &quot;F&quot; .. i,
+                  end),
+        awful.key({ modkey, &quot;Shift&quot; }, &quot;F&quot; .. i,
                   function ()
                       local screen = mouse.screen
                       if tags[screen][i] then
@@ -321,7 +317,7 @@ for i = 1, keynumber do
                               awful.client.movetotag(tags[screen][i], c)
                           end
                       end
-                   end), function(_, k) table.insert(globalkeys, k) end)
+                   end))
 end
 
 -- Set keys
@@ -389,9 +385,9 @@ awful.hooks.manage.register(function (c, startup)
     -- Check if the application should be floating.
     local cls = c.class
     local inst = c.instance
-    if floatapps[cls] then
+    if floatapps[cls] ~= nil then
         awful.client.floating.set(c, floatapps[cls])
-    elseif floatapps[inst] then
+    elseif floatapps[inst] ~= nil then
         awful.client.floating.set(c, floatapps[inst])
     end
 </diff>
      <filename>.config/awesome/rc.lua</filename>
    </modified>
    <modified>
      <diff>@@ -1,8 +1,80 @@
-startup_message off
-vbell off
-#Cool statusbar
+# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= #
+# Use this line if you want instant charset mapping from gbk to
+# unicode. Conflict with mutt's unicode setting.
+#defencoding gbk
+cjkwidth on
+
+# hardstatus line
+hardstatus on
 hardstatus alwayslastline
-hardstatus string &quot;%{=b}%{-b}%{R}[%{=b B}%-w%{=b BK}%&gt;%n %t%{-}%+w%{-b}%&lt; %=%{R}]&quot;
-#4 urxvt
-terminfo rxvt-256color 'Co#256:AB=\E[48;5;%dm:AF=\E[38;5;%dm'
+hardstatus string &quot;%{= R}[%{y}%l%{r}][ %{=b b}%-w%{=rb db}%&gt;%n %t%{-}%+w%{-b}%&lt; %=%{R}][%{G}%c %{M}%D %m-%d%{R}]&quot;
+#caption always &quot;%{= mW} %= %H %=&quot;
+#caption always &quot;%{= gk}%-Lw%{= rW}%50&gt; %n%f* %t %{-}%+Lw%&lt; %= %{= Gk} %H %{= rW} %l %{= Gk} %0c:%s %d/%m %{-}&quot;
+#new version from vermaden
+#hardstatus string '%{= M} %H%{= G} %l %= %{= w}%-w%{+b r}%n*%t%{-b r}%{w}%+w %= %{c}%d %D %{B}%c '
+# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= #
+##    Some general options    ##
+
+# Make the xterm scroller work in screen, also works
+# with mouse scrollwheel(does not work...)
+#termcapinfo xterm*|rxvt ti@:te@
+#dynamic title
+#termcapinfo xterm* 'hs:ts=\E]2;:fs=\007:ds=\E]2;screen\007'
+#fix rxvt-unicode 256 color problem
+terminfo rxvt-unicode 'Co#256:AB=\E[48;5;%dm:AF=\E[38;5;%dm'
+# bind Shift+PgUp/PgDn(does not work...)
+#bindkey -m -k kN stuff ^D
+#bindkey -m -k kP stuff ^U
+#bindkey -m &quot;^[[5;2~&quot; stuff ^b
+#bindkey -m &quot;^[[6;2~&quot; stuff ^f
+ 
+# Automatically detach on hangup, or the screen will keep eating your memory after the terminal emulator has been terminated.
+autodetach on		# default: on
+
+# Refresh the display when exiting programs like vim, nano, irssi and etc.
+altscreen on
+
+#define a large scrollback buffer
+defscrollback 1000
+
+# Set messages timeout to one second: 
+msgwait 1
+pow_detach_msg &quot;Screen session of \$LOGNAME \$:cr:\$:nl:ended.&quot;
+#version
+# start message:
+startup_message off	# default: on
+
+# use audio bell
+vbell off
+vbell_msg &quot;   Wuff  ----  Wuff!!  &quot;
+
+#nethack style messages
+#nethack on
+
+#utf-8 handling
+#defutf8 on
+
+#use zshell as default shell
+#shell zsh
+shell /bin/zsh
 
+# =-=-=-=-=-=-=-=-=-=-=Key bindings-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= #
+# bind F1  to select 1
+# bind F7  to detach screen session from this terminal
+# bind F8  to kill current screen window.
+# bind F9  to create a new screen
+# bind F10 to rename current screen window
+# bind F11 to move to previous window
+# bind F12 to move to next window
+#bindkey -k k1 select 1
+#bindkey -k k7 detach
+#bindkey -k k8 kill
+#bindkey -k k9 screen
+#bindkey -k k; title
+bindkey -k F1 prev
+bindkey -k F2 next
+# =-=-=-=-=-=-=-=-=-=-=-Sessions=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= #
+screen
+screen
+screen
+#screen</diff>
      <filename>.screenrc</filename>
    </modified>
    <modified>
      <diff>@@ -11,11 +11,12 @@
 alias hv3='~/hv3/hv3-linux-nightly-08_0203'
 alias cm='xset dpms force off'
 alias tb='thunderbird'
-export PATH=$PATH:$HOME/shuge_desktop/bin/:/opt/dropbox
+export PATH=$PATH:$HOME/shuge_desktop/shuge-desktop-latest/:/opt/dropbox
 
 #Set LOCALE
 export LC_ALL=&quot;zh_CN.UTF-8&quot;
 export LANG=&quot;zh_CN.UTF-8&quot;
+export LC_COLLATE=&quot;zh_CN.UTF-8&quot;
 
 #Xrdb
 xrdb &lt; ~/.Xresources
@@ -25,10 +26,10 @@ export XMODIFIERS=&quot;@im=SCIM&quot;
 export XIM=SCIM
 
 #Set scim-bridge
-export XIM_PROGRAM=&quot;/usr/bin/scim&quot;
-export XIM_ARGS=&quot;-d&quot;
-export GTK_IM_MODULE=scim-bridge
-export QT4_IM_MODULE=scim-bridge
+#export XIM_PROGRAM=&quot;/usr/bin/scim&quot;
+#export XIM_ARGS=&quot;-d&quot;
+#export GTK_IM_MODULE=scim-bridge
+#export QT4_IM_MODULE=scim-bridge
 scim -d &amp;
 
 #Set ibus
@@ -51,7 +52,7 @@ export AWT_TOOLKIT=MToolkit
 numlockx&amp;
 
 #shadows and translucency
-xcompmgr -c -t1 -l1 -r2  &amp;
+#xcompmgr -c -t1 -l1 -r2  &amp;
 
 # exec gnome-session
 # exec startkde
@@ -63,6 +64,6 @@ xcompmgr -c -t1 -l1 -r2  &amp;
 # exec ratpoison
 # exec dwm
 # exec jwm
-#exec startlxde
-exec awesome
+#ck-launch-session startlxde
+exec ck-launch-session awesome
 # ... or any other WM of your choosing ...</diff>
      <filename>.xinitrc</filename>
    </modified>
    <modified>
      <diff>@@ -1,57 +1,204 @@
-if [[ $TERM = 'linux' &amp;&amp; $(ps -ef | grep fbterm | grep -v grep | wc -l) == 0  ]]; then
-    fbterm
+#!/bin/zsh
+
+#------------------------listing color----------------------------------
+if [[ &quot;$TERM&quot; == *256color ]] || [[ &quot;$TERM&quot; = screen ]]; then
+    #use prefefined colors
+    eval $(dircolors -b $HOME/.lscolor256)
+else
+    eval $(dircolors -b $HOME/.lscolor)
 fi
-if [[ $STY = '' ]] then screen -xR; fi
-# Lines configured by zsh-newuser-install
-HISTFILE=~/.histfile
-HISTSIZE=1000
-SAVEHIST=1000
-bindkey -v
-# End of lines configured by zsh-newuser-install
-# The following lines were added by compinstall
-zstyle :compinstall filename '/home/qiukun/.zshrc'
 
+#---------------------------options-------------------------------------
+setopt complete_aliases     #do not expand aliases _before_ completion has finished
+setopt auto_cd              # if not a command, try to cd to it.
+setopt auto_pushd            # automatically pushd directories on dirstack
+setopt pushd_ignore_dups      # do not push dups on stack
+setopt pushd_silent          # be quiet about pushds and popds
+setopt brace_ccl            # expand alphabetic brace expressions
+#setopt chase_links          # ~/ln -&gt; /; cd ln; pwd -&gt; /
+setopt complete_in_word     # stays where it is and completion is done from both ends
+setopt correct              # spell check for commands only
+#setopt equals extended_glob # use extra globbing operators
+setopt hash_list_all        # search all paths before command completion
+setopt hist_ignore_all_dups     # when runing a command several times, only store one
+setopt hist_reduce_blanks   # reduce whitespace in history
+setopt share_history        # share history among sessions
+setopt hist_verify       # reload full command when runing from history
+setopt hist_expire_dups_first  #remove dups when max size reached
+setopt interactive_comments # why not?
+setopt list_types           # show ls -F style marks in file completion
+setopt long_list_jobs       # show pid in bg job list
+setopt numeric_glob_sort    # when globbing numbered files, use real counting
+setopt inc_append_history   # append to history once executed
+
+#remove / and . from WORDCHARS to allow alt-backspace to delete word
+#WORDCHARS='*?_-[]~=&amp;;!#$%^(){}&lt;&gt;'
+
+#replace the default beep with a message
+#ZBEEP='~/MACSound/System\ Notifi.wav'
+#-------------------------completion system-----------------------------
+zmodload -i zsh/complist
+zstyle ':completion:*' list-colors &quot;${(s.:.)LS_COLORS}&quot;
+zstyle ':completion:*:*:kill:*' list-colors '=%*=01;31' 
+#ignore list in completion
+zstyle ':completion:*' ignore-parents parent pwd directory
+#menu selection in completion
+zstyle ':completion:*' menu select=1
+#zstyle ':completion:*' completer _complete _match _approximate
+zstyle ':completion:*' completer _complete _match _user_expand
+zstyle ':completion:*:match:*' original only 
+zstyle ':completion:*' user-expand _pinyin
+zstyle ':completion:*:approximate:*' max-errors 1 numeric 
+## case-insensitive (uppercase from lowercase) completion
+zstyle ':completion:*' matcher-list 'm:{[:lower:]}={[:upper:]}'
+### case-insensitive (all) completion
+#zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}'
+#kill completion
+zstyle ':completion:*:*:kill:*' menu yes select
+zstyle ':completion:*:*:*:*:processes' force-list always
+zstyle ':completion:*:processes' command 'ps -au$USER' 
+#use cache to speed up pacman completion
+zstyle ':completion::complete:*' use-cache on
+#zstyle ':completion::complete:*' cache-path .zcache 
+#group matches and descriptions
+zstyle ':completion:*:matches' group 'yes'
+zstyle ':completion:*' group-name ''
+zstyle ':completion:*:options' description 'yes'
+zstyle ':completion:*:options' auto-description '%d'
+zstyle ':completion:*:descriptions' format $'\e[01;33m -- %d --\e[0m' 
+zstyle ':completion:*:messages' format $'\e[01;35m -- %d --\e[0m'
+zstyle ':completion:*:warnings' format $'\e[01;31m -- No Matches Found :( --\e[0m' 
+zstyle ':completion:*:corrections' format $'\e[0;31m -- %d (errors: %e) --\e[0m'
+
+#autoload -U compinit
 autoload -Uz compinit
 compinit
-# End of lines added by compinstall
-
-setopt auto_pushd
-setopt auto_cd
-autoload zkbd
-[[ ! -d ~/.zkbd ]] &amp;&amp; mkdir ~/.zkbd
-[[ ! -f ~/.zkbd/$TERM-$VENDOR-$OSTYPE ]] &amp;&amp; zkbd
-source  ~/.zkbd/$TERM-$VENDOR-$OSTYPE
-# setup key accordingly
-[[ -n &quot;${key[Home]}&quot;     ]]  &amp;&amp; bindkey  &quot;${key[Home]}&quot;     vi-beginning-of-line
-[[ -n &quot;${key[End]}&quot;      ]]  &amp;&amp; bindkey  &quot;${key[End]}&quot;      vi-end-of-line
-[[ -n &quot;${key[Insert]}&quot;   ]]  &amp;&amp; bindkey  &quot;${key[Insert]}&quot;   overwrite-mode
-[[ -n &quot;${key[Delete]}&quot;   ]]  &amp;&amp; bindkey  &quot;${key[Delete]}&quot;   delete-char
-[[ -n &quot;${key[Up]}&quot;       ]]  &amp;&amp; bindkey  &quot;${key[Up]}&quot;       vi-up-line-or-history
-[[ -n &quot;${key[Down]}&quot;     ]]  &amp;&amp; bindkey  &quot;${key[Down]}&quot;     vi-down-line-or-history
-[[ -n &quot;${key[Left]}&quot;     ]]  &amp;&amp; bindkey  &quot;${key[Left]}&quot;     vi-backward-char
-[[ -n &quot;${key[Right]}&quot;    ]]  &amp;&amp; bindkey  &quot;${key[Right]}&quot;    vi-forward-char
-[[ -n &quot;${key[PageUp]}&quot;   ]]  &amp;&amp; bindkey  &quot;${key[PageUp]}&quot;   vi-backward-blank-word
-[[ -n &quot;${key[PageDown]}&quot; ]]  &amp;&amp; bindkey  &quot;${key[PageDown]}&quot; vi-forward-blank-word 
-
-alias ls='ls --color=auto -X'
-alias grep='grep --color=always'
-alias less='less -R'
+
+#---------------------------prompt--------------------------------------
+#autoload -U promptinit zmv
+#promptinit
+if [ &quot;$SSH_TTY&quot; = &quot;&quot; ]; then
+    local host=&quot;%B%F{magenta}%m%f%b&quot;
+else
+    local host=&quot;%B%F{red}%m%f%b&quot;
+fi
+local user=&quot;%B%(!:%F{red}:%F{green})%n%f%b&quot;       #different color for privileged sessions
+local symbol=&quot;%B%(!:%F{red}# :%F{yellow}&gt; )%f%b&quot;
+local job=&quot;%1(j,%F{red}:%F{blue}%j,)%f%b&quot;
+export PROMPT=$user&quot;%F{yellow}@%f&quot;$host$job$symbol
+#export RPROMPT=&quot;%{$fg_no_bold[${1:-magenta}]%}%~%{$reset_color%}&quot;
+export RPROMPT=&quot;%F{magenta}%~%f&quot;
+
+# SPROMPT - the spelling prompt
+export SPROMPT=&quot;zsh: correct '%F{red}%B%R%f%b' to '%F{green}%B%r%f%b' ? ([Y]es/[N]o/[E]dit/[A]bort) &quot;
+
+#---------------------------history-------------------------------------
+# number of lines kept in history
+export HISTSIZE=10000
+# number of lines saved in the history after logout
+export SAVEHIST=10000
+# location of history
+export HISTFILE=$HOME/.zsh_history
+
+#---------------------------alias---------------------------------------
+# alias and listing colors
+export GREP_COLOR='31;1'
+alias grep='grep -I --color=always'
+alias egrep='egrep -I --color=always'
+alias cal='cal -3m'
+alias ls='ls -h --color=auto -X --time-style=&quot;+*[33m[*[32m%Y-%m-%d *[35m%k:%M*[33m]*[m&quot;'
+alias vi='vim'
+alias ll='ls -l'
 alias df='df -Th'
 alias du='du -h'
-alias x='startx'
-alias Syu='sudo pacman -Syu'
+alias mkdir='nocorrect mkdir'
+#show directories size
+alias dud='du -s *(/)'
+#alias which='alias | /usr/bin/which --read-alias'
+alias pyprof='python -m cProfile'
+alias ri='ri -f ansi'
+alias history='history 1'       #zsh specific
+#alias mplayer='mplayer -cache 512'
+alias zhcon='zhcon --utf8'
+alias vless=&quot;/usr/share/vim/macros/less.sh&quot;
+del() {mv -vif -- $* ~/.Trash}
+alias m='mutt'
+alias port='netstat -ntlp'      #opening ports
+alias e264='mencoder -vf harddup -ovc x264 -x264encopts crf=22:subme=5:frameref=2:8x8dct:bframes=3:weight_b:b_pyramid -oac mp3lame -lameopts aq=7:mode=0:vol=1.2:vbr=2:q=6 -srate 32000'
+#alias tree=&quot;tree --dirsfirst&quot;
+alias top10='print -l  ${(o)history%% *} | uniq -c | sort -nr | head -n 10'
+#alias tree=&quot;ls -R | grep &quot;:$&quot; | sed -e 's/:$//' -e 's/[^-][^\/]*\//--/g' -e 's/^/   /' -e 's/-/|/'&quot;
+#alias tt=&quot;vim +'set spell' ~/doc/TODO.otl&quot;
+#alias mlychee=&quot;sshfs -p 2023 roy@lychee: /home/roylez/remote/lychee&quot;
+#alias gfw=&quot;ssh -CNfg -D 7777 -l roy lychee &amp;&gt;/dev/null &amp;&quot;
+#alias rtm=&quot;twitter d rtm&quot;
+#alias rtorrent=&quot;screen rtorrent&quot;
+#if [ &quot;$HOSTNAME&quot; != 'lychee' ]; then
+#    for i in showq qstat qdel qnodes showstart; do 
+#        alias $i=&quot;ssh roy@lychee -p 2023 /opt/bin/$i&quot;
+#    done
+#    function qsub(){ssh roy@lychee -p 2023 &quot;cd ${(S)PWD#lez/remote/lychee};/opt/bin/qsub -o /tmp -e /tmp $1&quot;}
+#fi
+[ -x /usr/bin/pal ] &amp;&amp; alias pal=&quot;pal -r 0-7 --color&quot;
+[ -x /usr/bin/cdf ] &amp;&amp; alias df=&quot;cdf -h&quot;
+if [ -x /usr/bin/grc ]; then
+    alias cl=&quot;/usr/bin/grc -es --colour=auto&quot;
+    for i in diff cat make gcc g++ as gas ld netstat ping traceroute; do
+        alias $i=&quot;cl $i&quot;
+    done
+fi
+alias -g A=&quot;|awk&quot;
+alias -g C=&quot;|wc&quot;
+alias -g E=&quot;|sed&quot;
+alias -g G=&quot;|grep&quot;
+alias -g H=&quot;|head&quot;
+alias -g L=&quot;|less&quot;
+alias -g S=&quot;|sort&quot;
+alias -g T=&quot;|tail&quot;
+alias -g X=&quot;|xargs&quot;
 
-#screen integration to set caption bar dynamically
-function title {
-    # Use these two for GNU Screen:
-    print -nR $'\033k'$1$'\033'\\\
+#-----------------user defined functions--------------------------------
+#show 256 color tab
+#256tab() {
+#    for k in `seq 0 1`;do 
+#        for j in `seq $((16+k*18)) 36 $((196+k*18))`;do 
+#            for i in `seq $j $((j+17))`; do 
+#                printf &quot;\e[01;$1;38;5;%sm%4s&quot; $i $i;
+#            done;echo;
+#        done;
+#    done
+#}
 
-    print -nR $'\033]0;'$2$'\a'
-}
+#alarm() { 
+#    echo &quot;msg ${argv[2,-1]} &amp;&amp; aplay -q ~/.sounds/MACSound/System\ Notifi.wav&quot; | at now + $1 min
+#}
+#-----------------functions to set gnu screen title----------------------
+# active command as title in terminals
+case $TERM in
+    xterm*|rxvt*)
+    function title() 
+    { 
+        #print -nP '\e]0;'$*'\a'
+        print -nPR $'\033]0;'$1$'\a'
+    } ;;
+    screen*)
+    function title() 
+    {
+        #modify screen title
+        print -nPR $'\033k'$1$'\033'\\
+        #modify window title bar
+        #print -nPR $'\033]0;'$2$'\a'
+    } ;;
+    *) 
+    function title() {}
+    ;;
+esac     
 
 #set screen title if not connected remotely
+#if [ &quot;$STY&quot; != &quot;&quot; ]; then
 function precmd {
-    title &quot;`print -Pn &quot;%~&quot; | sed &quot;s:\([~/][^/]*\)/.*/:\1...:&quot;`&quot; &quot;$TERM $PWD&quot;
+    #title &quot;`print -Pn &quot;%~&quot; | sed &quot;s:\([~/][^/]*\)/.*/:\1...:&quot;`&quot; &quot;$TERM $PWD&quot;
+    title &quot;`print -Pn &quot;%~&quot; |sed &quot;s:\([~/][^/]*\)/.*/:\1...:;s:\([^-]*-[^-]*\)-.*:\1:&quot;`&quot; &quot;$TERM $PWD&quot;
     echo -ne '\033[?17;0;127c'
 }
 
@@ -59,14 +206,109 @@ function preexec {
     emulate -L zsh
     local -a cmd; cmd=(${(z)1})
     if [[ $cmd[1]:t == &quot;ssh&quot; ]]; then
-        title &quot;@&quot;$cmd[2] &quot;$TERM $cmd&quot;
+        title &quot;@&quot;&quot;`echo $cmd[2]|sed 's:.*@::'`&quot; &quot;$TERM $cmd&quot;
     elif [[ $cmd[1]:t == &quot;sudo&quot; ]]; then
         title &quot;#&quot;$cmd[2]:t &quot;$TERM $cmd[3,-1]&quot;
     elif [[ $cmd[1]:t == &quot;for&quot; ]]; then
         title &quot;()&quot;$cmd[7] &quot;$TERM $cmd&quot;
     elif [[ $cmd[1]:t == &quot;svn&quot; ]]; then
         title &quot;$cmd[1,2]&quot; &quot;$TERM $cmd&quot;
+    elif [[ $cmd[1]:t == &quot;ls&quot; ]] || [[ $cmd[1]:t == &quot;ll&quot; ]] ; then
     else
         title $cmd[1]:t &quot;$TERM $cmd[2,-1]&quot;
-    fi
+    fi 
 }
+
+#-----------------key bindings to fix keyboard---------------------------
+#bindkey &quot;\M-v&quot; &quot;\`xclip -o\`\M-\C-e\&quot;&quot;
+# create a zkbd compatible hash;
+# to add other keys to this hash, see: man 5 terminfo
+autoload -U zkbd
+source ~/.zkbd/$TERM-$VENDOR-$OSTYPE
+bindkey -e      #use emacs style keybindings :(
+#typeset -A key  #define an array
+#
+#key[Home]=${terminfo[khome]}
+#key[End]=${terminfo[kend]}
+#key[Insert]=${terminfo[kich1]}
+#key[Delete]=${terminfo[kdch1]}
+#key[Up]=${terminfo[kcuu1]}
+#key[Down]=${terminfo[kcud1]}
+#key[Left]=${terminfo[kcub1]}
+#key[Right]=${terminfo[kcuf1]}
+#key[PageUp]=${terminfo[kpp]}
+#key[PageDown]=${terminfo[knp]}
+
+# setup key accordingly
+[[ -n &quot;${key[Home]}&quot;    ]]  &amp;&amp; bindkey  &quot;${key[Home]}&quot;    beginning-of-line
+[[ -n &quot;${key[End]}&quot;     ]]  &amp;&amp; bindkey  &quot;${key[End]}&quot;     end-of-line
+[[ -n &quot;${key[Insert]}&quot;  ]]  &amp;&amp; bindkey  &quot;${key[Insert]}&quot;  overwrite-mode
+[[ -n &quot;${key[Delete]}&quot;  ]]  &amp;&amp; bindkey  &quot;${key[Delete]}&quot;  delete-char
+[[ -n &quot;${key[Up]}&quot;      ]]  &amp;&amp; bindkey  &quot;${key[Up]}&quot;      up-line-or-history
+[[ -n &quot;${key[Down]}&quot;    ]]  &amp;&amp; bindkey  &quot;${key[Down]}&quot;    down-line-or-history
+[[ -n &quot;${key[Left]}&quot;    ]]  &amp;&amp; bindkey  &quot;${key[Left]}&quot;    backward-char
+[[ -n &quot;${key[Right]}&quot;   ]]  &amp;&amp; bindkey  &quot;${key[Right]}&quot;   forward-char
+
+bindkey &quot;*&quot; history-beginning-search-backward
+bindkey &quot;*&quot; history-beginning-search-forward
+
+#-----------------user defined widgets &amp; binds-----------------------
+#from linuxtoy.org: 
+#   pressing TAB in an empty command makes a cd command with completion list
+dumb-cd(){
+    if [[ -n $BUFFER ]] ; then # &#22914;&#26524;&#35813;&#34892;&#26377;&#20869;&#23481;
+        zle expand-or-complete # &#25191;&#34892; TAB &#21407;&#26469;&#30340;&#21151;&#33021;
+    else # &#22914;&#26524;&#27809;&#26377;
+        BUFFER=&quot;cd &quot; # &#22635;&#20837; cd&#65288;&#31354;&#26684;&#65289;
+        zle end-of-line # &#36825;&#26102;&#20809;&#26631;&#22312;&#34892;&#39318;&#65292;&#31227;&#21160;&#21040;&#34892;&#26411;
+        zle expand-or-complete # &#25191;&#34892; TAB &#21407;&#26469;&#30340;&#21151;&#33021;
+    fi 
+}
+zle -N dumb-cd
+bindkey &quot;\t&quot; dumb-cd #&#23558;&#19978;&#38754;&#30340;&#21151;&#33021;&#32465;&#23450;&#21040; TAB &#38190;
+
+#&#25340;&#38899;&#34917;&#20840;
+function _pinyin() { reply=($($HOME/bin/chsdir 0 $*)) }
+
+#c-z to continue as well
+bindkey -s &quot;*&quot; &quot;fg\n&quot;
+#----------------------distro specific stuff---------------------------
+#if `cat /etc/issue |grep Arch &gt;/dev/null`; then
+#    function command_not_found_handler() {
+#        echo &quot;Man, you really need some coffee. \nA clear-headed one would not type things like \&quot;$1\&quot;.&quot;|cowsay -f small -W 50
+#        if grep Arch /etc/issue &gt;/dev/null; then
+#            echo 
+#            pacfile /bin/$1$|awk '{split($1,a,&quot;/&quot;);print a[1] &quot;/\033[31m&quot; a[2] &quot;\033[m\t\t\t/&quot; $2}'
+#        fi
+#        return 0
+#    }
+#fi
+#----------------------variables---------------------------------------
+export PATH=$PATH:$HOME/bin:$HOME/.gem/ruby/1.8/bin
+export EDITOR=vim
+export VISUAL=vim
+
+#MOST like colored man pages
+export LESS_TERMCAP_md=$'\E[1;31m'      #bold1
+export LESS_TERMCAP_mb=$'\E[1;31m'
+export LESS_TERMCAP_me=$'\E[m'
+export LESS_TERMCAP_so=$'\E[01;44;33m'  #search highlight
+export LESS_TERMCAP_se=$'\E[m'
+export LESS_TERMCAP_us=$'\E[1;2;32m'    #bold2
+export LESS_TERMCAP_ue=$'\E[m'
+export LESS=&quot;-M -i -R --shift 5&quot;
+export LESSCHARSET=utf-8
+#export LESSOPEN=&quot;|lesspipe.sh %s&quot;       #lesspipe
+
+#for ConTeX
+#source $HOME/.context_env /home/roylez/soft/ConTeXt/tex
+
+#for gnuplot, avoid locate!!!
+#export GDFONTPATH=$(dirname `locate DejaVuSans.ttf | tail -1`)
+[[ -n $DISPLAY ]] &amp;&amp; export GDFONTPATH=/usr/share/fonts/TTF
+
+#for intel fortran compiler
+#source $HOME/soft/intel/ifort/bin/ifortvars.sh
+
+#for slrn
+#export NNTPSERVER=news.newsfan.net </diff>
      <filename>.zshrc</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>31db921f62cb62802d84387d10c391fe3fd9d3fd</id>
    </parent>
  </parents>
  <author>
    <name>qiukun</name>
    <email>qykcdgm@gmail.com</email>
  </author>
  <url>http://github.com/qiukun/hmandcon/commit/80961deea6bba4f821782d038093ee3dde7765a7</url>
  <id>80961deea6bba4f821782d038093ee3dde7765a7</id>
  <committed-date>2009-08-21T06:14:47-07:00</committed-date>
  <authored-date>2009-08-21T06:14:47-07:00</authored-date>
  <message>&#27809;&#21861;&#22909;&#35828;</message>
  <tree>4f3d31779a3fb4adb81aedb62538a67fbe2c5e18</tree>
  <committer>
    <name>qiukun</name>
    <email>qykcdgm@gmail.com</email>
  </committer>
</commit>
