Advertisement
tonyrulez

etherwake

Mar 25th, 2018
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.72 KB | None | 0 0
  1. #!/bin/bash
  2. echo "Wake-on-lan opciók:"
  3. PS3='Ébresztendő gép sorszáma:'
  4. options=("PC1" "PC2" "PC3" "Manuális megadás" "Kilépés")
  5. select opt in "${options[@]}"
  6. do
  7.     case $opt in
  8.         "PC1")
  9.             etherwake -D -i wlp3s0 00:30:D5:CD:6F:59
  10.             ;;
  11.         "PC2")
  12.             etherwake -D -i wlp3s0 D4:3D:DE:C0:13:24
  13.             ;;
  14.         "PC3")
  15.             etherwake -D -i wlp3s0 98:DE:D0:D2:69:F4
  16.             ;;
  17.         "Manuális megadás")
  18.             read -p "Add meg a MAC címet a következő alakban: xx:yy:zz:11:22:33 -> " arg1
  19.             etherwake -D -i wlp3s0 $arg1
  20.             ;;
  21.         "Kilépés")
  22.             break
  23.             ;;
  24.         *) echo invalid option;;
  25.     esac
  26. done
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement