a37b3e848d
- config: add overrideTime for testing (HH:MM string) - state.ts: daily state persistence (reference, lastKnown, sentAt10) - differ.ts: detect text changes and sold-out changes between menu snapshots - logger.ts: append timestamped changes to logs/YYYY-MM-DD.log - index.ts: full cron logic — before 10 log only, at 10 send TG, after 10 send on text change; sold-out always to TG without log; exit after 14:00 - .gitignore: add state/ and logs/ Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
38 lines
570 B
TypeScript
38 lines
570 B
TypeScript
export interface DayUrls {
|
|
monday: string
|
|
tuesday: string
|
|
wednesday: string
|
|
thursday: string
|
|
friday: string
|
|
}
|
|
|
|
export interface TelegramConfig {
|
|
botToken: string
|
|
chatId: string
|
|
}
|
|
|
|
export interface Config {
|
|
days: DayUrls
|
|
devMode: boolean
|
|
overrideTime: string | null
|
|
telegram: TelegramConfig
|
|
}
|
|
|
|
const config: Config = {
|
|
days: {
|
|
monday: "",
|
|
tuesday: "",
|
|
wednesday: "",
|
|
thursday: "",
|
|
friday: "",
|
|
},
|
|
devMode: false,
|
|
overrideTime: null,
|
|
telegram: {
|
|
botToken: "",
|
|
chatId: "",
|
|
},
|
|
}
|
|
|
|
export default config
|