ref-filter.h: add max_count and omit_empty to ref_format
Add an internal 'array_opts' struct to 'struct ref_format' containing formatting options that pertain to the formatting of an entire ref array: 'max_count' and 'omit_empty'. These values are specified by the '--count' and '--omit-empty' options, respectively, to 'for-each-ref'/'tag'/'branch'. Storing these values in the 'ref_format' will simplify the consolidation of ref array formatting logic across builtins in later patches. Signed-off-by: Victoria Dye <vdye@github.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
56d26ade97
commit
9d4fcfe1ff
@ -92,6 +92,11 @@ struct ref_format {
|
||||
|
||||
/* List of bases for ahead-behind counts. */
|
||||
struct string_list bases;
|
||||
|
||||
struct {
|
||||
int max_count;
|
||||
int omit_empty;
|
||||
} array_opts;
|
||||
};
|
||||
|
||||
#define REF_FILTER_INIT { \
|
||||
|
Reference in New Issue
Block a user