diff options
author | Achilleas Pipinellis <axil@gitlab.com> | 2022-03-29 04:23:07 +0300 |
---|---|---|
committer | Marcel Amirault <mamirault@gitlab.com> | 2022-03-29 04:23:07 +0300 |
commit | 725dac5ba814c4c871afc24f9887155f0cd53ccb (patch) | |
tree | b5afc05ffc500cfb01f5af59494d31ba0e2ad4f7 | |
parent | 1a5631d58f3928a537c5d7eba13c66f9bb8928a9 (diff) |
Check for 'index.html' in navigation.yaml
-rw-r--r-- | .gitlab-ci.yml | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index be379460..0c405272 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -261,6 +261,26 @@ check_duplicate_redirects: - exit $(cat output.txt | wc -l) # +# Check for index.html in navigation.yaml +# +check_index_html: + image: busybox + extends: + - .rules_site_tests + needs: [] + before_script: [] + stage: test + script: + # Check for index.html in navigation.yaml and write the output in output.txt + - grep -Ir "/index.html" content/_data/navigation.yaml | sed -e '/^#/d' | tee output.txt + - | + echo "***************************************************************************" + echo "* If this job failed, it is because a navbar entry is using 'index.html'. *" + echo "* Link to just '/' instead, For example 'ee/user/' *" + echo "***************************************************************************" + - exit $(cat output.txt | wc -l) + +# # Run rspec tests # rspec: |