diff --git a/.github/actions/release/action.yaml b/.github/actions/release/action.yaml index db2cbbe..510ecde 100644 --- a/.github/actions/release/action.yaml +++ b/.github/actions/release/action.yaml @@ -2,6 +2,9 @@ name: Release description: create a GitHub Release and upload artifacts inputs: + github_token: + description: "GitHub token to request GitHub API" + required: true tag: description: "The tag name of the release" required: true @@ -18,12 +21,15 @@ runs: node-version: 18 - name: Install dependencies + shell: bash run: npm ci - name: Build project + shell: bash run: npm run build - name: Zip artifacts + shell: bash run: | zip -r notoin-bar-colorize.zip dist/ @@ -32,4 +38,5 @@ runs: with: files: notoin-bar-colorize.zip body_path: CHANGELOG.md - tag_name: ${{ inputs.tag }} \ No newline at end of file + tag_name: ${{ inputs.tag }} + token: ${{ inputs.github_token }} diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 936466d..52f3b27 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -28,3 +28,4 @@ jobs: uses: ./.github/actions/release with: tag: ${{ github.ref_name }} + github_token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/tagpr.yaml b/.github/workflows/tagpr.yaml index fea1dad..77514e8 100644 --- a/.github/workflows/tagpr.yaml +++ b/.github/workflows/tagpr.yaml @@ -34,3 +34,4 @@ jobs: - uses: ./.github/actions/release with: tag: ${{ needs.tagpr.outputs.tag }} + github_token: ${{ secrets.GITHUB_TOKEN }}