Pure-Kotlin module, drawn from the duplicate reminder logic in Agendula and Calendula: the lead-time unit model (ReminderUnit / decomposeReminderMinutes), the per-target override model (ReminderOverride + reminderLeadFor / applyReminderOverride) and the stored-format codec (ReminderOverrideCodec). The codec's separators are configurable so each app keeps its on-disk format (Agendula stores id:minutes, Calendula id=minutes) without a data migration. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
33 lines
985 B
Kotlin
33 lines
985 B
Kotlin
// core-reminders — pure-Kotlin reminder-lead plumbing shared across the family:
|
|
// the lead-time unit model (ReminderUnit / decomposeReminderMinutes), the
|
|
// per-target override model (ReminderOverride + resolution helpers) and the
|
|
// stored-format codec (ReminderOverrideCodec, separators configurable so each
|
|
// app keeps its on-disk format). No Android, no third-party deps — a plain JVM
|
|
// library, like core-time; each app layers its own DataStore + string labels on
|
|
// top.
|
|
plugins {
|
|
alias(libs.plugins.kotlin.jvm)
|
|
}
|
|
|
|
java {
|
|
sourceCompatibility = JavaVersion.VERSION_17
|
|
targetCompatibility = JavaVersion.VERSION_17
|
|
}
|
|
|
|
kotlin {
|
|
compilerOptions {
|
|
jvmTarget = org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_17
|
|
}
|
|
}
|
|
|
|
dependencies {
|
|
testImplementation(libs.junit.jupiter.api)
|
|
testRuntimeOnly(libs.junit.jupiter.engine)
|
|
testRuntimeOnly(libs.junit.platform.launcher)
|
|
testImplementation(libs.truth)
|
|
}
|
|
|
|
tasks.test {
|
|
useJUnitPlatform()
|
|
}
|