lumbersexual 0.3.14 → 0.3.15

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MDZkMmFjMTdiZDMwYWU4NmYzMjc3Y2Y5YzQwZWY0YzA0MGJkMDE3ZQ==
4
+ ODc1NDgzZWFiZTg2MDkyM2FlYzc0NGE0OTZmMDdlNTdjOTgyYmU3Ng==
5
5
  data.tar.gz: !binary |-
6
- NGQ0MzliNWYwZTQ1ZmM4MmE5MThkZGFmMjQzZGRhZTU3ZjQwZDk4Yw==
6
+ NjkwZGE5ZjNhM2UwMWQ2MTdhN2RkMDk5MWVhN2RkYWQ5NGRmMmRmNw==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- ODYyYzljZDY4MmQzZDBjNjk0NDBlYjYzMDYwYWI4YmIwODY3ZmU2YTQ0N2Vj
10
- MTM2YWEyNzM3NGViMWVkZDBkNjIzNjczN2IxNDAxNGZlNmIzOTM1MGM4ZTZh
11
- NmFmNjc4OGE5MjJlZmU5NzY1MWMzZWIyNzJhN2QwZDg1ZTgzOWQ=
9
+ OTZjN2I2MjlmYzU3MDI2MDI3YTJiMTY1M2JhZmIxNTRjZTJlMWJhNzQzNmEy
10
+ MDY4MzI0NDdiNTNjOWRjNjkxOTM5NzQ1NDI1NDhhMGIyNjVhNjViMzdjOTQ0
11
+ Mjg4MTc5NmQzMjQyYjNhYTQ1MmQyOTViZWU0YTg0YmRlMDg5NzI=
12
12
  data.tar.gz: !binary |-
13
- MWI4ZTFjOGM4NmI4YzBkNTA0ZDNlNjE4NGQ1MGE5YTQ0ZGNiNzViMmE3ZmEx
14
- OTlmZTA0NzMxODViMjc0OWZmN2MzMGZhZmZmMDdhODM2ZTY4NTViNTc5Njli
15
- NGNjYWUxMTA0ZmU0YjYzMzQxOWYzNjc4ZWI0N2JmOGI0MjBmZGI=
13
+ YzdmNjY0YWJjMWI0OTk5NTlmNjBlODNjYmNjN2I0Yjc3ZmUzMDk5OTVmODZk
14
+ NzY4ZGJiZjdkODExYTY1YTlhNzk4MmFjODdmYjk2OTI0N2U5Y2JiYmMzOWQ4
15
+ NmU5ZWVhZjMzYzZkMmRmNzQxNDNiNjU0NDUzZTY4NzQ1ODA3YWQ=
data/exe/lumbersexual CHANGED
@@ -2,9 +2,16 @@
2
2
 
3
3
  require "lumbersexual"
4
4
  require "slop"
5
- require "etc"
6
5
  require "uri"
7
6
 
7
+ ruby_version = RUBY_VERSION.split('.').join.to_i
8
+ if ruby_version >= 220
9
+ require 'etc'
10
+ nprocessors = Etc.nprocessors
11
+ else
12
+ nprocessors = %x[ nproc ]
13
+ end
14
+
8
15
  options = Slop.parse do |o|
9
16
  o.bool '-a', '--all', 'search all indices rather than today\'s in latency mode', default: nil
10
17
  o.string '-D', '--dictionaryfile', 'path to dictionary file (default: /etc/dictionaries-common/words)', default: '/etc/dictionaries-common/words'
@@ -18,7 +25,7 @@ options = Slop.parse do |o|
18
25
  o.array '-p', '--priorities', 'additional comma-seperated priorities', default: []
19
26
  o.integer '-r', '--rate', 'messages per second per thread (default: 50, 0 for unlimited)', default: 50
20
27
  o.string '-s', '--statsdhost', 'send statsd telemetry to the named host (default: off)', default: nil
21
- o.integer '-T', '--threads', 'number of threads (defaults to number of cores * 2)', default: Etc.nprocessors * 2
28
+ o.integer '-T', '--threads', 'number of threads (defaults to number of cores * 2)', default: nprocessors * 2
22
29
  o.integer '-t', '--timeout', 'length of execution. 0 for forever (default: 0)', default: 0
23
30
  o.string '-u', '--uri', 'elasticsearch uri when run in latency mode (default: http://localhost:9200/)', default: URI::parse("http://localhost:9200/")
24
31
  end
@@ -1,3 +1,3 @@
1
1
  module Lumbersexual
2
- VERSION = "0.3.14"
2
+ VERSION = "0.3.15"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lumbersexual
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.14
4
+ version: 0.3.15
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sam Pointer
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-04-20 00:00:00.000000000 Z
11
+ date: 2016-04-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler