-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Make component field configurable #150
Make component field configurable #150
Conversation
Codecov Report
@@ Coverage Diff @@
## main #150 +/- ##
=====================================
Coverage 0.00% 0.00%
=====================================
Files 1 1
Lines 67 67
=====================================
Misses 67 67 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
d6f50ee
to
605d8a2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great start, @lgecse!
The component field on Jira appears to support multiple components, so we'll want to support a slice of components vs a single component string in our config.
Additionally, have you considered what will happen in update scenarios (especially ones where the list of components that the user specifies in the config for this tool does not match the list of components already set on Jira)?
Given this tools' goal of being a one-way sync, we should:
- get the current list of components for the issue
- add the components specified in this config, but:
- never remove components that are already set on the issue
(and have tests to ensure that behavior is adhered to)
@justaugustus I was thinking about the update path, I'm working on it rn. The aim of this PR is to make the issue creation work when the I agree with never removing components from Jira issues, only adding new ones to the list. |
017897f
to
f514c5c
Compare
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
d72fc03
to
46ef7d1
Compare
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
Will this be part of this PR or it will be covered by #11? |
@lgecse -- it looks like the commits have slowed here... are you ready for another review pass? |
@justaugustus I'd be happy to get a second review, thanks a lot in advance! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@lgecse -- Flagging a previous review comment, which I think will change some of the logic throughout.
internal/config/config.go
Outdated
RepoName string `json:"repo-name,omitempty" mapstructure:"repo-name"` | ||
JiraURI string `json:"jira-uri,omitempty" mapstructure:"jira-uri"` | ||
JiraProject string `json:"jira-project,omitempty" mapstructure:"jira-project"` | ||
JiraComponents string `json:"jira-components,omitempty" mapstructure:"jira-components"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(discussed in #150 (review))
This should be []string
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
OK, on it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Resolved, please review.
Signed-off-by: Laszlo Gecse <[email protected]>
Signed-off-by: Laszlo Gecse <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @lgecse!!
Fixes #149
Dev notes:
jira-components
field to the config