Commit 05171be3 authored by Muhammad Herdiansyah's avatar Muhammad Herdiansyah

Local IP [IRIX]: Added initial support

parent a3af0a3f
...@@ -1936,7 +1936,7 @@ get_battery() { ...@@ -1936,7 +1936,7 @@ get_battery() {
get_local_ip() { get_local_ip() {
case "$os" in case "$os" in
"Linux" | "BSD" | "Solaris" | "AIX") "Linux" | "BSD" | "Solaris" | "AIX" | "IRIX")
local_ip="$(ip route get 1 | awk -F'src' '{print $2; exit}')" local_ip="$(ip route get 1 | awk -F'src' '{print $2; exit}')"
local_ip="${local_ip/uid*}" local_ip="${local_ip/uid*}"
[[ -z "$local_ip" ]] && local_ip="$(ifconfig -a | awk '/broadcast/ {print $2; exit}')" [[ -z "$local_ip" ]] && local_ip="$(ifconfig -a | awk '/broadcast/ {print $2; exit}')"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment