Skip to content

Commit

Permalink
Add usage instructions to the README
Browse files Browse the repository at this point in the history
  • Loading branch information
Calinou committed Apr 30, 2018
1 parent 98e5624 commit 6b0b47d
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 1 deletion.
52 changes: 52 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,58 @@ the country and Internet service provider).

## Usage

### Examples

#### Looking up your current IP address

```
$ ipinfo
IP address ... # Results will be based on your IP address
Hostname ...
City ...
Region ...
Country ...
Location ...
Postal code ...
Organization ...
```

#### Looking up an arbitrary IP address

```
$ ipinfo 8.8.8.8
IP address 8.8.8.8
Hostname google-public-dns-a.google.com
City Mountain View
Region California
Country US
Location 37.3860,-122.0840
Postal code 94035
Organization AS15169 Google LLC
```

### Reference

```
NAME:
ipinfo - Retrieve information about IP addresses
USAGE:
ipinfo [IP address]
VERSION:
0.1.0
COMMANDS:
help, h Shows a list of commands or help for one command
GLOBAL OPTIONS:
--help, -h show help
--version, -v print the version
```

## License

Copyright © 2018 Hugo Locurcio and contributors
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ type IpInfo struct {
func main() {
app := cli.NewApp()
app.Name = "ipinfo"
app.Version = "0.0.1"
app.Version = "0.1.0"
app.Usage = "Retrieve information about IP addresses"
app.UsageText = app.Name + " [IP address]"

Expand Down

0 comments on commit 6b0b47d

Please sign in to comment.