summaryrefslogtreecommitdiff
path: root/parse-options.h
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-05-03 15:13:31 -0700
committerJunio C Hamano <gitster@pobox.com>2012-05-03 15:13:31 -0700
commitf4ed0af6e2762bc43de474d1fcaa2863b00268eb (patch)
tree0553a911a76184db89924518e79b978b65dccc23 /parse-options.h
parent9a7b0bca366d8d9b3b26f1bb1a75885780c0f0e4 (diff)
parentd96e3c150f2b4508f2e7d23ce9183d5b807c2155 (diff)
downloadgit-f4ed0af6e2762bc43de474d1fcaa2863b00268eb.tar.gz
Merge branch 'nd/columns'
A couple of commands learn --column option to produce columnar output. By Nguyễn Thái Ngọc Duy (9) and Zbigniew Jędrzejewski-Szmek (1) * nd/columns: tag: add --column column: support piping stdout to external git-column process status: add --column branch: add --column help: reuse print_columns() for help -a column: add dense layout support t9002: work around shells that are unable to set COLUMNS to 1 column: add columnar layout Stop starting pager recursively Add column layout skeleton and git-column
Diffstat (limited to 'parse-options.h')
-rw-r--r--parse-options.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/parse-options.h b/parse-options.h
index def9ced739..da999f8995 100644
--- a/parse-options.h
+++ b/parse-options.h
@@ -234,5 +234,7 @@ extern int parse_opt_noop_cb(const struct option *, const char *, int);
PARSE_OPT_OPTARG, &parse_opt_abbrev_cb, 0 }
#define OPT__COLOR(var, h) \
OPT_COLOR_FLAG(0, "color", (var), (h))
+#define OPT_COLUMN(s, l, v, h) \
+ { OPTION_CALLBACK, (s), (l), (v), "style", (h), PARSE_OPT_OPTARG, parseopt_column_callback }
#endif