srushti / goldberg

Goldberg is a lightweight CI server written in Ruby which worries about Bundler & RVM so that you don't have to.
Other
243 stars 29 forks source link

svn cleanups #145

Closed ghost closed 11 years ago

ghost commented 11 years ago

I'm not 100% sure about the following, but I had two problems with SVN and goldberg, the first being not completely reverting a checkout, the second being nasty log messages when forcing multiple builds without having any new revision coming in. The latter tries to run something like the following for 4 times building some code at revision 42: svn log -r42:42:42:42 ...

Fix:

--- orangenschale.orig/app/models/scm/svn.rb    2012-07-12 05:14:44.000000000 -0500
+++ orangenschale/app/models/scm/svn.rb 2012-07-31 23:23:25.519184600 -0500
@@ -10,7 +10,7 @@
       end

       def update(branch)
-        "svn revert . && svn update"
+        "svn revert -R . && svn update"
       end

       def change_list(old_rev, new_rev)
@@ -22,7 +22,7 @@
       end

       def authors(versions)
-        "svn log -r#{versions.join(':')} | grep \"^[r\d]\" | awk '{print $3}'| uniq| tr \"\\n\" \" \""
+        "svn log -r#{versions.first+':'+versions.last} | grep \"^[r\d]\" | awk '{print $3}'| uniq| tr \"\\n\" \" \""
       end
     end
   end
srushti commented 11 years ago

Fixed with 47e464f492426221fa19735c6f8f16339b600a47 & 23ea9a58c85dbd0cc080dd94077486df4ffa6803. Thanks.

ghost commented 11 years ago

thanks!