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
80
81
82
|
# File 'lib/yobi/repository/forget.rb', line 80
def host
self["host"]
end
|
95
96
97
|
# File 'lib/yobi/repository/forget.rb', line 95
def keep
@keep ||= (self["keep"] || []).map { |entry| Yobi::Snapshot.new(entry) }
end
|
#paths ⇒ Array<String>
90
91
92
|
# File 'lib/yobi/repository/forget.rb', line 90
def paths
self["paths"]
end
|
Returns one per kept snapshot, explaining which policy rule(s) kept it.
105
106
107
|
# File 'lib/yobi/repository/forget.rb', line 105
def reasons
@reasons ||= (self["reasons"] || []).map { |entry| Yobi::KeepReason.new(entry) }
end
|
100
101
102
|
# File 'lib/yobi/repository/forget.rb', line 100
def remove
@remove ||= (self["remove"] || []).map { |entry| Yobi::Snapshot.new(entry) }
end
|
85
86
87
|
# File 'lib/yobi/repository/forget.rb', line 85
def tags
@tags ||= self["tags"] || []
end
|