View on GitHub

HomeSetup

HomeSetup simplifies terminal customization by offering seamless cloud integration for dotfiles, packages, and configurations, enhancing productivity and command line experiences without complex frameworks.

Download this project as a .zip file Download this project as a tar.gz file

HomeSetup Developer Handbook

Applications handbook

Table of contents

Check-IP

usage:  [Options] <ip_address>

    Options:
      -q | --quiet  : Silent mode. Do not check for IP details.
      -i | --info   : Fetch additional information from the web.

Purpose

Validate and check information about a provided IP address.

Returns

0 if the IP is valid; non-zero otherwise.

Parameters

Examples:

check-ip.bash 192.168.0.10

Output

Valid IP: 192.168.0.10, Class: C, Scope: Private

check-ip.bash -i 192.158.100.10

Output

Valid IP: 192.158.100.10, Class: C, Scope: Public
{
    "status": "success",
    "country": "United States",
    "countryCode": "US",
    "region": "OR",
    "regionName": "Oregon",
    "city": "Beaverton",
    "zip": "97077",
    "lat": 45.4991,
    "lon": -122.823,
    "timezone": "America/Los_Angeles",
    "isp": "Tektronix",
    "org": "Tektronix, Inc",
    "as": "",
    "query": "192.158.100.10"
}