hg copy in subdirectory
Matt Mackall
mpm at selenic.com
Fri Jul 1 00:19:44 CDT 2005
On Thu, Jun 30, 2005 at 10:08:38PM -0700, George Garvey wrote:
> Two subdirectories down from the top of the working copy, mv a file
> and then use hg copy to say what has been done. Results in an error
> message. Move back to the top of the working copy, give full
> pathnames, appears to work. (Haven't committed yet.)
> I don't know if this is a bug, but it wasn't what was expected.
Sounds like a bug.
> As a side note: this is the implementation of rename support in hg,
> I hope? It doesn't seem to do what I expect. A diff show main.h being
> removed, and Telephone.h being added. I was expecting to link the
> names so that updates to main.h would continue to be applied to
> Telephone.h.
Currently it's only capable of recording a rename/copy. At this point
nothing actually uses or displays that information. I wanted to get
the recording piece in as soon as possible for various reasons, the
other pieces should happen soon.
Even once Mercurial does completely handle renames, a diff will show
one file being removed and another appearing, because that's the best
diff/patch can do. We'll probably add a note of some sort outside the
diff data itself indicating a rename happened, at least for hg export.
> /home/tmwg/src/X11/devel/iaxclient/simpleclient/iaxcomm
> % mv main.h Telephone.h
> /home/tmwg/src/X11/devel/iaxclient/simpleclient/iaxcomm
> % hg copy main.h Telephone.h
> simpleclient/iaxcomm/Telephone.h does not exist!
> /home/tmwg/src/X11/devel/iaxclient/simpleclient/iaxcomm
> % v Telephone.h
> -rw-r----- 1 tmwg inX 2759 Jun 30 21:12 Telephone.h
> /home/tmwg/src/X11/devel/iaxclient/simpleclient/iaxcomm
> % r hg
> hg copy main.h Telephone.h
> simpleclient/iaxcomm/Telephone.h does not exist!
> /home/tmwg/src/X11/devel/iaxclient/simpleclient/iaxcomm
> % cd ../..
> /home/tmwg/src/X11/devel/iaxclient
> % hg copy simpleclient/iaxcomm/main.h simpleclient/iaxcomm/Telephone.h
> /home/tmwg/src/X11/devel/iaxclient
> % cd -
> ~/src/X11/devel/iaxclient/simpleclient/iaxcomm
> /home/tmwg/src/X11/devel/iaxclient/simpleclient/iaxcomm
> % hg status
> C simpleclient/iaxcomm/Makefile
> C simpleclient/iaxcomm/app.h
> C simpleclient/iaxcomm/calls.cc
> C simpleclient/iaxcomm/frame.cc
> C simpleclient/iaxcomm/main.cc
> A simpleclient/iaxcomm/ConfigFile.h
> A simpleclient/iaxcomm/inXException.h
> A simpleclient/iaxcomm/inXException.cc
> A simpleclient/iaxcomm/makefile
> A simpleclient/iaxcomm/ConfigFile.cc
> A simpleclient/iaxcomm/Telephone.h
> R simpleclient/iaxcomm/main.h
> _______________________________________________
> Mercurial mailing list
> Mercurial at selenic.com
> http://selenic.com/mailman/listinfo/mercurial
--
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial
mailing list