简体   繁体   中英

Mercurial; diffing a file from two branches using Beyond Compare and unable to save

I was trying to diff two files from two of my branches using Beyond Compare. Unfortunately although the display is fine and the diffs are displayed correctly, both of the file paths are temporary so I can't save.

I used this command to start the diff; hg bcomp --rev default:"Bug 70180" <filename>

I appreciate that you should only be able to save to the branch you're currently using, but this really limits the usefulness of a diff unless I can find a way round it. Thanks,

The command you are issuing is to compare a range of changesets ( <rev>:<rev> ), assuming 2 in your case, so Mercurial gets both changeset files as temporary files before starting bcomp . To compare the current file (the one you want to modify and save) and the file from another revision, just give it the revision to compare to.

In your case, try this command line instead:

hg bcomp --rev "Bug 70180" <filename>

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