From 31591fb4c7f726fe1450fe4b57cdd310a9ca7ae4 Mon Sep 17 00:00:00 2001 From: devaryakjha Date: Wed, 25 Dec 2024 08:07:57 +0530 Subject: [PATCH] chore(versioning): update GitHub Actions workflow for versioning and permissions - Modified the versioning workflow to use a personal access token (PAT) instead of the default GITHUB_TOKEN for enhanced permissions. - Added explicit permissions for contents and pull requests to improve workflow capabilities. - Ensured the environment variable GITHUB_TOKEN is now set to the PAT for better access during versioning steps. --- .github/workflows/versioning.yml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/.github/workflows/versioning.yml b/.github/workflows/versioning.yml index 20abac2..e42bfba 100644 --- a/.github/workflows/versioning.yml +++ b/.github/workflows/versioning.yml @@ -8,12 +8,15 @@ on: jobs: publish: + permissions: + contents: write + pull-requests: write runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: - token: ${{ secrets.GITHUB_TOKEN }} + token: ${{ secrets.PAT_TOKEN }} fetch-depth: 0 fetch-tags: true @@ -35,10 +38,9 @@ jobs: run-versioning-prerelease: true create-pr: true env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }} PUB_CREDENTIALS: ${{ secrets.CREDENTIALS_JSON }} - # Fixed tagging command - name: Create Git Tags run: | melos version --yes --no-git-tag-version --prerelease