Search in sources :

Example 11 with CvsEnvironment

use of com.intellij.cvsSupport2.connections.CvsEnvironment in project intellij-community by JetBrains.

the class CvsCommittedChangesProvider method getLocationFor.

@Nullable
public CvsRepositoryLocation getLocationFor(final FilePath root) {
    if (!CvsUtil.fileIsUnderCvs(root.getIOFile())) {
        return null;
    }
    final VirtualFile rootDir = root.isDirectory() ? root.getVirtualFile() : root.getVirtualFileParent();
    final String module = CvsUtil.getModuleName(root);
    final CvsEnvironment connectionSettings = CvsEntriesManager.getInstance().getCvsConnectionSettingsFor(rootDir);
    return new CvsRepositoryLocation(root.getVirtualFile(), connectionSettings, module);
}
Also used : VirtualFile(com.intellij.openapi.vfs.VirtualFile) CvsEnvironment(com.intellij.cvsSupport2.connections.CvsEnvironment) Nullable(org.jetbrains.annotations.Nullable)

Aggregations

CvsEnvironment (com.intellij.cvsSupport2.connections.CvsEnvironment)4 File (java.io.File)4 CvsResult (com.intellij.openapi.cvsIntegration.CvsResult)3 VirtualFile (com.intellij.openapi.vfs.VirtualFile)3 CvsRootProvider (com.intellij.cvsSupport2.connections.CvsRootProvider)2 CvsOperationExecutor (com.intellij.cvsSupport2.cvsExecution.CvsOperationExecutor)2 CommandCvsHandler (com.intellij.cvsSupport2.cvshandlers.CommandCvsHandler)2 AnnotateOperation (com.intellij.cvsSupport2.cvsoperations.cvsAnnotate.AnnotateOperation)2 ProcessCanceledException (com.intellij.openapi.progress.ProcessCanceledException)2 FilePath (com.intellij.openapi.vcs.FilePath)2 List (java.util.List)2 Nullable (org.jetbrains.annotations.Nullable)2 CheckoutCommand (org.netbeans.lib.cvsclient.command.checkout.CheckoutCommand)2 Revision (org.netbeans.lib.cvsclient.command.log.Revision)2 CvsChangeList (com.intellij.cvsSupport2.changeBrowser.CvsChangeList)1 CvsApplicationLevelConfiguration (com.intellij.cvsSupport2.config.CvsApplicationLevelConfiguration)1 CvsConnectionSettings (com.intellij.cvsSupport2.connections.CvsConnectionSettings)1 CvsRootException (com.intellij.cvsSupport2.connections.CvsRootException)1 DefaultCvsOperationExecutorCallback (com.intellij.cvsSupport2.cvsExecution.DefaultCvsOperationExecutorCallback)1 LoginPerformer (com.intellij.cvsSupport2.cvsoperations.common.LoginPerformer)1