mirror of
https://github.com/eclipse-sailing-analytics/sailing-analytics.git
synced 2026-11-03 01:29:33 +00:00
release: upload release assets via action-gh-release files:
Fold the tar.gz and release-notes.txt uploads into the single softprops/action-gh-release step using its files: input, and drop the two actions/upload-release-asset@v1 steps. Those steps still emitted the deprecated ::set-output workflow command; action-gh-release infers each asset's content type from its file extension. Assisted-By: Claude (claude-4.8-opus)
This commit is contained in:
1 parent
4f9a4d9d50
commit
f6143d189c
1 file changed
+5
-22
@@ -274,28 +274,11 @@ jobs:
|
||||
name: ${{ env.SIMPLE_VERSION_INFO }}
|
||||
draft: false
|
||||
prerelease: false
|
||||
- name: Upload Release Asset tar.gz
|
||||
id: upload-release-asset-tar-gz
|
||||
if: ${{ github.ref == 'refs/heads/main' || github.ref == 'refs/heads/docker-24' || github.ref == 'refs/heads/docker-25' || startsWith(github.ref, 'refs/heads/releases/') }}
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
|
||||
asset_path: ./dist/${{ env.SIMPLE_VERSION_INFO }}/${{ env.SIMPLE_VERSION_INFO }}.tar.gz
|
||||
asset_name: ${{ env.SIMPLE_VERSION_INFO }}.tar.gz
|
||||
asset_content_type: application/x-tar
|
||||
- name: Upload Release Asset release_notes.txt
|
||||
id: upload-release-asset-release-notes-txt
|
||||
if: ${{ github.ref == 'refs/heads/main' || github.ref == 'refs/heads/docker-24' || github.ref == 'refs/heads/docker-25' || startsWith(github.ref, 'refs/heads/releases/') }}
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
|
||||
asset_path: ./dist/${{ env.SIMPLE_VERSION_INFO }}/release-notes.txt
|
||||
asset_name: release-notes.txt
|
||||
asset_content_type: text/plain
|
||||
# Upload the release assets in this same step (newline-separated globs).
|
||||
# action-gh-release infers the content type from each file's extension.
|
||||
files: |
|
||||
./dist/${{ env.SIMPLE_VERSION_INFO }}/${{ env.SIMPLE_VERSION_INFO }}.tar.gz
|
||||
./dist/${{ env.SIMPLE_VERSION_INFO }}/release-notes.txt
|
||||
- name: Trigger CI job
|
||||
env:
|
||||
CI_JOB_USERNAME: ${{ vars.CI_JOB_USERNAME }}
|
||||
|
||||
Reference in new issue
Block a user