dotfiles/scripts/bin/ping-sweep.sh

9 lines
155 B
Bash
Executable file

#!/bin/bash
# ip=$1
echo "Scanning..."
for ip in $(seq 1 255); do
ping -c 1 -W 1 192.168.1.$ip | grep "64 bytes" | awk '{print $4}' | tr -d ':'
done