dorian-replace 1.0.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/replace +2 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 96a9df2e5164cbeedacfa3b810ff8fff7bf6798f879b864deeee27bd675bd867
|
4
|
+
data.tar.gz: a47debb703b96477d7ae70b93a42472ee2dde8f14a80f0f7e84c88076574d426
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 11f2a9dd68acdfc0987321f73f9932a7eaccc3111c58025df4904f6fb988d6a4bbf136c1ee8d2c12e7934f0c9e80eeaf688cf4fc6e25f047d5da1a7da5db8342
|
7
|
+
data.tar.gz: c2a93d304dd73bc849d6dbf5840b654eaae61c5def4ba9c73b42f1c4e1113fca5bae9e303211112944224142a7e5bf6dd8342a65562cbfbc821221ea3bc2e9f4
|
data/bin/replace
CHANGED
@@ -8,7 +8,7 @@ parsed = Dorian::Arguments.parse(version: { alias: :v }, help: { alias: :h })
|
|
8
8
|
abort parsed.help if parsed.options.help
|
9
9
|
|
10
10
|
if parsed.options.version
|
11
|
-
abort File.read(File.expand_path("
|
11
|
+
abort File.read(File.expand_path("../VERSION", __dir__))
|
12
12
|
end
|
13
13
|
|
14
14
|
from, to = parsed.arguments
|
@@ -16,5 +16,6 @@ files = parsed.files.any? ? parsed.files : $stdin.each_line.to_a.map(&:strip)
|
|
16
16
|
|
17
17
|
files.each do |file|
|
18
18
|
next if File.directory?(file)
|
19
|
+
|
19
20
|
File.write(file, File.read(file).gsub(from, to))
|
20
21
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dorian-replace
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.1
|
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-
|
11
|
+
date: 2024-09-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dorian-arguments
|
@@ -45,14 +45,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
45
45
|
requirements:
|
46
46
|
- - ">="
|
47
47
|
- !ruby/object:Gem::Version
|
48
|
-
version: '
|
48
|
+
version: '3'
|
49
49
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
50
50
|
requirements:
|
51
51
|
- - ">="
|
52
52
|
- !ruby/object:Gem::Version
|
53
53
|
version: '0'
|
54
54
|
requirements: []
|
55
|
-
rubygems_version: 3.5.
|
55
|
+
rubygems_version: 3.5.16
|
56
56
|
signing_key:
|
57
57
|
specification_version: 4
|
58
58
|
summary: replaces string with other string from files
|