Skip to content

Link Liveness Checker #103

Link Liveness Checker

Link Liveness Checker #103

# 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