xiaodao_mega_lotto 0.2.0 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 20548d192952412eee588c5152efde9faea24d07
4
- data.tar.gz: 9e9d1b87fbd9f82738e90b12971cbfaa7753ac01
3
+ metadata.gz: 5ae03b7ec80f3159b6937eb678ef61b2ff357f46
4
+ data.tar.gz: ce69d068e8df8fa6a9b868966423005069570b86
5
5
  SHA512:
6
- metadata.gz: 79745a959d1e0fb50d321bd039a749d9adc9222c85a0b61c7196aec2870adc248eb846a36cb494b909d6da017eeb11b82b7e12b1e1579eb28822c58204873f44
7
- data.tar.gz: 3bde553cf7808693db9969480111aa4cb90212243f52efa82f71aa7cf222aba4d8979850b88f464b1c6e59b3c281b35a3e873c376c0ea5afc4c84939956e13fb
6
+ metadata.gz: 74fe4a39f31c55e06a162609408ab3857caed2cabe73e6ae148b2f6cb7fef1516bdf444c5eef3803b8aef2028ef4a184de9316b951e64441f26952b7a2b3fe8b
7
+ data.tar.gz: 6ea5a0c8f533c9c1937679b084c9ce800151483833e4315a50cbf0ff8beeb16d2fd75049dee4ca52fce6408eddde1c6d66ee1407fc53338b0471133a5545164d
@@ -1,13 +1,15 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- xiaodao_mega_lotto (0.2.0)
4
+ xiaodao_mega_lotto (1.0.0)
5
+ gli (~> 2.12.2)
5
6
 
6
7
  GEM
7
8
  remote: https://rubygems.org/
8
9
  specs:
9
10
  coderay (1.1.2)
10
11
  diff-lcs (1.3)
12
+ gli (2.12.3)
11
13
  method_source (0.9.0)
12
14
  pry (0.11.3)
13
15
  coderay (~> 1.1.0)
@@ -0,0 +1,37 @@
1
+ #!/usr/bin/env ruby
2
+ require 'gli'
3
+ require 'xiaodao_mega_lotto'
4
+
5
+ include GLI::App
6
+
7
+ program_desc 'xiaodao_mega_lotto cli'
8
+ version XiaodaoMegaLotto::VERSION
9
+
10
+ desc '打印一组随机数'
11
+ command :mega do |c|
12
+ c.desc '打印随机数'
13
+ c.command :lottos do |lottos|
14
+ lottos.desc '7个随机数'
15
+ lottos.flag [:lotto, 'of-board', 'of'], requred: true
16
+ lottos.action do |global, opt, args|
17
+ puts XiaodaoMegaLotto::Drawing.new.draw
18
+ end
19
+ end
20
+ end
21
+
22
+
23
+ on_error do |err|
24
+ if debugging?
25
+ $stderr.puts err.message
26
+ $stderr.puts err.backtrace.join( "\n" )
27
+ else
28
+ next if GLI::CustomExit === err
29
+ $stderr.puts err.message
30
+ end
31
+ end
32
+
33
+ def debugging?
34
+ defined? Bundler
35
+ end
36
+
37
+ exit run(ARGV)
@@ -1,3 +1,3 @@
1
1
  module XiaodaoMegaLotto
2
- VERSION = "0.2.0"
2
+ VERSION = "1.0.0"
3
3
  end
@@ -9,8 +9,8 @@ Gem::Specification.new do |spec|
9
9
  spec.authors = ["liupc-ubuntu"]
10
10
  spec.email = ["liu_xiaodao@163.com"]
11
11
 
12
- spec.summary = "dao ge de di yi ge gem"
13
- spec.description = "dao ge shou xiu"
12
+ spec.summary = "Practice work"
13
+ spec.description = "Please do not use"
14
14
  spec.homepage = "http://robot.liuxiaodap.top"
15
15
  spec.license = "MIT"
16
16
 
@@ -26,12 +26,14 @@ Gem::Specification.new do |spec|
26
26
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
27
27
  f.match(%r{^(test|spec|features)/})
28
28
  end
29
- spec.bindir = "exe"
30
- spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
29
+ spec.bindir = "bin"
30
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
31
31
  spec.require_paths = ["lib"]
32
32
 
33
33
  spec.add_development_dependency "bundler", "~> 1.16"
34
34
  spec.add_development_dependency "rake", "~> 10.0"
35
35
  spec.add_development_dependency "rspec"
36
36
  spec.add_development_dependency "pry"
37
+ # for git-like commonad-line
38
+ spec.add_dependency "gli", "~> 2.12.2"
37
39
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: xiaodao_mega_lotto
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - liupc-ubuntu
8
8
  autorequire:
9
- bindir: exe
9
+ bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-11 00:00:00.000000000 Z
11
+ date: 2019-06-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -66,10 +66,28 @@ dependencies:
66
66
  - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
- description: dao ge shou xiu
69
+ - !ruby/object:Gem::Dependency
70
+ name: gli
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: 2.12.2
76
+ type: :runtime
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: 2.12.2
83
+ description: Please do not use
70
84
  email:
71
85
  - liu_xiaodao@163.com
72
- executables: []
86
+ executables:
87
+ - console
88
+ - setup
89
+ - xiaodao
90
+ - xiaodao_mega_lotto
73
91
  extensions: []
74
92
  extra_rdoc_files: []
75
93
  files:
@@ -83,6 +101,7 @@ files:
83
101
  - Rakefile
84
102
  - bin/console
85
103
  - bin/setup
104
+ - bin/xiaodao
86
105
  - bin/xiaodao_mega_lotto
87
106
  - lib/xiaodao_mega_lotto.rb
88
107
  - lib/xiaodao_mega_lotto/configuration.rb
@@ -113,5 +132,5 @@ rubyforge_project:
113
132
  rubygems_version: 2.5.1
114
133
  signing_key:
115
134
  specification_version: 4
116
- summary: dao ge de di yi ge gem
135
+ summary: Practice work
117
136
  test_files: []