Use git-log rather than the shell, git-rev-list, and git-diff-tree.
authorjoshtriplett <joshtriplett@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Thu, 30 Aug 2007 02:32:29 +0000 (02:32 +0000)
committerjoshtriplett <joshtriplett@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>
Thu, 30 Aug 2007 02:32:29 +0000 (02:32 +0000)
Patch by Jamey Sharp <jamey@minilop.net>.

IkiWiki/Rcs/git.pm

index 0483e9b162a335e5aeaabb9161acc09b36a8e18c..8db83233d99653a38c3017f1020b1461aab3333c 100644 (file)
@@ -256,8 +256,7 @@ sub git_commit_info ($;$) { #{{{
        $num ||= 1;
 
        my @raw_lines =
-           run_or_die(qq{git-rev-list --max-count=$num $sha1 |
-                         git-diff-tree --stdin --pretty=raw --always -M -m -r});
+           run_or_die('git-log', "--max-count=$num", '--pretty=raw', '--raw', '--abbrev=40', '--always', '-M', '-m', '-r', $sha1);
 
        my @ci;
        while (my $parsed = _parse_diff_tree(\@raw_lines)) {