Mercurial > hg > anonet-resdb
comparison scripts/cidr2hex @ 1193:2f57d4d36759 draft
add muh nameserver, some script tweaks
author | cathugger <cathugger@cock.li> |
---|---|
date | Fri, 10 Mar 2017 03:30:16 +0000 |
parents | 31e3b4edf502 |
children |
comparison
equal
deleted
inserted
replaced
1192:a0de6dd1652e | 1193:2f57d4d36759 |
---|---|
2 | 2 |
3 if [ x"$1" = x ]; then | 3 if [ x"$1" = x ]; then |
4 echo "Usage: $0 <cidr>" >&2; exit 255 | 4 echo "Usage: $0 <cidr>" >&2; exit 255 |
5 fi | 5 fi |
6 | 6 |
7 ./scripts/ip2hex "$(./scripts/cidr2ip "$1")" | 7 dn=$(dirname "$0") |
8 ip=$("$dn"/cidr2ip "$1") || exit 1 | |
9 "$dn"/ip2hex "$ip" |