From: Michael Tremer Date: Wed, 5 May 2021 15:00:39 +0000 (+0000) Subject: cli: Add switch for unattended mode X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=125ca7cb650fa1b2bd6611daa59449d6f4b99dac;p=people%2Fms%2Fbricklayer.git cli: Add switch for unattended mode Signed-off-by: Michael Tremer --- diff --git a/src/bricklayer b/src/bricklayer index aa02d90..0ecd262 100644 --- a/src/bricklayer +++ b/src/bricklayer @@ -43,6 +43,8 @@ class Cli(object): help=_("Enable debugging mode")) parser.add_argument("--test", action="store_true", help=_("Enable test mode (do not perform any actions)")) + parser.add_argument("--unattended", action="store_true", + help=_("Enable unattended mode")) # Parse arguments return parser.parse_args() diff --git a/src/python/__init__.py b/src/python/__init__.py index d399976..2602890 100644 --- a/src/python/__init__.py +++ b/src/python/__init__.py @@ -29,8 +29,9 @@ class Bricklayer(object): """ Bricklayer's base class """ - def __init__(self, test=False, debug=False): + def __init__(self, test=False, debug=False, unattended=False): self.test = test + self.unattended = unattended # Enable debug logging if debug: