From 447675b01aff2d4e661eef44fea2fd7cc23c4725 Mon Sep 17 00:00:00 2001 From: Gardouille Date: Mon, 9 Apr 2018 09:46:32 +0200 Subject: [PATCH] Ensure debops host function apply to one host/group --- zshrc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/zshrc b/zshrc index 7153371..11c3787 100644 --- a/zshrc +++ b/zshrc @@ -316,7 +316,11 @@ function tasec() { alias deal="debops" ## Limit to a define host/group function deho() { - debops -l "${ANS_HOST}" + if [ ${ANS_HOST} ]; then + debops -l "${ANS_HOST}" + else + printf '%b' "${MAGENTA}ANS_HOST${RESET} vars is ${REDB}not${RESET} define !\n" + fi } ## Limit to a define host/group and to a role function dero() {