mercurial status and keyword extension problem

Christian Ebert blacktrash at gmx.net
Tue Sep 16 14:13:55 CDT 2008


* George Feinberg on Tuesday, September 16, 2008 at 11:45:17 -0400
> I am seeing odd Mercurial behavior.  I'm using version 1.0.2 on OS X  
> Leopard.
> I am using multiple branches in a single repository.
> 
> Problem (names changed):
> 
> I clone the repository to a branch:
> hg clone -r xyz_branch myrepo mynewrepo
> cd mynewrepo
> hg update -r xyz_branch
> 
> Then I do this:
> hg status
> 
> And some number of the files appear as modified.  These files cannot  
> be reverted (revert "works" but doesn't
> change the status).  hg diff on the files show no changes.

Needless to say, this shouldn't happen. Needless to say, I can't
reproduce it ;)

> HOWEVER... I did some debugging.  First, I changed my version
> of Mercurial to 0.95 plus -- from mercurial.berkwood.com:
> (2008-02-25: Version 0.9.5 + fixes through 2008-02-25
>          * Mercurial 0.9.5-434139080ed4 for OS X 10.5
> 
> Interestingly, for already-created clones it has the same
> behavior as 1.0.2, but when I created new clones they were fine.

I'll make tests switching these versions. 

> I then tried committing the "modified" files.  This worked and
> lo and behold, there was a diff (hg outgoing -p) entirely
> related to keyword expansion (or not).  My repository definitely has  
> $Id$ keywords
> (from CVS originally).

You converted from cvs?

> I had added this to my .hgrc file a while back:

Repo-wise .hg/hgrc or ~/.hgrc or ... ? Even if it means more
work, I'd recommend using .hg/hgrc (repowise).

> [keyword]
> # expand keywords in all files
> ** =

Not recommended. Slows down, and rises risk of inadverted keyword
expansions.

> # except in the build directories
> build** = ignore

Are these files tracked? Otherwise no need to do that setting.
 
> By removing this from my .hgrc file I "fixed" my problem.   So... the  
> question is whether the
> behavior I've seen is expected for some keyword expansion or if it's a  
> bug
> in the extension.

Perhaps. Or rather when using the extension while upgrading from
0.9.5 plus to 1.0.2. Of course, again, this should not happen.

> If the former, then how can it be worked around and  if the
> latter, where should it be reported?

I am the who committed the keyword extension crime, so I guess
this was a good place to report; I hope to have more time to look
into this tomorrow.

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/


More information about the Mercurial mailing list