Uptime: Add puppy linux support
This commit is contained in:
parent
daa56b0851
commit
44ace4e837
1 changed files with 10 additions and 1 deletions
9
fetch
9
fetch
|
@ -500,8 +500,17 @@ getkernel() {
|
||||||
getuptime () {
|
getuptime () {
|
||||||
case "$os" in
|
case "$os" in
|
||||||
"Linux")
|
"Linux")
|
||||||
|
case "$distro" in
|
||||||
|
"Puppy Linux"*)
|
||||||
|
uptime=$(uptime | awk -F ':[0-9]{2}+ |(, ){1}+' '{printf $2}')
|
||||||
|
uptime=${uptime/ / }
|
||||||
|
;;
|
||||||
|
|
||||||
|
*)
|
||||||
uptime="$(uptime -p)"
|
uptime="$(uptime -p)"
|
||||||
;;
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
|
||||||
"Mac OS X" | *"BSD")
|
"Mac OS X" | *"BSD")
|
||||||
# Get boot time in seconds
|
# Get boot time in seconds
|
||||||
|
|
Loading…
Reference in a new issue