Author: kclark
Date: Tue Jun 17 18:13:48 2008
New Revision: 668984
URL: http://svn.apache.org/viewvc?rev=668984&view=rev
Log:
Add new gen-rb task to rebuild the bundled thrift generated code for specs
Also rewrite the test task to properly abort Rake if it fails
Modified:
incubator/thrift/trunk/lib/rb/Rakefile
Modified: incubator/thrift/trunk/lib/rb/Rakefile
URL:
http://svn.apache.org/viewvc/incubator/thrift/trunk/lib/rb/Rakefile?rev=668984&r1=668983&r2=668984&view=diff
==============================================================================
--- incubator/thrift/trunk/lib/rb/Rakefile (original)
+++ incubator/thrift/trunk/lib/rb/Rakefile Tue Jun 17 18:13:48 2008
@@ -17,8 +17,11 @@
end
task :test do
- fork do
- exec 'make', '-C', File.dirname(__FILE__) + "/../../test/rb"
- end
- Process.wait
+ sh 'make', '-C', File.dirname(__FILE__) + "/../../test/rb"
+end
+
+task :'gen-rb' do
+ thrift = '../../compiler/cpp/thrift'
+ dir = File.dirname(__FILE__) + '/spec'
+ sh thrift, '--gen', 'rb', '-o', dir, "#{dir}/ThriftSpec.thrift"
end