summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJonathan Nieder <jrnieder@gmail.com>2013-09-25 08:25:23 +0200
committerJonathan Nieder <jrnieder@gmail.com>2013-09-25 08:25:23 +0200
commiteb34959e107b0761053662a1498026f856f2ce44 (patch)
treedd2007a82eba3a25998dd752a015e0788efa307f
parentMerge branch 'jc/push-cas' (diff)
parentcontacts: fix to work in subdirectories (diff)
downloadgit-eb34959e107b0761053662a1498026f856f2ce44.tar.xz
git-eb34959e107b0761053662a1498026f856f2ce44.zip
Merge branch 'es/contacts-in-subdir'
* es/contacts-in-subdir: contacts: fix to work in subdirectories
-rwxr-xr-xcontrib/contacts/git-contacts4
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/contacts/git-contacts b/contrib/contacts/git-contacts
index fb6429b64b..428cc1a9a1 100755
--- a/contrib/contacts/git-contacts
+++ b/contrib/contacts/git-contacts
@@ -181,6 +181,10 @@ if (@rev_args) {
scan_rev_args(\%sources, \@rev_args)
}
+my $toplevel = `git rev-parse --show-toplevel`;
+chomp $toplevel;
+chdir($toplevel) or die "chdir failure: $toplevel: $!\n";
+
my %commits;
blame_sources(\%sources, \%commits);
import_commits(\%commits);