Re: RFC: a plugin architecture for git extensions?
- From
Jonathan Nieder <jrnieder@gmail.com>
- Date
- Apr 27, 2011, 03:58 UTC
- Message-ID
- <20110427035825.GA4546@elie>
- In-Reply-To
- <BANLkTinh3v1o7t4HRwzZtFW--zu-j4U3kw@mail.gmail.com>
Hi Jon,
Jon Seymour wrote:
Show 6 quoted lines
> Has anyone ever given consideration to git supporting a plugin > architecture for git extensions? > > The idea would be to provide a consistent way to install, and address > extensions to the core git functionality in a manner that does not > require the extension to actually be integrated into the git core.
I haven't looked into 'git work' yet, but for my own private tweaks, two mechanisms have sufficed:
* adding a program named git-foo to the $PATH introduces a 'git foo' command. For the git command look and feel, scripts tend to start with
. "$(git --exec-path)"/git-sh-setup
(see git-sh-setup(1) for details).
* various existing git commands can have their behavior modified through configuration and hooks.
Does 'git work' require changing the behavior of existing commands, and if so, are there hooks that could be introduced to help in doing that?