diff rc/bash @ 261:00ecebc73c73

Path rearrange.
author Edho Arief <edho@myconan.net>
date Thu, 24 Nov 2011 11:12:04 +0700
parents 6bdfe1746bb1
children 9481aac47ac5
line wrap: on
line diff
--- a/rc/bash	Thu Nov 24 11:07:25 2011 +0700
+++ b/rc/bash	Thu Nov 24 11:12:04 2011 +0700
@@ -16,11 +16,6 @@
 _org_path="${PATH}"
 export PATH="${HOME}/.ecos_bin:${HOME}/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin"
 
-# Custom application I usually install and safe to prioritize
-for i in {"${HOME}/app","/opt"}/{tmux,ruby19,node,tarsnap,symon,nginx}/{bin,sbin}; do
-  [ -d "${i}" ] && PATH="${i}:${PATH}"
-done
-
 shopt -s histappend
 PROMPT_COMMAND='history -a'
 export HISTFILESIZE=10000
@@ -104,6 +99,15 @@
 unset _has_gnu_grep
 unset _ls
 
+# Custom application I usually install and safe to prioritize
+for i in {"${HOME}/app","/opt"}/{tmux,ruby19,node,tarsnap,symon,nginx}/{bin,sbin}; do
+  [ -d "${i}" ] && PATH="${i}:${PATH}"
+done
+
+# Mercurial is optional since it will be inconsistent with ssh ... hg if this one gets priority.
+for hgdir in {"${HOME}/app","/opt"}/mercurial; do
+  [ -x "${hgdir}/hg" ] && PATH="${PATH}:${hgdir}"
+done
 
 case "${TERM}" in
   xterm*|screen*|dtterm*)