add start to dynmotd
This commit is contained in:
parent
613a6029fe
commit
507b0a35ae
34
files/etc/motd
Normal file
34
files/etc/motd
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
RED=$(tput setaf 1)
|
||||||
|
GREEN=$(tput setaf 2)
|
||||||
|
YELLOW=$(tput setaf 3)
|
||||||
|
BLUE=$(tput setaf 4)
|
||||||
|
MAGENTA=$(tput setaf 5)
|
||||||
|
CYAN=$(tput setaf 6)
|
||||||
|
WHITE=$(tput setaf 7)
|
||||||
|
RESET=$(tput sgr0)
|
||||||
|
BOLD=$(tput bold)
|
||||||
|
|
||||||
|
uptime=`cat /proc/uptime | cut -f1 -d.`
|
||||||
|
upDays=$((uptime/60/60/24))
|
||||||
|
upHours=$((uptime/60/60%24))
|
||||||
|
upMins=$((uptime/60%60))
|
||||||
|
upSecs=$((uptime%60))
|
||||||
|
|
||||||
|
echo -e "${GREEN}
|
||||||
|
.:^~~~~^:. ${RESET}$(hostname)${GREEN}
|
||||||
|
.^!?JJJJJJJJJJ?!^. -------------------------------------------------
|
||||||
|
~?JJJJJJJJJJJJJJJJ?~ ${RESET}$(cat /etc/redhat-release)${GREEN}
|
||||||
|
:?JJJJJJJJJJJJJJJJJJJJ?: ${RESET}Uptime: ${BOLD}$upDays days $upHours hours $upMins minutes $upSecs seconds${GREEN}
|
||||||
|
.?JJJJJJJJJJJJJJ7?JJJJJJ?.
|
||||||
|
!JJJJJJJJJJJJJ7: ^?JJJJJ!
|
||||||
|
7JJJJJJJJJJJ!: ^7JJJ7
|
||||||
|
!JJJJJJJJJ!. :. :7J!
|
||||||
|
.?JJJJJ?~. :7JJ!. :.
|
||||||
|
:?JJ?~. ^7JJJJJJ!:
|
||||||
|
.~~ ^?JJJJJJJJY?:
|
||||||
|
^?YYJJJJJJ?!^.
|
||||||
|
.:^~~~~^:.
|
||||||
|
${RESET}
|
||||||
|
"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user