equal
deleted
inserted
replaced
104 alias j='jobs ' |
104 alias j='jobs ' |
105 alias e.='e .' |
105 alias e.='e .' |
106 |
106 |
107 # make and change to a directory |
107 # make and change to a directory |
108 md () { mkdir -p "$1" && cd "$1"; } |
108 md () { mkdir -p "$1" && cd "$1"; } |
|
109 |
|
110 myfind() { find . -iname "$1"; } |
|
111 mypath() { |
|
112 local var="$2" |
|
113 [[ -z $var ]] && var=PATH |
|
114 local delim="$3" |
|
115 [[ -z $delim ]] && delim=: |
|
116 local split |
|
117 IFS="$delim" command eval "read -ra split <<< \"\${$var}\"" |
|
118 for dir in "${split[@]}"; do |
|
119 [[ -z "$dir" ]] && continue |
|
120 if [[ -f "$dir"/"$1" ]]; then |
|
121 echo "$dir"/"$1" |
|
122 else |
|
123 ls -d "$dir"/$1 2>/dev/null | cat |
|
124 fi |
|
125 done |
|
126 } |
109 |
127 |
110 # LANG=C for speed. |
128 # LANG=C for speed. |
111 alias grep='GREP_COLOR="31;47" LANG=C grep -n --color=auto' |
129 alias grep='GREP_COLOR="31;47" LANG=C grep -n --color=auto' |
112 alias ls='ls --color=auto' |
130 alias ls='ls --color=auto' |
113 alias minicom='minicom -c on' |
131 alias minicom='minicom -c on' |