Cobra is a library for creating powerful modern CLI applications. This project is a CLI application built using Cobra.
Clone this project
https://github.com/mbakin/iptracker.git
Open project
cd iptracker
Using Cobra is easy. First, use go get
to install the latest version
of the library.
go get -u github.com/spf13/cobra@latest
Next, include Cobra in your application:
import "github.com/spf13/cobra"
.iptracker
├── cmd
│ ├── root.go
│ ├── trace.go
│ ├── version.go
├── go.mod
├── go.sum
├── main.go
IP Info Model:
type Ip struct {
Ip string `json:"ip"`
City string `json:"city"`
Region string `json:"region"`
Country string `json:"country"`
Loc string `json:"loc"`
Timezone string `json:"timezone"`
}
The following commands are executed using the iptracker
command
Run this command to get the address information of the IP address iptracker trace X.X.X.X