gemplate 2.0.5 → 2.0.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: ad5b9b54c8d815b0cd9d1e50a1b72bcd04c58d24
4
- data.tar.gz: de51f9d60bcf5f75fb90463f5363be2443126a73
2
+ SHA256:
3
+ metadata.gz: ec27c79db93216455dd99b25bf9478f4d148df7b44e1b908e4918e7150c1a6c0
4
+ data.tar.gz: a872e30aae48b7bb8cae955a72b6fd9d4759234695edc1f29d9a0a002c0c5be1
5
5
  SHA512:
6
- metadata.gz: 8308e4b6067f6db9ccf49dd82e30c334f2f1fa7146b2629f1a105a79f63081b8404ea0f04960d63867756c7dc389c6cc683455fe3853578876d0296d8a302d60
7
- data.tar.gz: 4fcab8e10366e8aa54a488809a170e849f03210bc956ab2030d8281bc96bf3baf4cb7e3145e4cf2b6934827390016f8ae75899f4d1b55c6b4d1598946d9eae1d
6
+ metadata.gz: a71d106430c623d1a285d966182e617d040e755cc52c1cea678a4b29777b3c8decc18e6e87611c82c78eda1d5732b91c57b2a33d710d897d151a797e985fe7fb
7
+ data.tar.gz: 02ccd4ddc2677ddf5e9458adc6d0bf44dffaa03db2274abe9ca928170b2dc076e1159fa7443815c56c5b9fc18614d3a6950414f08c025316d669326e70c311e1
@@ -1,3 +1,3 @@
1
- 2.3.1
2
- 2.2.5
3
- 2.1.10
1
+ 2.5.1
2
+ 2.4.4
3
+ 2.3.7
@@ -1,11 +1,42 @@
1
- item do
2
- expected do
3
- static
4
- set 'green'
1
+ require 'open-uri'
2
+ Prospectus.extra_dep('file', 'nokogiri')
3
+ Prospectus.extra_dep('file', 'prospectus_circleci')
4
+ Prospectus.extra_dep('file', 'prospectus_gems')
5
+
6
+ def upstream_version
7
+ page = Nokogiri::HTML(open('https://www.ruby-lang.org/en/downloads/'))
8
+ table = page.xpath('//*[@id="content"]/ul[2]')
9
+ categories = table.xpath('li').select do |x|
10
+ x.xpath('strong').text =~ /^(Stable|In security)/
5
11
  end
12
+ versions = categories.map { |x| x.xpath('ul/li') }.flatten
13
+ versions.map { |x| x.text.split[1] }.join(', ')
14
+ end
6
15
 
7
- actual do
8
- gemnasium
9
- slug 'akerl/gemplate'
16
+ UPSTREAM_VERSION = upstream_version
17
+
18
+ my_slug = 'akerl/gemplate'
19
+
20
+ item do
21
+ noop
22
+
23
+ deps do
24
+ item do
25
+ name 'ruby'
26
+
27
+ expected do
28
+ static
29
+
30
+ set UPSTREAM_VERSION
31
+ end
32
+
33
+ actual do
34
+ static
35
+ set File.read('.circle-ruby').chomp.gsub("\n",', ')
36
+ end
37
+ end
10
38
  end
39
+
40
+ extend ProspectusCircleci::Build.new(my_slug)
41
+ extend ProspectusGems::Gemspec.new
11
42
  end
@@ -1,2 +1,5 @@
1
- Encoding:
2
- Enabled: false
1
+ inherit_gem:
2
+ goodcop: .rubocop.yml
3
+ AllCops:
4
+ Include:
5
+ - 'bin/*'
@@ -1,3 +1,15 @@
1
+ # 2.1.0 / 2018-06-23
2
+
3
+ * [ENHANCEMENT] Deprecate Ruby 2.2
4
+
5
+ # 2.0.5 / 2016-08-07
6
+
7
+ * [ENHANCEMENT] Improve circle RVM handling
8
+
9
+ # 2.0.4 / 2015-12-29
10
+
11
+ * [FEATURE] Add prospectus template
12
+
1
13
  # 2.0.3 / 2015-12-09
2
14
 
3
15
  * [BUGFIX] Fix dev dependency copying from gemspec to template
data/Gemfile CHANGED
@@ -1,4 +1,3 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
3
  gemspec
