From 186571965dccf57d15b9f37c1cca92a57187b7b3 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 7 Jun 2017 18:41:20 +0200 Subject: Don't show flags from config settings in "nix --help" --- src/libmain/common-args.cc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'src/libmain') diff --git a/src/libmain/common-args.cc b/src/libmain/common-args.cc index 9a7a893138de..3fa42c2aafa9 100644 --- a/src/libmain/common-args.cc +++ b/src/libmain/common-args.cc @@ -18,8 +18,12 @@ MixCommonArgs::MixCommonArgs(const string & programName) verbosity = lvlDebug; }); - mkFlag(0, "option", {"name", "value"}, "set a Nix configuration option (overriding nix.conf)", 2, - [](Strings ss) { + mkFlag() + .longName("option") + .labels({"name", "value"}) + .description("set a Nix configuration option (overriding nix.conf)") + .arity(2) + .handler([](Strings ss) { auto name = ss.front(); ss.pop_front(); auto value = ss.front(); try { -- cgit 1.4.1