snapshot_archive 0.17.0 → 0.19.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/snapshot_archive/archives.rb +1 -1
- data/lib/snapshot_archive/repositories.rb +2 -1
- data/lib/snapshot_archive/version.rb +1 -1
- 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: 8f8d2b4c725a1f21bdf25d688680e486fb3691b852b384953aa375f8fc609e02
|
4
|
+
data.tar.gz: e83411afc3f507e4a693a79b07fc25de87f039cd90824d843ea18e3cdd63a1bb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: acf170a6eeed4711b778d4aab84c737844ba3777ff3915825e79addeeca549cc1907595f080a6066fda368c007391d28e06f7853d9f57a8ea7e68723cf97369c
|
7
|
+
data.tar.gz: 7e5dbe60cc99216411bfa2d2f29871b8aa9c8641815d4cb3e2f20cc0302fc300105169aa37282599a5b6595d0563407297069a73c285d906d2606a4374b6a841
|
@@ -62,7 +62,7 @@ module SnapshotArchive
|
|
62
62
|
metadata.fetch("stores").each do |store_metadata|
|
63
63
|
store = Cfg.instance.store(store_metadata.fetch("type"))
|
64
64
|
if store.respond_to?(:delete)
|
65
|
-
store.delete(store_metadata)
|
65
|
+
store.delete(metadata: store_metadata)
|
66
66
|
end
|
67
67
|
end
|
68
68
|
end
|
@@ -67,7 +67,8 @@ module SnapshotArchive
|
|
67
67
|
end
|
68
68
|
|
69
69
|
def delete(id)
|
70
|
-
|
70
|
+
dir = File.join(path, id)
|
71
|
+
md_path = File.join(dir, "metadata.json")
|
71
72
|
raise ArgumentError.new("unknown snapshot: #{id}") unless File.exist?(md_path)
|
72
73
|
metadata = JSON.parse(File.read(md_path))
|
73
74
|
|