ipinfo-2.0.0
-
Two new subcommands,
cidr2range
&range2cidr
, are available.They convert between CIDRs and IP ranges, e.g.
1.1.1.0/30
gives the range
1.1.1.0-1.1.1.3
and vice versa.See
ipinfo cidr2range --help
andipinfo range2cidr --help
for details. -
Shell auto-completion is now supported for at least
bash
,zsh
andfish
.Other shells may also be supported if those shells support auto-completion
via using theCOMP_LINE
environment variable.Type
ipinfo completion --help
for more details. -
All subcommands which accepted IPs/IP ranges/CIDRs/files as input can now
accept all of these simultaneously.An example query showing what is now possible:
# stdin: ../tmp/tmp2.txt # files: ../tmp/tmp3.txt # range 1: 1.1.1.1,1.1.1.4 # range 2: 8.8.8.1-8.8.8.3 # ip: 123.123.123.123 # cidr: 3.3.3.0/31 cat ../tmp/tmp2.txt | ipinfo bulk 1.1.1.1,1.1.1.4 3.3.3.0/31 ../tmp/tmp3.txt 123.123.123.123 8.8.8.1-8.8.8.3
The
--help
messages for each relevant subcommand gives details.
BREAKING CHANGE
IP ranges must now be specified using ,
or -
as the delimiter, rather than
the space character
. For example, 1.1.1.0-1.1.1.4
or 1.1.1.0,1.1.1.4
are allowed, but 1.1.1.0 1.1.1.4
is now interpreted as 2 separate IPs rather
than as a range like before.