Skip to content

Commit

Permalink
chore: sync files (#302)
Browse files Browse the repository at this point in the history
Signed-off-by: GitHub <noreply@github.com>

Co-authored-by: kenji-miyake <kenji-miyake@users.noreply.github.com>
  • Loading branch information
1 parent 0e25ac8 commit 8bddcda
Showing 1 changed file with 15 additions and 1 deletion.
16 changes: 15 additions & 1 deletion .github/workflows/github-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,23 @@ jobs:
id: generate-changelog
uses: autowarefoundation/autoware-github-actions/generate-changelog@v1

- name: Select verb
id: select-verb
run: |
has_previous_draft=$(gh release view --json isDraft -q ".isDraft" "${{ steps.set-tag-name.outputs.tag-name }}")
verb=create
if [ "$has_previous_draft" = "true" ]; then
verb=edit
fi
echo ::set-output name=verb::"$verb"
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Release to GitHub
run: |
gh release create "${{ steps.set-tag-name.outputs.tag-name }}" \
gh release ${{ steps.select-verb.outputs.verb }} "${{ steps.set-tag-name.outputs.tag-name }}" \
--draft \
--target "${{ steps.set-target-name.outputs.target-name }}" \
--title "Release ${{ steps.set-tag-name.outputs.tag-name }}" \
Expand Down

0 comments on commit 8bddcda

Please sign in to comment.