diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-04-25 04:28:53 (GMT) |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-04-25 04:28:53 (GMT) |
commit | 8295f2028f622da2da2b9e31a2793be64ce45a07 (patch) | |
tree | 77e4db49ee740231a2a8cb863b7f20368af93e88 /builtin | |
parent | ff6eb825f0aa1f45230c10fbb0cf8d484c927c55 (diff) | |
parent | 86238e07ef633f7488ac708578aaf71e4375c057 (diff) | |
download | git-8295f2028f622da2da2b9e31a2793be64ce45a07.zip git-8295f2028f622da2da2b9e31a2793be64ce45a07.tar.gz git-8295f2028f622da2da2b9e31a2793be64ce45a07.tar.bz2 |
Merge branch 'bw/commit-partial-from-subdirectory-fix'
"cd sub/dir && git commit ../path" ought to record the changes to
the file "sub/path", but this regressed long time ago.
* bw/commit-partial-from-subdirectory-fix:
commit: allow partial commits with relative paths
Diffstat (limited to 'builtin')
-rw-r--r-- | builtin/commit.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/builtin/commit.c b/builtin/commit.c index 37fcb55..5571d4a 100644 --- a/builtin/commit.c +++ b/builtin/commit.c @@ -218,8 +218,7 @@ static int list_paths(struct string_list *list, const char *with_tree, if (with_tree) { char *max_prefix = common_prefix(pattern); - overlay_tree_on_index(&the_index, with_tree, - max_prefix ? max_prefix : prefix); + overlay_tree_on_index(&the_index, with_tree, max_prefix); free(max_prefix); } |