Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
[PATCH] killall completion for FreeBSD
- X-seq: zsh-workers 20177
- From: Jean-Baptiste Quenot <jb.quenot@xxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxx
- Subject: [PATCH] killall completion for FreeBSD
- Date: Wed, 21 Jul 2004 23:15:33 +0200
- Mail-followup-to: Jean-Baptiste Quenot <jb.quenot@xxxxxxxxxxx>, zsh-workers@xxxxxxxxxx
- Mailing-list: contact zsh-workers-help@xxxxxxxxxx; run by ezmlm
Dear workers,
I noticed that killall completion does not work on FreeBSD. This patch
addresses the issue, as the completion was originally only intended for
GNU/Linux. Indeed, FreeBSD uses a slightly different syntax for
expressing ps output options.
Best regards,
--
Jean-Baptiste Quenot
http://caraldi.com/jbq/
--- Completion/Unix/_killall.orig Wed Jul 21 22:31:12 2004
+++ Completion/Unix/_killall Wed Jul 21 23:13:13 2004
@@ -4,6 +4,10 @@
_alternative \
'signals:: _signals -p' \
'processes:process:{ compadd "$expl[@]" ${${${${(f)"$(_call_program processes-names ps ${${EUID/(#s)0(#e)/xa}//[0-9]#/} ho cmd 2> /dev/null)"//[][\(\)]/}:#(ps|COMMAND|-*)}%%\ *}:t} }'
+elif [[ $service = killall && "$OSTYPE" = freebsd* ]]; then
+ _alternative \
+ 'signals:: _signals -p' \
+ 'processes:process:{ compadd "$expl[@]" ${${${${(f)"$(_call_program processes-names ps ${${EUID/(#s)0(#e)/xa}//[0-9]#/}ho comm 2> /dev/null)"//[][\(\)]/}:#(ps|COMMAND|-*)}%%\ *}:t} }'
else
_signals -p
fi
Messages sorted by:
Reverse Date,
Date,
Thread,
Author