From 3391b6ab1fc023f3c688e3279deda39b6484413f Mon Sep 17 00:00:00 2001 From: John Southworth Date: Thu, 6 Oct 2011 01:01:36 -0500 Subject: fix help text printing when the command is runnable --- etc/bash_completion.d/vyatta-op | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'etc') diff --git a/etc/bash_completion.d/vyatta-op b/etc/bash_completion.d/vyatta-op index 16e25b0..19f2519 100644 --- a/etc/bash_completion.d/vyatta-op +++ b/etc/bash_completion.d/vyatta-op @@ -148,6 +148,9 @@ _vyatta_op_help () _vyatta_op_print_help '' "Execute the current command" fi for comp ; do + if [[ "$comp" == "" ]]; then + continue + fi if [ -z "$comp" ] ; then if [ "X$node_tag_help" == "X$last_help" ] ; then help="" @@ -168,11 +171,7 @@ _vyatta_op_help () else last_help=$help fi - if [[ "$comp" == "" ]]; then - continue - else - _vyatta_op_print_help "$comp" "$help" - fi + _vyatta_op_print_help "$comp" "$help" fi done } -- cgit v1.2.3