Skip to content
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

Add support for creating GitLab issues #37

Merged
merged 8 commits into from Aug 10, 2021
Merged

Add support for creating GitLab issues #37

merged 8 commits into from Aug 10, 2021

Conversation

tulir
Copy link
Member

@tulir tulir commented Aug 6, 2021

This adds support for creating GitLab issues using https://github.com/xanzy/go-gitlab.

I also updated the report body to have two spaces before newlines so it would work better as markdown. I'd assume GitHub doesn't care either way, but GitLab requires those.

Signed-off-by: Tulir Asokan <tulir@maunium.net>

@richvdh richvdh self-requested a review August 9, 2021 12:07
go.mod Outdated
@@ -1,17 +1,11 @@
module github.com/matrix-org/rageshake

go 1.16
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the readme claims "rageshake requires Go version 1.11 or later."

I have no particular desire to support ancient Go versions, but we better update the documentation and the CI if we want to update it.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated the readme and go.mod to say 1.15 and made matrix-org/pipelines#171 to update the CI.

@@ -541,7 +570,7 @@ func buildReportTitle(p parsedPayload) string {
return trimmedUserText
}

func buildReportBody(p parsedPayload, quoteChar string) *bytes.Buffer {
func buildReportBody(p parsedPayload, newline, quoteChar string) *bytes.Buffer {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is getting a bit confusing. A comment explaining what exactly the parameters do would be helpful.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm also not entirely convinced this needs to be different between email and github/gitlab?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Email isn't markdown and I didn't want to accidentally break something with extra spaces at the end of each line, but I guess it might be fine to add the spaces for emails too. (GitHub is markdown, but doesn't seem to require the two spaces for newlines. GitLab does require spaces to make a newline)

@richvdh richvdh self-requested a review August 10, 2021 11:39
Copy link
Member

@richvdh richvdh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm otherwise

rageshake.sample.yaml Outdated Show resolved Hide resolved
Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
@richvdh
Copy link
Member

richvdh commented Aug 10, 2021

Thanks @tulir!

@richvdh richvdh merged commit 065b2b9 into matrix-org:master Aug 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants