From: Matthew Martin <phy1729@gmail.com>
To: zsh-workers@zsh.org
Subject: [patch] _rm: Update BSD options
Date: Wed, 7 Sep 2016 07:41:24 -0500 [thread overview]
Message-ID: <20160907124124.rve4rr3uhyn5end4@CptOrmolo.darkstar> (raw)
This also didn't go through.
args=(${args:#*)--*\[*} to catch all the long options without specifying
each one. Also kills the tabs lurking in the file.
- Matthew Martin
diff --git a/Completion/Unix/Command/_rm b/Completion/Unix/Command/_rm
index 4d0dbdb..4a5c9a1 100644
--- a/Completion/Unix/Command/_rm
+++ b/Completion/Unix/Command/_rm
@@ -22,16 +22,24 @@ if _pick_variant gnu=gnu unix --help; then
'(- *)--version[output version information and exit]'
)
else
- args=(${args:#*--(force|recursive)\[*})
+ args=(${args:#*)--*\[*})
case $OSTYPE in
- freebsd*)
+ dragonfly*|freebsd*|netbsd*|openbsd*)
args+=(
'-d[remove directories as well]'
- '(-i)-I[prompt when removing many files]'
- '-P[overwrite files before deleting them]'
- '-v[explain what is being done]'
- '-W[attempt to undelete named files]'
- "-x[don't cross file systems when removing a hierarchy]"
+ '-P[overwrite files before deleting them]'
+ )
+ ;;
+ dragonfly*|freebsd*|netbsd*)
+ args+=(
+ '-v[explain what is being done]'
+ '-W[attempt to undelete named files]'
+ "-x[don't cross file systems when removing a hierarchy]"
+ )
+ ;;
+ dragonfly*|freebsd*)
+ args+=(
+ '(-i)-I[prompt when removing many files]'
)
;;
esac
reply other threads:[~2016-09-07 12:59 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160907124124.rve4rr3uhyn5end4@CptOrmolo.darkstar \
--to=phy1729@gmail.com \
--cc=zsh-workers@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).