[mr] bash-completion rules
ospite at studenti.unina.it
Sat Dec 17 15:14:47 CET 2011
On Sat, 17 Dec 2011 11:58:18 +0000
Adam Spiers <vcs-home at adamspiers.org> wrote:
> 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:
> >> For zsh, it's
> >> /usr/share/zsh/functions/Completion/Unix/_mr
> >> 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.
I obviously agree on that, in theory :)
That's why I asked here first.
> 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.
The cost of (a) is, for example, that bash-completion rules are going to
be copied to the filesystem even if bash itself isn't installed at all.
FWIW I think I could live with some zsh-related files on my system even
if I don't use zsh.
> 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.
I'd really like to avoid duplication, I am willing to update mr bash
completion rules when needed, but I definitely don't want to communicate
those changes twice, it's a waste of time.
I'd say it's up to the author of mr to decide whether he wants to keep
this stuff into his codebase or not. Joey?
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 198 bytes
Desc: not available
More information about the vcs-home