-
Notifications
You must be signed in to change notification settings - Fork 10
/
Rakefile
43 lines (34 loc) · 844 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
40
41
42
43
require 'bundler/gem_tasks'
require 'rake/testtask'
require 'yard'
require 'cosgrove'
Encoding.default_external = Encoding::UTF_8
Encoding.default_internal = Encoding::UTF_8
Rake::TestTask.new(:test) do |t|
t.libs << 'test'
t.libs << 'lib'
t.test_files = FileList['test/**/*_test.rb']
t.ruby_opts << if ENV['HELL_ENABLED']
'-W2'
else
'-W1'
end
end
YARD::Rake::YardocTask.new do |t|
t.files = ['lib/**/*.rb']
end
task default: :test
task :console do
exec "irb -r cosgrove -I ./lib"
end
task :build do
exec 'gem build cosgrove.gemspec'
end
task :push do
exec "gem push cosgrove-#{Cosgrove::VERSION}.gem"
end
# We're not going to yank on a regular basis, but this is how it's done if you
# really want a task for that for some reason.
# task :yank do
# exec "gem yank cosgrove -v #{Cosgrove::VERSION}"
# end