mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2025-01-10 17:38:13 +08:00
38 lines
605 B
Awk
38 lines
605 B
Awk
BEGIN {
|
|
print ""
|
|
print "D('" domain ", FILL_IN_REGISTRAR, DnsProvider(FILL_IN_PROVIDER),"
|
|
}
|
|
|
|
END {
|
|
print "END)"
|
|
}
|
|
|
|
$3 == "SOA" || $4 == "SOA" {
|
|
next
|
|
}
|
|
|
|
$3 == "A" || $3 == "CNAME" || $3 == "NS" {
|
|
name = $1
|
|
if (name == domain".") { name = "@" }
|
|
print "\t" $3 "('" name "', '" $4 "')," ;
|
|
next
|
|
}
|
|
|
|
$3 == "MX" {
|
|
name = $1
|
|
if (name == domain".") { name = "@" }
|
|
print "\tMX('" name "', " $4 ", '" $5 "')," ;
|
|
next
|
|
}
|
|
|
|
$3 == "TXT" {
|
|
name = $1
|
|
if (name == domain".") { name = "@" }
|
|
$1 = "";
|
|
$2 = "";
|
|
$3 = "";
|
|
print "\tTXT('" name "', " $0 ")," ;
|
|
next
|
|
}
|
|
|
|
{ print "UNKNOWN:" $0 }
|