Skip to content

Commit

Permalink
Merge pull request #59 from ipinfo/uman/fixes
Browse files Browse the repository at this point in the history
Batch of changes for next release
  • Loading branch information
UmanShahzad authored Oct 21, 2021
2 parents f42b3e3 + 219f943 commit a657e1f
Show file tree
Hide file tree
Showing 247 changed files with 22,785 additions and 20,519 deletions.
41 changes: 29 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,13 +24,13 @@ brew install ipinfo-cli
OR to install the latest `amd64` version without automatic updates:

```bash
curl -Ls https://github.com/ipinfo/cli/releases/download/ipinfo-2.1.1/macos.sh | sh
curl -Ls https://github.com/ipinfo/cli/releases/download/ipinfo-2.2.0/macos.sh | sh
```

### Debian / Ubuntu (amd64)

```bash
curl -Ls https://github.com/ipinfo/cli/releases/download/ipinfo-2.1.1/deb.sh | sh
curl -Ls https://github.com/ipinfo/cli/releases/download/ipinfo-2.2.0/deb.sh | sh
```

### FreeBSD
Expand All @@ -42,8 +42,8 @@ cd /usr/ports/net/ipinfo-cli && make install clean
OR

```bash
curl -LO https://github.com/ipinfo/cli/releases/download/ipinfo-2.1.1/ipinfo_2.1.1.deb
sudo dpkg -i ipinfo_2.1.1.deb
curl -LO https://github.com/ipinfo/cli/releases/download/ipinfo-2.2.0/ipinfo_2.2.0.deb
sudo dpkg -i ipinfo_2.2.0.deb
```

### Using `go get`
Expand Down Expand Up @@ -97,12 +97,12 @@ After choosing a platform `PLAT` from above, run:

```bash
# for Windows, use ".zip" instead of ".tar.gz"
curl -LO https://github.com/ipinfo/cli/releases/download/ipinfo-2.1.1/ipinfo_2.1.1_${PLAT}.tar.gz
curl -LO https://github.com/ipinfo/cli/releases/download/ipinfo-2.2.0/ipinfo_2.2.0_${PLAT}.tar.gz
# OR
wget https://github.com/ipinfo/cli/releases/download/ipinfo-2.1.1/ipinfo_2.1.1_${PLAT}.tar.gz
wget https://github.com/ipinfo/cli/releases/download/ipinfo-2.2.0/ipinfo_2.2.0_${PLAT}.tar.gz

tar -xvf ipinfo_2.1.1_${PLAT}.tar.gz
mv ipinfo_2.1.1_${PLAT} /usr/local/bin/ipinfo
tar -xvf ipinfo_2.2.0_${PLAT}.tar.gz
mv ipinfo_2.2.0_${PLAT} /usr/local/bin/ipinfo
```

### Using `git`
Expand Down Expand Up @@ -148,9 +148,9 @@ Currently these subcommands are separately shipped:

