Probably an easy one but I haven't dug up anything with the usual search queries so I thought I'd ask here. Basically I'm trying to rearrange my repo; for example:
mkdir test
hg mv DirectoryOfStuff test/
Mercurial moves most of the contents but it leaves some directories an files behind. So far I haven't seen any pattern to what it moves and what it doesn't.
Is there an obvious rule or command that I'm missing?
Thanks!
Once you decide that a file no longer belongs in your repository, use the hg remove command. This deletes the file, and tells Mercurial to stop tracking it (which will occur at the next commit). A removed file is represented in the output of hg status with a “ R ”.
hg folder keeps track of one repo only. If you've got one in your home directory it means your home directory is under version control.
Strictly speaking, the term repository refers to the directory named . hg (dot hg) in the repository root directory. The repository root directory is the parent directory of the . hg directory. Mercurial stores its internal data structures – the metadata – inside that .
hg mv
moves tracked files, not ignored or unknown ones.
To move everything and still record tracked files as a moved, use a regular (non-hg) move command and then hg addremove -s 100
. The addremove command retrofits your file operations as add/remove/rename/move.
Use less than 100 to allow changes in file content & names.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With