split lint docs action

This commit is contained in:
Sidharth Vinod
2022-10-03 14:21:54 +08:00
parent 3bae25fe6b
commit 8d6af3dfed

View File

@@ -20,8 +20,8 @@ jobs:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
if: ${{ github.event_name == 'pull_request' }} if: ${{ github.event_name == 'pull_request' }}
with: with:
repository: ${{ github.event.pull_request.head.repo.full_name }} # repository: ${{ github.event.pull_request.head.repo.full_name }}
ref: ${{ github.event.pull_request.head.ref }} # ref: ${{ github.event.pull_request.head.ref }}
fetch-depth: 0 fetch-depth: 0
- uses: pnpm/action-setup@v2 - uses: pnpm/action-setup@v2
@@ -49,7 +49,7 @@ jobs:
packages/mermaid/src/docs.mts packages/mermaid/src/docs.mts
- name: Run step if any file(s) in the docs folder change - name: Run step if any file(s) in the docs folder change
if: steps.changed-files-fork-point.outputs.any_modified == 'true' if: steps.changed-files-fork-point.outputs.only_modified == 'true'
run: | run: |
echo "Only files in the src/docs folder has changed." echo "Only files in the src/docs folder has changed."
echo "List all the files that have changed: ${{ steps.changed-files-specific.outputs.all_changed_files }}" echo "List all the files that have changed: ${{ steps.changed-files-specific.outputs.all_changed_files }}"
@@ -57,7 +57,7 @@ jobs:
- name: Commit changes - name: Commit changes
uses: EndBug/add-and-commit@v9 uses: EndBug/add-and-commit@v9
if: steps.changed-files-fork-point.outputs.any_modified == 'true' if: steps.changed-files-fork-point.outputs.only_modified == 'true'
with: with:
message: 'Update docs' message: 'Update docs'
add: 'docs/*' add: 'docs/*'