math-study
Static build of the Nebula proxy site, packaged for npm and jsDelivr.
The package contains the generated site routes (.svg, .xml, .xhtml, .xsl,
.svgz, and .svg.gz) plus the runtime assets they reference.
Serve through jsDelivr
After publishing, files are available at:
https://cdn.jsdelivr.net/npm/math-study@<version>/index.svg
https://cdn.jsdelivr.net/npm/math-study@<version>/en_US/index.xml
https://cdn.jsdelivr.net/npm/math-study@<version>/jp/index.xhtml
Use a pinned version in production. @latest is also supported by jsDelivr, but
pinned versions are cached more reliably.
Build
The generated routes are produced from the .svgz sources with xml-build.xsl:
./build.sh # regenerate routes and .svg.gz mirrors
./build.sh --check # verify the checked-in build is current
./build.sh --list # list generated paths
build.sh requires xsltproc and gzip.
Publish
publish.sh prompts for an npm token without echoing it, writes a temporary
mode-600 npmrc, verifies the token with npm whoami, and then publishes. The
temporary file is removed on exit.
./publish.sh
For CI, pass the token through the environment instead of stdin:
NPM_TOKEN=... ./publish.sh
Any extra arguments are forwarded to npm publish, for example:
./publish.sh --dry-run
./publish.sh --otp=123456
Before publishing, prepack runs ./build.sh --check so a stale route tree
cannot be uploaded.
License
MIT. See LICENSE.
The bundled glend / glend-controller runtime is derived from
Mercury Workshop's Scramjet, which is distributed under the MIT license.