tasks/system/CvsTask.php

Show: inherited
Table of Contents

\CvsTask

Package: phing\tasks\system

Task for performing CVS operations.

NOTE: This implementation has been moved here from Cvs.java with the addition of some accessors for extensibility. Another task can extend this with some customized output processing.

Parent(s)
\Task < \ProjectComponent
Author
Hans Lellelid (Phing)  
Author
costin@dnt.ro (Ant)  
Author
stefano@apache.org (Ant)  
Author
Wolfgang Werner (Ant)  
Author
Kevin Ross (Ant)  
Version
$Revision: 1311 $  

Constants

Constant  DEFAULT_COMPRESSION_LEVEL = 3

Default compression level to use, if compression is enabled via setCompression( true ).

Properties

Propertyprivate  $cmd= ''
Details
Type
n/a
Propertyprivate  $command= 'null'

the CVS command to execute.

Default valuenullDetails
Type
n/a
Propertyprivatearray  $commandlines= 'array()'

List of Commandline children

Commandline[]
Default valuearray()Details
Type
array
Propertyprivate  $compression= '0'

compression level to use.

Default value0Details
Type
n/a
Propertyprivate  $cvsModule= ''

the package/module to check out.

Details
Type
n/a
Propertyprivate  $cvsRoot= ''

the CVSROOT variable.

Details
Type
n/a
Propertyprivate  $cvsRsh= ''

the CVS_RSH variable.

Details
Type
n/a
Propertyprivate  $default_command= '"checkout"'
static

the default command.

Default value"checkout"Details
Type
n/a
Propertyprivate\File  $dest= ''

the directory where the checked out files should be placed.

Details
Type
\File
Propertyprivate  $error= ''
Details
Type
n/a
Propertyprivateboolean  $failOnError= 'false'

If true it will stop the build if cvs exits with error.

Default is false. (Iulian)

Default valuefalseDetails
Type
boolean
Propertyprivate  $noexec= 'false'

report only, don't change any files.

Default valuefalseDetails
Type
n/a
Propertyprivate  $output= ''
Details
Type
n/a
Propertyprivate\File  $passFile= 'null'

CVS password file

Default valuenullDetails
Type
\File
Propertyprivate  $port= '0'

CVS port

Default value0Details
Type
n/a
Propertyprivate  $quiet= 'false'

suppress information messages.

Default valuefalseDetails
Type
n/a

Methods

methodpublicaddConfiguredCommandline( \insertAtStart $c,  $insertAtStart = false ) : void

Configures and adds the given Commandline.

Parameters
Name Type Description
$c \insertAtStart

If true, c is

$insertAtStart
methodpublicappendCommandArgument(  $arg ) : void

This needs to be public to allow configuration of commands externally.

Parameters
Name Type Description
$arg
methodprotectedconfigureCommandline(  $c ) : string

Configure a commandline element for things like cvsRoot, quiet, etc.

Parameters
Name Type Description
$c
Returns
Type Description
string
methodpublicgetCommand( ) : void

methodpublicgetCvsRoot( ) : void

methodpublicgetCvsRsh( ) : void

methodpublicgetDescription( ) : void

methodpublicgetDest( ) : void

methodpublicgetLocation( ) : void

methodpublicgetModule( ) : void

methodpublicgetOwningTarget( ) : void

methodpublicgetPassFile( ) : \File

Returns
Type Description
\File
methodpublicgetPort( ) : int

Returns
Type Description
int
methodpublicgetProject( ) : void

methodprotectedgetRegisterSlot( ) : void

methodpublicgetRuntimeConfigurableWrapper( ) : void

methodpublicgetTaskName( ) : void

methodpublicgetTaskType( ) : void

methodpublicinit( ) : void

methodpubliclog( ) : void

methodpublicmain( ) : void

Throws
Exception Description
\BuildException
methodpublicmaybeConfigure( ) : void

methodpublicperform( ) : void

methodprotectedremoveCommandline(  $c ) : void

Parameters
Name Type Description
$c
methodprotectedrunCommand( \Commandline $toExecute ) : void

Sets up the environment for toExecute and then runs it.

Parameters
Name Type Description
$toExecute \Commandline
Throws
Exception Description
\BuildException
methodpublicsetCommand( string $c ) : void

The CVS command to execute.

Parameters
Name Type Description
$c string
methodpublicsetCompression( boolean $usecomp ) : void

If true, this is the same as compressionlevel="3".

Parameters
Name Type Description
$usecomp boolean

If true, turns on compression using default level, AbstractCvsTask.DEFAULT_COMPRESSION_LEVEL.

methodpublicsetCompressionLevel( int $level ) : void

If set to a value 1-9 it adds -zN to the cvs command line, else it disables compression.

Parameters
Name Type Description
$level int
methodpublicsetCvsRoot( string $root ) : void

The CVSROOT variable.

Parameters
Name Type Description
$root string
methodpublicsetCvsRsh(  $rsh ) : void

The CVS_RSH variable.

Parameters
Name Type Description
$rsh

rsh

methodpublicsetDate(  $p ) : void

Use the most recent revision no later than the given date.

Parameters
Name Type Description
$p

p

methodpublicsetDescription( ) : void

methodpublicsetDest( \PhingFile $dest ) : void

The directory where the checked out files should be placed.

Parameters
Name Type Description
$dest \PhingFile
methodpublicsetError(  $f ) : void

File to which error output should be written.

Parameters
Name Type Description
$f
methodpublicsetFailOnError( boolean $failOnError ) : void

Stop the build process if the command exits with a return code other than 0.

Defaults to false.

Parameters
Name Type Description
$failOnError boolean
methodpublicsetLocation( ) : void

methodpublicsetModule(  $m ) : void

The package/module to operate upon.

Parameters
Name Type Description
$m
methodpublicsetNoexec( boolean $ne ) : void

If true, report only and don't change any files.

Parameters
Name Type Description
$ne boolean
methodpublicsetOutput(  $f ) : void

File to which output should be written.

Parameters
Name Type Description
$f
methodpublicsetOwningTarget( ) : void

methodpublicsetPassfile(  $passFile ) : void

Password file to read passwords from.

Parameters
Name Type Description
$passFile

passFile

methodpublicsetPort( int $port ) : void

Port used by CVS to communicate with the server.

Parameters
Name Type Description
$port int
methodpublicsetProject( ) : void

methodpublicsetQuiet( boolean $q ) : void

If true, suppress informational messages.

Parameters
Name Type Description
$q boolean
methodpublicsetRuntimeConfigurableWrapper( ) : void

methodpublicsetTag( string $p ) : void

The tag of the package/module to operate upon.

Parameters
Name Type Description
$p string
methodpublicsetTaskName( ) : void

methodpublicsetTaskType( ) : void

Documentation was generated by DocBlox 0.17.1.