From: Aneesh Kumar K.V Date: Tue, 30 Jan 2007 07:56:49 +0000 (+0530) Subject: blameview: Use git-cat-file to read the file content. X-Git-Tag: v1.5.0-rc3~14 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/73a2acc0a09829f887fdf2dbcfba217102227932?ds=inline;hp=--cc blameview: Use git-cat-file to read the file content. Fix blameview to use git-cat-file to read the file content. This make sure we show the right content when we have modified file in the working directory which is not committed. Signed-off-by: Aneesh Kumar K.V Signed-off-by: Junio C Hamano --- 73a2acc0a09829f887fdf2dbcfba217102227932 diff --git a/contrib/blameview/blameview.perl b/contrib/blameview/blameview.perl index a55f799f00..5e9a67c123 100755 --- a/contrib/blameview/blameview.perl +++ b/contrib/blameview/blameview.perl @@ -28,7 +28,8 @@ $fileview->set_size_request(1024, 768); $fileview->set_rules_hint(1); -open(my $fh, '<', $fn) +my $fh; +open($fh, '-|', "git cat-file blob HEAD:$fn") or die "unable to open $fn: $!"; while(<$fh>) { chomp;