diff options
Diffstat (limited to 'builtin/tag.c')
-rw-r--r-- | builtin/tag.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/builtin/tag.c b/builtin/tag.c index d403417b56..d92d8e110b 100644 --- a/builtin/tag.c +++ b/builtin/tag.c @@ -63,8 +63,18 @@ static int list_tags(struct ref_filter *filter, struct ref_sorting *sorting, filter_refs(&array, filter, FILTER_REFS_TAGS); ref_array_sort(sorting, &array); - for (i = 0; i < array.nr; i++) - show_ref_array_item(array.items[i], format); + for (i = 0; i < array.nr; i++) { + struct strbuf output = STRBUF_INIT; + struct strbuf err = STRBUF_INIT; + + if (format_ref_array_item(array.items[i], format, &output, &err)) + die("%s", err.buf); + fwrite(output.buf, 1, output.len, stdout); + putchar('\n'); + + strbuf_release(&err); + strbuf_release(&output); + } ref_array_clear(&array); free(to_free); |