Demo script bugfix
This commit is contained in:
+2
-22
@@ -37,10 +37,6 @@ function maybe_first_prompt() {
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# After a `run` this variable will hold the stdout of the command that was run.
|
|
||||||
# If the command was interactive, this will likely be garbage.
|
|
||||||
#DEMO_RUN_STDOUT=""
|
|
||||||
|
|
||||||
function run() {
|
function run() {
|
||||||
maybe_first_prompt
|
maybe_first_prompt
|
||||||
rate=25
|
rate=25
|
||||||
@@ -52,27 +48,11 @@ function run() {
|
|||||||
sleep 0.5
|
sleep 0.5
|
||||||
fi
|
fi
|
||||||
$1
|
$1
|
||||||
echo; echo -n ">"
|
echo
|
||||||
|
echo -n ">"
|
||||||
read -s
|
read -s
|
||||||
echo -e "\b "
|
echo -e "\b "
|
||||||
# OFILE="$(mktemp -t $(basename $0).XXXXXX)"
|
|
||||||
# script -q -t0 "$OFILE" $1 # [removed -e,-c options -soam]
|
|
||||||
# r=$?
|
|
||||||
# read -d '' -t "${timeout}" -n 10000 # clear stdin
|
|
||||||
# prompt
|
|
||||||
# if [ -z "$DEMO_AUTO_RUN" ]; then
|
|
||||||
# read -s
|
|
||||||
# fi
|
|
||||||
# DEMO_RUN_STDOUT="$(tail -n +2 $OFILE | sed 's/\r//g')"
|
|
||||||
# return $r
|
|
||||||
}
|
|
||||||
|
|
||||||
function relative() {
|
|
||||||
for arg; do
|
|
||||||
echo "$(realpath $(dirname $(which $0)))/$arg" | sed "s|$(realpath $(pwd))|.|"
|
|
||||||
done
|
|
||||||
}
|
}
|
||||||
|
|
||||||
SSH_NODE=$(kubectl get nodes | tail -1 | cut -f1 -d' ')
|
SSH_NODE=$(kubectl get nodes | tail -1 | cut -f1 -d' ')
|
||||||
|
|
||||||
#trap "echo" EXIT
|
|
||||||
|
|||||||
Reference in New Issue
Block a user