Skip to content

Commit d49028e

Browse files
committed
worktree: honor configuration variables
The command accesses default_abbrev (defined in environment.c and is updated via core.abbrev configuration), but never makes any call to git_config(). The output from "worktree list" ignores the abbrev setting for this reason. Make a call to git_config() to read the default set of configuration variables at the beginning of the command. Signed-off-by: Junio C Hamano <[email protected]>
1 parent 7c0304a commit d49028e

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

builtin/worktree.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,8 @@ int cmd_worktree(int ac, const char **av, const char *prefix)
528528
OPT_END()
529529
};
530530

531+
git_config(git_default_config, NULL);
532+
531533
if (ac < 2)
532534
usage_with_options(worktree_usage, options);
533535
if (!prefix)

0 commit comments

Comments
 (0)