Skip to content

Commit 27f17ae

Browse files
miharpclaude
andcommitted
Add htmlproofer CI workflow (advisory)
Adds htmlproofer to the CI pipeline to catch broken internal links on every PR and push to master. Runs in advisory mode (continue-on-error: true) due to inherited link debt from the Puppet docs migration. - Internal links only (--disable-external) to avoid third-party flakiness - Ignores legacy /puppet/, /pe/, /puppetlabs/ URL prefixes - Pinned to ubuntu-24.04 and actions/checkout@v4 to match test.yml Signed-off-by: Michael Harp <mike@mikeharp.com> Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 0469c3c commit 27f17ae

2 files changed

Lines changed: 32 additions & 0 deletions

File tree

.github/workflows/htmlproofer.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
---
2+
name: HTML Proofer
3+
4+
on:
5+
pull_request: {}
6+
push:
7+
branches:
8+
- master
9+
workflow_dispatch: {}
10+
11+
permissions:
12+
contents: read
13+
14+
jobs:
15+
html-proofer:
16+
runs-on: ubuntu-24.04
17+
steps:
18+
- uses: actions/checkout@v4
19+
- uses: ruby/setup-ruby@v1
20+
with:
21+
ruby-version: '3.3'
22+
bundler-cache: true
23+
- name: Build site
24+
run: bundle exec jekyll build
25+
- name: Check links (advisory — failures reported but do not block)
26+
continue-on-error: true
27+
run: |
28+
bundle exec htmlproofer _site \
29+
--disable-external \
30+
--ignore-urls "/puppet/,/pe/,/puppetlabs/" \
31+
--allow-hash-href

Gemfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ gem 'rake', '~> 13.0', '>= 13.0.1'
1010
gem 'versionomy', '~> 0.5.0'
1111

1212
group(:build_site) do
13+
gem 'html-proofer', '~> 5.0'
1314
gem 'jekyll', '~> 4.4'
1415
gem 'jekyll-vitepress-theme', '~> 1.4'
1516
end

0 commit comments

Comments
 (0)