-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
52 lines (42 loc) · 1.44 KB
/
validate-links.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
name: "Link Liveness Checker"
on:
workflow_dispatch:
schedule:
- cron: '0 0 * * 0' # Sunday midnight UTC
push:
branches: [master, main]
pull_request:
branches: [master, main]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
validateLinks:
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout code
uses: actions/checkout@v4
- uses: actions/cache@v4
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-urlsup
- name: Install urlsup
# Check if the urlsup was already installed and retrieved
# from the cache in the previous step
run: command -v urlsup || cargo install urlsup
- name: Validate links
run: |
# Some URLs could be flaky, try twice in case the first execution fails.
bash run_awesome_bot.sh || bash run_awesome_bot.sh