From 3787269b0f41f792c3e90c1bdac543bfb8abf7c7 Mon Sep 17 00:00:00 2001 From: PHO Date: Thu, 24 Sep 2009 22:33:38 +0900 Subject: [PATCH] Auto commit by The Sugar System. --- IGNORE | 4 ++++ dot-files/_emacs_el | 5 +++++ dot-files/_zshrc | 37 +++++++++++++------------------------ 3 files changed, 22 insertions(+), 24 deletions(-) diff --git a/IGNORE b/IGNORE index 4986172..852ff3d 100644 --- a/IGNORE +++ b/IGNORE @@ -20,6 +20,7 @@ .aspell.* .btpd .cabal +.cabal-upload .cddbslave .config .covers @@ -29,6 +30,7 @@ .dbus .dillo/cookiesrc .dmrc +.dropbox .dvdcss .easytag .ecb-tip-of-day.el @@ -52,6 +54,7 @@ .forward .gconf* .gegl-* +.gimmix* .gimp* .gitk .glimpse* @@ -123,6 +126,7 @@ .w3m/*arrived .w3m/*cookie .w3m/*sessions +.w3m/.textarea .wine .xchat2* .xdvirc diff --git a/dot-files/_emacs_el b/dot-files/_emacs_el index e2daa01..72426b0 100644 --- a/dot-files/_emacs_el +++ b/dot-files/_emacs_el @@ -42,6 +42,11 @@ (display-time) ;; Setting for Frames ---------------------------------------------------------- +(when window-system + (set-default-font "Bitstream Vera Sans Mono 11") + (set-fontset-font (frame-parameter nil 'font) + 'japanese-jisx0208 + '("Hiragino Kaku Gothic Pro W3" . "unicode-bmp"))) ;; Hooks for newline-and-indent ------------------------------------------------ (mapcar (lambda (hook) diff --git a/dot-files/_zshrc b/dot-files/_zshrc index d5fdcf8..eaf7657 100644 --- a/dot-files/_zshrc +++ b/dot-files/_zshrc @@ -75,7 +75,7 @@ function preexec() { # Hook } function chpwd() { # Hook - local dirinfo=$(print_directory_info) + local dirinfo=$(print_directory_info $(pwd)) case $dirinfo in "") @@ -86,40 +86,29 @@ function chpwd() { # Hook } function print_directory_info() { - local vcs_type=$(print_vcs_type $(pwd)) - - case $vcs_type in - git) - git branch --no-color 2>/dev/null \ - | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/';; - hg) - hg branch 2>/dev/null;; - darcs-*) - # Delete `darcs-' at the beginning. - echo ${vcs_type#darcs-};; - *) - # Unknown - echo - esac -} - -function print_vcs_type() { local absdir=$1 if [[ -d $absdir/.git ]] then - echo git + # Git + git branch --no-color 2>/dev/null \ + | sed -e '/^[^*]/d' -e 's/* \(.*\)/\1/' + elif [[ -d $absdir/.hg ]] then - echo hg + # Hg + hg branch 2>/dev/null + elif [[ -d $absdir/_darcs ]] then - echo darcs-$(basename $absdir) + # Darcs + basename $absdir + else - # Nothing. + # Unknown. if [[ $absdir = "/" ]] then # This is the root directory so exit from the recursion. echo else # Recurse to the parent dir. - print_vcs_type $(dirname $absdir) + print_directory_info $(dirname $absdir) fi fi } -- 2.40.0