From d8f4273ed03006c7c5614ed9ad289a2aeb96429f Mon Sep 17 00:00:00 2001 From: Norwin Date: Sun, 13 Mar 2022 12:00:21 +0800 Subject: [PATCH] Add TSV to machine-readable formats (#467) ...so no ansi formatting (colors) is emitted in that format (eg `tea labels -o tsv`) Co-authored-by: Norwin Co-authored-by: 6543 <6543@obermui.de> Reviewed-on: https://gitea.com/gitea/tea/pulls/467 Reviewed-by: 6543 <6543@obermui.de> Reviewed-by: Lunny Xiao Co-authored-by: Norwin Co-committed-by: Norwin --- modules/print/table.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/print/table.go b/modules/print/table.go index 7f6988b..26f49f0 100644 --- a/modules/print/table.go +++ b/modules/print/table.go @@ -140,7 +140,7 @@ func outputyaml(headers []string, values [][]string) { func isMachineReadable(outputFormat string) bool { switch outputFormat { - case "yml", "yaml", "csv": + case "yml", "yaml", "csv", "tsv": return true } return false