Sha256: 1a169e464b23925e48f30b25b333fa65bd99ae54092709a98e651ce18dce7a5a
Contents?: true
Size: 1.5 KB
Versions: 1
Compression:
Stored size: 1.5 KB
Contents
$LOAD_PATH.unshift File.join(File.dirname(__FILE__)) $LOAD_PATH.unshift File.join(File.dirname(__FILE__), 'test') require 'bundler/setup' require 'rake/testtask' require File.expand_path(File.join(File.dirname(__FILE__), "lib", "fakefs", "version")) Rake::TestTask.new do |t| t.libs << 'test' t.test_files = FileList['test/**/*test.rb'] t.verbose = true end begin require 'rspec/core/rake_task' desc 'Run specs' RSpec::Core::RakeTask.new rescue LoadError puts "Spec task can't be loaded. `gem install rspec`" end begin require 'rubocop/rake_task' desc 'Run RuboCop' RuboCop::RakeTask.new(:rubocop) rescue LoadError puts "Rubocop task can't be loaded. `gem install rubocop`" end task default: [:test, :spec, :rubocop] desc 'Push a new version to rubygems.org' task :publish => [:rubocop, :test, :spec, :rubocop, :update_contributors, :tag, :release, :push] desc 'Update contributors' task :update_contributors do git_rank_contributors = "#{File.dirname(File.expand_path(__FILE__))}/etc/git-rank-contributors" sh "#{git_rank_contributors} > CONTRIBUTORS" if `git status | grep CONTRIBUTORS`.strip.length > 0 sh "git add CONTRIBUTORS" sh "git commit -m 'Update contributors for release'" end end desc 'Release a new version' task :release do sh "gem build fakefs.gemspec" sh "gem push fakefs-*.gem" end desc 'tag' task :tag do version = FakeFS::Version::VERSION sh "git tag v#{version}" sh "git push --tags" end desc 'Run git push' task :push do sh "git push origin master" end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
fakefs-0.7.0 | Rakefile |