Created
April 3, 2016 06:46
-
-
Save PonDad/27ec6e2a8148084ec70f358e858415b1 to your computer and use it in GitHub Desktop.
hubot-scripts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Description: | |
# Wifi定期接続 | |
# | |
# Commands: | |
# | |
cronJob = require('cron').CronJob | |
child_process = require('child_process') | |
module.exports = (robot) -> | |
new cronJob | |
cronTime: "*/10 * * * *" | |
onTick: -> | |
child_process.exec 'sh /home/pi/wifi_reconnect.sh', (error, stdout, stderr) -> | |
msg.send(stdout) | |
msg.send(stderr) | |
msg.send(error) | |
return | |
start: true | |
timeZone: "Asia/Tokyo" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment