Browse Source

Added quiet option for grep

pull/6/head
Giovanni Torres 9 years ago
parent
commit
b3799bd910
  1. 2
      kvm-install-vm

2
kvm-install-vm

@ -203,7 +203,7 @@ function get_pkg_mgr ()
function check_delete_known_host ()
{
echo "[$(date +%r)]----> Checking for ${IP} in known_hosts file..."
grep ${IP} ${HOME}/.ssh/known_hosts \
grep -q ${IP} ${HOME}/.ssh/known_hosts \
&& echo "[$(date +%r)]----> Found entry for ${IP}. Removing..." \
&& sed --in-place "/^${IP}/d" ~/.ssh/known_hosts \
|| echo "[$(date +%r)]----> No entries found for ${IP}..."

Loading…
Cancel
Save