Use yard/rspec Rake tasks
This commit is contained in:
parent
b083bddeeb
commit
9ad83268ee
13
.yardopts
13
.yardopts
@ -1,13 +0,0 @@
|
||||
--title "Teamocil"
|
||||
|
||||
--no-cache
|
||||
--protected
|
||||
--no-private
|
||||
|
||||
--markup "markdown"
|
||||
--markup-provider "maruku"
|
||||
|
||||
--format html
|
||||
|
||||
"README.mkd"
|
||||
"lib/**/*.rb"
|
@ -1,7 +1,7 @@
|
||||
PATH
|
||||
remote: .
|
||||
specs:
|
||||
teamocil (0.3.1)
|
||||
teamocil (0.3.2)
|
||||
|
||||
GEM
|
||||
remote: http://rubygems.org/
|
||||
@ -19,7 +19,7 @@ GEM
|
||||
diff-lcs (~> 1.1.2)
|
||||
rspec-mocks (2.6.0)
|
||||
syntax (1.0.0)
|
||||
yard (0.7.2)
|
||||
yard (0.7.5)
|
||||
|
||||
PLATFORMS
|
||||
ruby
|
||||
|
29
Rakefile
29
Rakefile
@ -1,11 +1,28 @@
|
||||
require "bundler"
|
||||
Bundler.require(:development)
|
||||
|
||||
require "bundler/gem_tasks"
|
||||
require "rspec/core/rake_task"
|
||||
|
||||
desc "Run specs"
|
||||
task :spec do # {{{
|
||||
sh "bundle exec rspec --color --format=nested #{Dir.glob(File.join(File.dirname(__FILE__), "spec/**/*_spec.rb")).join(" ")}"
|
||||
task :default => :spec
|
||||
|
||||
desc "Run all specs"
|
||||
RSpec::Core::RakeTask.new(:spec) do |task| # {{{
|
||||
task.pattern = "spec/**/*_spec.rb"
|
||||
task.rspec_opts = "--colour --format=documentation"
|
||||
end # }}}
|
||||
|
||||
desc "Generate documentation"
|
||||
task :doc do # {{{
|
||||
sh "bundle exec yard doc"
|
||||
desc "Generate YARD Documentation"
|
||||
YARD::Rake::YardocTask.new do |task| # {{{
|
||||
task.options = [
|
||||
"-o", File.expand_path("../doc", __FILE__),
|
||||
"--readme=README.md",
|
||||
"--markup=markdown",
|
||||
"--markup-provider=maruku",
|
||||
"--no-private",
|
||||
"--no-cache",
|
||||
"--protected",
|
||||
"--title=Teamocil",
|
||||
]
|
||||
task.files = ["lib/**/*.rb"]
|
||||
end # }}}
|
||||
|
Loading…
Reference in New Issue
Block a user