File scripts/remote.php changed (mode: 100644) (index 48dd957..7b25512) |
... |
... |
if ($push == 1) { |
287 |
287 |
// Prepare refs to avoid the following message: |
// Prepare refs to avoid the following message: |
288 |
288 |
// "No refs in common and none specified; doing nothing. |
// "No refs in common and none specified; doing nothing. |
289 |
289 |
// Perhaps you should specify a branch such as 'master'." |
// Perhaps you should specify a branch such as 'master'." |
290 |
|
$dst = $repo_path . "/refs/namespaces/" . $namespace . "/refs/heads"; |
|
291 |
|
$r = rg_copy_tree($repo_path . "/refs/heads", $dst . "/", 0755); |
|
|
290 |
|
$dst = $repo_path . '/refs/namespaces/' . $namespace . '/refs'; |
|
291 |
|
$r = rg_copy_tree($repo_path . '/refs/heads', $dst . '/heads/', 0755); |
292 |
292 |
if ($r !== TRUE) |
if ($r !== TRUE) |
293 |
|
fatal("Internal error (cannot copy refs)"); |
|
|
293 |
|
fatal("Internal error (cannot copy heads)"); |
|
294 |
|
$r = rg_copy_tree($repo_path . '/refs/tags', $dst . '/tags/', 0755); |
|
295 |
|
if ($r !== TRUE) |
|
296 |
|
fatal("Internal error (cannot copy tags)"); |
294 |
297 |
} |
} |
295 |
298 |
|
|
296 |
299 |
$run = "git-shell -c \"" . $cmd . " " . escapeshellarg($repo_path) . "\""; |
$run = "git-shell -c \"" . $cmd . " " . escapeshellarg($repo_path) . "\""; |