Browse Source

mergerfs.cpp

toml4
Antonio SJ Musumeci 10 months ago
parent
commit
39b72434ea
  1. 12
      config.toml
  2. 2
      src/mergerfs.cpp

12
config.toml

@ -116,25 +116,25 @@ func.open.policy = 'ff'
[branches] [branches]
min-free-space = 123 min-free-space = 123
[branches.tier.0]
[[branches.tier.0.branch]]
[[branches.tier]]
[[branches.tier.branch]]
name = 'branch0' name = 'branch0'
type = 'scan' type = 'scan'
path = '*' path = '*'
order = 'name:asc' # | size order = 'name:asc' # | size
[[branches.tier.0.branch]]
[[branches.tier.branch]]
name = 'branch1' name = 'branch1'
type = 'literal' type = 'literal'
path = '/mnt/branch1' path = '/mnt/branch1'
[[branches.tier.0.branch]]
[[branches.tier.branch]]
active = true active = true
path = '/tmp/mergerfs/a' path = '/tmp/mergerfs/a'
path-type = 'literal' path-type = 'literal'
mode = 'RW' mode = 'RW'
if-not-mountpoint = 'fail' # 'fail' | 'deactivate' ? if-not-mountpoint = 'fail' # 'fail' | 'deactivate' ?
[branches.tier.1]
[[branches.tier.1.branch]]
[[branches.tier]]
[[branches.tier.branch]]
name = 'branch0' name = 'branch0'
type = 'literal' type = 'literal'
path = 'foo' path = 'foo'

2
src/mergerfs.cpp

@ -304,7 +304,7 @@ main(int argc_,
{ {
auto data = toml::parse("config.toml"); auto data = toml::parse("config.toml");
std::cout << data["branches"]["tier"]["0"] << '\n';
std::cout << data["branches"] << '\n';
// Branches2 b(data["branches"]); // Branches2 b(data["branches"]);

Loading…
Cancel
Save