Skip to content

Commit

Permalink
Added whenever schedule.rb for automatic git repo updates, and keepin…
Browse files Browse the repository at this point in the history
…g system in sync
  • Loading branch information
ndbroadbent committed Jan 15, 2012
1 parent b4d304c commit 25e83aa
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
source :rubygems

gem "rake"
gem "whenever"
18 changes: 18 additions & 0 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
GEM
remote: http://rubygems.org/
specs:
activesupport (3.1.3)
multi_json (~> 1.0)
chronic (0.6.6)
multi_json (1.0.4)
rake (0.9.2.2)
whenever (0.7.0)
activesupport (>= 2.3.4)
chronic (~> 0.6.3)

PLATFORMS
ruby

DEPENDENCIES
rake
whenever
14 changes: 14 additions & 0 deletions schedule.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Use this file to easily define all of your cron jobs.
# Learn more: http://github.com/javan/whenever

every 10.minutes do
# Fetch all remotes for indexed git repos, and fast-forward if possible
command "git_index --rebuild && git_index --update-all"
# Update dotfiles (set up new symlinks, update generated bashrc, git config, etc.)
command "cd $DOTFILES_PATH && OVERWRITE_ALL=true rake install"
end

# Update Travis CI build statuses for indexed git repos
every 2.minutes do
command "git_index --rebuild && NOCD=true git_index --batch-cmd git_update_travis_status"
end

0 comments on commit 25e83aa

Please sign in to comment.