Merging files or directories

Each type of object for which you can merge source has default merge tools predefined by Rational Synergy for both the CLI and the GUI. The automerge tool creates a new, controlled version of your file. If the merge is successful, the merge results are written to the new file. When merging directories, the merge tool automatically includes all members from both directories in a new, controlled, merged directory.
If one of the objects to be merged is a member of the current project, Rational Synergy uses the new merged directory in the project. This applies to both root directories and subdirectories.

An area "in conflict" occurs when both versions have changes in the same place relative to the predecessor. If your merged file contains any conflicts, a warning is issued, the tool marks the conflicts so you can find them quickly and easily, then automerge writes the merge results to the new file.

The following example shows how the temporary file is marked:

<<<<<<<file1 (file1 changes recommended)
unique lines in file1
======= (common lines)
unique lines in file2
>>>>>>>file2 (file2 changes recommended)

About this task

ccm merge [[-create_task] | [-t|-task task_spec]]
          [-c|-comment comment_string]
          [-ce|-commentedit] [-cf|-commentfile file_path]
          file_spec1 file_spec2
-c|-comment comment
Specifies a comment that will be appended on all baseline projects and their members when they are checked in to the released state. The comment can contain more than one line and accepts backslash encoded values.

You can use this option with -commentedit and -commentfile. If you use the -commentedit option, the comment displays in the default text editor.

-ce|-commentedit
Specifies that the default text editor will be invoked to allow the comment to be composed and edited. The result saved from the text editor is used as the final comment. You can use this option with the -comment and -commentfile options.
-cf|-commentfile file_path
Specifies that the contents of the specified file will be used for the comment. If you specified -comment, it is appended to that comment. You can use this option with the -commentedit option.
-create_task
Causes a task to be created automatically when Rational Synergy creates the new, merged object version, and associates the new object version with that task.

The task is assigned to the user who performed the merge. The release value of a task is set to the release value of the project in which the new object version is created. If the object version is created outside of a project, the release value is not set.

file_spec1
file_spec1 specifies the first file or directory to be merged. This is used for determining the default next version for the merged object. You can set file_spec1 to be a File specification for one file or directory.
file_spec2
file_spec2 specifies the second file or directory to be merged. You can set file_spec2 to be a File specification for one file or directory. If file_spec1 is a file, then file_spec2 must also be a file. If file_spec1 is a directory, then file_spec2 must also be a directory.
-t|-task task_spec
Specifies the task to associate the new merged version with. If you don't specify -task but you've set a current task, the current task is used by default. See Task specification for further details.

Feedback