From 5f563ef584bebf4f441d2bd5834ec21fb29a4173 Mon Sep 17 00:00:00 2001 From: Matthias Mair Date: Wed, 1 Feb 2023 00:17:59 +0100 Subject: [PATCH] Feat/check links (#125) * always run CI, check for html errors * fix links * switch a tags to div * add alt text * fix internal links * remove unneeded example section * remove legacy section * update requirements * test more * fix flag --- .github/workflows/deploy.yml | 7 ++++--- Gemfile | 1 + Gemfile.lock | 23 +++++++++++++++++++++-- _data/functions/extras.yml | 2 +- _includes/base/footer.html | 4 ++-- _includes/block/features.html | 2 +- _includes/partial/newsletter.html | 4 ++-- _layouts/collection/collection_index.html | 2 +- _news/2022-11-14-website.md | 2 +- _posts/2021-11-22-translation.md | 4 ++-- _posts/2023-01-02-upcoming.md | 2 +- _publishers/SergeoLacruz.md | 2 +- deploy.md | 4 ++-- extend/app.md | 2 +- extend/index.md | 2 +- support.md | 2 +- use/maker.md | 10 ---------- 17 files changed, 43 insertions(+), 32 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 45657133..b3cc0b71 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -1,9 +1,7 @@ name: Build pages and publish on: - push: - branches: - - main + push jobs: build: @@ -23,7 +21,10 @@ jobs: uses: limjh16/jekyll-action-ts@v2 with: enable_cache: true + - run: bundle exec htmlproofer ./_site --enforce-https=false + name: Check links - name: Deploy + if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main'}} uses: peaceiris/actions-gh-pages@v3 with: github_token: ${{ secrets.GITHUB_TOKEN }} diff --git a/Gemfile b/Gemfile index 16b2a3e2..caa6dac9 100644 --- a/Gemfile +++ b/Gemfile @@ -10,3 +10,4 @@ group :jekyll_plugins do gem 'jekyll_custom_permalink' end gem "webrick", "~> 1.7" +gem 'html-proofer' diff --git a/Gemfile.lock b/Gemfile.lock index 50e896b5..e748d7c3 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -13,13 +13,23 @@ GEM em-websocket (0.5.3) eventmachine (>= 0.12.9) http_parser.rb (~> 0) + ethon (0.16.0) + ffi (>= 1.15.0) eventmachine (1.2.7) ffi (1.15.5) forwardable-extended (2.6.0) - google-protobuf (3.21.12-x86_64-linux) html-pipeline (2.14.3) activesupport (>= 2) nokogiri (>= 1.4) + html-proofer (4.4.3) + addressable (~> 2.3) + mercenary (~> 0.3) + nokogiri (~> 1.13) + parallel (~> 1.10) + rainbow (~> 3.0) + typhoeus (~> 1.3) + yell (~> 2.0) + zeitwerk (~> 2.5) http_parser.rb (0.8.0) i18n (1.12.0) concurrent-ruby (~> 1.0) @@ -64,12 +74,16 @@ GEM rb-inotify (~> 0.9, >= 0.9.10) mercenary (0.4.0) minitest (5.17.0) + nokogiri (1.14.0-aarch64-linux) + racc (~> 1.4) nokogiri (1.14.0-x86_64-linux) racc (~> 1.4) + parallel (1.22.1) pathutil (0.16.2) forwardable-extended (~> 2.6) public_suffix (5.0.1) racc (1.6.2) + rainbow (3.1.1) rb-fsevent (0.11.2) rb-inotify (0.10.1) ffi (~> 1.0) @@ -80,15 +94,20 @@ GEM ffi (~> 1.9) terminal-table (3.0.2) unicode-display_width (>= 1.1.1, < 3) + typhoeus (1.4.0) + ethon (>= 0.9.0) tzinfo (2.0.5) concurrent-ruby (~> 1.0) unicode-display_width (2.4.2) webrick (1.7.0) + yell (2.2.2) + zeitwerk (2.6.6) PLATFORMS x86_64-linux DEPENDENCIES + html-proofer jekyll jekyll-feed jekyll-mentions @@ -99,4 +118,4 @@ DEPENDENCIES webrick (~> 1.7) BUNDLED WITH - 2.3.26 + 2.4.6 diff --git a/_data/functions/extras.yml b/_data/functions/extras.yml index d18d7c8c..dd310b7e 100644 --- a/_data/functions/extras.yml +++ b/_data/functions/extras.yml @@ -7,4 +7,4 @@ functions: link: https://docs.inventree.org/en/latest/report/report/ - title: Extend and Customize text: InvenTree is designed to be highly extensible. If the core InvenTree functionality does not meet your particular need, InvenTree provides a RESTful API, a native Python library, and a powerful plugin system. - link: https://docs.inventree.org/en/latest/extend/api/ + link: https://docs.inventree.org/en/latest/api/api/ diff --git a/_includes/base/footer.html b/_includes/base/footer.html index 41a81eec..b1839f62 100644 --- a/_includes/base/footer.html +++ b/_includes/base/footer.html @@ -1,10 +1,10 @@