Added the ability to configure the paths to the SCM executables.

This commit is contained in:
Manuel Eidenberger
2009-02-25 14:28:14 +01:00
committed by Loic d'Anterroches
parent 64dc8ec3b8
commit 42c6f53fbc
7 changed files with 46 additions and 34 deletions

View File

@@ -192,7 +192,7 @@ class IDF_Plugin_SyncGit_Serve
{
mkdir($fullpath, 0750, true);
exec(sprintf(Pluf::f('idf_exec_cmd_prefix', '').
'git --git-dir=%s init', escapeshellarg($fullpath)),
Pluf::f('git_path', 'git').' --git-dir=%s init', escapeshellarg($fullpath)),
$out, $res);
if ($res != 0) {
throw new Exception(sprintf('Init repository error, exit status %d.', $res));

View File

@@ -77,7 +77,7 @@ class IDF_Plugin_SyncMercurial
}
$return = 0;
$output = array();
$cmd = sprintf('hg init %s',
$cmd = sprintf(Pluf::f('hg_path', 'hg').' init %s',
escapeshellarg($mercurial_path.'/'.$shortname));
$cmd = Pluf::f('idf_exec_cmd_prefix', '').$cmd;
$ll = exec($cmd, $output, $return);

View File

@@ -77,7 +77,7 @@ class IDF_Plugin_SyncSvn
}
$return = 0;
$output = array();
$cmd = sprintf('svnadmin create %s',
$cmd = sprintf(Pluf::f('svnadmin_path', 'svnadmin').' create %s',
escapeshellarg($svn_path.'/'.$shortname));
$cmd = Pluf::f('idf_exec_cmd_prefix', '').$cmd;
$ll = exec($cmd, $output, $return);