RubyMine 8.0 Help

Commit Changes Dialog

VCS | Commit Changes
View | Tool Windows | Version Control - Local Changes - Context menu of a file or change list - Commit Changes

Use this dialog box to commit (check in) changes from the selected changelist to the repository and, optionally, to create a patch file.

This dialog box consists of several areas:

The options available in this dialog depend on the version control system you are using.

Modified files pane

This section contains a list of files that were modified since the last commit. All files in this list are selected by default. Deselect the check-boxes next to the files that you want to exclude from the current commit.


ItemTooltip and ShortcutDescriptionAvailable in
icon_showDiff Show Differences
Click this button to open the Differences dialog box that points at the inconsistencies between your local working copy of the selected file and the file in the repository. All VCSs
moveChangelistItems Move to Another Changelist
Click this button to add the selected file(s) to another changelist. The Move to Another Changelist dialog box opens where you can select an existing changelist or create a new one. All VCSs
refresh Refresh Changes
Click this button to reload the Changed files tree view so it is up-to-date. All VCSs
rollbackSVN Rollback Click this button to revert all changes made to the local working copy of the selected file(s). All VCSs
edit Jump to source
Click this button to open the source code of the selected file in the editor.All VCSs
vcsToolbarRevertUnchangedIcon Revert Unchanged FilesClick this button to revert the files that have not been modified locally. Subversion
vcsToolbarGroupByDirIcon Group by Directory
Click this button to toggle between the flat view and the directory tree view. All VCSs
Expand or collapse all nodes
Ctrl+NumPad Plus
Ctrl+NumPad -
Click these buttons to expand or collapse all nodes in the directory tree. These buttons are not available in flat view. All VCSs
Change list N/A From this drop-down list, select the changelist that contains the modified files to be checked in or included in the patch. The active changelist is selected by default. All VCSs

The summary under the modified files pane shows statistics on the currently selected changelist, such as the number of modified, new and deleted files. This area also shows how many files of each type are shown, and how many of them will be committed.

Commit Message pane

In this area, enter a comment to the current commit. You cannot commit your changes until you enter some description in the Commit Message field.

This comment will also be used as the name of the patch file, if you decide to create a patch.


Icon and TooltipShortcutDescription
check_commit_message_spelling Check commit message spelling N/A Click this icon if you want to automatically check the spelling in your commit messages.
commit_message_history Commit Message History Ctrl+M Click this icon to invoke the Commit Message History dialog that contains a list of your twenty-five last commits and the corresponding commit messages.

VCS-specific controls

The controls in this section are located in the top-right part of the dialog, and contain the options that are specific for the version control system you are using.

ItemDescriptionAvailable for
Author Use this drop-down list to select the author of the changes that you are going to commit. This may be useful when you are committing changes made by another person. Git
Amend commit Select this check box to replace the previous commit with the current changes (see Git Basics: Undoing Things for details). Git, Mercurial
Keep files locked Select this check box to keep the changed files locked after they are checked in. Subversion

This area is available only if you select the Enable Perforce Jobs Support check box on the Perforce page of the Settings dialog box.

Use the controls in this area to search for Perforce jobs, link jobs to the selected changelist, and detach the currently linked jobs.

  • delete Unlink selected jobs: click this button to detach the selected job from the changelist.
  • icon_openLocalVersion Edit associated jobs: click this button to open the Edit Jobs Linked to Changelist dialog where you can search for available jobs, view their details, and link jobs to the selected changelist.
  • add Find and link job matching the pattern: click this button to start quick search for the job that matches the pattern specified in the text box and attach the job to the changelist.
    In the text box, specify the exact name of the job or a search pattern according to the Perforce jobs syntax rules.

The list box in the bottom of the area displays the jobs that are currently attached to the selected changelist.


Before Submit / Before Commit section

Use the controls in this area to define which additional actions you want RubyMine to perform before committing the selected files.

These controls are available for the following version control systems:

  • Git
  • CVS
  • Subversion
  • Perforce
Reformat code Select this check box to perform code formatting according to the Project Code Style settings.
Rearrange code Select this check box to rearrange your code according to the arrangement rules preferences.
Optimize imports Select this check box to remove redundant import statements.
Perform code analysis Select this check box to run code inspection on the files you are about to commit.
Check TODO (<filter name>) Select this check box to review the TODO items matching the specified filter. Click the Configure link to choose an existing TODO filter, or open the TODO settings page and define a new filter to be applied.
Cleanup Select this check box if you want to automatically apply the current inspection profile to the files you are going to commit.
Update copyright Select this check box to add or update a copyright notice according to the selected copyright profile - scope combination.
Revert unchanged files Select this check box to revert the files that have not been modified.

This option is only available for Perforce.

After Submit / After Commit section

Use the controls in this area to define which additional actions you want RubyMine to perform after committing the selected files.

ItemDescriptionAvailable for
Run tool From this drop-down list, select the external tool that you want RubyMine to launch after the selected changes have been committed. You can select a tool from the list, or click the Browse button browseButton and configure an external tool in the External Tools dialog box that opens. All VCSs
Upload files to From this drop-down list, select the server access configuration to use for uploading the committed files to a local or remote host, a mounted disk, or a directory. To suppress uploading, choose None. To add a server configuration to the list, click browseButton and fill in the required fields in the Add Server dialog that opens. All VCSs
Always use selected server Select this check box to always upload files to the selected server access configuration.

