Skip to content

Instantly share code, notes, and snippets.

@chewmanfoo
Created October 17, 2012 22:30
Show Gist options
  • Save chewmanfoo/3908755 to your computer and use it in GitHub Desktop.
Save chewmanfoo/3908755 to your computer and use it in GitHub Desktop.
a rake file which is failing
namespace :smeagol do
desc "Synchronize change_set_revisions with svn"
task :sync_svn_revisions => :environment do |t, args|
message :title, "In the beginning... gathering current revisions"
Branch.all.each do |b|
message :info, "Visiting branch #{b.name}"
message :plain, " running svn log for #{b.svn_url}..."
# this is failing at the sed
@revs_str = %x(svn log "#{b.svn_url}" | tr -d '\n' | sed -r 's/-{2,}/\n/g' | sed -r 's/ \([^\)]+\)//g' | sed -r 's/^r//' | sed -r "s/[0-9]+ lines?//g" | sort -g)
@revs = @revs_str.split("\n")
message :plain, " finished svn log for #{b.svn_url} - #{@revs.size} revisions found"
end
Visiting branch CERT4
running svn log for http://tcysvn02.dev.sabre.com/tvly/tvl-puppet/tvl/puppet/CERT4/...
sed: -e expression #1, char 8: unterminated `s' command
svn: Write error: Broken pipe
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment