-
Notifications
You must be signed in to change notification settings - Fork 50
/
Rakefile
41 lines (31 loc) · 976 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 'rubygems'
require 'rake'
require 'rake/clean'
JAVA = RUBY_PLATFORM == "java"
$LOAD_PATH.unshift File.expand_path("../lib", __FILE__)
require "akephalos/version"
CLEAN.include "*.gem"
task :build do
system "gem build akephalos.gemspec"
end
task "build:java" do
system "export PLATFORM=java && gem build akephalos.gemspec"
end
task "build:all" => ['build', 'build:java']
task :install => (JAVA ? 'build:java' : 'build') do
gemfile = "akephalos-#{Akephalos::VERSION}#{"-java" if JAVA}.gem"
system "gem install #{gemfile}"
end
task :release => 'build:all' do
puts "Tagging #{Akephalos::VERSION}..."
system "git tag -a #{Akephalos::VERSION} -m 'Tagging #{Akephalos::VERSION}'"
puts "Pushing to Github..."
system "git push --tags"
puts "Pushing to Gemcutter..."
["", "-java"].each do |platform|
system "gem push akephalos-#{Akephalos::VERSION}#{platform}.gem"
end
end
load 'tasks/docs.rake'
load 'tasks/spec.rake'
task :default => :spec