Sha256: fd34c1e2b1a8f32c5700b701bb7b009afee1e01895f3f929a3d68a1aec2f3e1e
Contents?: true
Size: 1.52 KB
Versions: 3
Compression:
Stored size: 1.52 KB
Contents
require "rake" require "rake/testtask" require "rake/gempackagetask" require "rake/rdoctask" require "rake/clean" CLEAN << "pkg" << "doc" << "coverage" << ".yardoc" Rake::GemPackageTask.new(eval(File.read("friendly_id.gemspec"))) { |pkg| } Rake::RDocTask.new do |r| r.rdoc_dir = "doc" r.rdoc_files.include "lib/**/*.rb" end begin require "yard" YARD::Rake::YardocTask.new do |t| t.options = ["--output-dir=doc"] t.options << "--files" << ["Guide.md", "Contributors.md", "Changelog.md"].join(",") end rescue LoadError end begin require "rcov/rcovtask" Rcov::RcovTask.new do |r| r.test_files = FileList["test/**/*_test.rb"] r.verbose = true r.rcov_opts << "--exclude gems/*" end rescue LoadError end task :test do Rake::Task["test:friendly_id"].invoke Rake::Task["test:ar"].invoke end namespace :test do task :rails do rm_rf "fid" sh "rails --template extras/template-gem.rb fid" sh "cd fid; rake test" end Rake::TestTask.new(:friendly_id) { |t| t.pattern = "test/*_test.rb" } Rake::TestTask.new(:ar) { |t| t.pattern = "test/acktive_record/*_test.rb" } namespace :rails do task :plugin do rm_rf "fid" sh "rails --template extras/template-plugin.rb fid" sh "cd fid; rake test" end end end task :pushdocs do branch = `git branch | grep "*"`.chomp.gsub("* ", "") sh "git stash" sh "git checkout gh-pages" sh "cp -rp doc/* ." sh 'git commit -a -m "Regenerated docs"' sh "git push origin gh-pages" sh "git checkout #{branch}" sh "git stash apply" end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
friendly_id-3.0.0.beta3 | Rakefile |
friendly_id-3.0.0.beta2 | Rakefile |
friendly_id-3.0.0.beta1 | Rakefile |