phong

package module
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 11, 2019 License: MIT Imports: 6 Imported by: 0

README

phong

Build Status

CLI tool to inform the region where a phone number is from.

Installation

To install, use go get:

$ go get github.com/ryoma123/phong/...

Usage

Pass one phone number as an argument.

$ phong 0363849000
🇯🇵  Japan -- Tokyo

$ phong 092-651-1111
🇯🇵  Japan -- Fukuoka, Fukuoka

Default is Japan. Other countries use country calling code or specify the country code using the region option.

$ phong +41446681800
🇨🇭  Switzerland -- Zurich

$ phong -r US 6502530000
🇺🇸  United States of America -- Mountain View, CA

Commands

help, h

Display a help message.

list, l

Show the list of country code (alpha-2).

$ phong l
Display all 249 lines? (Y or n)
🇦🇲  AM -- Armenia
🇨🇦  CA -- Canada
🇳🇿  NZ -- New Zealand
...

Options

--region , -r

Pass phone number region. (default: JP)

--version, -v

Display the version of phong.

License

MIT

Author

ryoma123

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Commands = []*cli.Command{
	commandList,
}

Commands variable

View Source
var Flags = []cli.Flag{
	flagName,
}

Flags variable

Functions

func RunCLI

func RunCLI(c *cli.Context) error

RunCLI runs as cli

Types

type Phong

type Phong struct {
	// contains filtered or unexported fields
}

Phong struct

func New

func New(n string) *Phong

New returns Phong

Directories

Path Synopsis
cmd

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL