11#include <llvm/Support/CommandLine.h>
12#include <llvm/Support/JSON.h>
17using namespace llvm::cl;
21opt<std::string> DefaultConfigJSON{
"config",
22 desc(
"JSON-encoded initial configuration"),
28 if (DefaultConfigJSON.empty())
Allow default configuration being passed via CLI.
Declares workspace configuration schema.
bool fromJSON(const llvm::json::Value &Params, Configuration::Diagnostic &R, llvm::json::Path P)
llvm::cl::OptionCategory NixdCategory
nixd::Configuration parseCLIConfig()
Parse the CLI flag and initialize the config nixd::DefaultConfig.
llvm::json::Value parse(llvm::StringRef JSON)