mirror of
https://github.com/git/git.git
synced 2024-11-18 06:54:55 +01:00
a21c2f94fb
The get_patch_filename function expects a commit argument and uses it to get the sanitized subject line when making a patch filename. However, we also want to use this same function for the cover letter, which does not have a commit object. The current solution is to create a fake commit with the subject "cover letter". Instead, let's make the get_patch_filename interface more flexibile, and allow passing a direct subject. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
27 lines
888 B
C
27 lines
888 B
C
#ifndef LOG_TREE_H
|
|
#define LOG_TREE_H
|
|
|
|
#include "revision.h"
|
|
|
|
struct log_info {
|
|
struct commit *commit, *parent;
|
|
};
|
|
|
|
int parse_decorate_color_config(const char *var, const int ofs, const char *value);
|
|
void init_log_tree_opt(struct rev_info *);
|
|
int log_tree_diff_flush(struct rev_info *);
|
|
int log_tree_commit(struct rev_info *, struct commit *);
|
|
int log_tree_opt_parse(struct rev_info *, const char **, int);
|
|
void show_log(struct rev_info *opt);
|
|
void show_decorations(struct rev_info *opt, struct commit *commit);
|
|
void log_write_email_headers(struct rev_info *opt, struct commit *commit,
|
|
const char **subject_p,
|
|
const char **extra_headers_p,
|
|
int *need_8bit_cte_p);
|
|
void load_ref_decorations(int flags);
|
|
|
|
#define FORMAT_PATCH_NAME_MAX 64
|
|
void get_patch_filename(struct commit *commit, const char *subject, int nr,
|
|
const char *suffix, struct strbuf *buf);
|
|
|
|
#endif
|