codeguessing 0.4.9 → 0.5

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: d0c64209b4b33c70a1ce3506d0f8408d158333bb
4
- data.tar.gz: 292948ab10bfcccfd1f964d4aff5b67702627d39
3
+ metadata.gz: 574f75947893255bd54c4b561c1e57e7d1edcba9
4
+ data.tar.gz: e3b9547acc9888807dbc7871cf059275f9f71e79
5
5
  SHA512:
6
- metadata.gz: c9c3caf37cfddb5fa1b3dd31657336599abcf55173c07a6cdb8de9f92ad1e6644a9c775d30290b1aa46b919f1f007f8ae3933edf242876500407015e8bed9782
7
- data.tar.gz: 69316cfe59d90eed5c67d924ec5d07d052ca869ee41c2141d497814bfc1bd53fdf917d386b4faba8753bbc5b86b40ef6d4bd9f3f862c6b3ecd4c64fc86fefb67
6
+ metadata.gz: ce22c3389cb27a5944303264989720bb58a229d5c5823c6d9fd95ebdb2151feb8810980c089c26be737a0482ca4cb7c14ee5c02939de23bfd92ae3986d0109f0
7
+ data.tar.gz: 4bd4d1b3aeb965f10803273047a092a74f02ce7d4157551ee90f80c7d3d8831df45a3c9e1111fef8c1c5970b7b8411adb1e696afa05f4641c3d1e0ba5971fd47
@@ -2,11 +2,11 @@ module Codeguessing
2
2
  class Console
3
3
  attr_reader :game, :scores
4
4
 
5
- MESSAGE = YAML.load_file(File.expand_path('data/messages.yml'))
5
+ MESSAGE = YAML.load_file(File.join(File.dirname(__FILE__), 'data/messages.yml'))
6
6
 
7
7
  def initialize
8
- @path = File.expand_path('data/scores.yml')
9
- @scores = load(@path)
8
+ @path = File.join(File.dirname(__FILE__), 'data/scores.yml')
9
+ @scores = load(@path) || []
10
10
  @game = Game.new
11
11
  end
12
12
 
File without changes
File without changes
@@ -1,3 +1,3 @@
1
1
  module Codeguessing
2
- VERSION = "0.4.9"
2
+ VERSION = "0.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: codeguessing
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.9
4
+ version: '0.5'
5
5
  platform: ruby
6
6
  authors:
7
7
  - bezrukavyi
@@ -81,10 +81,10 @@ files:
81
81
  - bin/console
82
82
  - bin/setup
83
83
  - codeguessing.gemspec
84
- - data/messages.yml
85
- - data/scores.yml
86
84
  - lib/codeguessing.rb
87
85
  - lib/codeguessing/console.rb
86
+ - lib/codeguessing/data/messages.yml
87
+ - lib/codeguessing/data/scores.yml
88
88
  - lib/codeguessing/game.rb
89
89
  - lib/codeguessing/version.rb
90
90
  homepage: https://github.com/bezrukavyi/codeguessing
data/data/scores.yml DELETED
@@ -1,132 +0,0 @@
1
- ---
2
- - :secret_code: '4336'
3
- :attempts: 3
4
- :hint_count: 2
5
- :state: win
6
- :answer: "++++"
7
- :name: YaroslavBIG
8
- :date: 1478811836
9
- - :secret_code: '4442'
10
- :attempts: 3
11
- :hint_count: 2
12
- :state: win
13
- :answer: "++++"
14
- :name: '1234124'
15
- :date: 1478981167
16
- - :secret_code: '4331'
17
- :attempts: 3
18
- :hint_count: 2
19
- :state: win
20
- :answer: "++++"
21
- :name: YaroslavBig
22
- :date: 1478983335
23
- - :secret_code: '6543'
24
- :attempts: 0
25
- :hint_count: 0
26
- :state: win
27
- :answer: "++++"
28
- :name: Y
29
- :date: 1480696247
30
- - :secret_code: '2222'
31
- :attempts: 5
32
- :hint_count: 2
33
- :state: win
34
- :answer: ''
35
- - :secret_code: '2222'
36
- :attempts: -1
37
- :hint_count: 0
38
- :state: ''
39
- :answer: ''
40
- :name: Anonim
41
- :date: 1480702360
42
- - :secret_code: '2222'
43
- :attempts: -1
44
- :hint_count: 0
45
- :state: ''
46
- :answer: ''
47
- :name: Anonim
48
- :date: 1480702455
49
- - :secret_code: '3424'
50
- :attempts: 4
51
- :hint_count: 2
52
- :state: win
53
- :answer: "++++"
54
- :name: Yaroslav
55
- :date: 1480703017
56
- - :secret_code: '1244'
57
- :attempts: 2
58
- :hint_count: 2
59
- :state: win
60
- :answer: "++++"
61
- :name: YaroslavYaroslav
62
- :date: 1480703532
63
- - :secret_code: '2222'
64
- :attempts: -1
65
- :hint_count: 0
66
- :state: win
67
- :answer: ''
68
- :name: TestRspec
69
- :date: 1480704981
70
- - :secret_code: '2222'
71
- :attempts: -1
72
- :hint_count: 0
73
- :state: win
74
- :answer: ''
75
- :name: TestRspec
76
- :date: 1480705000
77
- - :secret_code: '2222'
78
- :attempts: -1
79
- :hint_count: 0
80
- :state: win
81
- :answer: ''
82
- :name: TestRspec
83
- :date: 1480705003
84
- - :secret_code: '2222'
85
- :attempts: -1
86
- :hint_count: 0
87
- :state: win
88
- :answer: ''
89
- :name: TestRspec
90
- :date: 1480705034
91
- - :secret_code: '2222'
92
- :attempts: -1
93
- :hint_count: 0
94
- :state: win
95
- :answer: ''
96
- :name: TestRspec
97
- :date: 1480705083
98
- - :secret_code: '2222'
99
- :attempts: -1
100
- :hint_count: 0
101
- :state: win
102
- :answer: ''
103
- :name: TestRspec
104
- :date: 1480705090
105
- - :secret_code: '2222'
106
- :attempts: -1
107
- :hint_count: 0
108
- :state: win
109
- :answer: ''
110
- :name: TestRspec
111
- :date: 1480705102
112
- - :secret_code: '2222'
113
- :attempts: -1
114
- :hint_count: 0
115
- :state: win
116
- :answer: ''
117
- :name: TestRspec
118
- :date: 1480705104
119
- - :secret_code: '2222'
120
- :attempts: -1
121
- :hint_count: 0
122
- :state: win
123
- :answer: ''
124
- :name: TestRspec
125
- :date: 1480705458
126
- - :secret_code: '2222'
127
- :attempts: -1
128
- :hint_count: 0
129
- :state: win
130
- :answer: ''
131
- :name: TestRspec
132
- :date: 1480705500