Rakefile in clevic-0.6.0 vs Rakefile in clevic-0.7.0
- old
+ new
@@ -13,11 +13,12 @@
ui_file.gsub( /\.ui$/, '_ui.rb' )
end
# list of .ui files
UI_FILES = FileList.new( 'lib/clevic/ui/*.ui' )
-CLEAN.include( 'ChangeLog', 'lib/clevic/ui/*.rb' )
+CLEAN.include( 'ChangeLog' )
+CLOBBER.include( 'ChangeLog', 'pkg', 'lib/clevic/ui/*_ui.rb' )
UI_FILES.each do |ui_file|
# make tasks to generate _ui.rb files
file ui_rb_file( ui_file ) => [ ui_file ] do |t|
sh "rbuic4 #{t.prerequisites} -o #{t.name}"
@@ -48,16 +49,22 @@
end
true
end
end
-desc "Runs Clevic in warning mode, with test databases and debug flag on"
+desc "Runs Clevic in normal mode, with live database."
task :run => :ui do |t|
ARGV.shift()
- exec "ruby -w -Ilib bin/clevic -D #{ARGV.join(' ')}"
+ exec "ruby -Ilib bin/clevic #{ARGV.join(' ')}"
end
+desc "Runs Clevic in warning mode, with test databases and debug flag on"
+task :sqlite => :ui do |t|
+ ARGV.shift()
+ exec "ruby -Ilib bin/clevic #{ARGV.join(' ')} times_sqlite_model.rb"
+end
+
desc "Runs Clevic in debug mode, with test databases"
task :debug => :ui do |t|
ARGV.shift()
exec "ruby -w -rdebug -Ilib bin/clevic -D #{ARGV.join(' ')}"
end
@@ -87,14 +94,16 @@
exec "irb -Ilib -rclevic -r#{model_file} -rclevic/db_options.rb"
end
end
# generate runs
- desc "run clevic with #{model_file}"
- task short_model( model_file ) => :ui do |t|
- ARGV.shift()
- exec "ruby -w -Ilib bin/clevic -D #{model_file} #{ARGV.join(' ')}"
+ namespace :run do
+ desc "run clevic with #{model_file}"
+ task short_model( model_file ) => :ui do |t|
+ ARGV.shift()
+ exec "ruby -w -Ilib bin/clevic -D #{model_file} #{ARGV.join(' ')}"
+ end
end
end
task :package => :ui
@@ -111,6 +120,12 @@
title = "#{$hoe.name}-#{$hoe.version} Documentation"
title = "#{$hoe.rubyforge_name}'s " + title if $hoe.rubyforge_name != $hoe.name
rd.options << "-t #{title}"
+end
+
+desc "Update History.txt from the SVN log"
+task :history do |t|
+ ARGV.shift
+ exec "svn2cl --break-before-msg -o History.txt #{ARGV.join(' ')}"
end