summaryrefslogtreecommitdiffstats
path: root/git-access.c
diff options
context:
space:
mode:
authorGravatar Robert C. Helling <helling@atdotde.de>2015-09-23 11:13:07 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-10-04 16:29:31 +0100
commita241393e7b465ec0f263a7afaf20f7b65617adae (patch)
tree4cb6886134bba214c1918c3bbd927f88058cfe89 /git-access.c
parent3f900885df21200722b11bc09dad70af588e398e (diff)
downloadsubsurface-a241393e7b465ec0f263a7afaf20f7b65617adae.tar.gz
Print paths to internal files in verbose mode
When run with -v option, this prints local file names like the path to the local git repository and the hash file. Signed-off-by: Robert C. Helling <helling@atdotde.de> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'git-access.c')
-rw-r--r--git-access.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/git-access.c b/git-access.c
index 25f1d9e8a..eee066007 100644
--- a/git-access.c
+++ b/git-access.c
@@ -806,7 +806,7 @@ static struct git_repository *is_remote_git_repository(char *remote, const char
/*
* If it's not a git repo, return NULL. Be very conservative.
*/
-struct git_repository *is_git_repository(const char *filename, const char **branchp, const char **remote)
+struct git_repository *is_git_repository(const char *filename, const char **branchp, const char **remote, bool dry_run)
{
int flen, blen, ret;
int offset = 1;
@@ -857,6 +857,9 @@ struct git_repository *is_git_repository(const char *filename, const char **bran
return dummy_git_repository;
}
+ if (dry_run)
+ return dummy_git_repository;
+
repo = is_remote_git_repository(loc, branch);
if (repo) {
if (remote)