| 1 |
require 'rake'; require 'rubygems' |
| 2 |
|
| 3 |
$:.unshift(File.dirname(__FILE__) + '/lib') |
| 4 |
require 'strokedb'; require 'core_ext' |
| 5 |
|
| 6 |
require 'task/echoe' |
| 7 |
Echoe.taskify do |
| 8 |
Dir['task/**/*.task'].each {|t| load t} |
| 9 |
|
| 10 |
namespace :echoe do |
| 11 |
Echoe.new('strokedb', StrokeDB::VERSION) do |g| |
| 12 |
g.author = ['Yurii Rashkovskii', 'Oleg Andreev'] |
| 13 |
g.email = ['strokedb@googlegroups.com'] |
| 14 |
g.summary = 'embeddable, distributed, document-based database' |
| 15 |
g.url = 'http://strokedb.com' |
| 16 |
g.description = <<-EOF |
| 17 |
StrokeDB is an embeddable, distributed, document-based database written in Ruby. |
| 18 |
It is schema-free (allowing you to define any attribute on any object at any |
| 19 |
time), it scales infinitely, it even allows free versioning and integrates |
| 20 |
perfectly with Ruby applications. |
| 21 |
EOF |
| 22 |
|
| 23 |
g.platform = Gem::Platform::RUBY |
| 24 |
g.dependencies = ['diff-lcs >= 1.1.2', 'uuidtools >= 1.0.3', 'json >= 1.1.2'] |
| 25 |
|
| 26 |
g.manifest_name = 'meta/MANIFEST' |
| 27 |
g.ignore_pattern = /(^\.git|^.DS_Store$|^meta|^test\/storages|^examples\/(.*).strokedb|^bugs)/ |
| 28 |
g.executable_pattern = 'bin/strokedb' |
| 29 |
end |
| 30 |
|
| 31 |
desc 'tests packaged files to ensure they are all present' |
| 32 |
task :verify => :package do |
| 33 |
# An error message will be displayed if files are missing |
| 34 |
if system %(ruby -e "require 'rubygems'; require 'pkg/strokedb-#{StrokeDB::VERSION}/strokedb'") |
| 35 |
puts "\nThe library files are present" |
| 36 |
end |
| 37 |
end |
| 38 |
|
| 39 |
desc 'Clean tree, update manifest, and install gem' |
| 40 |
task :magic => [:clean, :manifest, :install] |
| 41 |
end |
| 42 |
|
| 43 |
desc 'Check what\'s up in this mug' |
| 44 |
task :sup => [:'rcov:run', :'rcov:verify'] |
| 45 |
|
| 46 |
# Developers: Run this before commiting! |
| 47 |
desc 'Check everything over before commiting!' |
| 48 |
task :aok => [:'rcov:verbose', :'rcov:strict', :'rcov:open', |
| 49 |
:'rdoc:html', :'rdoc:open', |
| 50 |
:'ditz:stage', :'ditz:html', :'ditz:todo', :'ditz:status', :'ditz:html:open'] |
| 51 |
end |
| 52 |
|
| 53 |
# desc 'Run by CruiseControl.rb during continuous integration' |
| 54 |
task :cruise => [:'ditz:html', :'rdoc:html', :'rcov:bw', :'rcov:verify'] |
| 55 |
|
| 56 |
# By default, we just list the tasks. |
| 57 |
task :default => :list |
| 58 |
task :list do |
| 59 |
system 'rake -T' |
| 60 |
end |