Avoid duplicating license many times
[gitphp.git] / include / gitutil.git_ls_tree.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
<?php
/*
 *  gitutil.git_ls_tree.php
 *  gitphp: A PHP git repository browser
 *  Component: Git utility - list tree
 *
 *  Copyright (C) 2008 Christopher Han <xiphux@gmail.com>
 */
 
 include_once('defs.commands.php');
 
function git_ls_tree($proj,$hash,$nullterm = FALSE)
{
        global $gitphp_conf;
        $cmd = "env GIT_DIR=" . $proj . " " . $gitphp_conf['gitbin'] . GIT_LS_TREE;
        if ($nullterm)
                $cmd .= " -z";
        return shell_exec($cmd . " " . $hash);
}
 
?>
 
comments