A shell script that returns you your ip address and its geolocation.
$ cd ~
$ git clone https://github.com/trozler/whereAmI.git
I recommend adding the following alias to your bashprofile (~/.bash_profile
).
~/.bashrc
should also work.
$ echo -e '\nalias myip="/bin/bash ~/whereamI/findmepls.sh"' >> ~/.bash_profile
$ source ~/.bash_profile
If you created the alias:
$ myip
88.2.154.243 - Balearic Islands, Spain.
Otherwise:
$ /bin/bash ~/whereAmI/findmepls.sh
88.2.154.243 - Balearic Islands, Spain.
This script utilises a free api which allows for 3 requests per second.
Lastly, if you are not connected to the internet, then well, you must be somewhere off the shoulder of Orion.