-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathreminders.js
55 lines (50 loc) · 1.28 KB
/
reminders.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
import env from 'dotenv';
const config = env.config();
const pr = config.parsed?.PR_CHAT_ID;
const vorstand = config.parsed?.VORSTAND_CHAT_ID;
if (!pr || !vorstand)
console.log(
new Date().toISOString(),
'No PR or Vorstand chat ID found => not setting up any CRON jobs!'
);
/**
* The reminders sent by the bot
* @type {Reminder[]}
*/
export const reminders =
pr && vorstand
? [
{
cron: '30 16 * * 1',
message: '🛎️ Vorstandsmeeting in 30 Minuten!',
chatIds: [vorstand],
},
{
cron: '0 17 * * 1',
message: '🛎️ Vorstandsmeeting startet jetzt!',
chatIds: [vorstand],
},
{
cron: '30 18 * * 1',
message: `🛎 PR-Meeting / Co-Working in 30 Minuten!`,
chatIds: [pr],
},
{
cron: '0 19 * * 1',
message: `🛎 PR-Meeting / Co-Working jetzt!`,
chatIds: [pr],
},
{
cron: '30 14 * * 5',
message: `⌚ Bitte die Weekly Reflection ausfüllen.
https://wuespace.koan.co/team/19733eca-8dff-4a87-8a3b-b8fbfdf5964e/nu/reflections`,
chatIds: [pr],
},
{
cron: '30 16 * * 0',
message: `⏰ Letzte Gelegenheit der Woche, die Weekly Reflection auszufüllen!
https://wuespace.koan.co/team/19733eca-8dff-4a87-8a3b-b8fbfdf5964e/nu/reflections`,
chatIds: [pr],
},
]
: [];