upload-release-action
upload-release-action copied to clipboard
Add draft release support
I had originally put this in and then removed it again as at https://github.com/svenstaro/upload-release-action/commit/1daf68639d5e4ffe0cd591010d871920f963c8a4
The reason was that draft releases don't support getting by tag via API as draft releases don't create tags.
These folks over here had the exact same problem and solved it in a different fashion: https://github.com/electron-userland/electron-builder/blob/7b335dbd7e5ca754598ca93318be1404fc518485/packages/electron-publish/src/gitHubPublisher.ts#L91
Sweet! Can't wait to use this. thnx
I used this action successfully on draft releases.
Here: https://github.com/Happypig375/github-actions-for-packages/blob/67a80bfb1baf1745dfee26d739ee86e9fdffe414/.github/workflows/Release%20Drafter.yml
I tried this the way Happypig is suggestion but it does not seem to work for me.. I end up with a duplicate release
@svenstaro I actually found this because I'm using release-drafter as well, but I'm a bit confused about whether upload-release-action
is just for uploading files to a release (the title says "Upload files to a GitHub release") or if it's actually creating the release as well.
If it's the latter, could that be clarified in the README?
Also, if it does create a release as well, is there a way to disable that so I can just upload an asset to the release draft created by release-drafter
?
@andrewbanchich in my testing it seems to create the release for the given tag if it doesn't exist yet, and otherwise just uses the existing release (probably only makes sense if "overwrite" is true).
@svenstaro any progress on this one?
I’m guessing this hasn’t been implemented yet (I see that #38 is open but seems abandoned), but I wanted to check and be sure.
Extremely grateful for this useful action and been using it for a long time! Yet, for my use case sometimes I’d really prefer to be able to upload assets to draft releases.
I haven't had time to work on this but I actively maintain the project at least so if you feel like making a contributions there's a good chance we could merge it quickly.
Thanks. I haven't played around very much with how releases show up and work with the GitHub API, but I might take a shot at it in the future.
I did some extra digging a few days back after my post and saw that unfortunately the release
event doesn't trigger at all for draft releases, which makes this feature less useful (not totally pointless, but I assume one would need to push a tag to trigger the creation of the draft release...)
Anyway, thanks again for developing the package and keeping it maintained!