gramrb 1.0.6 → 1.0.7

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
  SHA256:
3
- metadata.gz: 6cf8e4a48fdc5f714a69178bd7b66fab76dc40804e16a55fc619de6034878dd6
4
- data.tar.gz: b64231f40b0377ffddd24f45ec41dc584ae7bca9b2ddc929ed2a6a0a31cd4c4b
3
+ metadata.gz: b9e8638c359baf472d9d3800198d3654fc60b67677066a7c31e5209aa56e7704
4
+ data.tar.gz: 904d64bbe0cd3f52ef37b4b8526b3c1b94133f5985636d2070dd26627f27aa91
5
5
  SHA512:
6
- metadata.gz: abdec6bc264c80dd6f2aad08f3c97f493ba66e50c48d39b41bc096e7449a88f93950982375beb3b825937311875e846e2a95161a9eb99524e6eb1a865697c7f7
7
- data.tar.gz: 44f41c44272e67611517ca53fa88c1807eeffcb80cbb533de8f5ab58bbdb2e57027f2a4018cbb531db7b6f74922add894c250839346b4e3fb565a1d6e5ed4c65
6
+ metadata.gz: 668bb6fa2ab7c58296b7ad1d574ad1563f66b5138d497f4d3eee5f8125f84831a553754913614447f2c7495616efc203b8ac89a8681517d7b5bfbab079ec0834
7
+ data.tar.gz: 9210094c21071867ce799eb72edbed9cd277dd91e0083a45574ce572fc3d2cd23913cabd683f8b78ea0aef0eddaa7d78f3aa2b5e1819b235b2b46a9380b44786
data/lib/gramrb/cli.rb CHANGED
@@ -54,7 +54,11 @@ module Gramrb
54
54
  def highlight(error) = error[:item].gsub(error[:error], red(error[:error]))
55
55
 
56
56
  def files
57
- @files ||= File.file?(@path) ? [@path] : Dir.glob("#{@path}/**/*.rb").reject { |file| config.excluded.any? { |excluded| file.include?(excluded) } }
57
+ @files ||= if File.file?(@path)
58
+ [@path]
59
+ else
60
+ Dir.glob("#{@path}/**/*.rb").reject { |file| config.excluded.any? { |excluded| file.include?(excluded) } }
61
+ end
58
62
  end
59
63
 
60
64
  def config = @config ||= Config.new
@@ -30,6 +30,6 @@ module Gramrb
30
30
 
31
31
  def invalid?(item) = item.nil? || item.empty?
32
32
 
33
- def word?(word) = word.length > 1
33
+ def word?(word) = word.length > 1 && word.ascii_only?
34
34
  end
35
35
  end
@@ -1,5 +1,5 @@
1
1
  module Gramrb
2
2
  module Version
3
- VERSION = '1.0.6'.freeze
3
+ VERSION = '1.0.7'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gramrb
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.0.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pandaman74