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

bug: Prevent draft release creation if release already exists #28

Merged
merged 1 commit into from
Oct 24, 2022

Conversation

gabe565
Copy link
Contributor

@gabe565 gabe565 commented Oct 18, 2022

Currently, this action attempts to create a new release with assets and falls back to uploading to an existing release. Even if the call to gh release create fails, GitHub creates a draft release with assets attached.

Example

In gabe565/gh-profile, I created release v1.1.0 in the web UI. The action runs and logs the following:

image

But a draft release is created:

image

This PR modifies this behavior by checking if a release exists first. If it does, gh release upload is called. Else, gh release create is called.

@jef
Copy link

jef commented Oct 19, 2022

This is exactly the case!

Copy link
Contributor

@mislav mislav left a comment

Choose a reason for hiding this comment

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

Thanks!

@mislav mislav merged commit 397af79 into cli:trunk Oct 24, 2022
daido1976 added a commit to daido1976/gh-report that referenced this pull request Dec 28, 2022
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.

3 participants