简体   繁体   中英

Mercurial/Kiln: Compare local with remote, separate repositories?

I'm pretty newbish at this...

  1. I had a zip file on my Harddisk of many sourcecode files.
  2. I unzipped it and have worked on some of the files. I have now 'init'd a repository in the folder. (Obviously it believes there are no changes because it's just been init'd)
  3. I've extracted the zip file (1) into a REMOTE repository. How can I compare the LOCAL (2) with the REMOTE (3) repository? (Am I pushing/cloning/pulling? etc)

Thanks in advance :)

Your current problem is that the two repositories don't share a history and mercurial doesn't know that the different versions of a file are actually the same file.

If I was in your situation, here's what I'd do (and I'd back up any current work first!):

  1. init , add , and commit the remote repository
  2. clone that remote repository locally
  3. using the filesystem, copy your local code folder onto the local repository
  4. diff to make sure that the changes you copied onto the repo are what you expected.
  5. commit those changes as your first changeset
  6. push those changes to the remote repository .

Then you're all set to commit (N times), pull , merge , push , and repeat.

Alternatively, if all you need is to know what has changed, I'd recommend just diff-ing the two folders using a utility like kdiff3 or Beyond Compare 3.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM