}
echo "<hr>Sending some messages for db<br>";
- gwvpmini_SendMessageByDb("info", "message 1", $_SESSION["id"]);
- gwvpmini_SendMessageByDb("error", "message 1", $_SESSION["id"]);
- gwvpmini_SendMessageByDb("info", "message 1", $_SESSION["id"]);
- gwvpmini_SendMessageByDb("error", "message really really reallyrea rea asdf asdf asdf asdf asdf qwef asdf asdr qwef asdf qwef asdf asd fqwe fqs dfa sdf qwe fa sdf asd fq wef qdwf asdf qwe fa sdf asdf a ewfqa wesf awefqefd", $_SESSION["id"]);
- gwvpmini_SendMessageByDb("info", "message 1 sdfg sdfgs fdg sdfg sdfg sdfg sdfg sdfg sdfgwqerg fb sdvbefd wqerg zsdafg asdfgargf aerg afg agfs qrgasg agf wergafgs sag arg arg asgd arg argsa garg aerg sad gf ar gfasdg asd aweg asasd", $_SESSION["id"]);
+ //gwvpmini_SendMessageByDb("info", "message 1", $_SESSION["id"]);
+ //gwvpmini_SendMessageByDb("error", "message 1", $_SESSION["id"]);
+ //gwvpmini_SendMessageByDb("info", "message 1", $_SESSION["id"]);
+ //gwvpmini_SendMessageByDb("error", "message really really reallyrea rea asdf asdf asdf asdf asdf qwef asdf asdr qwef asdf qwef asdf asd fqwe fqs dfa sdf qwe fa sdf asd fq wef qdwf asdf qwe fa sdf asdf a ewfqa wesf awefqefd", $_SESSION["id"]);
+ //gwvpmini_SendMessageByDb("info", "message 1 sdfg sdfgs fdg sdfg sdfg sdfg sdfg sdfg sdfgwqerg fb sdvbefd wqerg zsdafg asdfgargf aerg afg agfs qrgasg agf wergafgs sag arg arg asgd arg argsa garg aerg sad gf ar gfasdg asd aweg asasd", $_SESSION["id"]);
echo "done<br>";
+
+ $repo_base = gwvpmini_getConfigVal("repodir");
+
+ $repos = glob("$repo_base/*.git");
+
+ foreach($repos as $repo) {
+ $bn = substr(basename($repo), 0, -4);
+ echo "Repo: $repo, $bn<br>";
+ echo "reflist:<pre>".print_r(gwvpmini_GetRefList($bn),true)."</pre>";
+ }
+
+
}
?>
\ No newline at end of file
function gwvpmini_GitLogProvider()\r
-{\r
+{
+ global $cmd_line_tool,$git_cli_cmd,$php_cli_cmd;\r
/*\r
* The home page provider will:\r
* 1) show the last 10 commits for every repository - though, excluding private repos\r
echo "<tr><td><a href=\"$BASE_URL/view/$name\">$name</a></td><td>$desc</td>";
echo "<td>";
$repo_base = gwvpmini_getConfigVal("repodir");
- $cmd = "git --git-dir=\"$repo_base/$name.git\" log --all -1 2> /dev/null";
+ $cmd = "$git_cli_cmd --git-dir=\"$repo_base/$name.git\" log --all -1 2> /dev/null";
// error_log("CMD: $cmd");
//system("$cmd");
$fls = popen($cmd, "r");
$repo_base = gwvpmini_getConfigVal("repodir");
- $cmd = "$cmd_line_tool --git-dir=$repo_base/$repo.git log $commitid -1 --format='%an'";
+ $cmd = "$git_cli_cmd --git-dir=$repo_base/$repo.git log $commitid -1 --format='%an'";
exec($cmd, $commitername, $returnvar);
- $cmd = "$cmd_line_tool --git-dir=$repo_base/$repo.git log $commitid -1 --format='%ae'";
+ $cmd = "$git_cli_cmd --git-dir=$repo_base/$repo.git log $commitid -1 --format='%ae'";
exec($cmd, $commiteremail, $returnvar);
- $cmd = "$cmd_line_tool --git-dir=$repo_base/$repo.git log $commitid -1 --format='%ct'";
+ $cmd = "$git_cli_cmd --git-dir=$repo_base/$repo.git log $commitid -1 --format='%ct'";
exec($cmd, $commitertime, $returnvar);
- $cmd = "$cmd_line_tool --git-dir=$repo_base/$repo.git log $commitid -1 --format='%s'";
+ $cmd = "$git_cli_cmd --git-dir=$repo_base/$repo.git log $commitid -1 --format='%s'";
exec($cmd, $commiterlog, $returnvar);
- $cmd = "$cmd_line_tool --git-dir=$repo_base/$repo.git log $commitid -1 --format='%b'";
+ $cmd = "$git_cli_cmd --git-dir=$repo_base/$repo.git log $commitid -1 --format='%b'";
exec($cmd, $commiterbody, $returnvar);
}
function gwvpmini_GetCommitList($repo, $branch, $num=20)
{
- global $cmd_line_tool,$git_cli_cmd,$php_cli_cmd;
+ global $git_cli_cmd,$git_cli_cmd,$php_cli_cmd;
$repo_base = gwvpmini_getConfigVal("repodir");
- $cmd = "$cmd_line_tool --git-dir=$repo_base/$repo.git log $commitid -1 --format='%an'";\r
+ $cmd = "$git_cli_cmd --git-dir=$repo_base/$repo.git log $commitid -1 --format='%an'";\r
exec($cmd, $commitername, $returnvar);\r
}
$repo_base = gwvpmini_getConfigVal("repodir");
- $cmd = "$cmd_line_tool --git-dir=$repo_base/$repo.git for-each-ref $commitid --format='%(objecttype):%(objectname):%(refname)'";
+ $cmd = "$git_cli_cmd --git-dir=$repo_base/$repo.git for-each-ref $commitid --format='%(objecttype):%(objectname):%(refname)'";
+ error_log("command was $cmd");
exec($cmd, $reflist, $returnvar);
+
+ return $reflist;
}
?>
\ No newline at end of file