-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathRakefile
39 lines (33 loc) · 925 Bytes
/
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
require 'bundler/gem_tasks'
require 'rake/testtask'
require 'rubocop/rake_task'
require 'yard'
Rake::TestTask.new do |t|
t.libs << 'lib'
t.libs << 'lib/pandocomatic'
t.test_files = FileList['test/test_helper.rb', 'test/unit/*.rb']
t.warning = true
t.verbose = true
end
RuboCop::RakeTask.new(:rubocop) do |t|
t.patterns = ['lib/']
t.fail_on_error = true
end
YARD::Rake::YardocTask.new do |t|
t.files = ['lib/**/*.rb']
t.stats_options = ['--list-undoc']
end
task :generate_docs do
sh %(
cd documentation;
../test/pandocomatic.rb --data-dir data-dir --config config.yaml --input manual.md --output ../index.md;
../test/pandocomatic.rb --data-dir data-dir --config config.yaml --input README.md --output ../README.md
)
end
task :build do
Rake::Task[:rubocop].execute
Rake::Task[:test].execute
Rake::Task[:yard].execute
Rake::Task['generate_docs'].execute
end
task default: :test