Skip to content

Commit 531b8d1

Browse files
committed
Improved lint to focus on markdown and fixed images in the developer guide
1 parent 8db7910 commit 531b8d1

File tree

3 files changed

+417
-16
lines changed

3 files changed

+417
-16
lines changed

.github/workflows/website-docs.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -72,20 +72,22 @@ jobs:
7272
WEBSITE_INCLUDE_JAVADOCS: "true"
7373
WEBSITE_INCLUDE_DEVGUIDE: "true"
7474

75-
- name: Lint internal links and images
75+
- name: Lint markdown links and static images
7676
run: |
7777
set -euo pipefail
78-
python3 scripts/website/lint_site_links.py \
79-
--site-dir docs/website/public \
78+
python3 scripts/website/lint_markdown_links.py \
79+
--content-root docs/website/content \
80+
--static-root docs/website/static \
81+
--redirects-file docs/website/static/_redirects \
8082
--max-log-errors 300 \
81-
--report-file docs/website/reports/link-lint-report.txt
83+
--report-file docs/website/reports/markdown-link-lint-report.txt
8284
83-
- name: Upload link lint report
85+
- name: Upload markdown link lint report
8486
if: ${{ always() }}
8587
uses: actions/upload-artifact@v4
8688
with:
87-
name: link-lint-report
88-
path: docs/website/reports/link-lint-report.txt
89+
name: markdown-link-lint-report
90+
path: docs/website/reports/markdown-link-lint-report.txt
8991
if-no-files-found: ignore
9092

9193
- name: Audit source URLs (absolute/WordPress)

scripts/website/build.sh

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -64,15 +64,12 @@ build_developer_guide_for_site() {
6464
)
6565

6666
cp "${html_out}/developer-guide.html" "${manual_dir}/index.html"
67-
cp "${html_out}/developer-guide.html" "${WEBSITE_DIR}/static/developer-guide.html"
68-
69-
for asset_dir in "${source_dir}"/*; do
70-
local base_name
71-
base_name="$(basename "${asset_dir}")"
72-
if [ -d "${asset_dir}" ] && [ "${base_name}" != "sketch" ]; then
73-
cp -R "${asset_dir}" "${manual_dir}/"
74-
fi
75-
done
67+
# Keep assets next to /manual/index.html exactly where generated HTML resolves them.
68+
rsync -a \
69+
--exclude 'sketch/' \
70+
--exclude '*.asciidoc' \
71+
--exclude '*.adoc' \
72+
"${source_dir}/" "${manual_dir}/"
7673
}
7774

7875
if ! command -v "${HUGO_BIN}" >/dev/null 2>&1; then

0 commit comments

Comments
 (0)