echo '<meta http-equiv="refresh" content="0; URL='.$_SERVER['HTTP_REFERER'].'"> ';
}else{
$b = shell_exec("cd /usr/share/gitweb/dl; git clone git://git.nexus-irc.de/".$_GET['build']);
- scandir_replace("/usr/share/gitweb/dl/".$name,"git-".substr($con, 0, -1)."-".substr($hash, 0, -1));
+ if($_GET['build'] != "gitweb.git") {
+ scandir_replace("/usr/share/gitweb/dl/".$name,"git-".substr($con, 0, -1)."-".substr($hash, 0, -1));
+ }
$c = shell_exec("cd /usr/share/gitweb/dl; tar czfv ".$name."-".substr($hash, 0, -1).".tar.gz ".$name);
$d = shell_exec("rm -r /usr/share/gitweb/dl/".$name);
echo '<meta http-equiv="refresh" content="0; URL='.$_SERVER['HTTP_REFERER'].'"> ';
$b = shell_exec("cd /usr/share/gitweb/dl/; git clone git://git.nexus-irc.de/".$_GET['build2']);
$c = shell_exec("cd /usr/share/gitweb/dl/".$name."/; git reset ".$_GET['h']);
$con= shell_exec('git --git-dir=/home/git/'.$_GET['build2'].' rev-list --oneline --header master | wc -l | sed "s/[ \t]//g"');
- scandir_replace("/usr/share/gitweb/dl/".$name,"git-".substr($con, 0, -1)."-".$hash);
+ if($_GET['build2'] != "gitweb.git") {
+ scandir_replace("/usr/share/gitweb/dl/".$name,"git-".substr($con, 0, -1)."-".$hash);
+ }
$c = shell_exec("cd /usr/share/gitweb/dl; tar czfv ".$name."-".$hash.".tar.gz ".$name);
$d = shell_exec("rm -r /usr/share/gitweb/dl/".$name);
header("Content-Type: application/x-gzip");