diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fd199c9..cc243f2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -75,19 +75,7 @@ jobs: uses: actions/download-artifact@v4 with: name: ncc-build - - - name: List files - run: | - ls -R - - - name: Get the release upload URL - id: get_release - run: | - release_id=$(curl -s \ - -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ - "$GITHUB_API_URL/repos/${{ github.repository }}/releases/tags/${{ github.event.release.tag_name }}" \ - | jq -r '.upload_url' | sed -e "s/{?name,label}//") - echo "::set-output name=upload_url::$release_id" + path: ncc-build - name: Upload release artifact to GitHub run: | @@ -99,8 +87,8 @@ jobs: -H "Authorization: Bearer ${{ secrets.GITHUB_TOKEN }}" \ -H "Content-Type: application/octet-stream" \ --data-binary @"$BUILD_FILE" \ - "${{ steps.get_release.outputs.upload_url }}?name=$(basename $BUILD_FILE)" + "$GITHUB_API_URL/repos/${{ github.repository }}/releases/${{ github.event.release.id }}/assets?name=$(basename $BUILD_FILE)" else echo "Build artifact not found" exit 1 - fi \ No newline at end of file + fi