Merging via Command Line

The command line for file merging looks like the following:

CODEMERGE [<Argument1> [<Argument2>] ...]

Command line parameter description:

Parameter Name Parameter Description
/THEIRSFILE,/TF <FilePath> Theirs file name. Required argument.
/MINEFILE,/MF <FilePath> Mine file name. Required argument.
/RESULTFILE,/RF <FilePath> Result file name. Required argument.
/BASEFILE,/BF <FilePath> Base file name. This option makes sense only if /REMOVEFILES is set up.
/THEIRSTITLE,/TT <Title> Theirs file title.
/MINETITLE,/MT <Title> Mine file title.
/RESULTFILE,/RT <Title> Result file title.
/REMOVEFILES Remove input files after merging.
/SOURCECONTROL,/SC <SourceControl> Source control system. It is used for detecting a programming language, as well as for displaying Review Assistant comments in the files opened from the source control client. Available values: tfs, svn, tortoisesvn, git, tortoisegit, hg, tortoisehg, starteam or none (by default).
/ENVIRONMENT <Environment> Environment type to open comparison. You can read more about this parameter in the Choosing Environment on Comparison Opening topic. Available values: visualstudio, standalone or auto (by default).
/BLOCKED,/B Use this option if called Visual Studio is blocked (for example, in integration with Visual SourceSafe).
/TWOWAY,/2 Use 2-way merge.
/NOPROMPT Merge files in silent mode without showing files. Applicable only if a base file is set up.

Example: “C:\Program Files\Devart\Code Compare\CodeMerge.exe” /MF=”c:\Class1.cs” /TF=”c:\Class2.cs” /RF=”c:\Class3.cs”

For more information about file merging, refer to the Merging Files article.