Add tea issues --fields, allow printing labels #312

Merged
6543 merged 16 commits from noerw/tea:print-issue-fields-labels into master 2020-12-21 15:41:07 +00:00
Member
  • refactor the field selection of tea repos ls --fields, so it can be reused with other entities.
  • use the new generic --fields flag & tableFromItems() to add field selection to tea issues ls & tea ms issues
  • add more printable fields to issues, most importantly colored labels :) (fixes #268)

Maybe we should reconsider the default fields that are printed for issues. At least labels should be included I think, not sure if we really need author and updated by default

- refactor the field selection of `tea repos ls --fields`, so it can be reused with other entities. - use the new generic `--fields` flag & `tableFromItems()` to add field selection to `tea issues ls` & `tea ms issues` - add more printable fields to issues, most importantly colored labels :) (fixes #268) Maybe we should reconsider the default fields that are printed for issues. At least `labels` should be included I think, not sure if we really need `author` and `updated` by default
noerw added this to the v0.7.0 milestone 2020-12-17 15:10:38 +00:00
noerw added the
kind
enhancement
kind
refactor
labels 2020-12-17 15:10:38 +00:00
noerw added 8 commits 2020-12-17 15:10:39 +00:00
6543 reviewed 2020-12-17 17:55:04 +00:00
Dismissed
@ -49,3 +53,3 @@
}
print.IssuesList(issues, ctx.Output)
fields, _ := flags.GetFields(cmd, nil)
Owner
-	fields, _ := flags.GetFields(cmd, nil)
+	fields, err := flags.GetFields(cmd, print.IssueFields)
+	if err != nil {
+		return err
+	}
```diff - fields, _ := flags.GetFields(cmd, nil) + fields, err := flags.GetFields(cmd, print.IssueFields) + if err != nil { + return err + } ```
noerw marked this conversation as resolved
Owner

now you use FullName for user, can you add a fiel username witch instead of FullName always use username?

now you use FullName for user, can you add a fiel username witch instead of FullName always use username?
noerw added 3 commits 2020-12-17 19:09:09 +00:00
Author
Member

now you use FullName for user, can you add a fiel username witch instead of FullName always use username?

@6543 This actually was the behaviour before too. I added author-id to get just the raw username.

> now you use FullName for user, can you add a fiel username witch instead of FullName always use username? @6543 This actually was the behaviour before too. I added `author-id` to get just the raw username.
noerw added 1 commit 2020-12-17 20:18:17 +00:00
change default fields
tea issues -> replace updated with labels
tea ms issues -> replace author with labels, reorder
All checks were successful
continuous-integration/drone/pr Build is passing
fb8d82f90a
lunny approved these changes 2020-12-18 04:19:25 +00:00
Dismissed
noerw added 1 commit 2020-12-18 12:28:59 +00:00
fixup! validate provided fields
All checks were successful
continuous-integration/drone/pr Build is passing
561a31c2fd
noerw added 1 commit 2020-12-21 13:41:17 +00:00
Merge branch 'master' into print-issue-fields-labels
All checks were successful
continuous-integration/drone/pr Build is passing
68339676fb
6543 added 1 commit 2020-12-21 15:23:44 +00:00
Merge branch 'master' into print-issue-fields-labels
All checks were successful
continuous-integration/drone/pr Build is passing
144df8384b
6543 approved these changes 2020-12-21 15:32:07 +00:00
Dismissed
6543 added 1 commit 2020-12-21 15:36:08 +00:00
Validate Fields for repos
All checks were successful
continuous-integration/drone/pr Build is passing
e1fb8682fb
6543 merged commit 9efee7bf99 into master 2020-12-21 15:41:07 +00:00
6543 deleted branch print-issue-fields-labels 2020-12-21 15:41:15 +00:00
Sign in to join this conversation.
No description provided.