trollop 2.1.0 → 2.1.1

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: be70256e210067fa6547103ba32b51a4242a6382
4
- data.tar.gz: 958ed3d139b74b319cf793208d7482c634663fbc
3
+ metadata.gz: 7652739adf1d95b0325d061a1f6c3601ea9c2ad2
4
+ data.tar.gz: d85880211b235bcbc661981dba6b1f3cd1843cbb
5
5
  SHA512:
6
- metadata.gz: 36ba799aa516cf9160cfce8809c45939bdfef580dac0f30f8c8bac85f6e1e1a13bd0f786eb7b8da79006a4f4677bd2e8bb036262a917db9ab5714c2910f5789c
7
- data.tar.gz: 6ffcdcf7434e5182eb8aca04cf1fbcdfd63d65e5af5a9b360e80a72c7a18ff39f45a7afe4fa429796ba6d1f297d28b1abbc32caf360f8a7a73643c06b7d84fb5
6
+ metadata.gz: ffc0188f1cf4e0c6295d6bd24f280ae9a09b74860e9b99023217613a156c52634a192a2522bdade449439832cc2d3d98613899b45da61e633a0fd056970cf7ea
7
+ data.tar.gz: e16e4a250eb2e29c3d905945cd3b2121ee71aaa3289b01ad5f3971512e729095ea745740ce29a59ef390ca0473b99d9f80ddd363b95c98aa1efcbd641a0475a1
@@ -3,3 +3,6 @@ rvm:
3
3
  - "1.9.3"
4
4
  - "2.0"
5
5
  - "2.1"
6
+ - jruby-18mode # JRuby in 1.8 mode
7
+ - jruby-19mode # JRuby in 1.9 mode
8
+ - rbx-2
@@ -1,4 +1,8 @@
1
- == 2.1.0 / 2014-12-23
1
+ == 2.1.1 / 2015-01-03
2
+ * Remove curses as a hard dependency. It is optional. This can leverage the gem if it is present.
3
+ * Fix ruby -w warnings
4
+
5
+ == 2.1.0 / 2015-01-02
2
6
  * Integer parser now supports underscore separator.
3
7
  * Add Parser#usage and Parser#synopsis commands for creating a standard banner
4
8
  message. Using Parser#banner directly will override both of those.
@@ -6,7 +6,7 @@
6
6
  require 'date'
7
7
 
8
8
  module Trollop
9
- VERSION = "2.1.0"
9
+ VERSION = "2.1.1"
10
10
 
11
11
  ## Thrown by Parser in the event of a commandline error. Not needed if
12
12
  ## you're using the Trollop::options entry.
@@ -235,21 +235,16 @@ class Parser
235
235
  ## Sets the version string. If set, the user can request the version
236
236
  ## on the commandline. Should probably be of the form "<program name>
237
237
  ## <version number>".
238
- def version s=nil; @version = s if s; @version end
238
+ def version(s = nil); @version = s if s; @version end
239
239
 
240
240
  ## Sets the usage string. If set the message will be printed as the
241
241
  ## first line in the help (educate) output and ending in two new
242
242
  ## lines.
243
- def usage s=nil; @usage = s if s; @usage end
244
-
245
- ## Sets the usage string. If set the message will be printed as the
246
- ## first line in the help (educate) output and ending in two new
247
- ## lines.
248
- def usage s=nil; @usage = s if s; @usage end
243
+ def usage(s = nil) ; @usage = s if s; @usage end
249
244
 
250
245
  ## Adds a synopsis (command summary description) right below the
251
246
  ## usage line, or as the first line if usage isn't specified.
252
- def synopsis s=nil; @synopsis = s if s; @synopsis end
247
+ def synopsis(s = nil) ; @synopsis = s if s; @synopsis end
253
248
 
254
249
  ## Adds text to the help display. Can be interspersed with calls to
255
250
  ## #opt to build a multi-section help page.
@@ -477,7 +472,7 @@ class Parser
477
472
  rightcol_start = leftcol_width + 6 # spaces
478
473
 
479
474
  unless @order.size > 0 && @order.first.first == :text
480
- command_name = File.basename($0).gsub /\.[^.]+$/, ''
475
+ command_name = File.basename($0).gsub(/\.[^.]+$/, '')
481
476
  stream.puts "Usage: #{command_name} #@usage\n" if @usage
482
477
  stream.puts "#@synopsis\n" if @synopsis
483
478
  stream.puts if @usage or @synopsis
@@ -21,7 +21,6 @@ specify."
21
21
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
22
22
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
23
23
 
24
- spec.add_runtime_dependency 'curses'
25
24
  spec.require_paths = ["lib"]
26
25
 
27
26
  spec.add_development_dependency "minitest", "~> 4.7.3"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: trollop
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - William Morgan
@@ -9,22 +9,8 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-01-02 00:00:00.000000000 Z
12
+ date: 2015-01-05 00:00:00.000000000 Z
13
13
  dependencies:
14
- - !ruby/object:Gem::Dependency
15
- name: curses
16
- requirement: !ruby/object:Gem::Requirement
17
- requirements:
18
- - - ">="
19
- - !ruby/object:Gem::Version
20
- version: '0'
21
- type: :runtime
22
- prerelease: false
23
- version_requirements: !ruby/object:Gem::Requirement
24
- requirements:
25
- - - ">="
26
- - !ruby/object:Gem::Version
27
- version: '0'
28
14
  - !ruby/object:Gem::Dependency
29
15
  name: minitest
30
16
  requirement: !ruby/object:Gem::Requirement