hatecf 0.0.3 → 0.0.4
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.
- checksums.yaml +4 -4
- data/remote/remote.rb +2 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ff51d0eb8d13e24dd523595c4f1f797bd20641fc408ff61c9e232fcaadfd18d2
|
4
|
+
data.tar.gz: 0fc385fb0393ba6dd0b75b5508b23a41e6d67ccadf02eae40c85741712d1e7dd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d7f45828e6513dd91e33facffadc7fddf8b5378476835c102f547187b7a5829032c4e3f8fdf9e25645a02e94b18fba1707185be7633cfb6907663c7df7579d6
|
7
|
+
data.tar.gz: 481c41a7994bfc02c422c78aba2c81119217a2d698a259afbadcc99ede993f21f89214fd58a6bdc45822b18d082e9fdc17e81c51c99cc6984b04838e82c3f076
|
data/remote/remote.rb
CHANGED
@@ -296,12 +296,12 @@ module Remote
|
|
296
296
|
|
297
297
|
def create_config(path, text)
|
298
298
|
path = File.expand_path path
|
299
|
-
unless File.exist?(path) && File.read(path).rstrip == text
|
299
|
+
unless File.exist?(path) && File.read(path).rstrip == text.rstrip
|
300
300
|
destructive "writing config #{path}" do
|
301
301
|
File.open(path, File::CREAT | File::TRUNC | File::WRONLY) do |f|
|
302
302
|
f.flock(File::LOCK_EX)
|
303
303
|
f.write(text)
|
304
|
-
f.write("\n")
|
304
|
+
f.write("\n") unless text[-1] == "\n"
|
305
305
|
end
|
306
306
|
end
|
307
307
|
else
|