mirror of
https://github.com/git/git.git
synced 2024-11-27 12:03:55 +08:00
log: introduce init_log_defaults()
This is currently a wrapper around init_grep_defaults(), but will allow adding more initialization in further patches. Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
a9276a69ca
commit
9501d191ad
@ -100,6 +100,11 @@ static int log_line_range_callback(const struct option *option, const char *arg,
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void init_log_defaults(void)
|
||||
{
|
||||
init_grep_defaults();
|
||||
}
|
||||
|
||||
static void cmd_log_init_defaults(struct rev_info *rev)
|
||||
{
|
||||
if (fmt_pretty)
|
||||
@ -416,7 +421,7 @@ int cmd_whatchanged(int argc, const char **argv, const char *prefix)
|
||||
struct rev_info rev;
|
||||
struct setup_revision_opt opt;
|
||||
|
||||
init_grep_defaults();
|
||||
init_log_defaults();
|
||||
git_config(git_log_config, NULL);
|
||||
|
||||
init_revisions(&rev, prefix);
|
||||
@ -527,7 +532,7 @@ int cmd_show(int argc, const char **argv, const char *prefix)
|
||||
struct pathspec match_all;
|
||||
int i, count, ret = 0;
|
||||
|
||||
init_grep_defaults();
|
||||
init_log_defaults();
|
||||
git_config(git_log_config, NULL);
|
||||
|
||||
memset(&match_all, 0, sizeof(match_all));
|
||||
@ -608,7 +613,7 @@ int cmd_log_reflog(int argc, const char **argv, const char *prefix)
|
||||
struct rev_info rev;
|
||||
struct setup_revision_opt opt;
|
||||
|
||||
init_grep_defaults();
|
||||
init_log_defaults();
|
||||
git_config(git_log_config, NULL);
|
||||
|
||||
init_revisions(&rev, prefix);
|
||||
@ -647,7 +652,7 @@ int cmd_log(int argc, const char **argv, const char *prefix)
|
||||
struct rev_info rev;
|
||||
struct setup_revision_opt opt;
|
||||
|
||||
init_grep_defaults();
|
||||
init_log_defaults();
|
||||
git_config(git_log_config, NULL);
|
||||
|
||||
init_revisions(&rev, prefix);
|
||||
@ -1280,7 +1285,7 @@ int cmd_format_patch(int argc, const char **argv, const char *prefix)
|
||||
extra_hdr.strdup_strings = 1;
|
||||
extra_to.strdup_strings = 1;
|
||||
extra_cc.strdup_strings = 1;
|
||||
init_grep_defaults();
|
||||
init_log_defaults();
|
||||
git_config(git_format_config, NULL);
|
||||
init_revisions(&rev, prefix);
|
||||
rev.commit_format = CMIT_FMT_EMAIL;
|
||||
|
Loading…
Reference in New Issue
Block a user