Added rsh function for ips file
This commit is contained in:
parent
57331ef47b
commit
3faf271337
@ -37,6 +37,15 @@ alias ll='ls -AglhF'
|
||||
alias la='ls -A'
|
||||
alias l='ls -CF'
|
||||
alias logout='sudo pkill -u $USER'
|
||||
function rsh(){
|
||||
ADDR=$(cat /home/stonewareslord/syncthing/shared/ips | sed -rne "s/^$1: //p")
|
||||
if [ -z $ADDR ] ; then
|
||||
echo "Hostname not found"
|
||||
return 1
|
||||
fi
|
||||
echo "SSH to $ADDR..."
|
||||
tsh $ADDR
|
||||
}
|
||||
function fixsh(){
|
||||
sed -i -e $1"d" ~/.ssh/known_hosts
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user