diff options
author | Christian Couder <chriscool@tuxfamily.org> | 2016-04-22 20:55:46 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-09-07 12:29:53 -0700 |
commit | 13b5af22f39f5e7d952a4c98ffb7ea25053800c1 (patch) | |
tree | f768b1893755e3ba1ba7e35d5f6a1934ac50df3e /apply.h | |
parent | 803bf4e012687d92f4c136febe0881852738d57d (diff) | |
download | git-13b5af22f39f5e7d952a4c98ffb7ea25053800c1.tar.gz |
apply: move libified code from builtin/apply.c to apply.{c,h}
As most of the apply code in builtin/apply.c has been libified by a number of
previous commits, it can now be moved to apply.{c,h}, so that more code can
use it.
Helped-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Helped-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'apply.h')
-rw-r--r-- | apply.h | 19 |
1 files changed, 19 insertions, 0 deletions
@@ -102,6 +102,20 @@ extern int parse_whitespace_option(struct apply_state *state, extern int parse_ignorewhitespace_option(struct apply_state *state, const char *option); +extern int apply_option_parse_exclude(const struct option *opt, + const char *arg, int unset); +extern int apply_option_parse_include(const struct option *opt, + const char *arg, int unset); +extern int apply_option_parse_p(const struct option *opt, + const char *arg, + int unset); +extern int apply_option_parse_whitespace(const struct option *opt, + const char *arg, int unset); +extern int apply_option_parse_directory(const struct option *opt, + const char *arg, int unset); +extern int apply_option_parse_space_change(const struct option *opt, + const char *arg, int unset); + extern int init_apply_state(struct apply_state *state, const char *prefix, struct lock_file *lock_file); @@ -115,4 +129,9 @@ extern int check_apply_state(struct apply_state *state, int force_apply); #define APPLY_OPT_INACCURATE_EOF (1<<0) /* accept inaccurate eof */ #define APPLY_OPT_RECOUNT (1<<1) /* accept inaccurate line count */ +extern int apply_all_patches(struct apply_state *state, + int argc, + const char **argv, + int options); + #endif |