Advertisement
smiba

ponysay

Feb 21st, 2014
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 1.44 KB | None | 0 0
  1. #Made by Smiba, edit everything to your needs!
  2. #THIS IS THE WORST WAY TO GET THE LOAD.. i guess
  3. load5M=$(uptime |grep load | awk '{print $10}')
  4. load10M=$(uptime |grep load | awk '{print $11}')
  5. load15M=$(uptime |grep load | awk '{print $12}')
  6. users=$(uptime |grep load | awk '{print $6}')
  7. hdduse=$(df -h | grep /dev/simfs | awk '{print $3}' | sed 's/G/GB/g' | sed 's/T/TB/g' | sed 's/M/MB/g')
  8. hddspace=$(df -h | grep /dev/simfs | awk '{print $2}' | sed 's/G/GB/g' | sed 's/T/TB/g' | sed 's/M/MB/g')
  9. datarecv1=$(ifconfig | grep "RX bytes" | sed 's/(//g' | sed 's/)//g'  | awk '{print $3}' | sed -n 2p)
  10. datarecv2=$(ifconfig | grep "RX bytes" | sed 's/(//g' | sed 's/)//g'  | awk '{print $4}' | sed -n 2p)
  11. datasent1=$(ifconfig | grep "TX bytes" | sed 's/(//g' | sed 's/)//g'  | awk '{print $7}' | sed -n 2p)
  12. datasent2=$(ifconfig | grep "TX bytes" | sed 's/(//g' | sed 's/)//g'  | awk '{print $8}' | sed -n 2p)
  13. money=$(dogecoind getbalance | cut -f1 -d".")
  14. stats="Welcome $USER! Current Load: $load5M $load10M $load15M"
  15. if [ $users > 1 ]
  16.    then
  17.     areis="are"
  18.     userss="ponies"
  19.    else
  20.     areis="is"
  21.     userss="pony"
  22. fi
  23. stats2="There $areis currently $users $userss logged in"
  24. stats3="You have $hdduse in use of your $hddspace space"
  25. stats4="In your doge wallet there are $money bits"
  26. stats5="Since the last boot you've sent $datasent1$datasent2 and received $datarecv1$datarecv2"
  27. ponysay -fderpy $stats $'\n'$stats2 $'\n'$stats3 $'\n'$stats4 $'\n'$stats5
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement