diff --git a/.github/workflows/main-branch-push.yaml b/.github/workflows/main-branch-push.yaml deleted file mode 100644 index a1c1edc..0000000 --- a/.github/workflows/main-branch-push.yaml +++ /dev/null @@ -1,31 +0,0 @@ -name: Main Branch Push -on: - push: - branches: - - main - - master -jobs: - main-branch-push: - runs-on: ubuntu-latest - permissions: - contents: write - issues: write - pull-requests: write - steps: - - uses: 8BitJonny/gh-get-current-pr@2.1.0 - id: PR - # checkov:skip=CKV_GHA_3 bypass check for CKV_GHA_3 since the GITHUB_TOKEN will be a one-time token https://docs.bridgecrew.io/docs/suspicious-use-of-curl-with-secrets - - name: Warn remaining PR branch - run: | - echo "=====> Query remaining pull requests" - response=$(curl \ - -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" \ - -H "Accept: application/vnd.github.v3+json" \ - https://api.github.com/repos/${{ github.repository }}/pulls?per_page=100) - export pr_number=$(echo "$response" | jq '.[].number') - - echo "=====> Warn pull requests branch" - - for p in $pr_number; do - curl -s -X POST -H "Accept: application/vnd.github+json" -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://api.github.com/repos/${{ github.repository }}/issues/$p/comments -d "{\"body\":\"MAIN BRANCH PUSH DETECTED DUE TO #${{steps.PR.outputs.number}}, THIS PR NEED TO BE UPDATED TO TRIGGER CI.\"}" - done \ No newline at end of file diff --git a/.github/workflows/update-changelog.yaml b/.github/workflows/update-changelog.yaml index b5a7136..0afc28e 100644 --- a/.github/workflows/update-changelog.yaml +++ b/.github/workflows/update-changelog.yaml @@ -39,6 +39,7 @@ jobs: MAJOR_VERSION=$((MAJOR_VERSION+1)) fi docker run --rm -v $(pwd):/src -w /src githubchangeloggenerator/github-changelog-generator -u ${{ github.repository_owner }} -p ${{ github.event.repository.name }} -t ${{ secrets.GITHUB_TOKEN }} --no-issues --no-compare-link --include-tags-regex "$MAJOR_VERSION\..*\..*" + sudo chmod -R ugo+rwX . - name: Commit & Push changes uses: actions-js/push@master with: