From f6438a9d07033ec4b0e588749333a24cde8ac4e2 Mon Sep 17 00:00:00 2001 From: Markus Hoffrogge Date: Fri, 16 Dec 2022 08:08:40 +0100 Subject: [PATCH] Fix warnings on release workflow (#293) --- .github/workflows/release.yaml | 29 ++++++++++++----------------- 1 file changed, 12 insertions(+), 17 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 03a9f325..aa3a551d 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -65,24 +65,19 @@ jobs: id: vars shell: bash run: | - echo "::set-output name=sha_short::$(git rev-parse --short HEAD)" - echo "::set-output name=timenow::$(date +'%Y-%m-%d')" + echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT + echo "timenow=$(date +'%Y-%m-%d')" >> $GITHUB_OUTPUT + - name: Rename release artifact + shell: bash + run: | + mv -v document.pdf armbian-document-${{ steps.vars.outputs.sha_short }}.pdf - name: Create Release - id: create_release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + uses: ncipollo/release-action@v1 with: - tag_name: ${{ steps.vars.outputs.sha_short }} - release_name: ${{ steps.vars.outputs.timenow }}-${{ steps.vars.outputs.sha_short }} + tag: ${{ steps.vars.outputs.sha_short }} + name: ${{ steps.vars.outputs.timenow }}-${{ steps.vars.outputs.sha_short }} draft: false prerelease: false - - name: Upload PDF to releases - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - asset_path: document.pdf - asset_name: armbian-document-${{ steps.vars.outputs.sha_short }}.pdf - asset_content_type: application/pdf + token: ${{ secrets.GITHUB_TOKEN }} + artifacts: armbian-document-${{ steps.vars.outputs.sha_short }}.pdf + artifactContentType: application/pdf