Skip to content

Commit

Permalink
Added check links as requirement for auto-merge
Browse files Browse the repository at this point in the history
  • Loading branch information
atteggiani committed Sep 9, 2024
1 parent fd5e7ee commit c332fd7
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
8 changes: 7 additions & 1 deletion .github/workflows/automatic_merge.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,17 @@ on:
# Run every Monday at 03:09 (AEDT)
# AEDT is UTC+10 --> Monday at 03:09 AEDT is Sunday at 17:09 UTC
- cron: "9 17 * * SUN"
push:

jobs:
check-links:
runs-on: ubuntu-latest
steps:
- name: Check links
uses: ./.github/workflows/check_links.yml

auto-merge:
runs-on: ubuntu-latest
# needs: check-links
steps:
- name: Checkout repo
uses: actions/checkout@master
Expand Down
14 changes: 5 additions & 9 deletions .github/workflows/check_links.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,25 +6,21 @@ on:
- opened
- reopened
- synchronize
schedule:
# Run every Monday at 03:07 (AEDT)
# AEDT is UTC+10 --> Monday at 03:07 AEDT is Sunday at 17:07 UTC
- cron: "7 17 * * SUN"
workflow_dispatch:
workflow_call:

jobs:
link-check:
runs-on: ubuntu-latest
steps:
- name: Checkout main repo
if: ${{github.event_name == 'schedule'}}
if: ${{github.event_name == 'pull_request'}}
uses: actions/checkout@master
with:
ref: main

- name: Checkout repo
if: ${{github.event_name != 'schedule'}}
if: ${{github.event_name != 'pull_request'}}
uses: actions/checkout@master
with:
ref: main

- name: Link checker
uses: lycheeverse/lychee-action@2b973e86fc7b1f6b36a93795fe2c9c6ae1118621 #v1.10.0
Expand Down

0 comments on commit c332fd7

Please sign in to comment.