comparison rc/bash @ 285:624eead87f86

Merge.
author Edho Arief <edho@myconan.net>
date Thu, 22 Dec 2011 15:00:25 +0700
parents 87ce8cfdb8d4
children 9d5247df20e9 5fbe9461efea
comparison
equal deleted inserted replaced
284:5ef99c47e636 285:624eead87f86
15 15
16 _org_path="${PATH}" 16 _org_path="${PATH}"
17 export PATH="${HOME}/.ecos_bin:${HOME}/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin" 17 export PATH="${HOME}/.ecos_bin:${HOME}/bin:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/bin:/usr/local/sbin"
18 18
19 shopt -s histappend 19 shopt -s histappend
20 PROMPT_COMMAND='history -a' 20 PROMPT_COMMAND="history -a"
21 export HISTFILESIZE=10000 21 export HISTFILESIZE=10000
22 export HISTCONTROL=ignoredups 22 export HISTCONTROL=ignoredups
23 23
24 export PAGER="less -Rins" 24 export PAGER="less -Rins"
25 export EDITOR=vi 25 export EDITOR=vi
67 [ -f /usr/share/lib/terminfo/?/"${TERM}" ] || export TERM=dtterm 67 [ -f /usr/share/lib/terminfo/?/"${TERM}" ] || export TERM=dtterm
68 if command -v ggrep > /dev/null 2>&1; then 68 if command -v ggrep > /dev/null 2>&1; then
69 _has_gnu_grep=y 69 _has_gnu_grep=y
70 _grep="ggrep" 70 _grep="ggrep"
71 fi 71 fi
72 if command -v gls > /dev/null 2>&1; then
73 _has_gnu_ls=y
74 _ls="gls"
75 fi
76 ;;
77 FreeBSD)
78 # Invalid characters when using en_US.UTF-8.
79 alias man="man -o"
80 # Multi CPU awesomeness.
81 alias top="top -P"
72 ;; 82 ;;
73 OpenBSD) 83 OpenBSD)
74 PATH="${PATH}:/usr/X11R6/bin" 84 PATH="${PATH}:/usr/X11R6/bin"
75 if command -v gls > /dev/null 2>&1; then 85 if command -v gls > /dev/null 2>&1; then
76 _has_gnu_ls=y 86 _has_gnu_ls=y
77 _ls="gls" 87 _ls="gls"
78 elif command -v colorls > /dev/null 2>&1; then 88 elif command -v colorls > /dev/null 2>&1; then
79 alias ls='colorls -F' 89 alias ls="colorls -F"
80 fi 90 fi
81 ;; 91 ;;
82 NetBSD) 92 NetBSD)
83 PATH="${PATH}:/usr/pkg/bin:/usr/pkg/sbin" 93 PATH="${PATH}:/usr/pkg/bin:/usr/pkg/sbin"
84 if command -v gls > /dev/null 2>&1; then 94 if command -v gls > /dev/null 2>&1; then
85 _has_gnu_ls=y 95 _has_gnu_ls=y
86 _ls="gls" 96 _ls="gls"
87 elif command -v colorls > /dev/null 2>&1; then 97 elif command -v colorls > /dev/null 2>&1; then
88 alias ls='colorls -F' 98 alias ls="colorls -F"
89 fi 99 fi
90 ;; 100 ;;
91 CYGWIN*) 101 CYGWIN*)
92 export PATH="${PATH}:${_org_path}" 102 export PATH="${PATH}:${_org_path}"
93 ;; 103 ;;
124 fi 134 fi
125 done 135 done
126 136
127 # Mercurial is optional since it will be inconsistent with ssh ... hg if this one gets priority. 137 # Mercurial is optional since it will be inconsistent with ssh ... hg if this one gets priority.
128 # And use only one. 138 # And use only one.
129 for hgdir in {"${HOME}/app","/opt"}/mercurial; do 139 for hgdir in {"${HOME}/app","/opt"}/mercurial{,/bin}; do
130 if [ -x "${hgdir}/hg" ]; then 140 hgbin="${hgdir}/hg"
141 if [ -x "${hgbin}" ]; then
131 PATH="${PATH}:${hgdir}" 142 PATH="${PATH}:${hgdir}"
143 alias nhg="${hgbin}"
144 break
145 fi
146 done
147
148 for supbindir in {"${HOME}/app","/opt"}/supervisor{,d}/bin; do
149 if [ -d "${supbindir}" ]; then
150 PATH="${PATH}:${supbindir}"
132 break 151 break
133 fi 152 fi
134 done 153 done
135 154
136 case "${TERM}" in 155 case "${TERM}" in