ultra_command_line 0.4.10 → 0.4.12
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/ultra_command_line/commands/help_formatter.rb +1 -1
- data/lib/ultra_command_line/commands/option_definition.rb +1 -1
- data/lib/ultra_command_line/commands/sub_command.rb +6 -1
- data/lib/ultra_command_line/version.rb +1 -1
- data/ultra_command_line.gemspec +1 -1
- metadata +6 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c7e8145f57a5104d0baa5b6e4af2808edb459c50
|
4
|
+
data.tar.gz: 39483fbff2577e4b4eab571088b4e6b6df4c7b89
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ba6516fface565ddc5d8881ed39da52528cc625d4c57f73139afd5ad95f2180012296f066ca5ebfb7cced90252242a5e01bccbdd007334d030f89a667a9248e2
|
7
|
+
data.tar.gz: a44a8fb669154fbc09da763c5e986375441332c5a76cd270533ef814016d0de7966bf68ddefaab1283b904aa54def98c58e8a52b9544c8392cb4d10db981fa97
|
@@ -6,7 +6,7 @@ module UltraCommandLine
|
|
6
6
|
DEFAULT_SUMMARY = 'Option summary not provided.'.freeze
|
7
7
|
attr_reader :name, :type
|
8
8
|
attr_reader :short_aliases, :long_aliases
|
9
|
-
attr_accessor :summary, :default, :description, :help, :dependencies, :incompatibilities
|
9
|
+
attr_accessor :summary, :default, :description, :help, :dependencies, :incompatibilities, :sub_command
|
10
10
|
|
11
11
|
def initialize(name, type, options = {})
|
12
12
|
@name = name
|
@@ -33,7 +33,7 @@ module UltraCommandLine
|
|
33
33
|
class << self; include UltraCommandLine::Commands::MainCommand; end
|
34
34
|
end
|
35
35
|
self.banner = banner
|
36
|
-
|
36
|
+
register_options(options)
|
37
37
|
@aliases = [self.name]
|
38
38
|
@type = type
|
39
39
|
end
|
@@ -50,6 +50,11 @@ module UltraCommandLine
|
|
50
50
|
|
51
51
|
attr_writer :manager
|
52
52
|
|
53
|
+
def register_options(options)
|
54
|
+
options.each { |option| option.sub_command = self }
|
55
|
+
@options = options
|
56
|
+
end
|
57
|
+
|
53
58
|
def self_view_of_manager_cmd_line_args
|
54
59
|
manager.cmd_line_args_for_command self
|
55
60
|
end
|
data/ultra_command_line.gemspec
CHANGED
@@ -20,7 +20,7 @@ Gem::Specification.new do |spec|
|
|
20
20
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
21
21
|
spec.require_paths = ['lib']
|
22
22
|
|
23
|
-
spec.add_development_dependency 'bundler'
|
23
|
+
spec.add_development_dependency 'bundler'
|
24
24
|
spec.add_development_dependency 'rake', '~> 10.0'
|
25
25
|
spec.add_development_dependency 'rspec', '~> 3.0'
|
26
26
|
spec.add_development_dependency 'simplecov'
|
metadata
CHANGED
@@ -1,29 +1,29 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ultra_command_line
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.12
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Laurent B.
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-11-
|
11
|
+
date: 2019-11-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- - "
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '0'
|
20
20
|
type: :development
|
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: '
|
26
|
+
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rake
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|