简体   繁体   中英

How do I use IntelliJ with Subversion, Git and “git-svn”

How do I use IntelliJ with Subversion, Git and "git-svn".

My firm is using subversion for the main repository but I like to use git so I use the command line and issue the following commands

git-svn clone -s http://example.com/my_subversion_repo local_dir

but at the end I have to issue a git-svn dcommit can this be done from within IntelliJ

git-svn dcommit

You can use built-in IntelliJ Git support with SubGit .

There are different options:

  1. If you have administrator access to Subversion repository, you can install SubGit 1.0 into this repository and enable Git access to your SVN repository. This way you can work with created Git repository and SubGit will synchronize all the changes with SVN counterpart.

  2. You can also use SubGit 2.0 (EAP stage at the moment) and synchronize local Git repository with remote SVN repository. So you can keep working with SubGit-enabled local Git repository and all the changes will be replicated to SVN repository.

For more information please refer to SubGit documentation and to comparison with git-svn .

Disclaimer: I'm one of SubGit developers; SubGit is a commercial software with some free options; SubGit 2.0 EAP builds are free to use.

我用IntelliJ确认它现在无法完成..

I use PyCharm (which is based on IntelliJ) and I worked around this by setting up a custom command under "External Tools" as follows:

Name:        dcommit
Program:     git
Arguments:   svn dcommit
Working Dir: $ProjectFileDir$

You can then dcommit in one of the following ways:

  • Select the Tools > External Tools > dcommit menu option
  • Use the Ctrl+Shift+A (Find Action...) popup to execute 'dcommit'
  • Assign a keyboard shortcut in your keymap for even easier execution

It could be a reality in short time: https://github.com/JetBrains/intellij-community/pull/725

Still you need to clone from command line, but after that is merged, other features will be implemented (dcommit, clone, tag)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM