Advertisement
Guest User

Untitled

a guest
May 29th, 2015
226
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.19 KB | None | 0 0
  1. hostup() {
  2. if (( $# != 1 )); then
  3. echo "Usage: hostup HOSTNAME"
  4. else
  5. until $(which ping) -W1 -c1 ${1} > /dev/null; do sleep 5; done && $(which say) "${1} is up"
  6. fi
  7. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement