dorian-csv-each 0.4.2 → 0.4.3

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.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/bin/csv-each +6 -4
  3. metadata +5 -8
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c908284a53ac555633ed006465e99eed2aa9ade5f26114b763bd3bd5bed6be18
4
- data.tar.gz: 5fc24316b7e8b379d5565ef36e4ada5e0e4626c0b040fc6d8a467b55e0807a94
3
+ metadata.gz: 440e5a06b361853b93805090439f123723b4e82b8e64d0a66c50f90ec352f8ad
4
+ data.tar.gz: 92863c9542f2b3372d5e223ca8dccb65f21cba4ba0f8c1cf592194c9cc167396
5
5
  SHA512:
6
- metadata.gz: ebe1b2b6a3035abee98acebf173b2dd26007c4f63a1f6d7995fda5ecacdbc71a2fe76ae8518fbd0f471db04b221b7aa3bd644ee74c55f8d6340c5a4897fc6ebe
7
- data.tar.gz: 7fd135fef597d1d44f492703da6052351996376505f9d2723216ac3a2f27a6e650dcee150494a419505dc84521ca03afdfd2c741a43493fb0c4d2811a7f414a6
6
+ metadata.gz: 1d97ef1b51b168c8feeb42fd951365cedb85f0c1d2bc0003a3e2f413aac185b1da3b459434b5bb72e474f98ccb0844af56b1a15d75562321002f67400c39b86c
7
+ data.tar.gz: e0997468eba3092217cc1159c1b97e5590c23a72df0bb6ab66726d6a7c23bae54968d128caffcd95f5b433be0caaa212f70a9b5664af19b04a82ad0278694b4d
data/bin/csv-each CHANGED
@@ -21,7 +21,9 @@ argv =
21
21
 
22
22
  abort "See --help" if argv.size != 1
23
23
 
24
- CSV.parse($stdin.each_line.to_a.join, headers: options[:headers]).each do |it|
25
- it = options[:headers] ? it.to_h.with_indifferent_access : it.to_a
26
- eval(argv.first)
27
- end
24
+ CSV
25
+ .parse($stdin.each_line.to_a.join, headers: options[:headers])
26
+ .each do |it|
27
+ it = options[:headers] ? it.to_h.with_indifferent_access : it.to_a
28
+ eval(argv.first)
29
+ end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dorian-csv-each
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.2
4
+ version: 0.4.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dorian Marié
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-08-15 00:00:00.000000000 Z
11
+ date: 2024-08-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: csv
@@ -25,7 +25,7 @@ dependencies:
25
25
  - !ruby/object:Gem::Version
26
26
  version: '0'
27
27
  - !ruby/object:Gem::Dependency
28
- name: activesupport
28
+ name: dorian-to_struct
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - ">="
@@ -38,10 +38,7 @@ dependencies:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
40
  version: '0'
41
- description: |-
42
- Evaluates some code on each line of the csv input
43
-
44
- e.g. `cat users.csv | csv-each --headers "puts it[:name]"`
41
+ description: evaluates some ruby code on each line of the csv input
45
42
  email: dorian@dorianmarie.com
46
43
  executables:
47
44
  - csv-each
@@ -72,5 +69,5 @@ requirements: []
72
69
  rubygems_version: 3.5.11
73
70
  signing_key:
74
71
  specification_version: 4
75
- summary: Evaluates some code on each line of the csv input
72
+ summary: evaluates some ruby code on each line of the csv input
76
73
  test_files: []