forked from assaf/uuid
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Rakefile
41 lines (31 loc) · 930 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
require 'rake/testtask'
require 'rake/rdoctask'
spec = Gem::Specification.load(File.expand_path("uuid.gemspec", File.dirname(__FILE__)))
desc "Default Task"
task :default => :test
desc "Run all test cases"
Rake::TestTask.new do |test|
test.verbose = true
test.test_files = ['test/*.rb']
test.warning = true
end
# Create the documentation.
Rake::RDocTask.new do |rdoc|
rdoc.rdoc_files.include "README.rdoc", "lib/**/*.rb"
rdoc.options = spec.rdoc_options
end
desc "Push new release to rubyforge and git tag"
task :push do
sh "git push"
puts "Tagging version #{spec.version} .."
sh "git tag v#{spec.version}"
sh "git push --tag"
puts "Building and pushing gem .."
sh "gem build #{spec.name}.gemspec"
sh "gem push #{spec.name}-#{spec.version}.gem"
end
desc "Install #{spec.name} locally"
task :install do
sh "gem build #{spec.name}.gemspec"
sh "gem install #{spec.name}-#{spec.version}.gem"
end