23 lines
469 B
JavaScript
23 lines
469 B
JavaScript
const q = require('daskeyboard-applet');
|
|
const Imap = require('imap');
|
|
const logger = q.logger;
|
|
|
|
function getTimestamp() {
|
|
return Math.round(new Date().getTime() / 1000);
|
|
}
|
|
|
|
class ImapAlerts extends q.DesktopApp {
|
|
constructor() {
|
|
super();
|
|
this.pollingInterval = 60000;
|
|
this.timestamp = getTimestamp();
|
|
logger.info("Waiting for new mail to arrive");
|
|
|
|
}
|
|
|
|
async run() {
|
|
logger.info("Imap running");
|
|
|
|
}
|
|
}
|