Clone hook?

Christian Ebert blacktrash at gmx.net
Tue Jun 9 14:58:22 CDT 2009


* Stephen Rasku on Tuesday, June 09, 2009 at 12:41:07 -0700
> We have converted one team at work from CVS to Mercurial.  We
> originally believed that all the code was isolated but there is one
> include directory that is used by other teams in the company.
> Although we are aware of drawbacks to this situation, it has been
> decided that that specific directory will remain in CVS.  Is there a
> way to run a "cvs checkout" when cloning a repository?  There doesn't
> seem to be a "clone" hook.  Does such a thing even make sense?
> 
> I can have the developer manually run the checkout when cloning the
> directory but if there are better ideas I'd like to hear them.

There are the pre- and post-<command> hooks:

post-<command>
       Run after successful invocations of the associated command. The contents
       of the command line are passed as $HG_ARGS and the result code in
       $HG_RESULT. Hook failure is ignored.

pre-<command>
       Run before executing the associated command. The contents of the command
       line are passed as $HG_ARGS. If the hook returns failure, the command
       doesn't execute and Mercurial returns the failure code.

c
-- 
  Was heißt hier Dogma, ich bin Underdogma!
[ What the hell do you mean dogma, I am underdogma. ]
_F R E E_  _V I D E O S_  http://www.blacktrash.org/underdogma/
                          http://www.blacktrash.org/underdogma/index-en.html


More information about the Mercurial mailing list