We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 59e0207 commit 622c423Copy full SHA for 622c423
system/.alias
@@ -57,8 +57,8 @@ alias ncuw="npm-check-updates --interactive --root --workspaces"
57
58
# Network
59
60
-alias ip="curl -s ipinfo.io | jq -r '.ip'"
61
-alias ipl="ifconfig | grep -Eo 'inet (addr:)?([0-9]*\.){3}[0-9]*' | grep -Eo '([0-9]*\.){3}[0-9]*' | grep -v '127.0.0.1'"
+alias ipp="dig +short myip.opendns.com @resolver1.opendns.com"
+alias ipl="ip route get 1.1.1.1 2>/dev/null | awk 'NR==1{print \$7}'"
62
63
# Miscellaneous
64
system/.alias.macos
@@ -2,6 +2,10 @@
2
3
alias cpwd="pwd|tr -d '\n'|pbcopy"
4
5
+# Get local IP address
6
+
7
+alias ipl="ifconfig | grep 'inet ' | grep -v 127.0.0.1 | awk '{print \$2}' | head -1"
8
9
# Application shortcuts
10
11
alias gg="$VISUAL_GIT"
0 commit comments