recovering from a bad merge that lost file permissions

Haszlakiewicz, Eric EHASZLA at transunion.com
Wed Oct 12 20:17:59 UTC 2011


> -----Original Message-----
> From: Matt Mackall [mailto:mpm at selenic.com]
> 
> On Tue, 2011-10-11 at 19:11 +0000, Haszlakiewicz, Eric wrote:
> > I'm having some trouble recovering from a bad merge than happened on
> > Windows and lost a number of file mode permissions on various files
> in
> > my repository.
> 
> This is a known issue. Issue1802 to be specific:
> 
> http://mercurial.selenic.com/bts/issue1802

Oh, bleh. :(  Well, thanks for pointing me at that.  At least I know it's not something I did wrong.

> You'll probably want to recover the exec bits from a known-good
> revision
> and apply them in a non-merge commit at your branch tip:
> 
> hg locate -r 1.0 "set:exec()" | xargs chmod +x

Neat, I didn't know about the locate command.
What's that "set:exec()" syntax from?  The help page for hg locate just says it's a "pattern" so I assumed it was just a regular file wildcard pattern.  Is there a pattern help page somewhere?

> But here's the most important step: you have to get all the Windows
> users out of the pool and working on a known-good checkout, otherwise
> issue1802 will come back and bite you. Also, you'll want any branches
> you merge to agree about these bits or branch merges on Windows will
> also reveal this problem.

Fortunately in this particular case the merge was done on windows just for convenience, so I can just tell people don't do that.

Thanks,
eric


More information about the Mercurial mailing list