From 65bcb8a35bd8475c400043a20c46e91e4b9cb874 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Fri, 3 Nov 2017 16:59:27 -0400 Subject: [PATCH] Add glob supressing aliases for new commands Also, document what they are for the curious. --- confluent_client/confluent_env.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/confluent_client/confluent_env.sh b/confluent_client/confluent_env.sh index b8cfddc8..8eed98d9 100644 --- a/confluent_client/confluent_env.sh +++ b/confluent_client/confluent_env.sh @@ -2,10 +2,15 @@ PATH=/opt/confluent/bin:$PATH export PATH MANPATH=/opt/confluent/share/man:$MANPATH export MANPATH +# The aliases below are to signify that file globbing is unwelcome at the shell +# this avoids a problem if a user does a noderange like 'n[21-33] and there is a file +# in the directory like 'n3' that causes the parameter to change and target a totally +# different node alias confetty='set -f;confetty';confetty(){ command confetty "$@"; set +f;} alias nodeattrib='set -f;nodeattrib';nodeattrib(){ command nodeattrib "$@"; set +f;} alias nodeboot='set -f;nodeboot';nodeboot(){ command nodeboot "$@"; set +f;} alias nodeconsole='set -f;nodeconsole';nodeconsole(){ command nodeconsole "$@"; set +f;} +alias nodedefine='set -f;nodedefine';nodedefine(){ command nodedefine "$@"; set +f;} alias nodeeventlog='set -f;nodeeventlog';nodeeventlog(){ command nodeeventlog "$@"; set +f;} alias nodefirmware='set -f;nodefirmware';nodefirmware(){ command nodefirmware "$@"; set +f;} alias nodegroupattrib='set -f;nodegroupattrib';nodegroupattrib(){ command nodegroupattrib "$@"; set +f;} @@ -14,6 +19,7 @@ alias nodeidentify='set -f;nodeidentify';nodeidentify(){ command nodeidentify "$ alias nodeinventory='set -f;nodeinventory';nodeinventory(){ command nodeinventory "$@"; set +f;} alias nodelist='set -f;nodelist';nodelist(){ command nodelist "$@"; set +f;} alias nodepower='set -f;nodepower';nodepower(){ command nodepower "$@"; set +f;} +alias nodereseat='set -f;nodereseat';nodereseat(){ command nodereseat "$@"; set +f;} alias noderun='set -f;noderun';noderun(){ command noderun "$@"; set +f;} alias nodesensors='set -f;nodesensors';nodesensors(){ command nodesensors "$@"; set +f;} alias nodesetboot='set -f;nodesetboot';nodesetboot(){ command nodesetboot "$@"; set +f;}