Skip to content

Instantly share code, notes, and snippets.

@coffeejunk
Created December 14, 2011 11:48
Show Gist options
  • Save coffeejunk/1476278 to your computer and use it in GitHub Desktop.
Save coffeejunk/1476278 to your computer and use it in GitHub Desktop.
#!/usr/env ruby
#require 'rubygems' # dies nur bei ruby 1.8
require 'sinatra'
post '/oh_yeah' do
pull = `cd git-repo && git checkout master && git pull`
unless pull.chomp == "Already up-to-date."
msg = `cd git-repo && git log -n 1 --format=full`
`cp -r git-repo/* svn-repo/`
`cd svn-repo && svn add --force . && svn commit --message "#{msg}"`
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment