Class: Yobi::ForgetGroup
Overview
One grouping Restic's forget policy was evaluated against (by default,
grouped by host+paths).
Instance Method Summary
collapse
Methods inherited from FancyHash
#initialize, #inspect, #pretty_print
Instance Method Details
#host ⇒ String
78
79
80
|
# File 'lib/yobi/repository/forget.rb', line 78
def host
self["host"]
end
|
93
94
95
|
# File 'lib/yobi/repository/forget.rb', line 93
def keep
@keep ||= (self["keep"] || []).map { |entry| Yobi::Snapshot.new(entry) }
end
|
#paths ⇒ Array<String>
88
89
90
|
# File 'lib/yobi/repository/forget.rb', line 88
def paths
self["paths"]
end
|
Returns one per kept snapshot, explaining which policy rule(s) kept it.
103
104
105
|
# File 'lib/yobi/repository/forget.rb', line 103
def reasons
@reasons ||= (self["reasons"] || []).map { |entry| Yobi::KeepReason.new(entry) }
end
|
98
99
100
|
# File 'lib/yobi/repository/forget.rb', line 98
def remove
@remove ||= (self["remove"] || []).map { |entry| Yobi::Snapshot.new(entry) }
end
|
83
84
85
|
# File 'lib/yobi/repository/forget.rb', line 83
def tags
@tags ||= self["tags"] || []
end
|