xaizek / rocketgit (License: AGPLv3+) (since 2018-12-09)
Light and fast Git hosting solution suitable to serve both as a hub or as a personal code storage with its tickets, pull requests, API and much more.
Commit d0be6070962a782adf99e08155ea04cef619368e

Added rg_git_content_by_file funcion, no users right now
Author: Catalin(ux) M. BOIE
Author date (UTC): 2015-03-22 08:28
Committer name: Catalin(ux) M. BOIE
Committer date (UTC): 2015-03-22 08:28
Parent(s): f50c94843c00656a453979591585c3d9d073469c
Signing key:
Tree: 2ef11c74d60ddcda03618ea70a4b96734c1e8d16
File Lines added Lines deleted
TODO 1 0
inc/git.inc.php 27 0
File TODO changed (mode: 100644) (index a123594..a26e75b)
12 12 proiectului, e nevoie. Dar intr-un form, in textarea, nu e nevoie. proiectului, e nevoie. Dar intr-un form, in textarea, nu e nevoie.
13 13 Apoi as putea elimina description_nice. Apoi as putea elimina description_nice.
14 14 [ ] Security: Link-uri + xss (Ionut) [ ] Security: Link-uri + xss (Ionut)
15 [ ] Only one daemon should update the structure, else they will conflict.
15 16 [ ] [ ]
16 17
17 18 == BEFORE NEXT RELEASE == == BEFORE NEXT RELEASE ==
File inc/git.inc.php changed (mode: 100644) (index 96a99c9..0cdb5ec)
... ... function rg_git_diff_tree($tree1, $tree2)
1387 1387 return $ret; return $ret;
1388 1388 } }
1389 1389
1390 /*
1391 * Outputs the content of a file, at a specific revision
1392 */
1393 function rg_git_content_by_file($treeish, $file)
1394 {
1395 rg_prof_start("git_content_by_file");
1396 rg_log_enter("git_content_by_file: treeish=$treeish file=$file");
1397
1398 $ret = FALSE;
1399 while (1) {
1400 $cmd = 'git show ' . escapeshellarg($treeish) . ':'
1401 . escapeshellarg($file);
1402 $a = rg_exec($cmd);
1403 if ($a['ok'] != 1) {
1404 rg_git_set_error("error on show (" . $a['errmsg'] . ")");
1405 break;
1406 }
1407
1408 $ret = $a['data'];
1409 break;
1410 }
1411
1412 rg_log_exit();
1413 rg_prof_end("git_content");
1414 return $ret;
1415 }
1416
1390 1417 ?> ?>
Hints

Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://code.reversed.top/user/xaizek/rocketgit

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@code.reversed.top/user/xaizek/rocketgit

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a pull request:
... clone the repository ...
... make some changes and some commits ...
git push origin master