---
 lib/cli.py       |    5 +++++
 scripts/gnt-node |    4 +---
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/lib/cli.py b/lib/cli.py
index 273a7a9..e81e107 100644
--- a/lib/cli.py
+++ b/lib/cli.py
@@ -79,6 +79,7 @@ __all__ = [
   "ON_SECONDARY_OPT",
   "OS_OPT",
   "OS_SIZE_OPT",
+  "READD_OPT",
   "SECONDARY_IP_OPT",
   "SELECT_OS_OPT",
   "SEP_OPT",
@@ -681,6 +682,10 @@ SECONDARY_IP_OPT = cli_option("-s", "--secondary-ip", 
dest="secondary_ip",
                               help="Specify the secondary ip for the node",
                               metavar="ADDRESS", default=None)
 
+READD_OPT = cli_option("--readd", dest="readd",
+                       default=False, action="store_true",
+                       help="Readd old node after replacing it")
+
 
 def _ParseArgs(argv, commands, aliases):
   """Parser for the command line arguments.
diff --git a/scripts/gnt-node b/scripts/gnt-node
index 4e5e419..61b86f1 100755
--- a/scripts/gnt-node
+++ b/scripts/gnt-node
@@ -625,9 +625,7 @@ commands = {
   'add': (AddNode, [ArgHost(min=1, max=1)],
           [DEBUG_OPT,
            SECONDARY_IP_OPT,
-           cli_option("--readd", dest="readd",
-                      default=False, action="store_true",
-                      help="Readd old node after replacing it"),
+           READD_OPT,
            cli_option("--no-ssh-key-check", dest="ssh_key_check",
                       default=True, action="store_false",
                       help="Disable SSH key fingerprint checking"),
-- 
1.6.3.3

Reply via email to