home
/
code
/
khome.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Rename soft to sw
[khome.git]
/
home
/
lib
/
login_functions.sh
diff --git
a/home/lib/login_functions.sh
b/home/lib/login_functions.sh
index
9af3af1
..
9442579
100644
(file)
--- a/
home/lib/login_functions.sh
+++ b/
home/lib/login_functions.sh
@@
-427,6
+427,10
@@
flat_top_5() {
'
}
'
}
+internet_addr() {
+ curl --silent --show-error --max-time "${1:=1}" 'https://api.ipify.org' 2>&1
+}
+
status_batt() {
case "$(uname)" in
'Linux')
status_batt() {
case "$(uname)" in
'Linux')
@@
-535,7
+539,12
@@
status() {
echo
echo
+ local -r internet_addr=$(internet_addr 0.5)
+ local -r internet_ptr=$(host -W 1 "$internet_addr" | awk 'NR == 1 {print $NF}' )
+
echo 'net'
echo 'net'
+ echo "${indent_unit}internet"
+ echo "${indent_unit}${indent_unit}$internet_addr $internet_ptr"
echo "${indent_unit}if"
(ifconfig; iwconfig) 2> /dev/null \
| awk '
echo "${indent_unit}if"
(ifconfig; iwconfig) 2> /dev/null \
| awk '
This page took
0.030358 seconds
and
4
git commands to generate.