From 6ff0f50cf6b7ad494641e34dd37e2027fecb13b5 Mon Sep 17 00:00:00 2001 From: Ed Baker Date: Tue, 5 Sep 2023 09:30:48 -0700 Subject: [PATCH] ci: Limit link checks to intel/perfmon Automatically checking links is intended to be a low volume reminder to update stale links. It isn't necessary for every fork (examples in [1] and [2]) to also act as a reminder. This pull request checks if the repository is 'intel/perfmon' and further removes push and pull_request triggers. [1] https://github.com/edwarddavidbaker/perfmon/actions/workflows/check-markdown-links.yml?query=event%3Aschedule [2] https://github.com/captain5050/perfmon/actions/workflows/check-markdown-links.yml?query=event%3Aschedule --- .github/workflows/check-markdown-links.yml | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/.github/workflows/check-markdown-links.yml b/.github/workflows/check-markdown-links.yml index 9c6fc1de..86fff396 100644 --- a/.github/workflows/check-markdown-links.yml +++ b/.github/workflows/check-markdown-links.yml @@ -1,12 +1,6 @@ name: Check Markdown links on: - pull_request: - branches: - - main - push: - branches: - - main schedule: # Tuesdays at 9AM PST. GitHub Actions run in UTC. - cron: '0 16 * * 2' @@ -14,6 +8,9 @@ on: jobs: markdown-link-check: runs-on: ubuntu-latest + # Only run link checks in the main repo and not forks. The intent + # is a low volume reminder to update stale links. + if: github.repository == 'intel/perfmon' steps: - uses: actions/checkout@v3 - uses: gaurav-nelson/github-action-markdown-link-check@v1