summaryrefslogtreecommitdiff
path: root/xsh
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2016-10-21 22:51:57 +0200
committerJonas Smedegaard <dr@jones.dk>2016-10-21 22:51:57 +0200
commit94d2357c843d2defc7513fe37843e3c7e9f475ac (patch)
treeec7ee9d7d92e28f59d67ee767964ba24283f0da2 /xsh
parent03300237940e13c709fde5430e684f8e67df1782 (diff)
Tidy use of variable prg (remote flavor superfluous).
Diffstat (limited to 'xsh')
-rwxr-xr-xxsh14
1 files changed, 6 insertions, 8 deletions
diff --git a/xsh b/xsh
index d4e82af..8ceecb3 100755
--- a/xsh
+++ b/xsh
@@ -99,25 +99,23 @@ if [ -z "$prg_base" ]; then
prg_base='/bin/bash'
fi
-prg_local="$prg_base $prg_opts"
-prg_remote="bash --login -i -c \"$prg_base $prg_opts\""
-prg_remote_suu="echo -n 'Changing to root...: '; su $su_opts -c \"cd; $prg_base $prg_opts\""
+prg="$prg_base $prg_opts"
+prg_remote_suu="echo -n 'Changing to root...: '; su $su_opts -c \"cd; $prg\""
if [ "$SU" != 1 ]; then
if [ $HOST = "localhost" ]; then
- termwrapper $prg_local
+ termwrapper $prg
else
- termwrapper ssh $ssh_opts $HOST $prg_remote
+ termwrapper ssh $ssh_opts $HOST $prg
fi
else
if [ "$SUHACK" = 1 ]; then
-# termwrapper ssh $ssh_opts $HOST su $su_opts -c \"$prg_remote\"
- termwrapper ssh $ssh_opts $HOST $prg_remote
+ termwrapper ssh $ssh_opts $HOST $prg
else
if [ "$SUU" = 1 ]; then
termwrapper ssh $ssh_opts $HOST $prg_remote_suu
else
- termwrapper ssh $ssh_opts root@$HOST $prg_remote
+ termwrapper ssh $ssh_opts root@$HOST $prg
fi
fi
fi