[#145] Simplify the slit utility
This commit is contained in:
parent
31c5d6e334
commit
dbc9dff760
|
@ -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.
|
||||
|
|
Loading…
Reference in a new issue