dorian-all 1.1.1 → 2.0.0

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/all +6 -2
  3. metadata +14 -10
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c931cee0fe3750fa990f7c741fea8337c48752818dbf392f33b8d2de08177189
4
- data.tar.gz: 2f3426b182380eb99bdf8df0a9da143daab73e110d828f99ff18ab40dc443baa
3
+ metadata.gz: 81fa2f502a13075048cfbad9e991a009e2cde9798343cfd0ba0f3d0c0565d705
4
+ data.tar.gz: 0e371530c932dcb111932bc6422a57a498d7b2caa0008d700ccf96c3501d140e
5
5
  SHA512:
6
- metadata.gz: e96952fbe86425ec82fb4c8d401fb41977c8e627776506e4a76ba3a6a377f1322dcff2b75d7afd14aac19574ecd90a69ba5feb9fab45f45063e8c26b706b24bd
7
- data.tar.gz: 283bf1cc61e80aad98b205e6b07a599a8394f15e0172d0474715307913a423e94b1e60bd9e4365901cd7f9c4c2a4cf9b98973872906e8b489a567c6fd4add536
6
+ metadata.gz: 0a9918d961943a731988718720687e4ca75c4f7c72a2fb3820eb608ccb48dd18eed76a1c68c894c7ee01fa4f8aa482b8f8e20fcc57a1ee45438312fa7ec3d512
7
+ data.tar.gz: 8e795eade015b17ba36669d506eae38b02eae248e990f339ff3a252c04fe98566356c71cc04b67b6b2d45226309491a29878a4e892e23ab9f66d743ce01e10ee
data/bin/all CHANGED
@@ -11,11 +11,15 @@ if parsed.options.version
11
11
  abort File.read(File.expand_path("../VERSION", __dir__))
12
12
  end
13
13
 
14
- it =
14
+ input =
15
15
  if parsed.files.any?
16
16
  parsed.files.map { |file| File.read(file) }.join
17
17
  else
18
18
  $stdin.each_line.to_a.map(&:strip)
19
19
  end
20
20
 
21
- eval(parsed.arguments.join(" "))
21
+ current_binding = binding
22
+ current_binding.local_variable_set(:it, input)
23
+ current_binding.local_variable_set(:lines, input)
24
+
25
+ eval(parsed.arguments.join(" "), current_binding)
metadata CHANGED
@@ -1,14 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dorian-all
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.1
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dorian Marié
8
- autorequire:
9
8
  bindir: bin
10
9
  cert_chain: []
11
- date: 2024-09-05 00:00:00.000000000 Z
10
+ date: 1980-01-02 00:00:00.000000000 Z
12
11
  dependencies:
13
12
  - !ruby/object:Gem::Dependency
14
13
  name: dorian-arguments
@@ -16,15 +15,22 @@ dependencies:
16
15
  requirements:
17
16
  - - ">="
18
17
  - !ruby/object:Gem::Version
19
- version: '0'
18
+ version: 1.2.3
19
+ - - "<"
20
+ - !ruby/object:Gem::Version
21
+ version: '2'
20
22
  type: :runtime
21
23
  prerelease: false
22
24
  version_requirements: !ruby/object:Gem::Requirement
23
25
  requirements:
24
26
  - - ">="
25
27
  - !ruby/object:Gem::Version
26
- version: '0'
27
- description: evaluates ruby code on all lines of the input
28
+ version: 1.2.3
29
+ - - "<"
30
+ - !ruby/object:Gem::Version
31
+ version: '2'
32
+ description: Runs a Ruby expression against every input line and prints the transformed
33
+ output.
28
34
  email: dorian@dorianmarie.com
29
35
  executables:
30
36
  - all
@@ -37,7 +43,6 @@ licenses:
37
43
  - MIT
38
44
  metadata:
39
45
  rubygems_mfa_required: 'true'
40
- post_install_message:
41
46
  rdoc_options: []
42
47
  require_paths:
43
48
  - lib
@@ -45,15 +50,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
45
50
  requirements:
46
51
  - - ">="
47
52
  - !ruby/object:Gem::Version
48
- version: '3'
53
+ version: '4.0'
49
54
  required_rubygems_version: !ruby/object:Gem::Requirement
50
55
  requirements:
51
56
  - - ">="
52
57
  - !ruby/object:Gem::Version
53
58
  version: '0'
54
59
  requirements: []
55
- rubygems_version: 3.5.16
56
- signing_key:
60
+ rubygems_version: 4.0.15
57
61
  specification_version: 4
58
62
  summary: evaluates ruby code on all lines of the input
59
63
  test_files: []