summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'scripts')
-rw-r--r--scripts/gen-sanctoral.go21
1 files changed, 16 insertions, 5 deletions
diff --git a/scripts/gen-sanctoral.go b/scripts/gen-sanctoral.go
index 561bec0..6d81d66 100644
--- a/scripts/gen-sanctoral.go
+++ b/scripts/gen-sanctoral.go
@@ -112,6 +112,15 @@ func main() {
entries := map[string]entry{} // slug -> entry (first year wins per slug)
+ // Genuinely MOVABLE celebrations tied to the temporal cycle (no fixed date):
+ // a fixed-date sanctoral cannot represent them; they need temporal-engine
+ // support. Skipped here (tracked as a known gap).
+ movableSkip := map[string]bool{
+ "mary-mother-of-the-church": true, // Monday after Pentecost
+ "the-immaculate-heart-of-mary": true, // Saturday after the Sacred Heart
+ "the-memorial-of-the-blessed-virgin-mary-on-saturday": true, // any free Saturday
+ }
+
// Reference years: cover every weekday so a saint whose date is a Sunday in
// one year is captured in another. 2025 is past -> niedziela gives pl names.
for _, y := range []int{2025, 2026, 2027} {
@@ -134,10 +143,12 @@ func main() {
// Christmas, Easter cycle, etc.). Sanctoral dates are ferial (or a
// plain Sunday) in the pure temporal.
temp := calendar.Compute(t, sel, nil)
- if temp.Observed.Rank == calendar.RankSolemnity && t.Weekday() != time.Sunday {
- continue
- }
- if temp.Observed.Rank == calendar.RankFeast {
+ // Skip dates the temporal engine owns: Sundays and its own
+ // solemnities/feasts (Christmas & Easter cycles, Christ the King,
+ // Trinity, Corpus Christi, …). Sanctoral saints are captured on their
+ // weekday (ferial) occurrences -- and since a fixed date lands on a
+ // weekday in most years, one reference year suffices per saint.
+ if temp.Observed.Rank == calendar.RankSolemnity || temp.Observed.Rank == calendar.RankFeast {
continue
}
// Polish name for the observed (obligatory) celebration, 2025 only.
@@ -153,7 +164,7 @@ func main() {
continue // "ferial" or unknown -> not a sanctoral saint
}
slug := slugify(c.Title)
- if slug == "" {
+ if slug == "" || movableSkip[slug] {
continue
}
if _, seen := entries[slug]; seen {