[Fix #60] Do not use parentheses in function names

This commit is contained in:
Sorin Ionescu 2012-03-23 14:57:51 -04:00
commit 6a9a4ea8d6
22 changed files with 66 additions and 67 deletions

View file

@ -14,42 +14,42 @@ alias history-stat="history | awk '{print \$2}' | sort | uniq -c | sort -n -r |
alias http-serve='python -m SimpleHTTPServer'
# Makes a directory and changes to it.
function mkdcd() {
function mkdcd {
[[ -n "$1" ]] && mkdir -p "$1" && cd "$1"
}
compdef _mkdir mkdcd
# Changes to a directory and lists its contents.
function cdll() {
function cdll {
builtin cd "$1" && ll
}
compdef _cd cdll
# Pushes an entry onto the directory stack and lists its contents.
function pushdll() {
function pushdll {
builtin pushd "$1" && ll
}
compdef _cd pushdll
# Pops an entry off the directory stack and lists its contents.
function popdll() {
function popdll {
builtin popd "$1" && ll
}
compdef _cd popdll
# Prints columns 1 2 3 ... n.
function slit() {
function slit {
awk "{ print $(for n; do print -n "\$$n,"; done | sed 's/,$//') }"
}
# Displays user owned process status.
function pmine() {
function pmine {
ps "$@" -U "$USER" -o pid,%cpu,%mem,command
}
compdef _ps pmine
# Finds files and executes a command on them.
function find-exec() {
function find-exec {
find . -type f -iname "*${1:-}*" -exec "${2:-file}" '{}' \;
}