| CLI | Version |
| ---------- | ------- |
| grepip | [1.1.0](https://github.com/ipinfo/cli/releases/tag/grepip-1.1.0) |
| cidr2range | [1.1.1](https://github.com/ipinfo/cli/releases/tag/cidr2range-1.1.1) |
| range2cidr | [1.1.0](https://github.com/ipinfo/cli/releases/tag/range2cidr-1.1.0) |
| grepip | [1.2.0](https://github.com/ipinfo/cli/releases/tag/grepip-1.2.0) |
| cidr2range | [1.2.0](https://github.com/ipinfo/cli/releases/tag/cidr2range-1.2.0) |
| range2cidr | [1.2.0](https://github.com/ipinfo/cli/releases/tag/range2cidr-1.2.0) |

## Quick Start

Expand Down Expand Up @@ -279,12 +279,29 @@ If you have an account, see our

All examples in this document use a token with all data enabled.

## Disabling Color Output
## Color Output

### Disabling Color Output

All our CLIs respect either the `--nocolor` flag or the
[`NO_COLOR`](https://no-color.org/) environment variable to disable color
output.

### Color on Windows

To enable color support for the Windows command prompt, run the following to
enable [`Console Virtual Terminal Sequences`](https://docs.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences).

```cmd
REG ADD HKCU\CONSOLE /f /v VirtualTerminalLevel /t REG_DWORD /d 1
```

You can disable this by running the following:

```cmd
REG DELETE HKCU\CONSOLE /f /v VirtualTerminalLevel
```

## Other IPinfo Tools

There are official IPinfo client libraries available for many languages including PHP, Python, Go, Java, Ruby, and many popular frameworks such as Django, Rails and Laravel. There are also many third party libraries and integrations available for our API.
Expand Down
2 changes: 1 addition & 1 deletion cidr2range/deb.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh

VSN=1.1.1
VSN=1.2.0

curl -LO https://github.com/ipinfo/cli/releases/download/cidr2range-${VSN}/cidr2range_${VSN}.deb
sudo dpkg -i cidr2range_${VSN}.deb
Expand Down
2 changes: 1 addition & 1 deletion cidr2range/dist/DEBIAN/control
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Source: cidr2range
Section: utils
Version: 1.1.1
Version: 1.2.0
Priority: optional
Maintainer: IPinfo <support@ipinfo.io>
Vcs-Git: https://github.com/ipinfo/cli
Expand Down
2 changes: 1 addition & 1 deletion cidr2range/macos.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh

VSN=1.1.1
VSN=1.2.0
PLAT=darwin_amd64

curl -LO https://github.com/ipinfo/cli/releases/download/cidr2range-${VSN}/cidr2range_${VSN}_${PLAT}.tar.gz
Expand Down
2 changes: 1 addition & 1 deletion cidr2range/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
)

var progBase = filepath.Base(os.Args[0])
var version = "1.1.1"
var version = "1.2.0"

func printHelp() {
fmt.Printf(
Expand Down
5 changes: 3 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,14 @@ require (
github.com/fatih/color v1.10.0
github.com/hashicorp/errwrap v1.1.0 // indirect
github.com/hashicorp/go-multierror v1.1.1
github.com/ipinfo/go/v2 v2.5.3
github.com/ipinfo/go/v2 v2.5.4
github.com/jszwec/csvutil v1.4.0
github.com/pkg/browser v0.0.0-20210115035449-ce105d075bb4
github.com/posener/script v1.1.5
github.com/spf13/pflag v1.0.5
github.com/stretchr/testify v1.7.0
golang.org/x/sys v0.0.0-20210420205809-ac73e9fd8988 // indirect
go.etcd.io/bbolt v1.3.6
golang.org/x/sys v0.0.0-20211004093028-2c5d950f24ef // indirect
golang.org/x/term v0.0.0-20201210144234-2321bbc49cbf
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
)
11 changes: 7 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brv
github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk=
github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo=
github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM=
github.com/ipinfo/go/v2 v2.5.3 h1:N8Ll2LDgzA7NTmHSaaQcFzmVw0RLyuSNDwX5cZRyA/o=
github.com/ipinfo/go/v2 v2.5.3/go.mod h1:2MrJVdUamrTc5VdC7yrbKGbsOOxMtdUpnpBJmtZgA8o=
github.com/ipinfo/go/v2 v2.5.4 h1:bfoNG2FJ+/SNwdTd/LlN8AJ0BrJf/W7Ko4FNGwv9Ohk=
github.com/ipinfo/go/v2 v2.5.4/go.mod h1:2MrJVdUamrTc5VdC7yrbKGbsOOxMtdUpnpBJmtZgA8o=
github.com/jszwec/csvutil v1.4.0 h1:ro7gZN8PRsyNUEX8qE/eYPE5/kffEXMs+4eRcOd1oUk=
github.com/jszwec/csvutil v1.4.0/go.mod h1:Rpu7Uu9giO9subDyMCIQfHVDuLrcaC36UA4YcJjGBkg=
github.com/mattn/go-colorable v0.1.8 h1:c1ghPdyEDarC70ftn0y+A/Ee++9zz8ljHG1b13eJ0s8=
Expand All @@ -32,13 +32,16 @@ github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/stretchr/testify v1.7.0 h1:nwc3DEeHmmLAfoZucVR881uASk0Mfjw8xYJ99tb5CcY=
github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
go.etcd.io/bbolt v1.3.6 h1:/ecaJf0sk1l4l6V4awd65v2C3ILy7MSj+s/x1ADCIMU=
go.etcd.io/bbolt v1.3.6/go.mod h1:qXsaaIqmgQH0T+OPdb99Bf+PKfBBQVAdyD6TY9G8XM4=
golang.org/x/sync v0.0.0-20201207232520-09787c993a3a h1:DcqTD9SDLc+1P/r1EmRBwnVsrOwW+kk2vWf9n+1sGhs=
golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210420205809-ac73e9fd8988 h1:EjgCl+fVlIaPJSori0ikSz3uV0DOHKWOJFpv1sAAhBM=
golang.org/x/sys v0.0.0-20210420205809-ac73e9fd8988/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20211004093028-2c5d950f24ef h1:fPxZ3Umkct3LZ8gK9nbk+DWDJ9fstZa2grBn+lWVKPs=
golang.org/x/sys v0.0.0-20211004093028-2c5d950f24ef/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/term v0.0.0-20201210144234-2321bbc49cbf h1:MZ2shdL+ZM/XzY3ZGOnh4Nlpnxz5GSOhOmtHo3iPU6M=
golang.org/x/term v0.0.0-20201210144234-2321bbc49cbf/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
Expand Down
2 changes: 1 addition & 1 deletion grepip/deb.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh

VSN=1.1.0
VSN=1.2.0

curl -LO https://github.com/ipinfo/cli/releases/download/grepip-${VSN}/grepip_${VSN}.deb
sudo dpkg -i grepip_${VSN}.deb
Expand Down
2 changes: 1 addition & 1 deletion grepip/dist/DEBIAN/control
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Source: grepip
Section: utils
Version: 1.1.0
Version: 1.2.0
Priority: optional
Maintainer: IPinfo <support@ipinfo.io>
Vcs-Git: https://github.com/ipinfo/cli
Expand Down
2 changes: 1 addition & 1 deletion grepip/macos.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/sh

VSN=1.1.0
VSN=1.2.0
PLAT=darwin_amd64

curl -LO https://github.com/ipinfo/cli/releases/download/grepip-${VSN}/grepip_${VSN}_${PLAT}.tar.gz
Expand Down
2 changes: 1 addition & 1 deletion grepip/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
)

var progBase = filepath.Base(os.Args[0])
var version = "1.1.0"
var version = "1.2.0"

func printHelp() {
fmt.Printf(
Expand Down
Loading

0 comments on commit a657e1f

Please sign in to comment.