Combine xls with TortoiseHg

I want to merge two MSX.xls files when updating a repository using TortoiseHg, and I get the following error:

tool tortoisemerge can't handle binary tool kdiff3 can't handle binary tool tortoisemerge can't handle binary tool docdiff can't handle binary abort: response expected 

When I add these lines to the hgrc file:

 [merge-patterns] **.xls = docdiff 

I get another error:

 merging test.xls merging test.xls failed! 0 files updated, 0 files merged, 0 files removed, 1 files unresolved 

What am I doing wrong? When I run docdiff from the command line, it succeeds.

+4
source share
3 answers

I solved the problem. It looks like I tried automatic merging instead of manual merging. Automatic binary merging is not supported, but I figured out how to start docdiff from the TortoiseHG interface.

So the answer is: to combine .xls files with TortoiseHg, you need to use manual merging with docdiff. TortoiseHg does not start docdiff during automatic merge.

+1
source

Hg tools cannot combine binary files, only text files (most source code files are text based). What you can do is try to save your XLS file in CSV format (comma separated). This is a regular text file (which can be opened, for example, using notepad). Hg tools should be able to combine this type of file.

If you want to know more about why XLS files cannot be combined. Try to open the XLS file with Notepad, you will see that this is a lot of gibberish, Hg can not understand this gibberish without knowing the specifications of the XLS file (which is not).

0
source
  • In Explorer, right-click on the repository and clone it into a temporary cloning folder.
  • Because Excel does not support opening two files with the same name, rename it to a temporary clone so that it can be opened in Excel.
  • Open both versions of the spreadsheet in Excel and manually copy the changes to the main repository.
  • Check the file allowed in the main repository.
  • Complete the merge.
  • Delete the temporary clone.
0
source

Source: https://habr.com/ru/post/1348096/


All Articles