GNU bug report logs - #43509
[PATCH] bash completion: Fix completion for commands and subcommands.

Previous Next

Package: guix-patches;

Reported by: Oleg Pykhalov <go.wigust <at> gmail.com>

Date: Sat, 19 Sep 2020 12:54:02 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Ludovic Courtès <ludo <at> gnu.org>
To: Oleg Pykhalov <go.wigust <at> gmail.com>
Cc: 43509 <at> debbugs.gnu.org
Subject: [bug#43509] [PATCH] bash completion: Fix completion for commands and subcommands.
Date: Mon, 21 Sep 2020 23:41:18 +0200
Hi!

Oleg Pykhalov <go.wigust <at> gmail.com> skribis:

> * etc/completion/bash/guix
> (_guix_complete_command, _guix_complete_subcommand): Fix completion.

Oops, I see.  Could you mention in the commit log that this is a
followup to 3794ce93be8216d8378df7b808ce7f53b1e05a53, which broke it all
(right?).

>  	# Cache the list of commands to speed things up.
> -	_guix_commands="$(guix --help 2> /dev/null \
> -                                     | grep '^  ' | cut -c 2-)"
> +	_guix_commands="$(guix --help 2> /dev/null | awk '/^    [a-z]/ { print $1 }')"

Could we avoid awk?

Thanks,
Ludo’.




This bug report was last modified 4 years and 241 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.