diff --git a/.github/workflows/commit-check.yml b/.github/workflows/commit-check.yml index d9faf0e..b68a5dc 100644 --- a/.github/workflows/commit-check.yml +++ b/.github/workflows/commit-check.yml @@ -16,8 +16,6 @@ jobs: with: fetch-depth: 0 # Required for merge-base checks - uses: ./ # self test - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed for PR comments with: message: true branch: true diff --git a/README.md b/README.md index 826bc2e..6da81e2 100644 --- a/README.md +++ b/README.md @@ -52,8 +52,6 @@ jobs: with: fetch-depth: 0 # Required for merge-base checks - uses: commit-check/commit-check-action@v2 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed for PR comments with: message: true branch: true @@ -123,7 +121,7 @@ jobs: - Default: `false` > [!IMPORTANT] -> `pr-comments` is an experimental feature. By default, it's disabled. To use it, you need to set `GITHUB_TOKEN` in the GitHub Action. +> `pr-comments` is an experimental feature. By default, it's disabled. > > This feature currently doesn’t work with forked repositories. For more details, refer to issue [#77](https://github.com/commit-check/commit-check-action/issues/77). diff --git a/action.yml b/action.yml index 68df492..98552ef 100644 --- a/action.yml +++ b/action.yml @@ -69,3 +69,4 @@ runs: DRY_RUN: ${{ inputs.dry-run }} JOB_SUMMARY: ${{ inputs.job-summary }} PR_COMMENTS: ${{ inputs.pr-comments }} + GITHUB_TOKEN: ${{ github.token }}