clin 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.codeclimate.yml +5 -0
- data/.gitignore +15 -0
- data/.rubocop.yml +19 -0
- data/.travis.yml +14 -0
- data/Gemfile +10 -0
- data/LICENSE.txt +22 -0
- data/README.md +98 -0
- data/Rakefile +10 -0
- data/clin.gemspec +27 -0
- data/examples/dispatcher.rb +76 -0
- data/examples/nested_dispatcher.rb +91 -0
- data/examples/optional_argument.rb +24 -0
- data/examples/simple.rb +39 -0
- data/examples/test.rb +2 -0
- data/lib/clin/argument.rb +90 -0
- data/lib/clin/command.rb +195 -0
- data/lib/clin/command_dispatcher.rb +48 -0
- data/lib/clin/command_options_mixin.rb +88 -0
- data/lib/clin/common/help_options.rb +25 -0
- data/lib/clin/errors.rb +31 -0
- data/lib/clin/general_option.rb +15 -0
- data/lib/clin/option.rb +102 -0
- data/lib/clin/version.rb +4 -0
- data/lib/clin.rb +29 -0
- data/spec/cli/argument_spec.rb +117 -0
- data/spec/cli/command_dispacher_spec.rb +84 -0
- data/spec/cli/command_options_mixin_spec.rb +64 -0
- data/spec/cli/command_spec.rb +225 -0
- data/spec/cli/common/help_options_spec.rb +29 -0
- data/spec/cli/option_spec.rb +132 -0
- data/spec/errors_spec.rb +8 -0
- data/spec/examples/simple_spec.rb +31 -0
- data/spec/spec_helper.rb +28 -0
- metadata +171 -0
metadata
ADDED
@@ -0,0 +1,171 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: clin
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.1.0
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Timothee Guerin
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2015-05-27 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: activesupport
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '4.0'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '4.0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: bundler
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '1.7'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '1.7'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rake
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '10.0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '10.0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rspec
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: coveralls
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: faker
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
description: ''
|
98
|
+
email:
|
99
|
+
- timothee.guerin@outlook.com
|
100
|
+
executables: []
|
101
|
+
extensions: []
|
102
|
+
extra_rdoc_files: []
|
103
|
+
files:
|
104
|
+
- ".codeclimate.yml"
|
105
|
+
- ".gitignore"
|
106
|
+
- ".rubocop.yml"
|
107
|
+
- ".travis.yml"
|
108
|
+
- Gemfile
|
109
|
+
- LICENSE.txt
|
110
|
+
- README.md
|
111
|
+
- Rakefile
|
112
|
+
- clin.gemspec
|
113
|
+
- examples/dispatcher.rb
|
114
|
+
- examples/nested_dispatcher.rb
|
115
|
+
- examples/optional_argument.rb
|
116
|
+
- examples/simple.rb
|
117
|
+
- examples/test.rb
|
118
|
+
- lib/clin.rb
|
119
|
+
- lib/clin/argument.rb
|
120
|
+
- lib/clin/command.rb
|
121
|
+
- lib/clin/command_dispatcher.rb
|
122
|
+
- lib/clin/command_options_mixin.rb
|
123
|
+
- lib/clin/common/help_options.rb
|
124
|
+
- lib/clin/errors.rb
|
125
|
+
- lib/clin/general_option.rb
|
126
|
+
- lib/clin/option.rb
|
127
|
+
- lib/clin/version.rb
|
128
|
+
- spec/cli/argument_spec.rb
|
129
|
+
- spec/cli/command_dispacher_spec.rb
|
130
|
+
- spec/cli/command_options_mixin_spec.rb
|
131
|
+
- spec/cli/command_spec.rb
|
132
|
+
- spec/cli/common/help_options_spec.rb
|
133
|
+
- spec/cli/option_spec.rb
|
134
|
+
- spec/errors_spec.rb
|
135
|
+
- spec/examples/simple_spec.rb
|
136
|
+
- spec/spec_helper.rb
|
137
|
+
homepage: ''
|
138
|
+
licenses:
|
139
|
+
- MIT
|
140
|
+
metadata: {}
|
141
|
+
post_install_message:
|
142
|
+
rdoc_options: []
|
143
|
+
require_paths:
|
144
|
+
- lib
|
145
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
146
|
+
requirements:
|
147
|
+
- - ">="
|
148
|
+
- !ruby/object:Gem::Version
|
149
|
+
version: '0'
|
150
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
151
|
+
requirements:
|
152
|
+
- - ">="
|
153
|
+
- !ruby/object:Gem::Version
|
154
|
+
version: '0'
|
155
|
+
requirements: []
|
156
|
+
rubyforge_project:
|
157
|
+
rubygems_version: 2.4.6
|
158
|
+
signing_key:
|
159
|
+
specification_version: 4
|
160
|
+
summary: Clin provide an advance way to define complex command line interface.
|
161
|
+
test_files:
|
162
|
+
- spec/cli/argument_spec.rb
|
163
|
+
- spec/cli/command_dispacher_spec.rb
|
164
|
+
- spec/cli/command_options_mixin_spec.rb
|
165
|
+
- spec/cli/command_spec.rb
|
166
|
+
- spec/cli/common/help_options_spec.rb
|
167
|
+
- spec/cli/option_spec.rb
|
168
|
+
- spec/errors_spec.rb
|
169
|
+
- spec/examples/simple_spec.rb
|
170
|
+
- spec/spec_helper.rb
|
171
|
+
has_rdoc:
|