aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--pars.sh12
1 files changed, 10 insertions, 2 deletions
diff --git a/pars.sh b/pars.sh
index 7af98b8..d033db7 100644
--- a/pars.sh
+++ b/pars.sh
@@ -62,11 +62,19 @@ parssh () {
_parssh.usage
return $?
;;
+ -)
+ shift
+ break
+ ;;
esac
shift
done
[[ -z "$_parssh_servers" ]] && {
+ [[ -t 0 ]] && {
+ echo "No list of servers provided."
+ return 79
+ }
exec 9<&0
} || {
exec 9<"$_parssh_servers"
@@ -88,11 +96,11 @@ parssh () {
}
_parssh.ssh () {
- ssh -no StrictHostKeyChecking=no $host "$@"
+ ssh -no StrictHostKeyChecking=no $host -- "$@"
}
_parssh.ssh_rinput () {
- ssh -To StrictHostKeyChecking=no $host "$@" < "$_parssh_rinput"
+ ssh -To StrictHostKeyChecking=no $host -- "$@" < "$_parssh_rinput"
}
_parssh.host_prepend ()