forked from sj26/skinny
-
Notifications
You must be signed in to change notification settings - Fork 31
/
Copy pathRakefile
32 lines (25 loc) · 751 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
require 'rubygems'
version_file = File.expand_path __FILE__ + '/../VERSION'
version = File.read(version_file).strip
spec_file = File.expand_path __FILE__ + '/../skinny.gemspec'
spec = Gem::Specification.load spec_file
require 'rdoc/task'
RDoc::Task.new :rdoc => "rdoc",
:clobber_rdoc => "rdoc:clean",
:rerdoc => "rdoc:force" do |rdoc|
rdoc.title = "Skinny #{version}"
rdoc.rdoc_dir = 'rdoc'
rdoc.main = 'README.md'
rdoc.rdoc_files.include 'lib/**/*.rb'
end
desc "Package as Gem"
task "package:gem" do
builder = Gem::Builder.new spec
builder.build
end
task "package" => ["package:gem"]
desc "Release Gem to RubyGems"
task "release:gem" do
%x[gem push skinny-#{version}.gem]
end
task "release" => ["package", "release:gem"]