The drop-down list and the check box are only available if the Remote Hosts Access plugin is enabled.

All VCSs
Tag committed files Select this check box to assign a tag to the committed files and type the name of the tag. To replace a previously assigned tag with a new one, select the Override existing tags option. CVS
Auto-update after commit Select this check box to automatically update your project after the commit. Enabling this option will help prevent your working copy against the mixed-revision state.

The mixed-revision state of a working copy may affect the Move and Rename refactoring applied to folders, in which case items in revisions different from the moved subtree root will be tracked separately, which can be confusing.

When the Auto-update after commit option is enabled:

  • Merge will fail with an error if the merge target is a mixed-revision working copy.
  • Your own changes will never cause a 409 conflict.


Details pane

The Details pane is hidden by default. To unfold it, click the arrow button unfold next to the pane title.

In this pane you can explore the differences between the base repository version of the selected file, and the version you are about to commit.


ItemTooltip and ShortcutDescription
arrowUparrowDownPrevious Difference / Next Difference Shift+F7 F7
Use these buttons to jump to the next/previous difference.

When the last/first difference is hit, RubyMine suggests to click the arrow buttons F7/Shift+F7 once more and compare other files, depending on the Go to the next file after reaching last change option in the Differences Viewer settings.

This behavior is supported only when the Differences Viewer is invoked from the Version Control tool window.

Compare Previous/Next File
Click these buttons to compare the local copy of the previous/next file with its update from the server.
edit Jump to Source
Click this button to open the selected file in the active pane in the editor. The caret will be placed in the same position as in the Differences Viewer.
Viewer type
Use this drop-down list to choose the desired viewer type. The default viewer has two panels; the unified viewer has one panel only.

Both types of viewers enable you to

  • Edit, for example, type text. Note that one can change text only in the right-hand part of the default viewer, or, in case of the unified viewer, in the lower ("after") line.
  • Perform the Apply/Append/Revert actions.
Use this drop-down list to define how the differences viewer should treat white spaces in the text.
  • Do not ignore: white spaces are important, and all differences are highlighted. This option is selected by default.
  • Trim whitespaces: ("\t", " ") , if they appear in the end and in the beginning of a line.
    • If two lines differ in trailing whitespaces only, these lines are considered equal.
    • If two lines are different, such trailing whitespaces are not highlighted in the By word mode.
  • Ignore whitespaces: white spaces are not important, regardless of their location in the source code.
  • Ignore whitespaces and empty lines: the following entities are ignored:
    • all whitespaces (as in the 'Ignore whitespaces' option)
    • all added or removed lines consisting of whitespaces only
    • all changes consisting of splitting or joining lines without changes to non-whitespace parts.
      For example, changing a b c to a \n b c is not highlighted in this mode.
Highlighting mode
Select the way differences granularity is highlighted.
The available options are:
  • Highlight words: the modified words are highlighted
  • Highlight lines: the modified lines are highlighted
  • Highlight split changes: if this option is selected, big changes are split into smaller 'atomic' changes.
    For example, A \n B vs. A X \n B X will be treated as two changes instead of one.
  • Do not highlight: if this option is selected, the differences are not highlighted at all. This option is intended for significantly modified files, where highlighting only introduces additional difficulties.
collapseAll Collapse unchanged fragmentsClick this button to collapse all unchanged fragments in both files. The amount of non-collapsible unchanged lines is configurable in the Diff settings page.
sync_scrolling Synchronize scrolling Click this button to scroll both differences panes simultaneously. If this button is released, each pane can be scrolled independently.
disable_editing Disable editing Click this button to enable editing of the local copy of the selected file, which is disabled by default. When editing is enabled, you can make last-minute changes to the modified file before committing it.
cogwheel_blue Editor settings Click this button to open a drop-down list of available options. Select or clear these options to show or hide line numbers, indentation guides, white spaces, and soft wraps.
external_toolShow diff in external toolClick this button to invoke an external differences viewer, specified in the External Diff Tools settings page.

This button only appears on the toolbar when the Use external diff tool option is enabled in the External Diff Tools settings page.

Click this button to show the corresponding help page.

Note that the options listed above are available for text files only. RubyMine cannot compare binary files, so most commands will be unavailable for them.

Submit / Commit button

Click this button to commit the selected files, or hover your mouse over this button to display one of the following available commit options:

  • Commit and Push: select this option to push the changes to the remote repository immediately after the commit. This option is available if you are using Git or Mercurial as a version control system.
  • Create MQ Patch: select this option to create an MQ patch based on your changes. This option is only available if you are using Mercurial as a version control system.
  • Create Patch: select this option if you want RubyMine to generate a patch based on the changes you are about to commit. In the Create Patch dialog that opens, type the name of the patch file and specify whether you need a reverse patch.
  • Remote Run: select this option to run your personal build. This option is only available when you are logged in to TeamCity. Refer to TeamCity plugin documentation for details.

See Also

Last modified: 5 November 2015