Module: Pullr::SCM::SubVersion

Includes:
CommandLine
Defined in:
lib/pullr/scm/sub_version.rb

Instance Method Summary collapse

Methods included from CommandLine

#cd, #sh

Instance Method Details

#scm_pull(uri, dest = nil) ⇒ Object

Pulls down a copy of a SubVersion source repository.

Parameters:

  • uri (Addressable::URI)

    The URI of the SubVersion repository.

  • dest (String) (defaults to: nil)

    Optional destination to pull the repository down into.



17
18
19
20
21
22
23
# File 'lib/pullr/scm/sub_version.rb', line 17

def scm_pull(uri,dest=nil)
  if dest
    sh 'svn', 'checkout', uri, dest
  else
    sh 'svn', 'checkout', uri
  end
end

#scm_update(path, uri = nil) ⇒ Object

Updates a local SubVersion repository.

Parameters:

  • path (String)

    Path to the local repository to update.

  • uri (Addressable::URI) (defaults to: nil)

    Optional URI of the remote SubVersion repository to update from.



34
35
36
# File 'lib/pullr/scm/sub_version.rb', line 34

def scm_update(path,uri=nil)
  cd(path) { sh 'svn', 'update' }
end