forked from infochimps-labs/gorillib
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
46 lines (39 loc) · 1.45 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
require 'rubygems' unless defined?(Gem)
require 'bundler/setup'
Bundler.setup(:default, :development)
require 'rake'
task :default => :rspec
require 'rspec/core/rake_task'
RSpec::Core::RakeTask.new(:rspec) do |spec|
Bundler.setup(:default, :development, :test)
spec.pattern = 'spec/**/*_spec.rb'
end
desc "Run RSpec with code coverage"
task :cov do
ENV['GORILLIB_COV'] = "yep"
Rake::Task[:rspec].execute
end
require 'yard'
YARD::Rake::YardocTask.new do
Bundler.setup(:default, :development, :docs)
end
require 'jeweler'
Jeweler::Tasks.new do |gem|
Bundler.setup(:default, :development, :test)
gem.name = 'gorillib'
gem.homepage = 'https://github.com/infochimps-labs/gorillib'
gem.license = 'Apache 2.0'
gem.email = 'coders@infochimps.org'
gem.authors = ['Infochimps']
gem.summary = %Q{include only what you need. No dependencies, no creep}
gem.description = %Q{Gorillib: infochimps lightweight subset of ruby convenience methods}
ignores = File.readlines(".gitignore").grep(/^[^#]\S+/).map{|s| s.chomp }
dotfiles = [".gemtest", ".gitignore", ".rspec", ".yardopts"]
gem.files = dotfiles + Dir["**/*"].
reject{|f| f =~ %r{^(vendor|coverage|old|away)/} }.
reject{|f| File.directory?(f) }.
reject{|f| ignores.any?{|i| File.fnmatch(i, f) || File.fnmatch(i+'/**/*', f) || File.fnmatch(i+'/*', f) } }
gem.test_files = gem.files.grep(/^spec\//)
gem.require_paths = ['lib']
end
Jeweler::RubygemsDotOrgTasks.new