Allow empty inputs with release artifacts #110
Merged
+28
−3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Resolves #109
Some projects don't generate artifacts as part of their releases but would still like to have their source archives attached to releases signed (using
release-signing-artifacts
). This was previously not possible to do with this action becauseinputs
was a required input.With this pull request, it will be possible to not specify
inputs
and userelease-signing-artifacts
for releases:Note that
inputs
is still required ifrelease-signing-artifacts
is nottrue
and the event type is notrelease
. In this case, the action will raise a descriptive error.Release Note
inputs
was made optional when the event type isrelease
andrelease-signing-artifacts
is true.Documentation
I adjusted the README to reflect the changes.
Tests
I'm not sure if I should add tests or not. I tested locally different scenarios and also ran the
selftest
workflow in my fork (https://github.com/JeanChristopheMorinPerso/gh-action-sigstore-python/actions/runs/7949857773), but I'm not sure how to properly test the release scenario without releasing a fork of the action...