mirror of
https://gh.wpcy.net/https://github.com/CaptainCore/captaincore.git
synced 2026-04-23 01:50:05 +08:00
20 lines
459 B
Bash
Executable file
20 lines
459 B
Bash
Executable file
#!/bin/zsh
|
|
|
|
#
|
|
# Bulk nameserver output
|
|
#
|
|
# captaincore dns nameservers [<domain>...]
|
|
#
|
|
# Example output
|
|
# website1.com nameserver1.com, nameserver2.com, nameserver3.com
|
|
# website2.com nameserver1.com, nameserver2.com, nameserver3.com
|
|
#
|
|
|
|
lightblue='\033[0;34m'
|
|
nocolor='\033[0m'
|
|
|
|
for var in "$@"; do
|
|
dnslookup=`dig $var NS +short`
|
|
dnslookup_sorted=(`echo $dnslookup | sort -n`)
|
|
echo -e "${lightblue}${var}${nocolor} - ${dnslookup_sorted[@]}"
|
|
done
|