mirror of
https://github.com/NixOS/nix
synced 2025-06-28 13:41:15 +02:00
Move doc() to Args
This commit is contained in:
parent
9fab14adbc
commit
346baec783
2 changed files with 5 additions and 5 deletions
|
@ -254,6 +254,8 @@ nlohmann::json Args::toJSON()
|
|||
res["description"] = description();
|
||||
res["flags"] = std::move(flags);
|
||||
res["args"] = std::move(args);
|
||||
auto s = doc();
|
||||
if (s != "") res.emplace("doc", stripIndentation(s));
|
||||
return res;
|
||||
}
|
||||
|
||||
|
@ -378,8 +380,6 @@ nlohmann::json Command::toJSON()
|
|||
|
||||
auto res = Args::toJSON();
|
||||
res["examples"] = std::move(exs);
|
||||
auto s = doc();
|
||||
if (s != "") res.emplace("doc", stripIndentation(s));
|
||||
return res;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue