From 0db9e6cd1af299f7d65e0b99019f0ccdbb1aaf3f Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 9 Feb 2016 21:07:48 +0100 Subject: New command line parsing infrastructure --- src/libmain/common-args.hh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 src/libmain/common-args.hh (limited to 'src/libmain/common-args.hh') diff --git a/src/libmain/common-args.hh b/src/libmain/common-args.hh new file mode 100644 index 000000000000..62657e0d0218 --- /dev/null +++ b/src/libmain/common-args.hh @@ -0,0 +1,22 @@ +#pragma once + +#include "args.hh" + +namespace nix { + +struct MixCommonArgs : virtual Args +{ + MixCommonArgs(const string & programName); +}; + +struct MixDryRun : virtual Args +{ + bool dryRun; + + MixDryRun() + { + mkFlag(0, "dry-run", "show what this command would do without doing it", &dryRun); + } +}; + +} -- cgit 1.4.1