Opens Fridays
Opens Fridays is a suggestion box for a local network: one Go binary with no dependencies, run by one person, serving a page where anyone on the network can put a note in without an account. All week the page shows only how many notes are inside, as a count retaken on the hour, at each opening and at each start, and stamped with the minute it is as of. At the posted hour, once a week, the same page shows every note of the closed week in one stated order (sorted by character code), ready to print on an A4 sheet, and a new box starts at zero. Its input is real and nothing else: what people type into the form, the server's own clock and time zone, its own network address, and the notes files in its data directory. No notes are shipped or seeded.
Run
From this folder, with Go 1.22 or later:
go build -o opens-fridays .
TZ=Europe/Berlin ./opens-fridays -opens "Fri 16:00" -addr :8080 -data ./data
It prints one line and nothing after it, for example http://192.168.1.20:8080 Opens Fridays 16:00 Europe/Berlin: the address the team opens, the posted hour, and the zone the hour is kept in. The address is this machine's own address on the network it routes through. If the team cannot reach it, the host's firewall must allow the port.
Flags, all of them: -addr (default :8080), -data (default ./data, created 0700), -opens (default Fri 16:00, a weekday and a 24-hour time in the local zone), -window (default 24h, how long an opened box is shown). If a file in the data directory waits for an opening that is no longer the next one (because -opens was changed), the server names the file and does not start; move the file or change -opens back. The same happens when a box opened earlier on the same day is keyed for the next opening (the hour was moved later during its window), since that opening would replace it.
The door card
Open /plate on any machine on the network and print it (Ctrl+P). It is one A6 card with the posted hour, the address from the startup line and the wordmark, and nothing else. Pin it by the kitchen door. If the host's address changes, reprint it.
What the host can see
The notes, at any time: data/YYYY-MM-DD.json is a JSON array of strings, keyed by the date of the opening it waits for, re-sorted on every write. The host can remove a note by editing it. The server sets the file's and the directory's modification and access times to the opening instant, but the file system keeps the time of the last change (ctime, and on macOS the birth time), which the server cannot edit. The server keeps no log, never reads a visitor's address, and prints one line per start.
An opened box is renamed YYYY-MM-DD.opened.json when it is first shown and deleted when its window ends. The printed sheet is the record; there is no archive.
Conditions of use
These are printed at /conditions, under the heading "Conditions of use. Posted inside the box.":
- No accounts. No names are asked for.
- Visitors' addresses are not read or logged by this server.
- No times are stored. A note is kept with the week it belongs to and nothing else.
- Treatment: whitespace flattened, sorted by character code, nothing else changed.
- The person who runs this server can read the notes file at any time, and can remove a note by editing it. The file system keeps times this server cannot edit. The last change to the file is still visible to its host.
- The count is retaken on the hour, at each opening and whenever this server is restarted. Anyone watching it can tell between which two of those a note arrived.
- The box is not moderated. Anyone on this network can put anything in it.
- Opened notes are deleted 24 hours after they are first shown. (The page prints the
-windowvalue.) - Writing style can identify a person to people who know them. This box does not hide style.
A note is at most 500 characters after its whitespace is flattened, and a box holds at most 100 notes. If a limit stops a note, the page gives the text back in the form exactly as it was typed.
The sheet
A4, 15 mm margins, two columns at 9.5 pt, each note numbered by its place in the sorted order. Measured in headless Chromium with a box of 100 notes of exactly 200 characters: 20 notes fit on the first A4 sheet and 22 on each sheet after it, so the full box prints on 5 pages (out/sheet-100-measure.pdf); 100 short notes of at most 25 characters print on 2 (out/sheet-100-short.pdf). The page makes no one-sheet promise. The footer of every sheet reads "Treatment: whitespace flattened, sorted by character code, nothing else changed." so that a photocopy keeps it.
Checks
go vet ./... && go test ./... # schedule, snapshots, files, retention, on an injected clock
scripts/e2e.sh # the acceptance run, about eight minutes
uv run --with playwright python scripts/look.py # the browser pass: every surface into shots/
scripts/e2e.sh runs on Linux with Go, curl, uv, GNU date and stat, poppler-utils (pdfinfo, pdftotext, pdftoppm) and a headless Chromium (CHROMIUM=/path/to/chrome picks one). It uses the real clock: it sets an opening about three minutes ahead, waits for it, and then waits out a two minute window. scripts/look.py needs Playwright's Chromium (uv run --with playwright playwright install chromium).
BUILD.md lists each acceptance check from the card with the command that verified it and its output.
Colophon
Catalogue no. 026, normal is dead. Set in the system sans-serif on cream, with one rule in brick under the posted hours. Notes are kept in the order of their letters, never of their arrival. The count was correct at the time stated.
Files
- README.md
- box.go
- box_test.go
- go.mod
- main.go
- out/e2e.log
- out/look.log
- out/plate.pdf
- out/sheet-100-measure.pdf
- out/sheet-100-short.pdf
- out/sheet.pdf
- schedule.go
- schedule_test.go
- scripts/e2e.sh
- scripts/look.py
- static/style.css
- static/wordmark.svg
- templates/conditions.html
- templates/front.html
- templates/message.html
- templates/page.html
- templates/plate.html
- templates/sheet.html