diff mbox series

[bug#53268] bash completion: Fix options completion.

Message ID YeHQ30DDDTIedAH7@bluewin.ch
State Accepted
Headers show
Series [bug#53268] bash completion: Fix options completion. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/issue success View issue

Commit Message

Fulbert Jan. 14, 2022, 7:37 p.m. UTC
* etc/completion/bash/guix (_guix_complete_option): Fix options
completion for first subcommand.
---
 etc/completion/bash/guix | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Ludovic Courtès Jan. 16, 2022, 10:50 p.m. UTC | #1
Hi,

Fulbert <fulbert@bluewin.ch> skribis:

> * etc/completion/bash/guix (_guix_complete_option): Fix options
> completion for first subcommand.

Applied, with an example in the commit log.  Thanks!

Ludo’.
Fulbert Jan. 17, 2022, 3:27 p.m. UTC | #2
Hello,

On 16/01/2022 23:50, Ludovic Courtès wrote:
> Applied, with an example in the commit log.  Thanks!

Welcome!
diff mbox series

Patch

diff --git a/etc/completion/bash/guix b/etc/completion/bash/guix
index f262d4d95a..38fb490cb3 100644
--- a/etc/completion/bash/guix
+++ b/etc/completion/bash/guix
@@ -73,7 +73,7 @@  _guix_complete_option ()
     local command="${COMP_WORDS[$1]}"
     local subcommand="${COMP_WORDS[$(($1 + 1))]}"
 
-    if [ $1 -le 1 ]
+    if [ $1 -eq 0 ]
     then
 	command=""
 	subcommand=""