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

fix: add support for message output #32

Merged
merged 8 commits into from
Oct 9, 2023
Merged

Conversation

wtrocki
Copy link
Contributor

@wtrocki wtrocki commented Aug 28, 2023

fix for #29

@wtrocki
Copy link
Contributor Author

wtrocki commented Oct 2, 2023

FYI: @joelanford

README.md Outdated
@@ -40,6 +40,11 @@ Skip automatic caching of go module directories (default: `false`)

Returns the type (patch, minor, major) of the sementic version that would be required if producing a release.

#### `message`
Copy link
Owner

Choose a reason for hiding this comment

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

nit: can we call this output instead of message? output seems a bit more intuitive, at least to me, because this will have the full output of the go-apidiff command.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

action.yml Outdated
@@ -72,5 +75,12 @@ runs:
echo "semver-type=minor" >> $GITHUB_OUTPUT
exit 0
fi
EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64)
Copy link
Owner

Choose a reason for hiding this comment

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

I've never seen this before. Is this a security measure to prevent code injection?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is how github recommends to do multiline output

action.yml Outdated
Comment on lines 80 to 84
{
echo "output<<$EOF"
echo "$OUTPUT"
echo "$EOF"
} >> $GITHUB_OUTPUT
Copy link
Owner

Choose a reason for hiding this comment

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

Seems like we'll only be setting the output variable if semver-type=major. I think this needs to move up above the semver-type checks.

@joelanford joelanford merged commit 77c3d01 into joelanford:main Oct 9, 2023
1 check passed
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