From 442587bf0ae419e26f0ad761555be6da74b9be98 Mon Sep 17 00:00:00 2001
From: Michael Hanselmann <hansmi@google.com>
Date: Thu, 7 Apr 2011 17:35:44 +0200
Subject: [PATCH] cli: Add option to force names to be treated as filter

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
---
 lib/cli.py | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/lib/cli.py b/lib/cli.py
index 50bb1580e..d6a74e5e4 100644
--- a/lib/cli.py
+++ b/lib/cli.py
@@ -77,6 +77,7 @@ __all__ = [
   "FIELDS_OPT",
   "FILESTORE_DIR_OPT",
   "FILESTORE_DRIVER_OPT",
+  "FORCE_FILTER_OPT",
   "FORCE_OPT",
   "FORCE_VARIANT_OPT",
   "GLOBAL_FILEDIR_OPT",
@@ -1181,6 +1182,11 @@ POWER_DELAY_OPT = cli_option("--power-delay", dest="power_delay", type="float",
                              default=constants.OOB_POWER_DELAY,
                              help="Time in seconds to wait between power-ons")
 
+FORCE_FILTER_OPT = cli_option("-F", "--filter", dest="force_filter",
+                              action="store_true", default=False,
+                              help=("Whether command argument should be treated"
+                                    " as filter"))
+
 
 #: Options provided by all commands
 COMMON_OPTS = [DEBUG_OPT]
-- 
GitLab