aboutsummaryrefslogtreecommitdiff
path: root/internal/config
Commit message (Collapse)AuthorAgeFilesLines
* feat(config): reading_lang/reading_version + ReadingCorpus resolverLukasz Kasprzak2026-07-272-0/+53
| | | | | | | | | | | | | | | | Task 3 of national-bibles. Adds reading_lang (any language code) and reading_version (explicit corpus code) config fields, setField cases, renderConfigINI lines + self-documenting header, and Config.ReadingCorpus(): reading_version > reading_lang match > ui_language match > "" (Latin fallback applied by the caller). Also adds an `autoselect` corpus-metadata flag (default true), surfaced during this task: the built-in wuj declares lang=pl, so lang-auto would have re-selected the incomplete Wujek for Polish users and defeated the wuj-drop. wuj.ini now sets autoselect=false, so it is reachable only via an explicit reading_version or --ref; the resolver's language auto-match skips non-autoselectable corpora. A corrected Wujek drop-in (autoselect defaults true) auto-serves Polish with zero config.
* feat(bible): user corpus discovery + override registryLukasz Kasprzak2026-07-271-0/+11
|
* feat(ef): complete offline EF readings — proper ferias, deuterocanon, ↵Lukasz Kasprzak2026-07-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Latin fallback Finish the Extraordinary Form (1962) offline Mass readings so every day of the year resolves in both English and Polish. Temporal engine (temporal_ef.go): - Unique ferial slugs "ef-<season>-<week>-<weekday>" so penitential-season weekdays (Lent, Advent, Passiontide, Easter octave) can key their own proper Masses; green-season ferias have no entry and fall back to the preceding Sunday (the 1962 rule). - Special "ef-lent-after-ashes-<weekday>" case for the days between Ash Wednesday and Lent I, which have their own propers. Lectionary (tridentine-lectionary.ini, 55 -> 143 entries) via genlect.go: - Generator now fetches proper-season weekdays and stores a feria only when its Mass differs from the preceding Sunday's. - cleanCite() normalises two missalemeum data glitches: a stray comma between book and chapter ("4 Kings, 5:1" -> "4 Kings 5:1") and a period-as-separator ("John 20. 19-31" -> "John 20:19-31"), both guarded so legitimate multi-chapter citations are untouched. Citations & corpora: - books.ini: Douay abbreviations in the [en] dialect (Ex, Ezech, Jonas, and 3/4 Kings -> canonical 1/2 Kings), so the EF Lenten epistles resolve while the display keeps modern sigla. - drb.tsv: +205 rows backfilling the deuterocanonical Daniel 13-14 (Susanna, Bel) and Esther 11-16 (Greek additions) from get.bible douayrheims, which the base corpus omitted; scripts/gen-deutero.py documents the fetch. Rendering (liturgy.go): - readingLine() falls back to the Latin Vulgate (complete) when the vernacular corpus lacks a passage, with a clear note. Covers the Polish Wujek deuterocanon gap (no clean public-domain source exists) and any future vernacular gap; faithful to the EF as a Latin rite. Result: 730/730 days resolve for both EN (native) and PL (native + Latin fallback for 3 deuterocanon days). Version 0.32.0 -> 0.33.0.
* chore: bump to 0.32.0 (EF ferial readings)Lukasz Kasprzak2026-07-271-1/+1
|
* chore: bump to 0.31.0 (EF temporal Sunday lectionary + cross-chapter citations)Lukasz Kasprzak2026-07-271-1/+1
|
* chore: bump to 0.30.0 (EF feast readings + books.ini multi-language)Lukasz Kasprzak2026-07-271-1/+1
|
* feat: books.toml -> books.ini, multi-language (add Latin dialect), ↵Lukasz Kasprzak2026-07-271-9/+65
| | | | | | | | | | 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.
* chore: bump to 0.29.0 (deuterocanon in vul + drb)Lukasz Kasprzak2026-07-271-1/+1
|
* chore: bump to 0.28.0 (EF 1962 computed calendar)Lukasz Kasprzak2026-07-271-1/+1
|
* chore: bump to 0.27.0 (custom calendar layers)Lukasz Kasprzak2026-07-271-1/+1
|
* feat(config): 'use' layer stack + CalendarsDir()Lukasz Kasprzak2026-07-272-0/+40
|
* chore: bump to 0.26.1 (self-documenting config.ini)Lukasz Kasprzak2026-07-271-1/+1
|
* config: self-documenting default config.ini (reference header) as single sourceLukasz Kasprzak2026-07-272-34/+36
| | | | | | | | renderConfigINI now emits a top-of-file reference block listing each option's allowed values (full-line comments; ascension/corpus_christi note the 'following Sunday' transfer). seedIfMissing generates from renderConfigINI, so the seed, migrated configs, and web-settings saves all carry the same header; dropped the separate embedded config.ini.
* chore: bump to 0.26.0 (offline OF calendar engine); document -L/--liturgyLukasz Kasprzak2026-07-271-1/+1
|
* feat(config): migrate to INI + one-shot TOML conversion + calendar SelectionLukasz Kasprzak2026-07-274-91/+269
| | | | | | | config.Load/Save now read/write config.ini; a pre-existing config.toml is converted once (old file kept, reversible). New [calendar] section (epiphany/ascension/corpus_christi) + Config.Selection() feeding the engine. Config struct API unchanged, so daily-readings and web /settings keep working.
* lectio-ui reader: go-to-chapter jump (c)Lukasz Kasprzak2026-07-241-1/+1
| | | | | | | | | | Inside a book, 'c' opens a centered prompt showing the book's chapter range (e.g. "1-21: ") and accepts a chapter number to jump straight there, instead of scrolling (handy for Psalm 119 etc). Digits only, backspace edits, Enter clamps to the valid range and opens that chapter at its top, Esc cancels. New modeChapterJump + updateChapterJump/jumpToChapter/ viewChapterJump; i18n ReaderJumpChapter/ReaderJumpChapterKeys (en/pl) and 'c' added to the reading keybar. Only offered when the book has >1 chapter.
* i18n: localize remaining web UI chrome (nav, bookmarks, settings)Lukasz Kasprzak2026-07-241-1/+1
| | | | | | | | | The web nav links (settings, bookmarks, home), the /reader bookmark-add form placeholders and button, the /bookmarks filter/empty/delete labels, and every /settings field label were hardcoded English and stayed English under ui_language=pl. Route them all through i18n (en/pl) so the Polish UI is fully localized. No server.go change: every page's data already carries L: i18n.Get(cfg.UILanguage).
* export: localize calendar title (month name via i18n Months + lectionary ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | label); --ui-lang flag overrides interface/export language (cli + web ?lang=); v0.24.0
* export: month calendar PDF (A4 landscape, Monday-first grid, feast name + ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | gospel ref + liturgical colour per day); cli --calendar YYYY-MM; web /calendar + link; readings.GospelCitation; v0.23.0
* export: internal/export (Markdown/Text/ReadingsPDF via pure-Go go-pdf/fpdf + ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | embedded DejaVu Sans, covers pl/la/gr); cli --md/--pdf/--out; web /export + download links; v0.22.0
* bookmarks: store as universal TSV (header row) with one-time JSON migration; ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | tui note box wraps long notes with hanging indent + hard-break; v0.21.0
* tui reader: bookmark note+tags as a prominent centered modal (tab switches ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | fields), delete confirmation as a modal; v0.20.0
* tui reader: m opens a verse cursor (↑/↓ pick the verse) then a note box ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | (write or skip); d in bookmarks confirms before deleting; v0.19.0
* tui reader: bookmarks (m=mark w/ note, b=list/jump/delete, per-verse via ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | top-visible verse) + remember last place; v0.18.0
* bookmarks: per-verse (optional Verse field); web reader verse input + list ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | shows Book Ch:V; v0.17.0
* cli: --rand -b accepts any version incl. bt (bt falls back to a corpus ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | version instead of erroring); v0.16.1
* cli: --rand/--rand-v (random verse) + --rand-ch (random chapter) from the ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | corpus, using the config default version; v0.16.0
* bookmarks: web reader bookmarks with notes + tags ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | (add/list/filter/jump/delete); v0.15.0
* web: /settings page to edit config + books.toml, persisted and applied live; ↵Lukasz Kasprzak2026-07-242-1/+98
| | | | v0.14.0
* web: drop phantom hidden bt for traditional on explicit submit, so 'no ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | version -> nothing' works in trad too; v0.13.1
* web: empty pane when no version selected (hidden vset marker); config ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | default checked on fresh load; v0.13.0
* grb: strip SBLGNT apparatus markers (U+2E00–U+2E0D); render: show ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | scripture ref in traditional headings; v0.12.0
* corpus: fix vul book mislabel 2 King -> 2 Kings (restores Vulgate 2 Kings); ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | v0.11.1
* citation: render --citation/--week gospel ref in the configured sigla ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | dialect (bible.FormatRef); v0.11.0
* qol: tui jump-to-date (d) + lectio --citation/--week + hide bt for ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | traditional web; v0.10.0
* web reader: /reader book picker + chapter nav + version compare, reusing ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | pane templates; v0.9.0
* reader: lectio-ui --reader fuzzy book picker + chapter reader over the ↵Lukasz Kasprzak2026-07-241-1/+16
| | | | corpora; v0.8.0
* books: language-scoped --ref/--list via customizable books.toml + ↵Lukasz Kasprzak2026-07-243-1/+68
| | | | sigla_style config; v0.7.0
* bible-lookup: add --ref passage lookup + --list-pl/--list-en book lists; v0.6.0Lukasz Kasprzak2026-07-241-1/+1
|
* dayinfo: show feast/day name + colour (modern niedziela + traditional ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | missalemeum) in cli/tui/web; v0.5.0
* rename the pl scripture version to bt (Biblia Tysiąclecia); v0.4.0Lukasz Kasprzak2026-07-243-11/+11
| | | | | | | | | | 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.
* cli: pager for reading output (-P/--pager, --no-pager, config pager, $PAGER ↵Lukasz Kasprzak2026-07-243-1/+38
| | | | fallback); v0.3.0
* tradlit: offline caching + read; update pre-caches traditional; --clean ↵Lukasz Kasprzak2026-07-241-1/+1
| | | | prunes it; v0.2.0
* cli-ui,web: real flag parsing for lectio-ui/lectio-web (accept useful flags, ↵Lukasz Kasprzak2026-07-231-0/+24
| | | | reject unknown, -h/-v)
* i18n: ui_language config (default en) for UI chrome across cli/tui/web; ↵Lukasz Kasprzak2026-07-233-0/+58
| | | | version labels localised
* config,web: web_versions — which version checkboxes start toggled on in ↵Lukasz Kasprzak2026-07-233-0/+11
| | | | lectio-web
* config: parts.new preset to false (uncomment=hide); drop dead ↵Lukasz Kasprzak2026-07-231-21/+12
| | | | parts.traditional; clarify web_theme/web_display are the web defaults
* web: remove deus_vult theme; add global monospace toggle (web_mono config + ↵Lukasz Kasprzak2026-07-233-0/+6
| | | | top-bar 'mono')
* web: default lectio-web to port 1099 with free-port fallbackLukasz Kasprzak2026-07-231-1/+1
| | | | | | | | | | | | | chooseListener(port) factors the listen logic out of Run: port==0 now tries defaultWebPort (1099) first and only falls back to an OS-picked free port if 1099 is taken; a non-zero port is still bound exactly, surfacing its bind error as before. config.Default() keeps WebPort: 0 unchanged (0 still means "auto"). Adds TestChooseListener, robust to sandboxes that can't bind 1099 or :0 (t.Skip instead of failing). Also folds the ?ref= whitespace trim into renderLookup itself so GET / and GET /lookup treat a whitespace-only ref identically (previously only lookupHandler trimmed it).
* web: horizontal/vertical/interlinear display modes + web_display configLukasz Kasprzak2026-07-233-0/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds a display-layout option to lectio-web alongside the existing colour themes: - config: WebDisplay field (toml web_display), default "horizontal", normalized on load via the new exported config.NormalizeDisplay (unknown -> "horizontal", same lenient style as the other web_* fields). - render: extracts the citation/ToEnglishRef resolution shared by GatherVersion into an unexported resolveRef helper (GatherVersion's signature/behavior unchanged) and adds GatherVerses(version, sec, lectionary) returning raw bible.Verse structs plus a versified flag, for column/interlinear alignment. - web/render: RenderReadings gains a display parameter. "horizontal" is the original stacked layout, byte-for-byte the same code path as before. "vertical" reuses the same per-version column data in a .display-vertical/.vcol grid (the CLI compare view, browser-side). "interlinear" maps versions through render.OfflineVersions' pl->wuj substitution (pl has no verse numbers), gathers GatherVerses per version, and interleaves them by chapter:verse into .ilverse/.illine blocks (ordered union of keys, first versified version's order first). - server: adds a display <select> to the top bar wired into the existing #controls HTMX form; a resolveQuery(cfg, r) helper replaces the duplicated date/lectionary/all/versions(+now display) resolution in indexHandler and readingsHandler. - fold-in from the B2 review: indexHandler now populates indexData.Lookup via a shared renderLookup(ref, versions) helper (also used by lookupHandler), so a bookmarked "/?ref=...&v=..." link shows its lookup result instead of an empty pane. - base.css: layout-only rules for the two new modes (no colours; themes stay colour-only). go test ./..., go vet ./..., gofmt clean; go build ./cmd/lectio-web ok.