| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
clectio's Makefile unpacks gen/verses_<form>.keys from the COMMITTED .gz, and
its clean target deletes the plain file. clectio-gen wrote only the plain one,
so regenerating the tables without separately re-gzipping the keys left
gen/liturgy_<form>.h indexing verses the packed text did not hold.
clectio then dereferenced a NULL verse pointer. That shipped: 1246 of the 10957
EF dates in the 2025-2054 range segfaulted, 11% of the calendar. OF was
unaffected -- its tables had not been regenerated since the keys were last
packed.
The two artefacts are generated together, so they are now written together and
cannot drift. OF's keys are byte-different after this (Go's gzip, not gzip(1))
but content-identical, verified.
|
| |
|
|
|
|
|
| |
colitur's differential compares reading citations from this release onward,
and needs them per day rather than per lectionary key -- this engine resolves
a feria to the preceding Sunday's Mass itself, which is exactly the behaviour
the differential has to check.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The verification instrument this task's own diff comparisons run
against emitted season/week/slug/rank/colour but no display name at
all, so it was structurally incapable of seeing the 322-line name.pl
deletion (fix round 2) -- the season/rank/colour columns it already
printed were all still correct, since name is a wholly separate field
naming.CelebrationName reads independently, and no diff against this
tool's own prior output could ever have caught the regression.
Appends two fixed columns after colour (before the existing +other
tokens): the observed celebration's own name.en and name.pl (spaces
replaced with "_" so the line stays whitespace-delimited; "-" for an
empty name, matching the week column's own convention). Format is
documented in the package doc comment as a departure from colitur's
matching day-line format: a straight diff against colitur's output
must now ignore these two trailing-before-others fields.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Prints one line per day, sorted ascending, for a civil-year range: date,
weekday, season, week, observed slug, rank, colour, then zero or more
+slug tokens for the day's other (losing) candidates. The line format
matches colitur's `colitur day` output field-for-field so the two
streams diff directly; every column carries lectio's own vocabulary
(season names, slugs, rank/colour spellings) with no translation toward
colitur's — that mapping belongs to the differential comparator, not
this dumper.
Uses calendar.Compute with Selection{Form: "old"} over the embedded
tridentine layer (caldata.Tridentine()), mirroring the setup already
used by oracle_ef_test.go. Lives in cmd/ because internal/calendar
cannot be imported outside this module; colitur's build is untouched.
Note for the comparator: lectio has no RG 111 commemoration-admission
logic, so the trailing +slug tokens are the day's losing candidates,
not admitted commemorations.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add opt-in flags so clectio's tables can be regenerated from a customized
calendar instead of only the embedded universal one:
clectio-gen -caldir DIR -use a,b [-sanctorale DIR] <new|old> y0 y1 out/
- -caldir + -use stack calendar layers (rank, colour, name, reading.*) over the
calendar; -sanctorale DIR applies a full of.ini/ef.ini replacement.
- The BOOK table stays hermetic (LECTIO_CONFIG still points nowhere), so the
generator can't read a stale user books.ini -- calendar customization and the
book aliases are kept separate concerns.
- config.SetCalendarsDir lets CalendarsDir be pointed at an explicit layer dir
without a full config tree (and without an unrelated books.ini there).
Verified end to end: a layer adding a feast with a proper gospel regenerates
into liturgy_of.h + verses_of.keys, and the rebuilt clectio shows it. Default
(no flags) output is byte-identical to before. make test green.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The help text predated this session's changes. Update all three binaries:
- Taglines: drop "(Polish + 4 versions)" -> "offline ... daily readings (OF + EF)".
- Versions: state that only the Latin Vulgate is built in; wuj/grb/drb are
optional (make build-full, or drop <code>.tsv/.ini into the corpora dir); a
missing version renders "(not in <code>)".
- --ui-lang: now any code (en, pl, ...), not just pl|en; note names/<code>.ini,
ui/<code>.ini, custom calendars and the sanctorale override.
- lectio-ui: drop the removed "bt" version and the no-op -o/--offline flag from
the help (the tool is fully offline; --offline only ever dropped bt).
- lectio-web: drop -o/--offline; add a one-line description of what it serves.
No behaviour change; full suite green.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
hermetic
Two EF Ember-day lessons ("Osee 14:2-10", "2 Esd. 8:1-10") rendered as
"(not in vul)" because the lookup path (ResolveBook, English dialect) lacked
these Douay-Rheims book forms -- they existed only in the Latin dialect, which
ResolveBook does not consult. Add them to the [en] dialect so both lectio and
clectio resolve them (the text is present in vul: Hosea 14, Nehemiah 8).
Also make clectio-gen hermetic: it now points LECTIO_CONFIG at a nonexistent
path so it always uses the EMBEDDED calendar/lectionary/book table, never the
running user's ~/.config/lectio (whose stale books.ini was silently dropping
~30 EF readings from the generated data). It warns on any reading it cannot
resolve. Full range 2025-2054 now generates with 0 dropped readings.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
clectio (~/git/projects/clectio) is a tiny suckless-C daily-readings build
that compiles the calendar, citations and scripture text in. clectio-gen is
its data compiler: it reuses this engine to compute, for a year range, each
day's name/colour/readings and emits corpus-independent C tables plus the
verse KEYS, so the C side is a dumb lookup and the hard liturgical logic
stays here (oracle-validated).
- bible.LookupKeyed(version, ref) returns each resolved verse's
(book, chapter, verse) key, mirroring Lookup's splitting/versification.
clectio-gen uses it to record the exact pericopes a lectionary cites.
- Verified: clectio's output is byte-identical to lectio's readings, day
names 157/157 over a 3-year sample.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The universal calendar of saints can now be refreshed or replaced without a
rebuild: if ~/.config/lectio/sanctorale/of.ini (OF) or ef.ini (EF) is present
and parses, caldata.Base uses it instead of the embedded calendar; a missing or
malformed file falls back to the embedded default, so the binary stays
self-contained and correct out of the box. Local diocesan/national additions
keep layering on top via calendars/ + `use` (unchanged). The temporal cycle and
precedence rules stay in code -- only the sanctorale is data.
- caldata.SetSanctoraleDir hook (mirrors bible/naming/i18n); Base() prefers the
external file per form. config.SanctoraleDir(); wired in the CLI, TUI and web
entry points. Tests cover override, no-file, and malformed-file fallback.
- README: new "Calendar of saints" section (two tiers: overlay via `use`,
replace via sanctorale/<form>.ini); config comment notes the override.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The interface chrome (version labels, TUI keybar/messages, CLI banner words,
web control labels, section-heading words) was English/Polish hardcoded in Go.
It is now data: the English and Polish tables ship as embedded lang/en.ini and
lang/pl.ini, and any language is user-overridable at <config>/ui/<code>.ini,
resolved per key with an English fallback. With ui_language = <code> plus a
names/<code>.ini, the WHOLE interface -- chrome, day names, saint names -- is
translatable without a rebuild.
- i18n.Get loads the embedded English baseline, overlays the embedded/user
language file, caches per lang; field <-> INI-key mapping is by reflection
(lang.go) so the tables and files stay in sync automatically. Edge-space
values (e.g. "error: ") are double-quoted so the INI trim keeps them. The
Go tables move to golden_test.go; TestGoldenMatchesEmbedded asserts the
embedded files still parse back to them, and TestGenerateLangFiles
regenerates them (LECTIO_GEN=1).
- config.UIDir(); wire i18n.SetUserDir in the CLI, TUI and web entry points.
- README/config: document ui/<code>.ini alongside names/<code>.ini.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add internal/naming, which renders temporal day names and celebration
display names from the calendar engine's slugs in any language. English is
the built-in baseline; a language is data -- an embedded lang/<code>.ini
(pl shipped) and/or a user file at <config dir>/names/<code>.ini that
overrides it key by key. Names compose from a small vocabulary plus
per-language format templates, so word order and grammatical case can
differ (e.g. Polish genitive "3. Niedziela Okresu Zwykłego"); any string a
language omits falls back to English.
- Move day-name generation out of calendar (calendar.HumanizeSlug removed,
calendar stays a pure engine) into naming.DayName; the English golden
cases carry over verbatim.
- naming.CelebrationName unifies the three duplicated resolvers
(cli/readings/calfeed): name.<lang> -> English -> Latin -> humanized slug.
Saint names stay in the calendar data (name.<lang>), overridable via
calendar layers.
- config: ui_language now accepts any code (lower-cased, not clamped to
en/pl) so names/<code>.ini applies; UI chrome still resolves en/pl and
falls back to English. Add NamesDir(); wire naming.SetUserDir (and the
previously unwired bible.SetUserCorporaDir) in the TUI and web mains too,
so external corpora and name files work across all three binaries.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The daily view now computes entirely offline (previous commit), so retire the
network path and everything that served it:
- Delete internal/tradlit (missalemeum) and the niedziela scraper from
internal/liturgy (fetch/store/parse + fixtures); keep Section, DayInfo and
ExtractCitation.
- Remove the "bt" version everywhere (render gatherBT + branches, config,
i18n, web form, TUI) and bible.ToEnglishRef (Polish citation converter).
A legacy config carrying "bt" migrates to "wuj" on load (config.migrateBT).
- Remove the traditional_lang config field and the -g/--lang flag from all
three binaries.
- Drop the now-dead flags -R/--refresh, -o/--offline, -u/--update,
-C/--clean and the harvest/clean commands.
- New defaults: versions = wuj,vul,grb,drb; default_version = vul.
Update the README (offline-by-design, no harvest/update), help text, and
stale niedziela/bt doc comments. Tests updated for the offline reality;
go test ./... and go vet ./... are clean, all three binaries build and run
offline (OF + EF, compare, web).
|
| |
|
|
|
|
|
|
|
|
| |
config-scoped citation display
books.ini with [en]/[pl]/[la]; parseBooks reads INI (bible drops go-toml).
Latin dialect resolves EF citations (Eccli->Sirach, Apoc->Revelation, Luc...);
sigla_style gains 'latin'. Reading citations now DISPLAY in the configured
sigla (FormatRef(SiglaLang)), not raw English. One-shot books.toml->books.ini
user migration (go-toml now config-only). Web settings editor -> books.ini.
|
| |
|
|
| |
top-visible verse) + remember last place; v0.18.0
|
| |
|
|
| |
corpora; v0.8.0
|
| |
|
|
|
|
|
|
|
|
| |
The niedziela.pl scraped Polish paragraph text is the Biblia Tysiąclecia
translation; rename its version code from "pl" to "bt" and its i18n label
to "Biblia Tysiąclecia (niedziela.pl)" everywhere the scripture VERSION is
meant, across config, i18n, render, web, tui, cli and both binaries' help
text. Language-role "pl" (ui_language, traditional_lang, i18n.Get lang,
--lang validation) is untouched. Behavior is identical -- bt is still
dropped for offline/traditional and substituted with wuj.
|
| |
|
|
| |
reject unknown, -h/-v)
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
NewServer wires B1's RenderReadings/Themes/themeCSS/embedded static+
templates FS into an http.ServeMux: GET / (full page), GET /readings
(HTMX reading-pane fragment), GET /lookup (bible.Lookup passage search
fragment), GET /theme.css (theme stylesheet, falling back through
cfg.WebTheme to the built-in default on an unknown name), GET /static/.
Run listens on cfg.WebPort (0 = OS-picked free port), prints the URL,
best-effort opens a browser, then serves. cmd/lectio-web is the binary
entry point (config.Load -> web.Run).
Fold-in from the B1 review: hardened themeCSS's name guard to an
explicit ^[A-Za-z0-9_-]+$ allowlist (the old filepath.Base/ContainsAny
check let ".." through), plus guard-rejection and HTML-escaping
regression tests -- B2 is what makes /theme.css?name=<raw> reachable
from the network, so it owns closing this out.
|
| | |
|
| |
|