| 1952 | } |
| 1953 | |
| 1954 | int cmd_format_patch(int argc, |
| 1955 | const char **argv, |
| 1956 | const char *prefix, |
| 1957 | struct repository *repo UNUSED) |
| 1958 | { |
| 1959 | struct format_config cfg; |
| 1960 | struct commit *commit; |
| 1961 | struct commit_stack list = COMMIT_STACK_INIT; |
| 1962 | struct rev_info rev; |
| 1963 | char *to_free = NULL; |
| 1964 | struct setup_revision_opt s_r_opt; |
| 1965 | size_t total, i; |
| 1966 | int use_stdout = 0; |
| 1967 | int start_number = -1; |
| 1968 | int just_numbers = 0; |
| 1969 | int ignore_if_in_upstream = 0; |
| 1970 | int cover_letter = -1; |
| 1971 | const char *cover_letter_fmt = NULL; |
| 1972 | int boundary_count = 0; |
| 1973 | int no_binary_diff = 0; |
| 1974 | int zero_commit = 0; |
| 1975 | struct commit *origin = NULL; |
| 1976 | const char *in_reply_to = NULL; |
| 1977 | struct patch_ids ids; |
| 1978 | struct strbuf buf = STRBUF_INIT; |
| 1979 | int use_patch_format = 0; |
| 1980 | int quiet = 0; |
| 1981 | const char *reroll_count = NULL; |
| 1982 | char *cover_from_description_arg = NULL; |
| 1983 | char *description_file = NULL; |
| 1984 | char *branch_name = NULL; |
| 1985 | struct base_tree_info bases; |
| 1986 | struct commit *base; |
| 1987 | int show_progress = 0; |
| 1988 | struct progress *progress = NULL; |
| 1989 | struct oid_array idiff_prev = OID_ARRAY_INIT; |
| 1990 | struct strbuf idiff_title = STRBUF_INIT; |
| 1991 | const char *rdiff_prev = NULL; |
| 1992 | struct strbuf rdiff1 = STRBUF_INIT; |
| 1993 | struct strbuf rdiff2 = STRBUF_INIT; |
| 1994 | struct strbuf rdiff_title = STRBUF_INIT; |
| 1995 | const char *rfc = NULL; |
| 1996 | int creation_factor = -1; |
| 1997 | const char *signature = git_version_string; |
| 1998 | char *signature_to_free = NULL; |
| 1999 | char *signature_file_arg = NULL; |
| 2000 | struct keep_callback_data keep_callback_data = { |
| 2001 | .cfg = &cfg, |
| 2002 | .revs = &rev, |
| 2003 | }; |
| 2004 | const char *fmt_patch_suffix = NULL; |
| 2005 | |
| 2006 | const struct option builtin_format_patch_options[] = { |
| 2007 | OPT_CALLBACK_F('n', "numbered", &cfg, NULL, |
| 2008 | N_("use [PATCH n/m] even with a single patch"), |
| 2009 | PARSE_OPT_NOARG, numbered_callback), |
| 2010 | OPT_CALLBACK_F('N', "no-numbered", &cfg, NULL, |
| 2011 | N_("use [PATCH] even with multiple patches"), |
nothing calls this directly
no test coverage detected