diff --git a/.github/workflows/pr_commits.yml b/.github/workflows/pr_commits.yml index 4115298..fe8ed84 100644 --- a/.github/workflows/pr_commits.yml +++ b/.github/workflows/pr_commits.yml @@ -10,7 +10,6 @@ jobs: - uses: actions/checkout@v3 with: fetch-depth: 0 - ref: ${{ github.head_ref }} - uses: dart-lang/setup-dart@v1.3 @@ -18,4 +17,4 @@ jobs: run: dart pub get - name: Validate PR Commits - run: VERBOSE=true dart run commitlint_cli --from="origin/${{ github.base_ref }}" --to="${{ github.head_ref }}" --config lib/commitlint.yaml + run: VERBOSE=true dart run commitlint_cli --from=${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to=${{ github.event.pull_request.head.sha }} --config lib/commitlint.yaml diff --git a/docs/guides-setup.md b/docs/guides-setup.md index 32ea75d..20374cb 100644 --- a/docs/guides-setup.md +++ b/docs/guides-setup.md @@ -101,7 +101,6 @@ jobs: - uses: actions/checkout@v3 with: fetch-depth: 0 - ref: ${{ github.head_ref }} - uses: dart-lang/setup-dart@v1.3 @@ -109,5 +108,5 @@ jobs: run: dart pub get - name: Validate PR Commits - run: dart run commitlint_cli --from="origin/${{ github.base_ref }}" --to="${{ github.head_ref }}" + run: VERBOSE=true dart run commitlint_cli --from=${{ github.event.pull_request.head.sha }}~${{ github.event.pull_request.commits }} --to=${{ github.event.pull_request.head.sha }} --config lib/commitlint.yaml ```