IntelliJ Community . VcsIntegrations

 
VcsIntegrations 

HOME INDEX SEARCH CHANGES GO  
Build #627 contains the drop of VCS API. Before going into API details I’d like to make a small disclaimer first.

This API is in alpha stage (not in beta, like the whole Ariadna), and it might (should) not satisfy your needs. It has bugs and is still work in progress. We’re opening it in the early stage in order to gather as much as possible user feedback, use cases and bug reports. So, don’t hesitate to share your opinion/needs, bug reports and whatever you find appropriate concerning this API.

VCS Integration Philosophy

The main goal of creating VCS integration in IDEA is not just allowing checking in /checking out files from the IDE, but propagating refactoring changes in a simple and consistent way right from IDEA to VCS. A few of the solutions for IDEA currently exist in form of plugins which achieve this goal through listening file events and making the corresponding changes in the VCS at the same moment. But this approach is not appropriate because of the obvious reasons – you shouldn’t propagate changes before you finish your work and not all VCS systems support transaction-based commits.

Thus it was decided that IDEA should track changes for all files itself (through the Local VCS facility). And when the user decides to check in all his changes to VCS, integration subsystem will drive the check in process and issue commands for synchronizing VCS with user changes. It will also consider the VCS capabilities and the pair of remove/add command will issued if rename command is not supported by target VCS.

Thereupon the concept of “current sources” becomes very important. At some point of your work you should say IDEA that your sources are now current (i.e. you’ve synchronized them manually) and then, all file status computations will be computed relative to the marked point. And only the sources, which will be changed in IDEA since they are current, will be proposed to check in when you’re checking in your changes.

This description is rather complex and intricate, but we encourage you to try this way of work because we find it quite comfortable.

VCS API

In order to IDEA perform check in operation to external VCS it requires some sort of bridge to that VCS. The bridge should be the project-level component and implement the com.intellij.openapi.vcs.AbstractVcs interface. The VCS subsystem will automatically discover all integrations available and allow the user to select/configure the necessary one. The common way to provide the VCS integration is packaging it as plugin.

It is important, that VCS integration subsystem will be using the bridge only for performing “Check In Project” operation and for several other simple commands. All complicate actions, branch management etc. should be provided by the concrete plugin itself.

Reference Implementation

The reference implementation for StarTeam (http://www.starbase.com) integration exists. It’s available at public CVS server :pserver:cvs@cvs.intellij.net:/intellij-plugins. Module name: starteam. The plugin itself and its source code are also bundled with latest EAP builds at IDEA_HOME/starteam_plugin. Please read the readme.txt.

Other Integrations

Currently there’re no other integrations for IDEA which are implemented via the VCS API. We are encouraging the user community in developing additional integrations. We are not sure how the process of developing will be organized (any ideas?) but we’ll provide CVS hosting for all VCS integrations (including the StarTeam one).

You may mention that IDEA already has the CVS & SourceSafe integrations. However these are based on internal IDEA APIs. We are planning to rewrite these integrations on the basis of VCS API but most probably it will be done after Ariadna release. So, it might be reasonable for IDEA community to create CVS & SourceSafe integrations themselves from the scratch.

-- MikeAizatsky - 31 May 2002

There's a ClearCase VCS plugin on Sourceforge at http://sourceforge.net/projects/transparent/

However, there appears to be a more up-to-date version at ClearcasePlugin. (DerekFoster)

-- MikeRoberts - 29 Aug 2002

I have created an AccuRev plugin AccuRevPlugin I don't yet know how I will publish the source code but if you are interested in it please drop me a note and we will work it out.

-- JoeyEdelstein - 01 Oct 2002

The MksIntegration plugin integrates MKS Source Integrity into Idea -- EricSheffer - 11 Dec 2003

Potential problems

VcsRenameMoveProblem

-- JacquesMorel - 08 Aug 2002

StarTeamIntegration

-- MatthewInger - 09 Jan 2003

e d i t a t t a c h r e f - b y d i f f s m o r e
Have ideas, requests, problems regarding this site? Send feedback.
Copyright © 2000-2003 by the contributing authors. All materials at intellij.org are the property of the contributing authors.