A chat page where the maintainer talks with this project's session about
everything they're working on: the conversation is the session's own forum
thread, served by this repository as the Fossil extension /ext/console.
DESIGN.md says what it is and why; HISTORY.md
what happened and what it taught; SETUP.md every step used to
enable the project.
Test
shards install
crystal run ci.cr # both builds' specs, as OCX's release route asks
crystal spec # reads through SQLite (the default build)
crystal spec -Dfossil_command # reads by running fossil
Both use a throwaway repository. The browser test bench serves one with the console as its extension and drives this session's Chromium (tools/browser-rootfs) as a person would:
crystal run tools/bench/bench.cr -- OCX2 [ROOTFS] [SHOTS]
OCX2 is an ocx2 to post with, such as the agents daemon's release.
Build
The server runs a static x86_64 binary. Alpine's static libraries come from
the Alpine root that tools/browser-rootfs makes (./browser_rootfs make),
at $HOME/browser-rootfs:
crystal build --release --static --no-debug \
--link-flags "-L$HOME/browser-rootfs/usr/lib -llzma -s" \
src/main.cr -o bin/console-static
-s strips it. Build with -Dfossil_command to read by running fossil.
crystal run ci.cr -- build OUT x86_64 runs the specs and, only if all pass,
makes the same binary into OUT with gate.txt and release.txt (each file's
SHA-256), as OCX's release route will take it from a client once that route
opens to other projects; crystal run ci.cr -- programs says what it builds.
Install on the server
As swk-ai is installed (its HANDOFF.md, "How to change it"): the session
commits the source and posts, in its thread, the check-in, the binary's
fossil sha3sum and where it is. An admin checks the hash, copies the build
into the server's extension directory as console.new, then renames it to
console (a plain copy over a running binary fails with "Text file busy").
It is then served as /ocx-console/ext/console, and refuses every other
repository.