codebreakergem 0.1.11 → 0.1.12

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
  SHA256:
3
- metadata.gz: cf7e699f9296e4da94d81363c398f171622ac1cb364411d32aefade8468aa314
4
- data.tar.gz: 9e1be7a615d9a5ceb111a5c03cc0747d31a529a8e32a3c2f2f5defca0557121a
3
+ metadata.gz: db252ffc7ce598601b77335ada268b415a4f16fd6d0c59b83e85d10f7fe0384f
4
+ data.tar.gz: 91d67d1725dfa77bbf88883a18a9d87ca0a1b665bf08992ea555012b36534bdc
5
5
  SHA512:
6
- metadata.gz: df92eaafb7bfa8edc3068327eab0802d72992f7908109178d141aab6ae04cd16bcf20a96d727d58e13a02072e7e5a5c99f682379ede6413238a1c4adc9e74826
7
- data.tar.gz: ef453b7fe0f9463c7227494401c7d86567fbd5c2eab2e137548465938b50fd7c901681814dd4fc1534c4abedf6670a06f95c7dbadd9054bdf66907bdb4ae0468
6
+ metadata.gz: 1cbdbfd46830d0e5f24371d4f7de74bf856f81fba8d2b7f9327b2ca2cedddcc3f7bfee95c677f8ed0429546f40db7bb33a551b5e51beee14e3430ec54197663a
7
+ data.tar.gz: 116363dacb70978f86d9101200f134c0daa9fdb6243b508c2b00443ac5a00586000ae348e4e5274d5731611c378b8e03ad31bfb406eae85227849ff239580ea5
@@ -0,0 +1,13 @@
1
+ version: 2.0
2
+ jobs:
3
+ build:
4
+ branches:
5
+ only:
6
+ - codebreakergemrepo
7
+ docker:
8
+ - image: circleci/ruby:2.6.5
9
+ steps:
10
+ - checkout
11
+ - run: bundle install
12
+ - run: rubocop
13
+ - run: fasterer
@@ -20,12 +20,10 @@ module Codebreakergem
20
20
  end
21
21
 
22
22
  def show_hint
23
- if difficulty.hints.positive?
24
- difficulty.hints -= 1
25
- secret_code[difficulty.hints]
26
- else
27
- I18n.t(:no_hints)
28
- end
23
+ return I18n.t(:no_hints) unless difficulty.hints.positive?
24
+
25
+ difficulty.hints -= 1
26
+ secret_code[difficulty.hints]
29
27
  end
30
28
 
31
29
  def try_guess(guess)
@@ -2,7 +2,7 @@
2
2
 
3
3
  module Codebreakergem
4
4
  class Statistic
5
- attr_accessor :name, :difficulty, :attempts_total,
5
+ attr_reader :name, :difficulty, :attempts_total,
6
6
  :attempts_used, :hints_total, :hints_used
7
7
 
8
8
  def initialize(name:, difficulty:, attempts_total:, hints_total:)
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Codebreakergem
4
- VERSION = '0.1.11'
4
+ VERSION = '0.1.12'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: codebreakergem
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.11
4
+ version: 0.1.12
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sasha
@@ -59,6 +59,7 @@ executables: []
59
59
  extensions: []
60
60
  extra_rdoc_files: []
61
61
  files:
62
+ - ".circleci/config.yml"
62
63
  - ".fasterer.yml"
63
64
  - ".gitignore"
64
65
  - ".rspec"