renommer start-screen en Sscreen

This commit is contained in:
Jephté Clain 2020-10-26 16:30:35 +04:00
parent e395720902
commit 85842f3c41
2 changed files with 3 additions and 3 deletions

6
cssh
View File

@ -24,15 +24,15 @@ eval "$vars"
[ "${#hosts[*]}" -gt 0 ] || die "Vous devez spécifier l'hôte sur lequel se connecter"
[ ${#args[*]} -gt 0 ] && cmd="$(qvals "${args[@]}"); " || cmd=
cmd="$cmd$(<"$scriptdir/start-screen")"
cmd="$cmd$(<"$scriptdir/Sscreen")"
cmd="'${cmd//\'/\'\\\'\'}'"
for host in "${hosts[@]}"; do
"$ssh" \
"${options[@]}" -qt "$host" -- \
"[ -x /usr/local/nutools/start-screen ] && exec /usr/local/nutools/start-screen $(qvals "${args[@]}") || exit 123"
"[ -x /usr/local/nutools/Sscreen ] && exec /usr/local/nutools/Sscreen $(qvals "${args[@]}") || exit 123"
if [ $? -eq 123 ]; then
# pas de start-screen en face, le faire à la main
# pas de Sscreen en face, le faire à la main
${exec:+exec} \
"$ssh" "${options[@]}" -t "$host" -- \
/bin/bash -c "$cmd"