mirror of https://github.com/einverne/dotfiles.git
Ein Verne
3 years ago
2 changed files with 28 additions and 22 deletions
@ -1,15 +1,15 @@ |
|||||||
log = hs.logger.new('autoscript', 'debug') |
-- log = hs.logger.new('autoscript', 'debug') |
||||||
|
-- |
||||||
function taskCallback(exitCode, stdOut, stdErr) |
-- function taskCallback(exitCode, stdOut, stdErr) |
||||||
log.i("task call back ", exitCode, stdOut, stdErr) |
-- log.i("task call back ", exitCode, stdOut, stdErr) |
||||||
end |
-- end |
||||||
|
-- |
||||||
function runAutoScripts() |
-- function runAutoScripts() |
||||||
args = {"-c", "/Users/einverne/Sync/wiki/auto-push.sh"} |
-- args = {"-c", "/Users/einverne/Sync/wiki/auto-push.sh"} |
||||||
autoCommitTask = hs.task.new("/bin/bash", taskCallback, args) |
-- autoCommitTask = hs.task.new("/bin/bash", taskCallback, args) |
||||||
autoCommitTask:setWorkingDirectory("/Users/einverne/Sync/wiki/") |
-- autoCommitTask:setWorkingDirectory("/Users/einverne/Sync/wiki/") |
||||||
autoCommitTask:start() |
-- autoCommitTask:start() |
||||||
end |
-- end |
||||||
|
-- |
||||||
myTimer = hs.timer.doEvery(7200, runAutoScripts) |
-- myTimer = hs.timer.doEvery(7200, runAutoScripts) |
||||||
myTimer:start() |
-- myTimer:start() |
||||||
|
Loading…
Reference in new issue