Jump to content

mergetool configuration


DJMatty

Recommended Posts

Hi

 

Is it possible to configure semantic merge to default the text based merge tool to ignore whitespace and eol differences?

 

I set it to ignore whitespace & eol in the options menu, but it reverts back to just ignoring eol everytime it runs.

 

Link to comment
Share on other sites

Hi,

 

When configuring SemanticMerge there is an option to configure the comparison method:

 

comparisonMethod:    {-i | --ignore}={none | eol | whitespaces | eol&whitespaces}

 

eg: (you can modify one of the scripts we provide in "samples" folder)

 

::  ..\..\..\semanticmergetool.exe -s=src.cs -b=base.cs -d=dst.cs -r=semanticmergetoolresult.cs 
-emt="..\..\..\mergetool.exe -b=""@basefile"" -bn=""@basesymbolic"" -s=""@sourcefile"" -sn=""@sourcesymbolic"" -d=""@destinationfile"" -dn=""@destinationsymbolic"" -r=""@output"" -t=""@filetype"" -i="eol&whitespaces" -e=""@fileencoding""" 
-edt="..\..\..\mergetool.exe  -s=""@sourcefile"" -sn=""@sourcesymbolic"" -d=""@destinationfile"" -dn=""@destinationsymbolic"" -t=""@filetype"" -i="eol&whitespaces" -e=""@fileencoding"""

You can see that I´ve modified the "-i" parameter in the external merge tool  and external diff tool parameters --> eol&whitespaces.

 

This way, your chosen option shouldn´t be reverted back.

 

Regards,

Carlos

Link to comment
Share on other sites

Ah thanks Carlos! I didn't realise the -i parameter also worked in semanticmerge.exe

 

I had been speaking with Pablo and he suggested using a semanticmerge.conf file to control mergetool.exe and supply the -i parameter to it that way, which works too.

 

I'll try changing my git config settings to add the -i parameter, that way I can get rid of the .conf file.

 

Thanks

 

Matt

Link to comment
Share on other sites

Hi Matt,

 

Yes, we have recently added the possibility to use a configuration file. This way you don't need to setup a long configuration line (potentially having trouble with scape characters) in your version control diff and merge tool configuration because every argument will be defined there.

 

http://www.semanticmerge.com/sm-guides/main.shtml#Launchoptionsconfigurationfile

 

Regards,

Carlos

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...