]> git.ipfire.org Git - thirdparty/git.git/blobdiff - parse-options.h
Merge branch 'rs/parse-options-lithelp-help'
[thirdparty/git.git] / parse-options.h
index eebab6c7d71f55654c262ee4ab10f99fe2a9b906..659a4c28b2d2afa515a1efb0a75843b538fad498 100644 (file)
@@ -230,6 +230,16 @@ NORETURN void usage_msg_opt(const char *msg,
                            const char * const *usagestr,
                            const struct option *options);
 
+/**
+ * usage_msg_optf() is like usage_msg_opt() except that the first
+ * argument is a format string, and optional format arguments follow
+ * after the 3rd option.
+ */
+__attribute__((format (printf,1,4)))
+void NORETURN usage_msg_optf(const char *fmt,
+                            const char * const *usagestr,
+                            const struct option *options, ...);
+
 /*
  * Use these assertions for callbacks that expect to be called with NONEG and
  * NOARG respectively, and do not otherwise handle the "unset" and "arg"
@@ -306,6 +316,8 @@ enum parse_opt_result parse_opt_unknown_cb(struct parse_opt_ctx_t *ctx,
                                           const char *, int);
 int parse_opt_passthru(const struct option *, const char *, int);
 int parse_opt_passthru_argv(const struct option *, const char *, int);
+/* value is enum branch_track* */
+int parse_opt_tracking_mode(const struct option *, const char *, int);
 
 #define OPT__VERBOSE(var, h)  OPT_COUNTUP('v', "verbose", (var), (h))
 #define OPT__QUIET(var, h)    OPT_COUNTUP('q', "quiet",   (var), (h))