juwelier 2.3.4 → 2.3.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
2
  SHA1:
3
- metadata.gz: e6d90f41aec17c524cd9d16d1c6f3627ea4d7f3d
4
- data.tar.gz: 815a192e1ae8a26497f3b26e53aca2b133f9687c
3
+ metadata.gz: da7ab0af1c0165d1bb78a81dcefdc5f9444d8963
4
+ data.tar.gz: ea8c2c9060d230921e2deff6edb7c9ab638a12e4
5
5
  SHA512:
6
- metadata.gz: 6c04f047c6d324716b5af2db04b2e0f67bdbef182a01f812a675f5182fc2ca72225657d554511860673dc4b9d8f28a4b04182cf1db6e4c142134bfec42ce7ee2
7
- data.tar.gz: 54230436efe962a82f9d24549e423786b00e1880bf9036b2a8df9288bef61089af0ccfe4d6043dbb8f726835bed884afa0eeda77e4385bc63bb9c1f02781f11a
6
+ metadata.gz: 41929dc46d991affc14ce5113910166747fa3d0269b804efe5dcc6949da4e4695f44fe67044bb644542350a706515f3ba50e711a3f6a2cf7960d22ae16fd6332
7
+ data.tar.gz: 3cbedef396c211f68e47e86fdc87610734ed3e4b0c592e845e2584aee53d33dc8b6c4fc664312e4b057140fb8ec3ea287fc1f79df6986efa120ad4e4aa730f79
data/.semver CHANGED
@@ -1,5 +1,5 @@
1
1
  ---
2
2
  :major: 2
3
3
  :minor: 3
4
- :patch: 4
4
+ :patch: 6
5
5
  :special: ''
data/.travis.yml CHANGED
@@ -1,10 +1,9 @@
1
1
  language: ruby
2
+ before_install:
3
+ - gem install bundler # need more up-to-date bundler to match Gemfile's
2
4
  rvm:
3
- - 2.0.0
4
- - 2.2.0
5
- - 2.2.1
6
- - 2.2.2
7
- - 2.3.0
8
- - 2.3.1
5
+ - 2.2.6
6
+ - 2.3.3
7
+ - 2.4.0
9
8
  notifications:
10
9
  irc: "irc.freenode.org#juwelier"
data/Gemfile CHANGED
@@ -24,6 +24,7 @@ group :test do
24
24
  gem "shoulda"
25
25
  gem "mhennemeyer-output_catcher"
26
26
  gem "rr", ">= 1.0.4"
27
+ gem "test-unit-rr", "~> 1.0"
27
28
  gem "mocha"
28
29
  gem "redgreen"
29
30
  gem "test-construct"
data/README.markdown CHANGED
@@ -10,6 +10,10 @@ maintaining both repos for a while, and eventually converge them to one. In
10
10
  the mean time, all new features shall be added to Juwelier, while keeping
11
11
  the origial Jeweler up-to-date with the latest Ruby releases.
12
12
 
