Add zsh anything.el plugin
[zsh.git] / .zsh / zaw / sources / command-output.zsh
1 # zaw source for locate
2
3 autoload -U read-from-minibuffer
4
5 function zaw-src-command-output() {
6 local buf
7 read-from-minibuffer "command: "
8 buf=$(${(Q@)${(z)REPLY}})
9 if [[ $? != 0 ]]; then
10 return 1
11 fi
12 : ${(A)candidates::=${(f)buf}}
13 : ${(A)cand_descriptions::=${(f)buf}}
14 actions=( zaw-callback-append-to-buffer )
15 act_descriptions=( "append to buffer" )
16 }
17
18 zaw-register-src -n command-output zaw-src-command-output
19