File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -41,6 +41,7 @@ const PR_TIME = config.pr_time;
41
41
* At 21:00 on every day-of-week from Monday through Friday.
42
42
*/
43
43
const MEETING_TIME = config . meeting_time ;
44
+ const MEETING_NOTICE_TIME = config . meeting_notice_time ;
44
45
const octokit = new Octokit ( { auth : TOKEN } ) ;
45
46
46
47
const MEMBERS_QUERY = require ( './queries/members' ) ;
@@ -388,6 +389,24 @@ function parseMeetingMessage(mentionList) {
388
389
* Call the Github GraphQL API, parse its response to message and add that message as cron job.
389
390
*/
390
391
async function main ( ) {
392
+ if ( MEETING_NOTICE_TIME ) {
393
+ const meetingNoticeJob = new CronJob (
394
+ MEETING_NOTICE_TIME ,
395
+ ( ) => {
396
+ notify ( `Meeting will start in 15 minutes🕒` )
397
+ . then ( ( ) => console . log ( 'MeetingNotice Job Completed' ) )
398
+ . catch ( HawkCatcher . send ) ;
399
+ } ,
400
+ null ,
401
+ true ,
402
+ 'Europe/Moskow'
403
+ ) ;
404
+
405
+ meetingNoticeJob . start ( ) ;
406
+ console . log ( 'MeetingNotice notifier started' ) ;
407
+ console . log ( 'Will notify at:' + MEETING_NOTICE_TIME ) ;
408
+ }
409
+
391
410
if ( MEETING_TIME ) {
392
411
const meetingJob = new CronJob (
393
412
MEETING_TIME ,
You can’t perform that action at this time.
0 commit comments