gem-release 0.7.0 → 0.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/gem_release/helpers.rb +15 -1
- data/lib/gem_release/version.rb +1 -1
- data/lib/rubygems/commands/bump_command.rb +0 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7d9466f0a6360107630002e0eec22301f05e7b66
|
4
|
+
data.tar.gz: eef4cc82d90ee716db8f6067b7bb38b9d276fedc
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 74213f2756bbb185d537894b6a06f1a278808432108d595a447823e461f4b7d064f3545ddc4fe255d9c69c51daccc2e1b506f9d9259d811f914edd9061cb575a
|
7
|
+
data.tar.gz: 67dcbf4cd8a86d4a388191d38cddc0dfb90927a4cf2e2fd9557727ae367ce3aa8d5bb5331f4d1f73bb3e1f1806908d5bec5f897f201dbdbaa3d7d5fe3a624328
|
data/lib/gem_release/helpers.rb
CHANGED
@@ -35,7 +35,7 @@ module GemRelease
|
|
35
35
|
end
|
36
36
|
|
37
37
|
def gem_version
|
38
|
-
|
38
|
+
gemspec.version.to_s
|
39
39
|
end
|
40
40
|
|
41
41
|
def gemspec
|
@@ -70,7 +70,21 @@ module GemRelease
|
|
70
70
|
end
|
71
71
|
end
|
72
72
|
|
73
|
+
def reset_gemspec_cache
|
74
|
+
# Gemspecs are cached in rubygems >= 2.1, so we need to clear the cache
|
75
|
+
# in case gem versions have changed.
|
76
|
+
#
|
77
|
+
# Note: This is not needed or supported with older rubygems, which is
|
78
|
+
# why exceptions are swallowed.
|
79
|
+
begin
|
80
|
+
Gem::Specification.reset
|
81
|
+
rescue
|
82
|
+
end
|
83
|
+
end
|
84
|
+
|
73
85
|
def run_cmd(command)
|
86
|
+
reset_gemspec_cache
|
87
|
+
|
74
88
|
unless send(command)
|
75
89
|
say "The task `#{command}` could not be completed. Subsequent tasks will not be attempted."
|
76
90
|
abort
|
data/lib/gem_release/version.rb
CHANGED
@@ -89,7 +89,6 @@ class Gem::Commands::BumpCommand < Gem::Command
|
|
89
89
|
end
|
90
90
|
cmd.options[:quiet] = options[:quiet]
|
91
91
|
cmd.options[:quiet_success] = true
|
92
|
-
cmd.options[:version_number] = @new_version_number
|
93
92
|
cmd.execute
|
94
93
|
true
|
95
94
|
end
|
@@ -99,7 +98,6 @@ class Gem::Commands::BumpCommand < Gem::Command
|
|
99
98
|
cmd.options[:quiet] = options[:quiet]
|
100
99
|
cmd.options[:quiet_success] = true
|
101
100
|
cmd.options[:push_tags_only] = true
|
102
|
-
cmd.options[:version_number] = @new_version_number
|
103
101
|
cmd.execute
|
104
102
|
true
|
105
103
|
end
|