Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions template/.github/workflows/build.yml.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:
tags: ['v*']
pull_request:
branches: [main, master]
# Run on a tag again from the Actions tab once its artifacts have expired.
workflow_dispatch:

permissions:
contents: read
Expand Down
14 changes: 8 additions & 6 deletions template/CONTRIBUTING.md.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -308,12 +308,14 @@ per-driver Lua). `<repo>.zip` sits alongside them and contains `c4z/` and
`docs/` only: `source/` is the driver's unencrypted Lua, which an encrypted
driver must not ship.

`dist/drivercentral/` also holds the DriverCentral listing's text, pasted over
the listing's own at each upload. `revisions.html` is the Revisions tab: every
released `CHANGELOG.md` section as the DriverCentral build shows it.
`description.html` is the description, made from `description.md` in
`resources/drivercentral/`. Both come with the drivercentral CI artifact,
outside the zip.
`dist/drivercentral/listing/` holds what a DriverCentral upload needs beyond the
zip and the PDFs. `description.html` is the listing's description, made from
`description.md` in `resources/drivercentral/`. `revisions.html` is the
Revisions tab, every released `CHANGELOG.md` section as the DriverCentral build
shows it. The product card, the banners and the listing photos are copied from
`resources/drivercentral/`. A tag build's drivercentral CI artifact is the whole
upload. When it has expired, run the Build workflow on the tag again from the
Actions tab.

Step 1 rewrites tracked files in place. Formatting covers `tools/*.py`, all Lua
under `drivers/`, `src/`, `test/`, `tools/` and `vendor/`, and every Markdown
Expand Down
17 changes: 12 additions & 5 deletions template/Makefile.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -197,17 +197,24 @@ docs-readme: preprocess $(VENV_STAMP)
build/$(README_BUILD)/drivers/$(README_DRIVER)/www/documentation/index.md README.md
{% endif %}

# The DriverCentral listing's Revisions tab and description, pasted at each
# upload. They sit beside the zip integrators download, not in it.
# What a DriverCentral upload needs beyond the zip and the PDFs: the listing's
# description, Revisions tab and images. It sits beside the zip integrators
# download, not in it.
docs-drivercentral: preprocess $(VENV_STAMP)
@mkdir -p dist/drivercentral
@rm -rf dist/drivercentral/listing && mkdir -p dist/drivercentral/listing
$(VENV_PY) tools/docs.py revisions \
build/drivercentral/{% if readme_driver_slug == "root" %}documentation{% else %}drivers/$(README_DRIVER)/www/documentation{% endif %}/index.md \
dist/drivercentral/revisions.html
dist/drivercentral/listing/revisions.html
@if [ -f resources/drivercentral/description.md ]; then \
$(VENV_PY) tools/docs.py description \
resources/drivercentral/description.md dist/drivercentral/description.html; \
resources/drivercentral/description.md dist/drivercentral/listing/description.html; \
fi
@cd resources/drivercentral 2>/dev/null || exit 0; \
for f in product-card-300x300.png banners/*.png photos/*.png; do \
[ -f "$$f" ] || continue; \
mkdir -p "$(CURDIR)/dist/drivercentral/listing/$$(dirname "$$f")"; \
cp "$$f" "$(CURDIR)/dist/drivercentral/listing/$$f"; \
done

docs-html: $(VENV_STAMP)
@for build in $(DISTRIBUTIONS); do \
Expand Down
2 changes: 1 addition & 1 deletion template/resources/drivercentral/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Marketing images for the driver's DriverCentral listing. Each banner and photo i

`assets/` holds what the pages share: the Finite Labs logo, `scene.js`, which draws the banners' art, and the brand's logo as `brand-mark.png`.

`description.md` is the listing's description, written as below. `make build` turns it into `dist/drivercentral/description.html`, with `##` as the editor's section headings, for pasting into the listing. The Revisions tab comes from the build too, as `dist/drivercentral/revisions.html`.
`description.md` is the listing's description, written as below. `make build` turns it into `dist/drivercentral/listing/description.html`, with `##` as the editor's section headings, for pasting into the listing. The Revisions tab comes from the build too, as `listing/revisions.html`, and the build copies the product card, banners and listing photos beside them. A tag build's drivercentral artifact holds the whole upload.

## Writing the description

Expand Down
Loading