13
+ ALSO NOTE that I am transistioning the README to the orgmode format. As such,
14
+ the Markdown version may be out of date, especially with the release notes
15
+ and changelogs. Please refer to it instead.
16
+
13
17
  [![Build Status](https://travis-ci.org/flajann2/juwelier.png)](https://travis-ci.org/flajann2/juwelier)
14
18
  [![Coverage Status](https://coveralls.io/repos/flajann2/juwelier/badge.png)](https://coveralls.io/r/flajann2/juwelier)
15
19
  [![Dependency Status](https://www.versioneye.com/ruby/juwelier/2.0.0/badge.png)](https://www.versioneye.com/ruby/juwelier/2.0.0)
@@ -28,25 +32,27 @@ the origial Jeweler up-to-date with the latest Ruby releases.
28
32
  a migration option, but in the meantime, you may wish to
29
33
  run this bash script from the root directory of your project:
30
34
 
31
- for f in $(grep -irl jeweler *)
32
- do
33
- sed -i 's/jeweler/juwelier/g' $f
34
- sed -i 's/Jeweler/Juwelier/g' $f
35
- done
36
- bundle update
37
-
35
+ ```bash
36
+ for f in $(grep -irl jeweler *)
37
+ do
38
+ sed -i 's/jeweler/juwelier/g' $f
39
+ sed -i 's/Jeweler/Juwelier/g' $f
40
+ done
41
+ bundle update
42
+ ```
43
+
38
44
  As you know, "Juwelier" is "Jeweler" in German. Since I
39
45
  have made Germany my new home, it only seemed approporiate.
40
-
46
+
41
47
  ## Hello, world
42
48
 
43
49
  Use RubyGems to install the heck out of juwelier to get started:
44
50
 
45
- $ gem install juwelier
51
+ `$ gem install juwelier`
46
52
 
47
53
  With juwelier installed, you can use the `juwelier` command to generate a new project. For the most basic use, just give it a name:
48
54
 
49
- $ juwelier hello-gem
55
+ `$ juwelier hello-gem`
50
56
 
51
57
  This requires some Git configuration (like name, email, GitHub account, etc), but `juwelier` will prompt along the way.
52
58
 
@@ -70,40 +76,40 @@ Check out `juwelier --help` for the most up to date options.
70
76
 
71
77
  Beyond just editing source code, you'll be interacting with your gem using `rake` a lot. To see all the tasks available with a brief description, you can run:
72
78
 
73
- $ rake -T
79
+ `$ rake -T`
74
80
 
75
81
  You'll need a version before you can start installing your gem locally. The easiest way is with the `version:write` Rake task. Let's imagine you start with 0.1.0
76
82
 
77
- $ rake version:write MAJOR=0 MINOR=1 PATCH=0
83
+ `$ rake version:write MAJOR=0 MINOR=1 PATCH=0`
78
84
 
79
85
  You can now go forth and develop, now that there's an initial version defined. Eventually, you should install and test the gem:
80
86
 
81
- $ rake install
87
+ `$ rake install`
82
88
 
83
89
  The `install` rake task builds the gem and `gem install`s it. You're all set if you're using [RVM](http://rvm.beginrescueend.com/), but you may need to run it with sudo if you have a system-installed ruby:
84
90
 
85
- $ sudo rake install
91
+ `$ sudo rake install`
86
92
 
87
93
  ### Releasing
88
94
 
89
95
  At last, it's time to [ship it](http://shipitsquirrel.github.com/)! Make sure you have everything committed and pushed, then go wild:
90
96
 
91
- $ rake release
97
+ `$ rake release`
92
98
 
93
99
  This will automatically:
94
100
 
95
- *Juwelier Generate `hello-gem.gemspec` and commit it
101
+ * Juwelier Generate `hello-gem.gemspec` and commit it
96
102
  * Use `git` to tag `v0.1.0` and push it
97
103
  * Build `hello-gem-0.1.0.gem` and push it to [rubygems.org](http://rubygems.org/gems/)
98
104
 
99
105
  `rake release` accepts REMOTE(default: `origin`), LOCAL_BRANCH(default: `master`), REMOTE_BRANCH(default: `master`) and BRANCH(default: master)as options.
100
106
 
101
- $ rake release REMOTE=upstream LOCAL_BRANCH=critical-security-fix REMOTE_BRANCH=v3
107
+ `$ rake release REMOTE=upstream LOCAL_BRANCH=critical-security-fix REMOTE_BRANCH=v3`
102
108
 
103
109
  This will tag and push the commits on your local branch named `critical-security-fix` to branch named `v3` in remote named `upstream` (if you have commit rights
104
110
  on `upstream`) and release the gem.
105
111
 
106
- $ rake release BRANCH=v3
112
+ `$ rake release BRANCH=v3`
107
113
 
108
114
  If both remote and local branches are the same, use `BRANCH` option to simplify.
109
115
  This will tag and push the commits on your local branch named `v3` to branch named `v3` in remote named `origin` (if you have commit rights
@@ -113,21 +119,23 @@ on `origin`) and release the gem.
113
119
 
114
120
  It feels good to release code. Do it, do it often. But before that, bump the version. Then release it. There's a few ways to update the version:
115
121
 
116
- # version:write like before
117
- $ rake version:write MAJOR=0 MINOR=3 PATCH=0
122
+ ```bash
123
+ # version:write like before
124
+ $ rake version:write MAJOR=0 MINOR=3 PATCH=0
118
125
 
119
- # bump just major, ie 0.1.0 -> 1.0.0
120
- $ rake version:bump:major
126
+ # bump just major, ie 0.1.0 -> 1.0.0
127
+ $ rake version:bump:major
121
128
 
122
- # bump just minor, ie 0.1.0 -> 0.2.0
123
- $ rake version:bump:minor
129
+ # bump just minor, ie 0.1.0 -> 0.2.0
130
+ $ rake version:bump:minor
124
131
 
125
- # bump just patch, ie 0.1.0 -> 0.1.1
126
- $ rake version:bump:patch
132
+ # bump just patch, ie 0.1.0 -> 0.1.1
133
+ $ rake version:bump:patch
134
+ ```
127
135
 
128
136
  Then it's the same `release` we used before:
129
137
 
130
- $ rake release
138
+ `$ rake release`
131
139
 
132
140
  ## Customizing your gem
133
141
 
@@ -135,119 +143,119 @@ If you've been following along so far, your gem is just a blank slate. You're go
135
143
 
136
144
  You can customize your gem by updating your `Rakefile`. With a newly generated project, it will look something like this:
137
145
 
138
- Juwelier require 'juwelier'
139
- ::Tasks.new do |gem|
140
- # gem is a Gem::Specification... see http://guides.rubygems.org/specification-reference/ for more options
141
- gem.name = "whatwhatwhat"
142
- gem.summary = %Q{TODO: one-line summary of your gem}
143
- gem.description = %Q{TODO: longer description of your gem}
144
- gem.email = "fred.mitchell@gmx.com"
145
- gem.homepage = "http://github.com/flajann2/whatwhatwhat"
146
- Juwelier gem.authors = ["Joshua Nichols"]
147
- end
148
- JuwelierJuwelier ::RubygemsDotOrgTasks.new
146
+ ```ruby
147
+ require 'juwelier'
148
+ Juwelier::Tasks.new do |gem|
149
+ # gem is a Gem::Specification... see http://guides.rubygems.org/specification-reference/ for more options
150
+ gem.name = "whatwhatwhat"
151
+ gem.summary = %Q{TODO: one-line summary of your gem}
152
+ gem.description = %Q{TODO: longer description of your gem}
153
+ gem.email = "fred.mitchell@gmx.com"
154
+ gem.homepage = "http://github.com/flajann2/whatwhatwhat"
155
+ gem.authors = ["Joshua Nichols"]
156
+ end
157
+ JuwelierJuwelier::RubygemsDotOrgTasks.new
158
+ ```
149
159
 
150
160
  It's crucial to understand the `gem` object is just a Gem::Specification. You can read up about it at [guides.rubygems.org/specification-reference](http://guides.rubygems.org/specification-reference/). This is the most basic way of specifying a gem, -managed or not. just exposes this to you, in addition to providing some reasonable defaults, which we'll explore now.
151
161
 
152
162
  ### Project information
153
163
 
154
- gem.name = "whatwhatwhat"
155
-
156
- Every gem has a name. Among other things, the gem name is how you are able to `gem install` it. [Reference](http://guides.rubygems.org/specification-reference/#name)
157
-
158
- gem.summary = %Q{TODO: one-line summary of your gem}
159
-
160
- This is a one line summary of your gem. This is displayed, for example, when you use `gem list --details` or view it on [rubygems.org](http://rubygems.org/gems/).
161
-
162
- gem.description = %Q{TODO: longer description of your gem}
164
+ A short description about the configuration in the previous item.
163
165
 
164
- Description is a longer description. Scholars ascertain that knowledge of where the description is used was lost centuries ago.
166
+ - **gem.name**: Every gem has a name. Among other things, the gem name is how you are able to `gem install` it. [Reference](http://guides.rubygems.org/specification-reference/#name)
165
167
 
166
- gem.email = "fred.mitchell@gmx.com"
168
+ - **gem.summary**: This is a one line summary of your gem. This is displayed, for example, when you use `gem list --details` or view it on [rubygems.org](http://rubygems.org/gems/).
167
169
 
168
- This should be a way to get a hold of you regarding the gem.
170
+ - **gem.description**: Description is a longer description. Scholars ascertain that knowledge of where the description is used was lost centuries ago.
169
171
 
170
- gem.homepage = "http://github.com/flajann2/whatwhatwhat"
172
+ - **gem.email**: This should be a way to get a hold of you regarding the gem.
171
173
 
172
- The homepage should have more information about your gem. The juwelier generator guesses this based on the assumption your code lives on [GitHub](http://github.com/), using your Git configuration to find your GitHub username. This is displayed by `gem list --details` and on rubygems.org.
174
+ - **gem.homepage**: The homepage should have more information about your gem. The juwelier generator guesses this based on the assumption your code lives on [GitHub](http://github.com/), using your Git configuration to find your GitHub username. This is displayed by `gem list --details` and on rubygems.org.
173
175
 
174
- gem.authors = ["Joshua Nichols"]
176
+ - **gem.authors**: Hey, this is you, the author (or me in this case). The `juwelier` generator also guesses this from your Git configuration. This is displayed by `gem list --details` and on rubygems.org.
175
177
 
176
- Hey, this is you, the author (or me in this case). The `juwelier` generator also guesses this from your Git configuration. This is displayed by `gem list --details` and on rubygems.org.
178
+ ### Files
177
179
 
178
- ##Juwelier# Files
180
+ The quickest way to add more files is to `git add` them. Juwelier uses your git repository to populate your gem's files by including added and committed and excluding `.gitignore`d. In most cases, this is reasonable enough.
179
181
 
180
- ThJuweliere quickest way to add more files is to `git add` them. uses your Git repository to populate your gem's files by including added and committed and excluding `.gitignore`d. In most cases, this is reasonable enough.
182
+ If you need to tweak the files, that's cool. Juwelier populates `gem.files` as a `Rake::FileList`. It's like a normal array, except you can `include` and `exclude` file globs:
181
183
 
182
- If you need to tweak the files, that's cool. populates `gem.files` as a `Rake::FileList`. It's like a normal array, except you can `include` and `exclude` file globs:
183
-
184
- gem.files.exclude 'tmp' # exclude temporary directory
185
- gem.files.include 'lib/foo/bar.rb' # explicitly include lib/foo/bar.rb
184
+ ```ruby
185
+ gem.files.exclude 'tmp' # exclude temporary directory
186
+ gem.files.include 'lib/foo/bar.rb' # explicitly include lib/foo/bar.rb
187
+ ```
186
188
 
187
189
  If that's not enough, you can just set `gem.files` outright
188
190
 
189
- gem.files = Dir.glob('lib/**/*.rb')
191
+ `gem.files = Dir.glob('lib/**/*.rb')`
190
192
 
191
193
  ### Dependencies
192
194
 
193
195
  Dependencies let you define other gems that your gem needs to function. `gem install your-gem` will install your-gem's dependencies along with it, and when you use your-gem in an application, the dependencies will be made available. Use `gem.add_dependency` to register them. [Reference](http://guides.rubygems.org/specification-reference/#add_development_dependency)
194
196
 
195
- gem.add_dependency 'nokogiri'
197
+ `gem.add_dependency 'nokogiri'`
196
198
 
197
199
  This will ensure a version of `nokogiri` is installed, but it doesn't require anything more than that. You can provide extra args to be more specific:
198
200
 
199
- gem.add_dependency 'nokogiri', '= 1.2.1' # exactly version 1.2.1
200
- gem.add_dependency 'nokogiri', '>= 1.2.1' # greater than or equal to 1.2.1, ie, 1.2.1, 1.2.2, 1.3.0, 2.0.0, etc
201
- gem.add_dependency 'nokogiri', '>= 1.2.1', '< 1.3.0' # greater than or equal to 1.2.1, but less than 1.3.0
202
- gem.add_dependency 'nokogiri', '~> 1.2.1' # same thing, but more concise
201
+ ```ruby
202
+ gem.add_dependency 'nokogiri', '= 1.2.1' # exactly version 1.2.1
203
+ gem.add_dependency 'nokogiri', '>= 1.2.1' # greater than or equal to 1.2.1, ie, 1.2.1, 1.2.2, 1.3.0, 2.0.0, etc
204
+ gem.add_dependency 'nokogiri', '>= 1.2.1', '< 1.3.0' # greater than or equal to 1.2.1, but less than 1.3.0
205
+ gem.add_dependency 'nokogiri', '~> 1.2.1' # same thing, but more concise
206
+ ```
203
207
 
204
208
  When specifying which version is required, there's a bit of the condunrum. You want to allow the most versions possible, but you want to be sure they are compatible. Using `>= 1.2.1` is fine most of the time, except until the point that 2.0.0 comes out and totally breaks backwards the API. That's when it's good to use `~> 1.2.1`, which requires any version in the `1.2` family, starting with `1.2.1`.
205
209
 
206
- ##Juwelier# Executables
210
+ ### Executables
207
211
 
208
212
  Executables let your gem install shell commands. Just put any executable scripts in the `bin/` directory, make sure they are added using `git`, and will take care of the rest.
209
213
 
210
214
  When you need more finely grained control over it, you can set it yourself:
211
215
 
212
- gem.executables = ['foo'] # note, it's the file name relative to `bin/`, not the project root
216
+ `gem.executables = ['foo'] # note, it's the file name relative to bin/, not the project root`
213
217
 
214
218
  ### Versioning
215
219
 
216
- WeJuwelierJuwelier discussed earlier how to bump the version. The rake tasks are really just convience methods for manipulating the `VERSION` file. It just contains a version string, like `1.2.3`.
220
+ We discussed earlier how to bump the version. The rake tasks are really just convience methods for manipulating the `VERSION` file. It just contains a version string, like `1.2.3`.
217
221
 
218
222
  `VERSION` is a convention used by , and is used to populate `gem.version`. You can actually set this yourself, and won't try to override it:
219
223
 
220
- gem.version = '1.2.3'
224
+ `gem.version = '1.2.3'`
221
225
 
222
226
  A common pattern is to have this in a version constant in your library. This is convenient, because users of the library can query the version they are using at runtime.
223
227
 
224
- # in lib/foo/version.rb
225
- class Foo
226
- module Version
227
- MAJOR = 1
228
- MINOR = 2
229
- PATCH = 3
230
- BUILD = 'pre3'
231
-
232
- STRING = [MAJOR, MINOR, PATCH, BUILD].compact.join('.')
233
- end
234
- end
235
-
236
- # in Rakefile
237
- Juwelier require 'juwelier'
238
- require './lib/foo/version.rb'
239
- ::Tasks.new do |gem|
240
- # snip
241
- gem.version = Foo::Version::STRING
242
- end
243
-
244
- ##Juwelier# Rake tasks
245
-
246
- lives inside of Rake. As a result, they are dear friends. But, that friendship doesn't interfere with typical Rake operations.
247
-
248
- The Juwelier Rake means you can define your own namespaces, tasks, or use third party Rake libraries without cause for concern.
249
-
250
- ## Contributing to
228
+ ```ruby
229
+ # in lib/foo/version.rb
230
+ class Foo
231
+ module Version
232
+ MAJOR = 1
233
+ MINOR = 2
234
+ PATCH = 3
235
+ BUILD = 'pre3'
236
+
237
+ STRING = [MAJOR, MINOR, PATCH, BUILD].compact.join('.')
238
+ end
239
+ end
240
+ ```
241
+
242
+ ```ruby
243
+ # in Rakefile
244
+ require 'juwelier'
245
+ require './lib/foo/version.rb'
246
+ Juwelier::Tasks.new do |gem|
247
+ # snip
248
+ gem.version = Foo::Version::STRING
249
+ end
250
+ ```
251
+
252
+ ### Rake tasks
253
+
254
+ Juwelier tasks lives inside of Rake. As a result, they are dear friends. But, that friendship doesn't interfere with typical Rake operations.
255
+
256
+ This means you can define your own namespaces, tasks, or use third party Rake libraries without cause for concern.
257
+
258
+ ## Contributing to
251
259
 
252
260
  * Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet
253
261
  * Ask on the [mailing list](http://groups.google.com/group/juwelier-rb) for feedback on your proposal, to see if somebody else has done it.
data/README.org CHANGED
@@ -369,15 +369,17 @@ use third party Rake libraries without cause for concern.
369
369
  ** Release Notes
370
370
  | Version | Date | Notes |
371
371
  |---------+------------+-------------------------------------------------------------------------------------------------------------|
372
+ | 2.3.5 | 2017-02-10 | Revving Semver to be Semver2 |
372
373
  | 2.2.3 | 2016-11-21 | Psych bug fixed |
373
374
  | 2.2.2 | 2016-11-19 | Added support for pry -- includes pry, pry-byebug, pry-doc, pry-remote, pry-rescue. and pry-stack_explorer. |
374
375
  | 2.2.0 | 2016-11-19 | Bugs with --semver fixed, new options for using .org and .markdown for README |
375
376
  | 2.1.3 | 2016-11-19 | Problems with --semver, --required-version |
376
377
 
377
378
  ** Known Issues
378
- | Date | Issue |
379
- |------------+------------------------------------------------------------------------------------------------|
380
- | 2016-11-19 | On generation of the Markdown, the initial title does not linefeed before the header sequence. |
379
+ | Date | Issue |
380
+ |------------+----------------------------------------------------------------------------------------------------------|
381
+ | 2017-02-10 | Orgmode and Markdown sync issue. They are out of sync for various reasons, and this must be ameorilated. |
382
+ | 2016-11-19 | On generation of the Markdown, the initial title does not linefeed before the header sequence. |
381
383
 
382
384
  ** Contributing to
383
385
 
@@ -21,7 +21,7 @@ Given /^I use the juwelier command to generate the "([^"]+)" project in the work
21
21
  end
22
22
 
23
23
  Given /^"([^"]+)" does not exist$/ do |file|
24
- assert ! File.exists?(File.join(@working_dir, file))
24
+ assert ! File.exist?(File.join(@working_dir, file))
25
25
  end
26
26
 
27
27
  When /^I run "([^"]+)" in "([^"]+)"$/ do |command, directory|
@@ -110,7 +110,7 @@ end
110
110
  Then /^a directory named '(.*)' is created$/ do |directory|
111
111
  directory = File.join(@working_dir, directory)
112
112
 
113
- assert File.exists?(directory), "#{directory} did not exist"
113
+ assert File.exist?(directory), "#{directory} did not exist"
114
114
  assert File.directory?(directory), "#{directory} is not a directory"
115
115
  end
116
116
 
@@ -124,14 +124,14 @@ end
124
124
  Then /^a file named '(.*)' is created$/ do |file|
125
125
  file = File.join(@working_dir, file)
126
126
 
127
- assert File.exists?(file), "#{file} expected to exist, but did not"
127
+ assert File.exist?(file), "#{file} expected to exist, but did not"
128
128
  assert File.file?(file), "#{file} expected to be a file, but is not"
129
129
  end
130
130
 
131
131
  Then /^a file named '(.*)' is not created$/ do |file|
132
132
  file = File.join(@working_dir, file)
133
133
 
134
- assert ! File.exists?(file), "#{file} expected to not exist, but did"
134
+ assert ! File.exist?(file), "#{file} expected to not exist, but did"
135
135
  end
136
136
 
137
137
  Then /^a sane '.gitignore' is created$/ do
data/juwelier.gemspec CHANGED
@@ -2,16 +2,16 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Juwelier::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: juwelier 2.3.4 ruby lib
5
+ # stub: juwelier 2.3.6 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "juwelier".freeze
9
- s.version = "2.3.4"
9
+ s.version = "2.3.6"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0".freeze) if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib".freeze]
13
13
  s.authors = ["Fred Mitchell".freeze, "Josh Nichols".freeze, "Yusuke Murata".freeze]
14
- s.date = "2016-12-27"
14
+ s.date = "2017-04-24"
15
15
  s.description = "Simple and opinionated helper for creating Rubygem projects on GitHub".freeze
16
16
  s.email = ["fred.mitchell@gmx.de".freeze, "fred.mitchell@gmx.com".freeze, "info@muratayusuke.com".freeze]
17
17
  s.executables = ["juwelier".freeze]
@@ -194,7 +194,7 @@ Gem::Specification.new do |s|
194
194
  s.homepage = "http://github.com/flajann2/juwelier".freeze
195
195
  s.licenses = ["MIT".freeze]
196
196
  s.required_ruby_version = Gem::Requirement.new(">= 2.2.2".freeze)
197
- s.rubygems_version = "2.6.8".freeze
197
+ s.rubygems_version = "2.6.11".freeze
198
198
  s.summary = "Powerful and Opinionated tool for creating and managing RubyGem projects".freeze
199
199
 
200
200
  if s.respond_to? :specification_version then
data/lib/juwelier.rb CHANGED
@@ -159,7 +159,7 @@ class Juwelier
159
159
  base_dir = File.expand_path(self.base_dir || ".")
160
160
  end
161
161
  return nil if base_dir==File.dirname("/")
162
- return base_dir if File.exists?(File.join(base_dir, '.git'))
162
+ return base_dir if File.exist?(File.join(base_dir, '.git'))
163
163
  return git_base_dir(base_dir)
164
164
  end
165
165
 
@@ -168,7 +168,7 @@ class Juwelier
168
168
  end
169
169
 
170
170
  def version_file_exists?
171
- File.exists?(@version_helper.plaintext_path) || File.exists?(@version_helper.yaml_path)
171
+ File.exist?(@version_helper.plaintext_path) || File.exist?(@version_helper.yaml_path)
172
172
  end
173
173
 
174
174
  def expects_version_file?
@@ -126,7 +126,7 @@ class Juwelier
126
126
  ["pry-rescue", "~> 1"] <<
127
127
  ["pry-stack_explorer", "~> 0"] if should_use_pry
128
128
 
129
- production_dependencies << ["semver", "~> 1.0.1"] if should_use_semver
129
+ production_dependencies << ["semver2", "~> 3"] if should_use_semver
130
130
 
131
131
  self.user_name = options[:user_name]
132
132
  self.user_email = options[:user_email]
@@ -201,7 +201,7 @@ class Juwelier
201
201
  private
202
202
 
203
203
  def create_files
204
- unless File.exists?(target_dir) || File.directory?(target_dir)
204
+ unless File.exist?(target_dir) || File.directory?(target_dir)
205
205
  FileUtils.mkdir target_dir
206
206
  else
207
207
  raise FileInTheWay, "The directory #{target_dir} already exists, aborting. Maybe move it out of the way before continuing?"
@@ -39,7 +39,7 @@ class Juwelier
39
39
  end
40
40
 
41
41
  def read_yaml
42
- if File.exists?(yaml_path)
42
+ if File.exist?(yaml_path)
43
43
  YAML.load_file(yaml_path)
44
44
  else
45
45
  raise VersionYmlError, "#{yaml_path} does not exist!"
@@ -86,12 +86,12 @@ class Juwelier
86
86
  def initialize(base_dir)
87
87
  self.base_dir = base_dir
88
88
 
89
- if File.exists?(yaml_path)
89
+ if File.exist?(yaml_path)
90
90
  extend YamlExtension
91
91
  parse_yaml
92
92
  else
93
93
  extend PlaintextExtension
94
- if File.exists?(plaintext_path)
94
+ if File.exist?(plaintext_path)
95
95
  parse_plaintext
96
96
  end
97
97
  end
@@ -102,7 +102,7 @@ class Juwelier
102
102
  end
103
103
 
104
104
  should 'raise error' do
105
- assert_raises RuntimeError, /try commiting/i do
105
+ assert_raises RuntimeError do
106
106
  @command.run
107
107
  end
108
108
  end
@@ -264,7 +264,7 @@ class Juwelier
264
264
  deleted { options[:deleted] }
265
265
  changed { options[:changed] }
266
266
  end
267
-
267
+
268
268
  end
269
269
  end
270
270
  end
@@ -120,7 +120,7 @@ class Juwelier
120
120
  end
121
121
 
122
122
  should 'raise error' do
123
- assert_raises RuntimeError, /try commiting/i do
123
+ assert_raises RuntimeError do
124
124
  @command.run
125
125
  end
126
126
  end
@@ -470,7 +470,7 @@ class Juwelier
470
470
  deleted { options[:deleted] }
471
471
  changed { options[:changed] }
472
472
  end
473
-
473
+
474
474
  end
475
475
  end
476
476
  end
@@ -30,7 +30,7 @@ class TestGemspecHelper < Test::Unit::TestCase
30
30
  end
31
31
 
32
32
  should "create gemspec file" do
33
- assert File.exists?(@helper.path)
33
+ assert File.exist?(@helper.path)
34
34
  end
35
35
 
36
36
  should "make valid spec" do
@@ -165,10 +165,10 @@ class TestVersionHelper < Test::Unit::TestCase
165
165
 
166
166
  should_have_version 0, 0, 1
167
167
  should "not create VERSION.yml" do
168
- assert ! File.exists?(File.join(VERSION_TMP_DIR, 'VERSION.yml'))
168
+ assert ! File.exist?(File.join(VERSION_TMP_DIR, 'VERSION.yml'))
169
169
  end
170
170
  should "not create VERSION" do
171
- assert ! File.exists?(File.join(VERSION_TMP_DIR, 'VERSION'))
171
+ assert ! File.exist?(File.join(VERSION_TMP_DIR, 'VERSION'))
172
172
  end
173
173
 
174
174
  context "outputting" do
@@ -177,7 +177,7 @@ class TestVersionHelper < Test::Unit::TestCase
177
177
  end
178
178
 
179
179
  should "create VERSION" do
180
- assert File.exists?(File.join(VERSION_TMP_DIR, 'VERSION'))
180
+ assert File.exist?(File.join(VERSION_TMP_DIR, 'VERSION'))
181
181
  end
182
182
 
183
183
  context "re-reading VERSION" do
data/test/test_helper.rb CHANGED
@@ -1,4 +1,6 @@
1
1
  require 'test/unit'
2
+ require 'rr'
3
+ require 'test/unit/rr'
2
4
  require 'rubygems'
3
5
 
4
6
  require 'bundler'
@@ -15,7 +17,6 @@ end
15
17
 
16
18
  require 'rake'
17
19
  require 'shoulda'
18
- require 'rr'
19
20
  #require 'redgreen'
20
21
  require 'construct'
21
22
  require 'git'
@@ -38,7 +39,6 @@ class RubyForgeStub
38
39
  end
39
40
 
40
41
  class Test::Unit::TestCase
41
- include RR::Adapters::TestUnit unless include?(RR::Adapters::TestUnit)
42
42
  include Construct::Helpers
43
43
 
44
44
  def tmp_dir
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: juwelier
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.4
4
+ version: 2.3.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fred Mitchell
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2016-12-27 00:00:00.000000000 Z
13
+ date: 2017-04-24 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: rake
@@ -410,7 +410,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
410
410
  version: '0'
411
411
  requirements: []
412
412
  rubyforge_project:
413
- rubygems_version: 2.6.8
413
+ rubygems_version: 2.6.11
414
414
  signing_key:
415
415
  specification_version: 4
416
416
  summary: Powerful and Opinionated tool for creating and managing RubyGem projects