Browse Source

branches2.cpp

toml4
Antonio SJ Musumeci 8 months ago
parent
commit
281c8eef63
  1. 5
      config.toml
  2. 6
      src/branches2.cpp

5
config.toml

@ -83,6 +83,8 @@ min-free-space = 123
# TIER 0
[[branches.tier]]
enabled = true
[branches.tier.func.create]
policy.default = 'mfs'
[[branches.tier.func.create.policy.overrides]]
@ -115,10 +117,11 @@ type = 'glob'
mode = 'RW'
if-not-mountpoint = 'fail' # 'fail' | 'deactivate' ?
# TIER 1
[[branches.tier]]
[[branches.tier.branch]]
enabled = true
enabled = false
name = 'branch0'
type = 'literal'
path = '/mnt/*'

6
src/branches2.cpp

@ -19,6 +19,12 @@ Branches2::Branches2(toml::value const &v_)
for(auto const &tier : tiers.as_array())
{
bool enabled;
enabled = toml::find_or(tier,"enabled",false);
if(!enabled)
continue;
_branches.emplace_back(tier);
}
}

Loading…
Cancel
Save