public
Description: resources_controller rails plugin: rc makes RESTful controllers fun
Homepage: http://plugins.ardes.com/doc/resources_controller
Clone URL: git://github.com/ianwhite/resources_controller.git
Click here to lend your support to: resources_controller and make a donation at www.pledgie.com !
updating to use new garlic gem style
ianwhite (author)
Thu Nov 20 01:56:06 -0800 2008
commit  3b8ea1c2027a7601bd4c9a9950dc63ea7983a76d
tree    ac803eff7c4e0ace9ecd3f43498c976382d4e46f
parent  8457e5703f7c147a2444da62931841a28e456b31
...
1
2
3
4
5
 
6
...
1
 
 
 
2
3
4
0
@@ -1,4 +1,2 @@
0
 doc/*
0
-garlic
0
-garlic.rb
0
-garlic_example.txt
0
\ No newline at end of file
0
+.garlic
0
\ No newline at end of file
...
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
 
 
 
 
 
108
109
 
 
110
...
67
68
69
 
 
 
 
 
 
 
 
 
 
 
70
71
72
73
74
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
75
76
77
78
79
80
 
81
82
83
0
@@ -67,43 +67,16 @@ namespace :doc do
0
   task :all => ["spec:doc:html", "spec:doc", "spec:rcov", "doc"]
0
 end
0
 
0
-# load up garlic if it's here
0
-if File.directory?(File.join(File.dirname(__FILE__), 'garlic'))
0
-  require File.join(File.dirname(__FILE__), 'garlic/lib/garlic_tasks')
0
-  require File.join(File.dirname(__FILE__), 'garlic')
0
-end
0
-
0
-desc "clone the garlic repo (for running ci tasks)"
0
-task :get_garlic do
0
-  sh "git clone git://github.com/ianwhite/garlic.git garlic"
0
-end
0
-
0
 # load up the tasks for testing rspec generators against RC
0
 require File.join(File.dirname(__FILE__), 'spec/generate_rake_task')
0
 
0
 task :cruise do
0
   # run the garlic task, capture the output, if succesful make the docs and copy them to ardes
0
-  begin
0
-    `cp garlic_example.rb garlic.rb`
0
-    `rake get_garlic`
0
-    `cd garlic; git pull`
0
-    `rake garlic:clean`
0
-    sh "rake garlic:all"
0
-
0
-    # the following can fail
0
-    `rake garlic:clean`
0
-    `rake garlic:run_targets > garlic_report.txt`
0
-    
0
-    # send abridged report
0
-    report = File.read('garlic_report.txt').sub(/^.*?==========/m, '==========')
0
-    report = "garlic report for #{plugin_name}\n#{`git log -n 1 --pretty=oneline --no-color`}\n" + report
0
-    File.open('garlic_report.txt', 'w+') {|f| f << report }
0
-    `scp -i ~/.ssh/ardes garlic_report.txt ardes@ardes.com:~/subdomains/plugins/httpdocs/doc/#{plugin_name}_garlic_report.txt`
0
-
0
-    # build doc and send that
0
-    cd "garlic/work/edge/vendor/plugins/#{plugin_name}" do
0
-      `rake doc:all`
0
-      `scp -i ~/.ssh/ardes -r doc ardes@ardes.com:~/subdomains/plugins/httpdocs/doc/#{plugin_name}`
0
-    end
0
+  sh "garlic clean && mkdir -p .garlic && (garlic all > .garlic/report.txt)"
0
+  `scp -i ~/.ssh/ardes .garlic/report.txt ardes@ardes.com:~/subdomains/plugins/httpdocs/doc/#{plugin_name}_garlic_report.txt`
0
+  cd ".garlic/2.2-stable/vendor/plugins/#{plugin_name}" do
0
+    `rake doc:all`
0
+    `scp -i ~/.ssh/ardes -r doc ardes@ardes.com:~/subdomains/plugins/httpdocs/doc/#{plugin_name}`
0
   end
0
-end
0
+  puts "The build is GOOD"
0
+end
0
\ No newline at end of file

Comments