Skip to content

Instantly share code, notes, and snippets.

@emilstahl
Created Apr 8, 2015
Embed
What would you like to do?
terminal ips
# IP addresses
alias ip="dig +short myip.opendns.com @resolver1.opendns.com"
alias localip="ipconfig getifaddr en0"
alias ips="ifconfig -a | grep -o 'inet6\? \(\([0-9]\+\.[0-9]\+\.[0-9]\+\.[0-9]\+\)\|[a-fA-F0-9:]\+\)' | sed -e 's/inet6* //'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment