Skip to content

Commit

Permalink
ci: skip the scheduled workflows in forked repositories
Browse files Browse the repository at this point in the history
The idea of the scheduled workflows is to keep the actual
https://git-scm.com/ site up to date. To do that, commits are added to
the branch as needed.

Doing this in fork repositories makes little sense, as these commits
will necessarily diverge from the `gh-pages` branch of
https://github.com/git/git-scm.com/.

So let's not run them in forks.

Note: To allow for improving said workflows, manually triggered runs
will still do the work as intended.

Signed-off-by: Johannes Schindelin <[email protected]>
  • Loading branch information
dscho committed Sep 25, 2024
1 parent d09d33d commit 0221ad5
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions .github/workflows/update-book.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ on:

jobs:
check-for-updates:
if: github.event.repository.fork == false || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/update-download-data.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:

jobs:
update-download-data:
if: github.event.repository.fork == false || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
permissions:
contents: write # to push changes (if any)
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/update-git-version-and-manual-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ on:

jobs:
update-git-version-and-manual-pages:
if: github.event.repository.fork == false || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
permissions:
contents: write # to push changes (if any)
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/update-translated-manual-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ on:

jobs:
check-for-updates:
if: github.event.repository.fork == false || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand Down

0 comments on commit 0221ad5

Please sign in to comment.