gemsmith 5.5.0 → 5.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/README.md +7 -7
- data/lib/gemsmith/identity.rb +2 -2
- data/lib/gemsmith/rake/build.rb +1 -1
- data/lib/gemsmith/rake/release.rb +19 -38
- data/lib/gemsmith/rake/tasks.rb +2 -3
- data/lib/gemsmith/templates/%gem_name%/lib/%gem_name%/identity.rb.tt +1 -1
- data/lib/gemsmith/templates/%gem_name%/spec/support/kit/default_config.rb.tt +1 -1
- data/lib/gemsmith/templates/%gem_name%/spec/support/kit/temp_dir.rb.tt +5 -4
- metadata +16 -2
- metadata.gz.sig +1 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c8fae3eed50e6c041a0468c15d995f955f2a12e0
|
4
|
+
data.tar.gz: d7c8f707c174b7e5f3c80d40a007a56b3d651338
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ec5db0c1fafa1130cb9edaeaacd570bd9f58c352cc0b10fb0a70300f561e8b2f881cede25541b69eb6b5d8325715577383a9dc39dfb9d8377a925927b8174fdc
|
7
|
+
data.tar.gz: 3d2f2b54e0b818b5a75229dafa41b0f08b5eda1301521d1c72266bed7c2336192d46305edb929f9d919f68e98939188addb8dc93643a075ae55533debf710e67
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/README.md
CHANGED
@@ -48,8 +48,8 @@ A command line interface for smithing new Ruby gems.
|
|
48
48
|
- Supports [Travis CI](http://travis-ci.org).
|
49
49
|
- Provides the ability to open the source code of any gem within your favorite editor.
|
50
50
|
- Provides the ability to read the documentation of any gem within your default browser.
|
51
|
-
- Adds commonly needed README
|
52
|
-
template files.
|
51
|
+
- Adds commonly needed [README](README.md), [CHANGELOG](CHANGELOG.md), [CONTRIBUTING](CONTRIBUTING.md),
|
52
|
+
[LICENSE](LICENSE.md), etc. template files.
|
53
53
|
|
54
54
|
# Requirements
|
55
55
|
|
@@ -138,13 +138,13 @@ For more gem creation options, type: gemsmith help create
|
|
138
138
|
|
139
139
|
Once a gem skeleton has been created, the following tasks are available within the project via Bundler (i.e. rake -T):
|
140
140
|
|
141
|
-
rake build # Build
|
141
|
+
rake build # Build example-0.1.0.gem into the pkg directory
|
142
142
|
rake clean # Clean gem artifacts
|
143
|
-
rake install # Build and install
|
144
|
-
rake install:local # Build and install
|
145
|
-
rake publish # Build, tag
|
143
|
+
rake install # Build and install example-0.1.0.gem into system gems
|
144
|
+
rake install:local # Build and install example-0.1.0.gem into system gems without network access
|
145
|
+
rake publish # Build, tag v0.1.0 (signed), and push example-0.1.0.gem to RubyGems
|
146
146
|
rake readme:toc # Update README Table of Contents
|
147
|
-
rake release # Create tag
|
147
|
+
rake release # Create tag v0.1.0 and build and push example-0.1.0.gem to Rubygems
|
148
148
|
rake rubocop # Run RuboCop
|
149
149
|
rake rubocop:auto_correct # Auto-correct RuboCop offenses
|
150
150
|
rake spec # Run RSpec code examples
|
data/lib/gemsmith/identity.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
module Gemsmith
|
2
|
-
#
|
2
|
+
# Gem identity information.
|
3
3
|
module Identity
|
4
4
|
def self.name
|
5
5
|
"gemsmith"
|
@@ -10,7 +10,7 @@ module Gemsmith
|
|
10
10
|
end
|
11
11
|
|
12
12
|
def self.version
|
13
|
-
"5.
|
13
|
+
"5.6.0"
|
14
14
|
end
|
15
15
|
|
16
16
|
def self.version_label
|
data/lib/gemsmith/rake/build.rb
CHANGED
@@ -2,7 +2,7 @@ require "bundler/ui/shell"
|
|
2
2
|
|
3
3
|
module Gemsmith
|
4
4
|
module Rake
|
5
|
-
#
|
5
|
+
# Provides gem build functionality. Meant to be wrapped in Rake tasks.
|
6
6
|
class Build
|
7
7
|
def initialize shell: Bundler::UI::Shell.new, kernel: Kernel
|
8
8
|
@shell = shell
|
@@ -1,62 +1,43 @@
|
|
1
|
-
require "
|
1
|
+
require "milestoner"
|
2
2
|
|
3
3
|
module Gemsmith
|
4
4
|
module Rake
|
5
|
-
#
|
5
|
+
# Provides gem release functionality. Meant to be wrapped in Rake tasks.
|
6
6
|
class Release
|
7
7
|
def initialize gem_spec_path = Dir.glob("#{Dir.pwd}/*.gemspec").first,
|
8
|
-
|
9
|
-
|
8
|
+
bundler: Bundler,
|
9
|
+
tagger: Milestoner::Tagger.new,
|
10
|
+
shell: Bundler::UI::Shell.new
|
10
11
|
|
11
12
|
@gem_spec_path = gem_spec_path
|
13
|
+
@tagger = tagger
|
12
14
|
@shell = shell
|
13
|
-
@
|
14
|
-
|
15
|
-
@
|
16
|
-
end
|
17
|
-
|
18
|
-
def name
|
19
|
-
gem_spec.name
|
15
|
+
@gem_spec = bundler.load_gemspec gem_spec_path.to_s
|
16
|
+
rescue Errno::ENOENT
|
17
|
+
@shell.error "Invalid gemspec file path: #{@gem_spec_path}."
|
20
18
|
end
|
21
19
|
|
22
|
-
def
|
20
|
+
def version_number
|
23
21
|
gem_spec.version.version
|
24
22
|
end
|
25
23
|
|
26
|
-
def
|
27
|
-
"v#{
|
24
|
+
def version_label
|
25
|
+
"v#{version_number}"
|
28
26
|
end
|
29
27
|
|
30
|
-
def
|
31
|
-
"#{name}-#{
|
28
|
+
def gem_file_name
|
29
|
+
"#{gem_spec.name}-#{version_number}.gem"
|
32
30
|
end
|
33
31
|
|
34
|
-
def
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
kernel.system "git tag -d #{version_formatted}"
|
40
|
-
shell.error %(Removed "#{version_formatted}" due to errors.)
|
41
|
-
end
|
42
|
-
|
43
|
-
def push
|
44
|
-
kernel.system "git push --tags"
|
32
|
+
def publish
|
33
|
+
tagger.create version_number, sign: true
|
34
|
+
rescue Milestoner::Errors::Base => error
|
35
|
+
shell.error error.message
|
45
36
|
end
|
46
37
|
|
47
38
|
private
|
48
39
|
|
49
|
-
attr_reader :gem_spec_path, :gem_spec, :
|
50
|
-
|
51
|
-
def load_gem_spec
|
52
|
-
Bundler.load_gemspec gem_spec_path.to_s
|
53
|
-
rescue Errno::ENOENT
|
54
|
-
shell.error "Invalid gemspec file path: #{gem_spec_path}."
|
55
|
-
end
|
56
|
-
|
57
|
-
def tagged?
|
58
|
-
kernel.system %(git show #{version_formatted})
|
59
|
-
end
|
40
|
+
attr_reader :gem_spec_path, :gem_spec, :tagger, :shell
|
60
41
|
end
|
61
42
|
end
|
62
43
|
end
|
data/lib/gemsmith/rake/tasks.rb
CHANGED
@@ -31,10 +31,9 @@ module Gemsmith
|
|
31
31
|
build.clean!
|
32
32
|
end
|
33
33
|
|
34
|
-
desc "Build, tag #{release.
|
34
|
+
desc "Build, tag #{release.version_label} (signed), and push #{release.gem_file_name} to RubyGems"
|
35
35
|
task publish: [:clean, :build, "release:guard_clean"] do
|
36
|
-
release.
|
37
|
-
release.push
|
36
|
+
release.publish
|
38
37
|
::Rake::Task["release:rubygem_push"].invoke
|
39
38
|
end
|
40
39
|
end
|
@@ -2,7 +2,7 @@ RSpec.configure do |config|
|
|
2
2
|
config.order = "random"
|
3
3
|
config.filter_run focus: true
|
4
4
|
config.run_all_when_everything_filtered = true
|
5
|
-
config.example_status_persistence_file_path = "./tmp/rspec
|
5
|
+
config.example_status_persistence_file_path = "./tmp/rspec-status.txt"
|
6
6
|
|
7
7
|
config.mock_with :rspec do |mocks|
|
8
8
|
mocks.verify_partial_doubles = true
|
@@ -14,9 +14,10 @@ RSpec.configure do |config|
|
|
14
14
|
config.include RSpec::Kit::TempDirContext
|
15
15
|
|
16
16
|
config.before do |example|
|
17
|
-
if example.metadata[:temp_dir]
|
18
|
-
|
19
|
-
|
20
|
-
|
17
|
+
FileUtils.mkdir_p(temp_dir) if example.metadata[:temp_dir]
|
18
|
+
end
|
19
|
+
|
20
|
+
config.after do |example|
|
21
|
+
FileUtils.rm_rf(temp_dir) if example.metadata[:temp_dir]
|
21
22
|
end
|
22
23
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gemsmith
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 5.
|
4
|
+
version: 5.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brooke Kuhlmann
|
@@ -30,7 +30,7 @@ cert_chain:
|
|
30
30
|
aSif+qBc6oHD7EQWPF5cZkzkIURuwNwPBngZGxIKaMAgRhjGFXzUMAaq++r59cS9
|
31
31
|
xTfQ4k6fglKEgpnLAXiKdo2c8Ym+X4rIKFfedQ==
|
32
32
|
-----END CERTIFICATE-----
|
33
|
-
date: 2015-09-
|
33
|
+
date: 2015-09-27 00:00:00.000000000 Z
|
34
34
|
dependencies:
|
35
35
|
- !ruby/object:Gem::Dependency
|
36
36
|
name: thor
|
@@ -60,6 +60,20 @@ dependencies:
|
|
60
60
|
- - "~>"
|
61
61
|
- !ruby/object:Gem::Version
|
62
62
|
version: '2.1'
|
63
|
+
- !ruby/object:Gem::Dependency
|
64
|
+
name: milestoner
|
65
|
+
requirement: !ruby/object:Gem::Requirement
|
66
|
+
requirements:
|
67
|
+
- - "~>"
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '1.0'
|
70
|
+
type: :runtime
|
71
|
+
prerelease: false
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
requirements:
|
74
|
+
- - "~>"
|
75
|
+
- !ruby/object:Gem::Version
|
76
|
+
version: '1.0'
|
63
77
|
- !ruby/object:Gem::Dependency
|
64
78
|
name: rake
|
65
79
|
requirement: !ruby/object:Gem::Requirement
|
metadata.gz.sig
CHANGED
@@ -1,2 +1 @@
|
|
1
|
-
|
2
|
-
Z�� b��5�]l&\�ݯ��U`��);�A�"/���ˣ%�~�t��� ����=������0�����R�s�T�L4�ZkQ�H����)�bB����p<�{�:���[G_��\Œ�!��n�PFMȿ��]A)fO$��F�����A��D���+��f�`��9p�
|
1
|
+
*��D4��6����ԟK_���Q����b�~���F��|j��[=f��C�<�f�{���сh5{Q7���\�&�-��9���Mvr�oϦ�fѕH����u�?0[�>7kn�]�����%�Ѝ�G
|