Browse Source

show my external on terminal open /A

Anton 2 weeks ago
parent
commit
40b3e3210f
1 changed files with 4 additions and 0 deletions
  1. 4 0
      console-terminal/zshrc-anton.sh

+ 4 - 0
console-terminal/zshrc-anton.sh

@@ -1,7 +1,11 @@
 #
 # 2024-05-20  * changed time and date position /A
+# 2025-02-14  + show external IP, check for DHCP, DNS resolution and routing /A
+# 2025-03-11  + Reverse resolve DNS record /A 
 #
 # add to ~/.zshrc
 # "source /Users/Shared/dox-prj/repos/gogs.2dz.fi/gogs.2dz.fi.InstallAndUse.Daily/console-terminal/zshrc-anton.sh"
 
 PROMPT="[20%D %*] @%m %~ $ "
+ip4=$(curl -s https://myip.2dz.fi)
+echo "My external IP is: ${ip4} = $(dig -x ${ip4} +short)"