[#145] Simplify the slit utility

This commit is contained in:
Sorin Ionescu 2012-04-14 20:28:28 -04:00
parent 31c5d6e334
commit dbc9dff760

View file

@ -42,7 +42,7 @@ compdef _cd popdll 2> /dev/null
# Prints columns 1 2 3 ... n.
function slit {
awk "{ print $(for n; do print -n "\$$n,"; done | sed 's/,$//') }"
awk "{ print ${(j:,:):-\$${^@}} }"
}
# Finds files and executes a command on them.