branch, tag: use porcelain output
Call ref-filter's setup_ref_filter_porcelain_msg() to enable translated messages for the %(upstream:tack) atom. Although branch.c doesn't currently use ref-filter's printing API's, this will ensure that when it does in the future patches, we do not need to worry about translation. Written-by: Matthieu Moy <matthieu.moy@grenoble-inp.fr> Mentored-by: Christian Couder <christian.couder@gmail.com> Mentored-by: Matthieu Moy <matthieu.moy@grenoble-inp.fr> Signed-off-by: Karthik Nayak <karthik.188@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Karthik Nayak committed
Jan 10, 2017 at 14:19 UTC
56b43607f975841e70203e55bba3c0b0228da6b0
2 files changed
+4
builtin/branch.c
+2
@@ -649,6 +649,8 @@ int cmd_branch(int argc, const char **argv, const char *prefix)
649
OPT_END(),
650
};
651
652
+ setup_ref_filter_porcelain_msg();
653
+
654
memset(&filter, 0, sizeof(filter));
655
filter.kind = FILTER_REFS_BRANCHES;
656
filter.abbrev = -1;
builtin/tag.c
+2
@@ -375,6 +375,8 @@ int cmd_tag(int argc, const char **argv, const char *prefix)
375
OPT_END()
376
};
377
378
+ setup_ref_filter_porcelain_msg();
379
+
380
git_config(git_tag_config, sorting_tail);
381
382
memset(&opt, 0, sizeof(opt));