[mr] bash-completion rules
vcs-home at adamspiers.org
Sat Dec 17 12:58:18 CET 2011
On Sat, Dec 17, 2011 at 11:20 AM, Antonio Ospite
<ospite at studenti.unina.it> wrote:
> On Wed, 7 Dec 2011 17:11:52 +0100
> Richard Hartmann <richih.mailinglist at gmail.com> wrote:
>> On Wed, Dec 7, 2011 at 16:21, Adam Spiers <vcs-home at adamspiers.org> wrote:
>> > On Wed, Dec 7, 2011 at 2:34 PM, Antonio Ospite <ospite at studenti.unina.it> wrote:
>> >> or where else?
>> > Good question - I will probably write zsh completion rules for mr
>> > at some point too.
>> For zsh, it's
>> but just send it to zsh-workers at zsh.org once done.
> That's a good point, maybe I too will just send the bash rules to the
> bash-completion project instead of having them in 'mr'.
Personally I always thought that was the wrong approach, because
completion rules are necessarily coupled to functionality, e.g. if mr
learns a new option `--foo' then the completion rules need to learn it
at the same time. Therefore it makes sense for the completion rules
to live in the same repository as the program, and to be installed at
the same time the program is installed.
Unfortunately, in practice this isn't perfect, because (a) a program's
upstream maintainer(s) and its completion rule maintainer(s) are often
not the same people (e.g. the maintainer of program X may not ever use
bash/zsh) and (b) there is no official standard on where an
installation should drop a new completion function.
Therefore in practice, it's up to the distribution packagers to get
this right, but their job is made a lot easier if the upstream tarball
contains the completion functions, and all they have to do is ensure
that the rpm/deb/whatever places that file in the correct location,
which ideally would override the completion function shipped with the
So my recommendation would be: ship completion rules with mr, but also
submit them to the shell project.
More information about the vcs-home