Skip to content

Instantly share code, notes, and snippets.

@vbonacci
Created March 31, 2012 23:05
Show Gist options
  • Save vbonacci/2269419 to your computer and use it in GitHub Desktop.
Save vbonacci/2269419 to your computer and use it in GitHub Desktop.
{
"name": "1in7-cron",
"version": "0.0.1",
"scripts": {
"start": "node ./server.js"
},
"dependencies": {
"request": "2.9.153",
"cron": "0.1.3"
}
}
var util = require('util')
, cronJob = require('cron').CronJob
, request = require('request');
cronJob('0 * * * * *', function(){
request({uri:'http://1in7.com/_email_test.php'}, function (error, response, body) {
util.log('Request succeeded');
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment