forked from riak-ripple/ripple
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathRakefile
59 lines (50 loc) · 1.44 KB
/
Rakefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
require 'rubygems'
require 'rake'
require 'rake/clean'
require 'yard'
desc "Generate YARD documentation."
YARD::Rake::YardocTask.new do |yard|
docfiles = FileList['{riak-client,ripple,riak-sessions}/lib/**/*.rb']
docfiles.exclude '**/generators/**/templates/*'
yard.files = docfiles.to_a + ['-','RELEASE_NOTES.textile']
yard.options = ["--no-private"]
end
desc "Generate YARD documentation into a repo on the gh-pages branch."
task :doc => :yard do
original_dir = Dir.pwd
docs_dir = File.expand_path(File.join(original_dir, "..", "ripple-docs"))
rm_rf File.join(docs_dir, "*")
cp_r File.join(original_dir, "doc", "."), docs_dir
touch File.join(docs_dir, '.nojekyll')
end
namespace :spec do
%w{riak-client ripple riak-sessions}.each do |dir|
desc "Run specs for sub-project #{dir}."
task dir do
Dir.chdir(dir) do
system 'rake spec'
end
end
end
desc "Run integration specs for all sub-projects."
task :integration do
%w{riak-client ripple}.each do |dir|
Dir.chdir(dir) do
system 'rake spec:integration'
end
end
end
end
desc "Release all gems to Rubygems.org."
task :release do
%w{riak-client ripple riak-sessions}.each do |dir|
Dir.chdir(dir) do
system "rake release"
end
end
end
desc "Run all sub-project specs."
task :spec => ["spec:riak-client", "spec:ripple", "spec:riak-sessions"]
task :default => :spec
CLOBBER.include(".yardoc")
CLOBBER.include("doc")