Skip to content

Check

Check #13

Workflow file for this run

# check for broken links
name: URL Check
on:
push:
branches: [hrm_test]
pull_request:
branches: [hrm_test]
# release:
# types: [published]
workflow_dispatch:
jobs:
url_check:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up R
uses: r-lib/actions/setup-r@v2
- name: Install curl
run: sudo apt-get install -y curl
- name: Run URL check
run: |
Rscript -e "
urls <- c('https://github.com/USEPA/EPATADA/')
for (url in urls) {
status <- system(paste('curl -o /dev/null -s -w \"%{http_code}\"', url), intern = TRUE)
if (status != '200') {
stop(paste('URL check failed for', url))
}
}
"