zsh-workers
 help / color / mirror / code / Atom feed
From: Arseny Maslennikov <arseny@altlinux.org>
To: zsh-workers@zsh.org
Cc: Arseny Maslennikov <arseny@altlinux.org>
Subject: [PATCH] _rpmbuild: complete non-options after `rpmbuild -[btr]?'
Date: Sat, 27 Feb 2021 14:55:01 +0300	[thread overview]
Message-ID: <20210227115501.332503-1-arseny@altlinux.org> (raw)

The "tmp" array is being filled up with specstrings for _arguments in
all three cases, but is unused afterwards. Thus non-option arguments
after e. g. `rpmbuild -ba' are not being offered as completion matches.
---
 Completion/Redhat/Command/_rpm | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Completion/Redhat/Command/_rpm b/Completion/Redhat/Command/_rpm
index e3469245f..6e4a1e6a1 100644
--- a/Completion/Redhat/Command/_rpm
+++ b/Completion/Redhat/Command/_rpm
@@ -283,6 +283,7 @@ _rpm () {
     build_t) tmp=( '*:tar file:_files -g "*.(#i)tar(.*|)(-.)"' ) ;|
     build_?)
       _arguments -s -C $buildopts $commonopts $pathopts \
+          "${tmp[@]}"
       ;;
     checksig)
       _arguments -s -C \!-K \
-- 
2.29.2



             reply	other threads:[~2021-02-27 11:55 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-27 11:55 Arseny Maslennikov [this message]
2021-02-27 13:24 ` Daniel Shahaf
2021-02-27 14:36   ` Arseny Maslennikov

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=20210227115501.332503-1-arseny@altlinux.org \
    --to=arseny@altlinux.org \
    --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).