4
-
data/README.md CHANGED
@@ -3,7 +3,7 @@ gemplate
3
3
 
4
4
  [![Gem Version](https://img.shields.io/gem/v/gemplate.svg)](https://rubygems.org/gems/gemplate)
5
5
  [![Dependency Status](https://img.shields.io/gemnasium/akerl/gemplate.svg)](https://gemnasium.com/akerl/gemplate)
6
- [![Build Status](https://img.shields.io/circleci/project/akerl/gemplate.svg)](https://circleci.com/gh/akerl/gemplate)
6
+ [![Build Status](https://img.shields.io/circleci/project/akerl/gemplate/master.svg)](https://circleci.com/gh/akerl/gemplate)
7
7
  [![Coverage Status](https://img.shields.io/codecov/c/github/akerl/gemplate.svg)](https://codecov.io/github/akerl/gemplate)
8
8
  [![Code Quality](https://img.shields.io/codacy/5e5249869fbb4e91acc69f53d8dd7da5.svg)](https://www.codacy.com/app/akerl/gemplate)
9
9
  [![MIT Licensed](https://img.shields.io/badge/license-MIT-green.svg)](https://tldrlegal.com/license/mit-license)
data/Rakefile CHANGED
@@ -7,8 +7,7 @@ RSpec::Core::RakeTask.new(:spec)
7
7
 
8
8
  desc 'Run Rubocop on the gem'
9
9
  RuboCop::RakeTask.new(:rubocop) do |task|
10
- task.patterns = ['lib/**/*.rb', 'spec/**/*.rb', 'bin/**/*']
11
10
  task.fail_on_error = true
12
11
  end
13
12
 
14
- task default: [:spec, :rubocop, :build, :install]
13
+ task default: %i[spec rubocop build install]
@@ -6,6 +6,7 @@ require 'rugged'
6
6
  require 'curb'
7
7
  require 'mercenary'
8
8
 
9
+ # rubocop:disable Metrics/BlockLength
9
10
  Mercenary.program(:gemplate) do |p|
10
11
  p.version Gemplate::VERSION
11
12
  p.description 'Tool for bootstrapping new gems'
@@ -68,3 +69,4 @@ Mercenary.program(:gemplate) do |p|
68
69
  puts 'New gem has been created!'
69
70
  end
70
71
  end
72
+ # rubocop:enable Metrics/BlockLength
data/circle.yml CHANGED
@@ -1,5 +1,6 @@
1
1
  dependencies:
2
2
  override:
3
+ - 'for i in $(cat .circle-ruby) ; do rvm-exec $i gem update --system --no-doc || exit 1 ; done'
3
4
  - 'for i in $(cat .circle-ruby) ; do rvm-exec $i bundle install || exit 1 ; done'
4
5
  test:
5
6
  override:
@@ -1,6 +1,8 @@
1
- $:.unshift File.expand_path('../lib/', __FILE__)
1
+ require 'English'
2
+ $LOAD_PATH.unshift File.expand_path('lib', __dir__)
2
3
  require 'gemplate/version'
3
4
 
5
+ # rubocop:disable Metrics/BlockLength
4
6
  Gem::Specification.new do |s|
5
7
  s.name = 'gemplate'
6
8
  s.version = Gemplate::VERSION
@@ -17,18 +19,20 @@ Gem::Specification.new do |s|
17
19
  s.test_files = `git ls-files spec/*`.split
18
20
  s.executables = ['gemplate']
19
21
 
20
- s.add_dependency 'rugged', '~> 0.24.0'
21
- s.add_dependency 'userinput', '~> 1.0.0'
22
- s.add_dependency 'octoauth', '~> 1.4.5'
23
- s.add_dependency 'octokit', '~> 4.3.0'
24
22
  s.add_dependency 'curb', '~> 0.9.0'
25
23
  s.add_dependency 'mercenary', '~> 0.3.4'
24
+ s.add_dependency 'octoauth', '~> 1.5.1'
25
+ s.add_dependency 'octokit', '~> 4.9.0'
26
+ s.add_dependency 'rugged', '~> 0.27.0'
27
+ s.add_dependency 'userinput', '~> 1.0.0'
26
28
 
27
- s.add_development_dependency 'rubocop', '~> 0.42.0'
28
- s.add_development_dependency 'rake', '~> 11.2.0'
29
29
  s.add_development_dependency 'codecov', '~> 0.1.1'
30
- s.add_development_dependency 'rspec', '~> 3.5.0'
31
- s.add_development_dependency 'fuubar', '~> 2.1.0'
32
- s.add_development_dependency 'webmock', '~> 2.1.0' # SKIP WHEN COPYING TO TEMPLATE
33
- s.add_development_dependency 'vcr', '~> 3.0.0' # SKIP WHEN COPYING TO TEMPLATE
30
+ s.add_development_dependency 'fuubar', '~> 2.3.0'
31
+ s.add_development_dependency 'goodcop', '~> 0.5.0'
32
+ s.add_development_dependency 'rake', '~> 12.3.0'
33
+ s.add_development_dependency 'rspec', '~> 3.7.0'
34
+ s.add_development_dependency 'rubocop', '~> 0.57.1'
35
+ s.add_development_dependency 'vcr', '~> 4.0.0' # SKIP WHEN COPYING TO TEMPLATE # rubocop:disable Metrics/LineLength
36
+ s.add_development_dependency 'webmock', '~> 3.4.0' # SKIP WHEN COPYING TO TEMPLATE # rubocop:disable Metrics/LineLength
34
37
  end
38
+ # rubocop:enable Metrics/BlockLength
@@ -1,4 +1,5 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  require 'rugged'
3
4
  require 'pathname'
4
5
  require 'fileutils'
@@ -68,7 +69,7 @@ module Gemplate
68
69
  [/REPO_NAME/, @name],
69
70
  [/EMAIL_ADDRESS/, @email],
70
71
  [/CURRENT_YEAR/, Time.now.strftime('%Y')],
71
- [/#DEV_DEPS/, dependencies]
72
+ [/# DEV_DEPS/, dependencies]
72
73
  ]
73
74
  end
74
75
 
@@ -82,9 +83,9 @@ module Gemplate
82
83
  end
83
84
 
84
85
  def adjust_files
85
- moves = [['REPO_NAME.gemspec', "#{@name}.gemspec"],
86
- ['lib/REPO_NAME.rb', "lib/#{@name}.rb"],
87
- ['spec/REPO_NAME_spec.rb', "spec/#{@name}_spec.rb"]]
86
+ moves = [['repo_name.gemspec', "#{@name}.gemspec"],
87
+ ['lib/repo_name.rb', "lib/#{@name}.rb"],
88
+ ['spec/repo_name_spec.rb', "spec/#{@name}_spec.rb"]]
88
89
  moves.each { |original, new| FileUtils.move original, new }
89
90
  end
90
91
 
@@ -1,6 +1,7 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  ##
3
4
  # Declare version of module
4
5
  module Gemplate
5
- VERSION = '2.0.5'.freeze
6
+ VERSION = '2.0.6'.freeze
6
7
  end
@@ -1,4 +1,5 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  require 'spec_helper'
3
4
  require 'fileutils'
4
5
 
@@ -19,7 +19,7 @@ VCR.configure do |c|
19
19
  c.hook_into :webmock
20
20
  c.before_record do |i|
21
21
  i.request.headers.delete 'Authorization'
22
- %w(Etag X-Github-Request-Id X-Served-By).each do |header|
22
+ %w[Etag X-Github-Request-Id X-Served-By].each do |header|
23
23
  i.response.headers.delete header
24
24
  end
25
25
  end
@@ -1,3 +1,3 @@
1
- 2.3.1
2
- 2.2.5
3
- 2.1.10
1
+ 2.5.1
2
+ 2.4.4
3
+ 2.3.7
@@ -1,11 +1,25 @@
1
+ Prospectus.extra_dep('file', 'prospectus_circleci')
2
+
3
+ my_slug = 'AUTHOR_NAME/REPO_NAME'
4
+
1
5
  item do
2
- expected do
3
- static
4
- set 'green'
5
- end
6
+ noop
6
7
 
7
- actual do
8
- gemnasium
9
- slug 'AUTHOR_NAME/REPO_NAME'
8
+ deps do
9
+ item do
10
+ name 'gems'
11
+
12
+ expected do
13
+ static
14
+ set 'green'
15
+ end
16
+
17
+ actual do
18
+ gemnasium
19
+ slug my_slug
20
+ end
21
+ end
10
22
  end
23
+
24
+ extend ProspectusCircleci::Build.new(my_slug)
11
25
  end
@@ -1,2 +1,2 @@
1
- Encoding:
2
- Enabled: false
1
+ inherit_gem:
2
+ goodcop: .rubocop.yml
@@ -1,4 +1,3 @@
1
1
  source 'https://rubygems.org'
2
2
 
3
3
  gemspec
4
-
@@ -7,8 +7,7 @@ RSpec::Core::RakeTask.new(:spec)
7
7
 
8
8
  desc 'Run Rubocop on the gem'
9
9
  RuboCop::RakeTask.new(:rubocop) do |task|
10
- task.patterns = ['lib/**/*.rb', 'spec/**/*.rb']
11
10
  task.fail_on_error = true
12
11
  end
13
12
 
14
- task default: [:spec, :rubocop, :build, :install]
13
+ task default: %i[spec rubocop build install]
@@ -4,7 +4,7 @@ Gem::Specification.new do |s|
4
4
  s.date = Time.now.strftime('%Y-%m-%d')
5
5
 
6
6
  s.summary = ''
7
- s.description = ""
7
+ s.description = ''
8
8
  s.authors = ['FULL_NAME']
9
9
  s.email = 'EMAIL_ADDRESS'
10
10
  s.homepage = 'https://github.com/AUTHOR_NAME/REPO_NAME'
@@ -13,5 +13,5 @@ Gem::Specification.new do |s|
13
13
  s.files = `git ls-files`.split
14
14
  s.test_files = `git ls-files spec/*`.split
15
15
 
16
- #DEV_DEPS
16
+ # DEV_DEPS
17
17
  end
@@ -1,2 +1 @@
1
1
  require 'spec_helper'
2
-
metadata CHANGED
@@ -1,197 +1,211 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gemplate
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.5
4
+ version: 2.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Les Aker
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-08-07 00:00:00.000000000 Z
11
+ date: 2018-06-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: rugged
14
+ name: curb
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: 0.24.0
19
+ version: 0.9.0
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: 0.24.0
26
+ version: 0.9.0
27
27
  - !ruby/object:Gem::Dependency
28
- name: userinput
28
+ name: mercenary
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - "~>"
32
32
  - !ruby/object:Gem::Version
33
- version: 1.0.0
33
+ version: 0.3.4
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - "~>"
39
39
  - !ruby/object:Gem::Version
40
- version: 1.0.0
40
+ version: 0.3.4
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: octoauth
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
45
  - - "~>"
46
46
  - !ruby/object:Gem::Version
47
- version: 1.4.5
47
+ version: 1.5.1
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - "~>"
53
53
  - !ruby/object:Gem::Version
54
- version: 1.4.5
54
+ version: 1.5.1
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: octokit
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: 4.3.0
61
+ version: 4.9.0
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: 4.3.0
68
+ version: 4.9.0
69
69
  - !ruby/object:Gem::Dependency
70
- name: curb
70
+ name: rugged
71
71
  requirement: !ruby/object:Gem::Requirement
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: 0.9.0
75
+ version: 0.27.0
76
76
  type: :runtime
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: 0.9.0
82
+ version: 0.27.0
83
83
  - !ruby/object:Gem::Dependency
84
- name: mercenary
84
+ name: userinput
85
85
  requirement: !ruby/object:Gem::Requirement
86
86
  requirements:
87
87
  - - "~>"
88
88
  - !ruby/object:Gem::Version
89
- version: 0.3.4
89
+ version: 1.0.0
90
90
  type: :runtime
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
- version: 0.3.4
96
+ version: 1.0.0
97
97
  - !ruby/object:Gem::Dependency
98
- name: rubocop
98
+ name: codecov
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
101
  - - "~>"
102
102
  - !ruby/object:Gem::Version
103
- version: 0.42.0
103
+ version: 0.1.1
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - "~>"
109
109
  - !ruby/object:Gem::Version
110
- version: 0.42.0
110
+ version: 0.1.1
111
111
  - !ruby/object:Gem::Dependency
112
- name: rake
112
+ name: fuubar
113
113
  requirement: !ruby/object:Gem::Requirement
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: 11.2.0
117
+ version: 2.3.0
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: 11.2.0
124
+ version: 2.3.0
125
125
  - !ruby/object:Gem::Dependency
126
- name: codecov
126
+ name: goodcop
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
129
  - - "~>"
130
130
  - !ruby/object:Gem::Version
131
- version: 0.1.1
131
+ version: 0.5.0
132
132
  type: :development
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
136
  - - "~>"
137
137
  - !ruby/object:Gem::Version
138
- version: 0.1.1
138
+ version: 0.5.0
139
139
  - !ruby/object:Gem::Dependency
140
- name: rspec
140
+ name: rake
141
141
  requirement: !ruby/object:Gem::Requirement
142
142
  requirements:
143
143
  - - "~>"
144
144
  - !ruby/object:Gem::Version
145
- version: 3.5.0
145
+ version: 12.3.0
146
146
  type: :development
147
147
  prerelease: false
148
148
  version_requirements: !ruby/object:Gem::Requirement
149
149
  requirements:
150
150
  - - "~>"
151
151
  - !ruby/object:Gem::Version
152
- version: 3.5.0
152
+ version: 12.3.0
153
153
  - !ruby/object:Gem::Dependency
154
- name: fuubar
154
+ name: rspec
155
155
  requirement: !ruby/object:Gem::Requirement
156
156
  requirements:
157
157
  - - "~>"
158
158
  - !ruby/object:Gem::Version
159
- version: 2.1.0
159
+ version: 3.7.0
160
160
  type: :development
161
161
  prerelease: false
162
162
  version_requirements: !ruby/object:Gem::Requirement
163
163
  requirements:
164
164
  - - "~>"
165
165
  - !ruby/object:Gem::Version
166
- version: 2.1.0
166
+ version: 3.7.0
167
167
  - !ruby/object:Gem::Dependency
168
- name: webmock
168
+ name: rubocop
169
169
  requirement: !ruby/object:Gem::Requirement
170
170
  requirements:
171
171
  - - "~>"
172
172
  - !ruby/object:Gem::Version
173
- version: 2.1.0
173
+ version: 0.57.1
174
174
  type: :development
175
175
  prerelease: false
176
176
  version_requirements: !ruby/object:Gem::Requirement
177
177
  requirements:
178
178
  - - "~>"
179
179
  - !ruby/object:Gem::Version
180
- version: 2.1.0
180
+ version: 0.57.1
181
181
  - !ruby/object:Gem::Dependency
182
182
  name: vcr
183
183
  requirement: !ruby/object:Gem::Requirement
184
184
  requirements:
185
185
  - - "~>"
186
186
  - !ruby/object:Gem::Version
187
- version: 3.0.0
187
+ version: 4.0.0
188
+ type: :development
189
+ prerelease: false
190
+ version_requirements: !ruby/object:Gem::Requirement
191
+ requirements:
192
+ - - "~>"
193
+ - !ruby/object:Gem::Version
194
+ version: 4.0.0
195
+ - !ruby/object:Gem::Dependency
196
+ name: webmock
197
+ requirement: !ruby/object:Gem::Requirement
198
+ requirements:
199
+ - - "~>"
200
+ - !ruby/object:Gem::Version
201
+ version: 3.4.0
188
202
  type: :development
189
203
  prerelease: false
190
204
  version_requirements: !ruby/object:Gem::Requirement
191
205
  requirements:
192
206
  - - "~>"
193
207
  - !ruby/object:Gem::Version
194
- version: 3.0.0
208
+ version: 3.4.0
195
209
  description: Creates a basic repository layout for a new gem
196
210
  email: me@lesaker.org
197
211
  executables:
@@ -229,11 +243,11 @@ files:
229
243
  - template/.rubocop.yml
230
244
  - template/Gemfile
231
245
  - template/README.md
232
- - template/REPO_NAME.gemspec
233
246
  - template/Rakefile
234
247
  - template/circle.yml
235
- - template/lib/REPO_NAME.rb
236
- - template/spec/REPO_NAME_spec.rb
248
+ - template/lib/repo_name.rb
249
+ - template/repo_name.gemspec
250
+ - template/spec/repo_name_spec.rb
237
251
  - template/spec/spec_helper.rb
238
252
  homepage: https://github.com/akerl/gemplate
239
253
  licenses:
@@ -255,7 +269,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
255
269
  version: '0'
256
270
  requirements: []
257
271
  rubyforge_project:
258
- rubygems_version: 2.5.1
272
+ rubygems_version: 2.7.6
259
273
  signing_key:
260
274
  specification_version: 4
261
275
  summary: Bootstrap tool for making gems