Example #1
0
 /**
  * Checkout SVN repository into filesystem
  * @param string Path to subversion repository
  * @param string Path to destination
  */
 public static function checkoutSvn($src, $dst)
 {
     $dst = escapeshellarg($dst);
     $src = SVNUtils::getRepositoryPath($src);
     $message = ConsoleUtils::runCmdCaptureMessage(SVNUtils::svnCommand("co {$src} {$dst}"), $return);
     if ($return) {
         throw new USVN_Exception("Can't checkout subversion repository: " . $message);
     }
 }
Example #2
0
 /**
  * Create SVN repository with standard organisation
  * /trunk
  * /tags
  * /branches
  *
  * @param string Path to create subversion
  */
 public function createSvn($path)
 {
     $escape_path = escapeshellarg($path);
     $message = ConsoleUtils::runCmdCaptureMessage(SVNUtils::svnadminCommand("create {$escape_path}"), $return);
     if ($return) {
         throw new Exception("Can't create subversion repository: " . $message);
     }
 }