Skip to content

Embed URL

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Simple reboot example
require('crontab').load(cronLoaded);
function cronLoaded(err, tab) {
if (err) { console.log(err); process.exit(1); }
var command = '/usr/bin/env echo "starting some service..."';
tab.remove(tab.findCommand(command));
var item = tab.create(command);
item.everyReboot();
tab.save(cronSaved);
}
function cronSaved(err, tab) {
if (err) { console.log(err); process.exit(1); }
console.log('saved');
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.