Package hudson.scm
Class CVSSCM
java.lang.Object
hudson.scm.SCM
hudson.scm.AbstractCvs
hudson.scm.CVSSCM
- All Implemented Interfaces:
ExtensionPoint,Describable<SCM>,ICvs,Serializable
CVS.
I couldn't call this class "CVS" because that would cause the view folder name to collide with CVS control files.
This object gets shipped to the remote machine to perform some of the work,
so it implements Serializable.
- Author:
- Kohsuke Kawaguchi, Michael Clarke
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classfinal classDeprecated.we now use CvsTagAction but have to keep this class around for old builds that have a serialized version of this class and use the old archive method of tagging a buildNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Field Summary
Fields inherited from class hudson.scm.AbstractCvs
DATE_FORMATTERFields inherited from class hudson.scm.SCM
PERMISSIONS, TAG -
Constructor Summary
ConstructorsConstructorDescriptionCVSSCM(String cvsRoot, String allModules, String branch, String cvsRsh, boolean canUseUpdate, boolean useHeadIfNotFound, boolean legacy, boolean isTag, String excludedRegions) Deprecated.we now use multiple repositories and don't use cvsRshCVSSCM(String cvsRoot, String allModules, String branch, String cvsRsh, boolean canUseUpdate, boolean useHeadIfNotFound, boolean legacy, boolean isTag, String excludedRegions, CVSRepositoryBrowser browser) Deprecated.CVSSCM(List<CvsRepository> repositories, boolean canUseUpdate, boolean legacy, boolean skipChangeLog, boolean pruneEmptyDirectories, boolean disableCvsQuiet, boolean cleanOnFailedUpdate, boolean forceCleanCopy) Deprecated.CVSSCM(List<CvsRepository> repositories, boolean canUseUpdate, boolean legacy, boolean skipChangeLog, boolean pruneEmptyDirectories, boolean disableCvsQuiet, boolean cleanOnFailedUpdate, boolean forceCleanCopy, boolean checkoutCurrentTimestamp) -
Method Summary
Modifier and TypeMethodDescriptionvoidbuildEnvVars(AbstractBuild<?, ?> build, Map<String, String> env) booleancheckout(AbstractBuild<?, ?> build, Launcher launcher, FilePath workspace, BuildListener listener, File changelogFile) voidcheckout(Run<?, ?> build, Launcher launcher, FilePath workspace, TaskListener listener, File changelogFile, SCMRevisionState baseline) protected PollingResultcompareRemoteRevisionWith(AbstractProject<?, ?> project, Launcher launcher, FilePath workspace, TaskListener listener, SCMRevisionState baseline) Checks for differences between the current workspace and the remote repository.Gets the descriptor for the current plugin.getModuleRoot(FilePath workspace, AbstractBuild build) If there are multiple modules, return the module directory of the first one.FilePath[]getModuleRoots(FilePath workspace, AbstractBuild build) Gets the repositories currently configured for this job.booleanWhether CVS update can be used in place of CVS checkout if a workspace is already checked out.booleanbooleanAllows cleaning of the workspace with a fresh checkout if CVS update fails.booleanCVS is normally run in quiet mode to reduce un-needed log output.booleanWhether to checkout an individual module's files directly into the workspace root rather than into a subdirectory of the module name.booleanControls whether CVS should apply the 'C' option to update commands to overwrite local changes.booleanisLegacy()booleanWhether CVS should be instructed to remove empty directories as part of checkout/update.booleanAllows the option of skipping the changelog generation after checkout.final ObjectConvert legacy configuration into the new class structure.booleanMethods inherited from class hudson.scm.AbstractCvs
calcRevisionsFromBuild, calcRevisionsFromBuild, calculateChangeLog, calculateRepositoryState, checkout, compareRemoteRevisionWith, createChangeLogParser, getCheckoutDate, getCvsClient, getCvsClient, getGlobalOptions, isSymLink, postCheckoutMethods inherited from class hudson.scm.SCM
_calcRevisionsFromBuild, _for, _for, all, buildEnvironment, compareRemoteRevisionWith, createEmptyChangeLog, createEmptyChangeLog, getApi, getEffectiveBrowser, getKey, getModuleRoot, getModuleRoots, getType, guessBrowser, nullify, poll, pollChanges, postCheckout, postCheckout, processWorkspaceBeforeDeletion, processWorkspaceBeforeDeletion, supportsPolling
-
Constructor Details
-
CVSSCM
@Deprecated public CVSSCM(String cvsRoot, String allModules, String branch, String cvsRsh, boolean canUseUpdate, boolean useHeadIfNotFound, boolean legacy, boolean isTag, String excludedRegions) Deprecated.we now use multiple repositories and don't use cvsRsh -
CVSSCM
@Deprecated public CVSSCM(String cvsRoot, String allModules, String branch, String cvsRsh, boolean canUseUpdate, boolean useHeadIfNotFound, boolean legacy, boolean isTag, String excludedRegions, CVSRepositoryBrowser browser) Deprecated. -
CVSSCM
@Deprecated public CVSSCM(List<CvsRepository> repositories, boolean canUseUpdate, boolean legacy, boolean skipChangeLog, boolean pruneEmptyDirectories, boolean disableCvsQuiet, boolean cleanOnFailedUpdate, boolean forceCleanCopy) Deprecated. -
CVSSCM
@DataBoundConstructor public CVSSCM(List<CvsRepository> repositories, boolean canUseUpdate, boolean legacy, boolean skipChangeLog, boolean pruneEmptyDirectories, boolean disableCvsQuiet, boolean cleanOnFailedUpdate, boolean forceCleanCopy, boolean checkoutCurrentTimestamp)
-
-
Method Details
-
readResolve
Convert legacy configuration into the new class structure.- Returns:
- an instance of this class with all the new fields transferred from the old structure to the new one
-
getRepositories
Gets the repositories currently configured for this job.- Specified by:
getRepositoriesin interfaceICvs- Returns:
- an array of
CvsRepository
-
getBrowser
- Overrides:
getBrowserin classSCM
-
requiresWorkspaceForPolling
public boolean requiresWorkspaceForPolling()- Overrides:
requiresWorkspaceForPollingin classSCM
-
compareRemoteRevisionWith
protected PollingResult compareRemoteRevisionWith(AbstractProject<?, ?> project, Launcher launcher, FilePath workspace, TaskListener listener, SCMRevisionState baseline) throws IOException, InterruptedExceptionChecks for differences between the current workspace and the remote repository.- Overrides:
compareRemoteRevisionWithin classSCM- Throws:
IOExceptionInterruptedException- See Also:
-
getModuleRoot
If there are multiple modules, return the module directory of the first one.- Overrides:
getModuleRootin classSCM- Parameters:
workspace-
-
getModuleRoots
- Overrides:
getModuleRootsin classSCM
-
isCanUseUpdate
@Exported public boolean isCanUseUpdate()Description copied from interface:ICvsWhether CVS update can be used in place of CVS checkout if a workspace is already checked out.- Specified by:
isCanUseUpdatein interfaceICvs- Returns:
- true is the
cvs upcan be used in place ofcvs counder the correct circumstances.
-
isSkipChangeLog
@Exported public boolean isSkipChangeLog()Description copied from interface:ICvsAllows the option of skipping the changelog generation after checkout. Primarily used to save time as part of the build process . Has no effect on the polling configuration which uses a similar method to calculate changes.- Specified by:
isSkipChangeLogin interfaceICvs- Returns:
- whether changelog generation should be skipped or not.
-
isPruneEmptyDirectories
@Exported public boolean isPruneEmptyDirectories()Description copied from interface:ICvsWhether CVS should be instructed to remove empty directories as part of checkout/update.- Specified by:
isPruneEmptyDirectoriesin interfaceICvs- Returns:
- if CVS should remove empty directories from the workspace on checkout
-
isFlatten
@Exported public boolean isFlatten()Description copied from interface:ICvsWhether to checkout an individual module's files directly into the workspace root rather than into a subdirectory of the module name. Some scripts expect this functionality so this switch allows users to enabled or disable this. Some plugins may not have the option of supporting this if they automatically checkout multiple module (e.g. the CVS projectset plugin) -
isDisableCvsQuiet
@Exported public boolean isDisableCvsQuiet()Description copied from interface:ICvsCVS is normally run in quiet mode to reduce un-needed log output. This option allows plugins to stop quiet mode being enabled.- Specified by:
isDisableCvsQuietin interfaceICvs- Overrides:
isDisableCvsQuietin classAbstractCvs- Returns:
- whether to disable quiet mode or not.
-
isCleanOnFailedUpdate
@Exported public boolean isCleanOnFailedUpdate()Description copied from interface:ICvsAllows cleaning of the workspace with a fresh checkout if CVS update fails.- Specified by:
isCleanOnFailedUpdatein interfaceICvs- Returns:
- whether to do a workspace wipe-out followed be CVS checkout if CVS update fails
-
isForceCleanCopy
@Exported public boolean isForceCleanCopy()Description copied from interface:ICvsControls whether CVS should apply the 'C' option to update commands to overwrite local changes.- Specified by:
isForceCleanCopyin interfaceICvs- Returns:
- whether CVS should over-write modifications to controlled files int he workspace during update
-
isLegacy
public boolean isLegacy() -
isCheckoutCurrentTimestamp
@Exported public boolean isCheckoutCurrentTimestamp()- Overrides:
isCheckoutCurrentTimestampin classAbstractCvs
-
buildEnvVars
- Overrides:
buildEnvVarsin classSCM
-
checkout
public boolean checkout(AbstractBuild<?, ?> build, Launcher launcher, FilePath workspace, BuildListener listener, File changelogFile) throws IOException, InterruptedException- Overrides:
checkoutin classSCM- Throws:
IOExceptionInterruptedException
-
checkout
public void checkout(@NonNull Run<?, ?> build, @NonNull Launcher launcher, @NonNull FilePath workspace, @NonNull TaskListener listener, @CheckForNull File changelogFile, @CheckForNull SCMRevisionState baseline) throws IOException, InterruptedException- Overrides:
checkoutin classSCM- Throws:
IOExceptionInterruptedException
-
getDescriptor
Description copied from interface:ICvsGets the descriptor for the current plugin.- Specified by:
getDescriptorin interfaceDescribable<SCM>- Specified by:
getDescriptorin interfaceICvs- Overrides:
getDescriptorin classAbstractCvs- Returns:
- the current descriptor
- See Also:
-