pru 0.2.0 → 0.2.1

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
- SHA1:
3
- metadata.gz: d7ab83319d415eed24a2650913be76d27c0652a1
4
- data.tar.gz: 69d39153bc5388450fb4125e6d66513740e81273
2
+ SHA256:
3
+ metadata.gz: 5e3aadfba1442b50864edd1817ede514cf9592cd5cda84df67969958160d4053
4
+ data.tar.gz: 56047bf61575504fc0c3c489b084c3537ca715d20498c2571d01df92585fe684
5
5
  SHA512:
6
- metadata.gz: f21fbb6b7a9925e65176555fe73b732f9708c32dbc202d83555542b710f14ef92bbc6543edb1f0d0b1f21fc38b4f2dbea05c1189a85353e3a49fc0bd74b70d00
7
- data.tar.gz: 8c10b8fdd4a47e024c603729b6d5b6b260f0402c4c71e1e0c7fa2f0182c68ca50f4adfee06f389d4bdcfc4b3da2f9d937897b00bf67831ec83bc0b581c528133
6
+ metadata.gz: '0995c519eaee3cf6b9fd41fa21578b3b4138214d2a5cbc6848fa03d37f9ad0328f16bef8dfbee6c274744408708d7ac47eeb545b5c228f89cf41cc2c42336de0'
7
+ data.tar.gz: fd7de3b48e9291ab01ad4478b65bc76a02f97841f4d84aa93ae624a600e2c188f921f32e5f2fc90e10cd76579f7fb2434771a9fb586fdebf9fe96dab29c28513
data/bin/pru CHANGED
@@ -59,7 +59,15 @@ else
59
59
  end
60
60
 
61
61
  collector = lambda do |line|
62
- output_lines ? output_lines << line : puts(line)
62
+ if output_lines
63
+ output_lines << line
64
+ else
65
+ begin
66
+ puts(line)
67
+ rescue Errno::EPIPE
68
+ exit 0
69
+ end
70
+ end
63
71
  end
64
72
 
65
73
  if reduce
@@ -11,8 +11,8 @@ class Array
11
11
  end
12
12
  end unless method_defined?(:sum)
13
13
 
14
- def mean(method = nil, &block)
15
- sum(method, &block) / size.to_f
14
+ def mean(*args, &block)
15
+ sum(*args, &block) / size.to_f
16
16
  end unless method_defined?(:mean)
17
17
 
18
18
  def grouped
data/lib/pru/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Pru
2
- VERSION = "0.2.0"
2
+ VERSION = "0.2.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pru
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Grosser
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-24 00:00:00.000000000 Z
11
+ date: 2021-11-18 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description:
14
14
  email: michael@grosser.it
@@ -33,15 +33,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
33
33
  requirements:
34
34
  - - ">="
35
35
  - !ruby/object:Gem::Version
36
- version: 2.0.0
36
+ version: '2.5'
37
37
  required_rubygems_version: !ruby/object:Gem::Requirement
38
38
  requirements:
39
39
  - - ">="
40
40
  - !ruby/object:Gem::Version
41
41
  version: '0'
42
42
  requirements: []
43
- rubyforge_project:
44
- rubygems_version: 2.5.1
43
+ rubygems_version: 3.2.16
45
44
  signing_key:
46
45
  specification_version: 4
47
46
  summary: Pipeable Ruby - forget about grep / sed / awk / wc ... use pure, readable