Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-07 Thread SZEDER Gábor
> > OK how about some thing like this fixup patch? __gitcomp_builtin now > > allows to add extra options as well as remove some. > > > > -- 8< -- > > __gitcomp_builtin () > > { > > + local incl="$2" > > + local excl="$3" > > + options="$(__git ${cmd/_/ } --git-completio

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-05 Thread Eric Sunshine
On Mon, Feb 5, 2018 at 4:56 AM, Duy Nguyen wrote: > On Thu, Feb 01, 2018 at 02:16:46PM -0500, Eric Sunshine wrote: >> On Thu, Feb 1, 2018 at 5:21 AM, Duy Nguyen wrote: >> > On Thu, Feb 1, 2018 at 4:54 PM, Eric Sunshine >> > wrote: >> >> I don't see that as convincing argument for two classes of

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-05 Thread Duy Nguyen
On Mon, Feb 5, 2018 at 5:46 PM, Ævar Arnfjörð Bjarmason wrote: > > On Wed, Jan 31 2018, Eric Sunshine jotted: > >> On Wed, Jan 31, 2018 at 6:05 AM, Nguyễn Thái Ngọc Duy >> wrote: >>> This option is designed to be used by git-completion.bash. For many >>> simple cases, what we do in there is usua

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-05 Thread Ævar Arnfjörð Bjarmason
On Wed, Jan 31 2018, Eric Sunshine jotted: > On Wed, Jan 31, 2018 at 6:05 AM, Nguyễn Thái Ngọc Duy > wrote: >> This option is designed to be used by git-completion.bash. For many >> simple cases, what we do in there is usually >> >> __gitcomp "lots of completion options" >> >> which has to

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-05 Thread Duy Nguyen
On Thu, Feb 01, 2018 at 02:16:46PM -0500, Eric Sunshine wrote: > On Thu, Feb 1, 2018 at 5:21 AM, Duy Nguyen wrote: > > On Thu, Feb 1, 2018 at 4:54 PM, Eric Sunshine > > wrote: > >> I don't see that as convincing argument for two classes of "no > >> complete". Since git-completion.bash already sp

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-01 Thread Eric Sunshine
On Thu, Feb 1, 2018 at 5:21 AM, Duy Nguyen wrote: > On Thu, Feb 1, 2018 at 4:54 PM, Eric Sunshine wrote: >> I don't see that as convincing argument for two classes of "no >> complete". Since git-completion.bash already special-cases >> rebase/am/cherry-pick for --continue|--abort|--skip, it is no

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-01 Thread Duy Nguyen
On Thu, Feb 1, 2018 at 4:54 PM, Eric Sunshine wrote: > On Wed, Jan 31, 2018 at 7:05 PM, Duy Nguyen wrote: >> On Thu, Feb 1, 2018 at 4:04 AM, Eric Sunshine >> wrote: >>> On Wed, Jan 31, 2018 at 6:05 AM, Nguyễn Thái Ngọc Duy >>> wrote: Dangerous/Unpopular options could be hidden with

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-02-01 Thread Eric Sunshine
On Wed, Jan 31, 2018 at 7:05 PM, Duy Nguyen wrote: > On Thu, Feb 1, 2018 at 4:04 AM, Eric Sunshine wrote: >> On Wed, Jan 31, 2018 at 6:05 AM, Nguyễn Thái Ngọc Duy >> wrote: >>> Dangerous/Unpopular >>> options could be hidden with the new "NOCOMPLETE" flag. >> >> I wonder if this option should b

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-01-31 Thread Duy Nguyen
On Thu, Feb 1, 2018 at 4:04 AM, Eric Sunshine wrote: > On Wed, Jan 31, 2018 at 6:05 AM, Nguyễn Thái Ngọc Duy > wrote: >> This option is designed to be used by git-completion.bash. For many >> simple cases, what we do in there is usually >> >> __gitcomp "lots of completion options" >> >> whic

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-01-31 Thread Eric Sunshine
On Wed, Jan 31, 2018 at 6:05 AM, Nguyễn Thái Ngọc Duy wrote: > This option is designed to be used by git-completion.bash. For many > simple cases, what we do in there is usually > > __gitcomp "lots of completion options" > > which has to be manually updated when a new user-visible option is >

Re: [PATCH v2 01/41] parse-options: support --git-completion-helper

2018-01-31 Thread Eric Sunshine
On Wed, Jan 31, 2018 at 6:05 AM, Nguyễn Thái Ngọc Duy wrote: > This option is designed to be used by git-completion.bash. For many > simple cases, what we do in there is usually > > __gitcomp "lots of completion options" > > which has to be manually updated when a new user-visible option is >

[PATCH v2 01/41] parse-options: support --git-completion-helper

2018-01-31 Thread Nguyễn Thái Ngọc Duy
This option is designed to be used by git-completion.bash. For many simple cases, what we do in there is usually __gitcomp "lots of completion options" which has to be manually updated when a new user-visible option is added. With support from parse-options, we can write __gitcomp "$(git