script suggestions

mp3geek mp3geek at gmail.com
Sat Jan 23 03:05:33 CST 2010


so hg add should be the first command then? like so? (sorry for being a noob
here)

#!/bin/bash
hg add .
hg update
hg pull --rebase remote
hg pull
hg commit -m "$1"
hg push

On Sat, Jan 23, 2010 at 9:59 PM, Giorgos Keramidas <keramida at ceid.upatras.gr
> wrote:

> On Sat, 23 Jan 2010 21:41:40 +1300, mp3geek <mp3geek at gmail.com> wrote:
> > okay slight modification, so is the order the script okay?
> >
> > #!/bin/bash
> > hg update
> > hg pull --rebase remote
> > hg pull
> > hg add .
> > hg commit -m "$1"
> > hg push
> >
> > If both users (2) use this script, I won't get lost commits, any data
> loss
> > sucks or "mixups"
>
> Why do you need to "hg add" files *after* a rebase?  Are you using
> rebase in a working area that includes local uncommitted changes?
>
> If that's true, then don't do that.  It is a _lot_ safer to first commit
> everything in the local tree and _then_ "hg update" or "hg rebase".
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://selenic.com/pipermail/mercurial/attachments/20100123/59c90ad5/attachment.htm>


More information about the Mercurial mailing list