File tree 1 file changed +14
-10
lines changed
1 file changed +14
-10
lines changed Original file line number Diff line number Diff line change 1
- #!/usr/bin/env ruby
2
-
3
- require 'rubygems'
4
1
require 'rake'
5
2
require 'rake/testtask'
6
- require 'rubygems/package_task'
3
+ $LOAD_PATH. unshift File . expand_path ( "../lib" , __FILE__ )
4
+ require "liquid/version"
7
5
8
6
task :default => 'test'
9
7
@@ -29,14 +27,20 @@ task :test do
29
27
Rake ::Task [ 'base_test' ] . invoke
30
28
end
31
29
32
- gemspec = eval ( File . read ( 'liquid.gemspec' ) )
33
- Gem ::PackageTask . new ( gemspec ) do |pkg |
34
- pkg . gem_spec = gemspec
30
+ task :gem => :build
31
+ task :build do
32
+ system "gem build liquid.gemspec"
33
+ end
34
+
35
+ task :install => :build do
36
+ system "gem install liquid-#{ Liquid ::VERSION } .gem"
35
37
end
36
38
37
- desc "Build the gem and release it to rubygems.org"
38
- task :release => :gem do
39
- sh "gem push pkg/liquid-#{ gemspec . version } .gem"
39
+ task :release => :build do
40
+ system "git tag -a v#{ Liquid ::VERSION } -m 'Tagging #{ Liquid ::VERSION } '"
41
+ system "git push --tags"
42
+ system "gem push liquid-#{ Liquid ::VERSION } .gem"
43
+ system "rm liquid-#{ Liquid ::VERSION } .gem"
40
44
end
41
45
42
46
namespace :benchmark do
You can’t perform that action at this time.
0 commit comments