update while pushing
Matt Mackall
mpm at selenic.com
Mon Jul 11 17:03:58 UTC 2005
On Sun, Jul 10, 2005 at 10:25:27PM -0400, Theodore Ts'o wrote:
> Right now, I'm doing this with a local shell script, which works well
> enough for my application. However, it would be nice if there could
> be "post-push" trigger scripts in .hg which could do any number of
> things (e-mail notifications to mailing lists, execute an "hg update"
> if there is some reason why you do want the destination working
> directory to be updated, etc.)
Adding a hook is trivial:
if not self.hook("push"):
return 1
> > Also, update often needs to be interactive. The best (only) way to
> > deal with this is with an actual interactive session.
>
> It would also be nice if "hg push" had a mode where if remote
> repository contains changesets which are not in the local repository,
> the push is aborted with a warning message so the user can do an "hg
> pull" and a merge before doing the "hg push". BitKeeper does this,
> and it's a very nice safety belt feature, IMHO. With this feature,
> then there is no need for the update to be interactive.
Interesting. This isn't generally necessary with hg as we allow
multiple heads. But it should also be pretty easy to add: findoutgoing
is wrapped around findincoming so we are already calculating both sets.
--
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial
mailing list