This commit is contained in:
Anthony Cicchetti 2020-10-19 09:53:53 -04:00
parent e3eba24f7e
commit a738e2119e

View file

@ -11,13 +11,11 @@ function ssh-del-name {
local host_name
set -u
host_name=${1}
sed -n "/${host_name}/p" ~/.ssh/known_hosts
printf "Delete the above? (y/n)"
read -q resp
if [[ "y" == "${resp}" ]]; then
sed -n -i.bak "/${host_name}/d" ~/.ssh/known_hosts
sed -i.bak "/${host_name}/d" ~/.ssh/known_hosts
fi
set +u