Embedded Studio VCS configuration

From SEGGER Wiki
Revision as of 10:52, 7 September 2017 by Nino (talk | contribs) (Created page with "SEGGER Embedded Studio (ES) offers the possibility to configure an external Version Control System (VCS). This article will explain how to set up such a system and how to use...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

SEGGER Embedded Studio (ES) offers the possibility to configure an external Version Control System (VCS). This article will explain how to set up such a system and how to use it.

Set up source control system

SEGGER Embedded Studio supports Subversion, Git, and Mercurial as source-control systems. To enable SEGGER Embedded Studio to utilize source-control features, you need to install the appropriate command line client on your operating system for the source-control systems that you will use.

Once you have installed the command line client, you must configure SEGGER Embedded Studio to use it.

To configure Subversion:

  1. Choose Tools > Options.
  2. Select the Source Control category in the options dialog.
  3. Set the Executable environment option of the Subversion Options group to point to Subversion svn command. On Windows operating systems, the Subversion command is svn.exe.

To configure Git:

  1. Choose Tools > Options.
  2. Select the Source Control category in the options dialog.
  3. Set the Executable environment option of the Git Options group to point to Git git command. On Windows operating systems, the Git command is git.exe.

To configure Mercurial:

  1. Choose Tools > Options.
  2. Select the Source Control category in the options dialog.
  3. Set the Executable environment option of the Mercurial Options group to point to Git hg command. On Windows operating systems, the Git command is hg.exe.
Example with SVN

Use source control in ES

To use the set up source control in ES you can either go to Project > VCS and choose one of the many source control options available or to use it on a single file basis right-click the file and from the shortcut menu choose Source Control

Set up external diff tool

To show the differences between the file in the project and the version checked into source control you can use the build in diff tool:

  1. In the Project Explorer, right-click the file.
  2. From the shortcut menu, choose Source Control > Compare.
ES internal diff tool

You can also use an external diff tool in preference to the built-in SEGGER Embedded Studio diff tool. To define the diff command line SEGGER Embedded Studio generates, choose Tools > Options > Source Control > Diff Command Line. The command line is defined as a list of strings to avoid problems with spaces in arguments. The diff command line can contain the following macros:

  • $(localfile): The filename of the file in the project.
  • $(remotefile): The filename of the latest version of the file in source control.
  • $(localname): A display name for $(localfile).
  • $(remotename): A display name for $(remotefile).
Cmd line example with WinMerge