From ab3ac07cde99cb1e7e5c06350c9ac6f23c641122 Mon Sep 17 00:00:00 2001 From: Francesco Lattanzio Date: Sun, 12 Mar 2017 22:43:29 +0100 Subject: [PATCH] Enable parameters expansion in the prompt For this to work on zsh a specific option must be enabled. --- rumpctrl.sh.in | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/rumpctrl.sh.in b/rumpctrl.sh.in index b56f1c0..55873a4 100644 --- a/rumpctrl.sh.in +++ b/rumpctrl.sh.in @@ -6,6 +6,10 @@ rrCANDO=true #[ "${SHELL}" != "${SHELL%bash}" ] \ # || { echo "environment requires bash"; rrCANDO=false; } +# enable parameters expansion in the prompt +[ "${SHELL}" = "${SHELL%/zsh}" ] \ + || set -o PROMPT_SUBST + # sed replacement is not run with /g ... [ "XXXPATHXXX" = "XXXPATHXXX" ] && { echo "not preprocessed"; rrCANDO=false; }