Skip to content

Latest commit

 

History

History
185 lines (133 loc) · 3.91 KB

README.textile

File metadata and controls

185 lines (133 loc) · 3.91 KB

Installing

Current version: 0.7

Note: this step can be skipped if you’re using the gem.

Copy files to a directory in your PATH. I recommend /usr/local/bin. This will make the commands accessible by just typing the name of it. Be sure to give them permissions (755 should be fine).

Uptime

Displays your system’s uptime.

  uptime | awk '{print "Uptime : " $3 " " $4 " " $5 }' | sed -e 's/.$//g'
  Uptime : 25 days, 8:28

Network Info

Internal IP

Displays your Wifi or Ethernet IP. Also see IP script

  ifconfig en1 | grep "inet " | awk '{print $2}'
  192.168.1.2

External IP

Displays your external IP

  curl -s www.whatismyip.com/automation/n09230945.asp | awk {'print "External : " $1'}
  External: 72.45.123.12

Calendar

  cal | sed "s/^/ /;s/$/ /;s/ $(date +%e) / $(date +%e | sed 's/./#/g') /"
      July 2009 
  Su Mo Tu We Th Fr Sa 
            1  2  3  4 
   5  6  7  8  9 ## 11 
  12 13 14 15 16 17 18 
  19 20 21 22 23 24 25 
  26 27 28 29 30 31 

Memory Usage

Prints out total Memory Usage

  top -l 1 | awk '/PhysMem/ {print "Used: " $8}'
  top -l 1 | awk '/PhysMem/ {print "Inactive:  " $6+$10"M"}'


Used: 1769M
Inactive: 688M

CPU (horizontal)

  top -l 1| awk '/CPU usage/ {print $6, $7, $8, $9, $10, $11, $12, $13}'


CPU usage: 22.22% user, 71.11% sys, 6.67% idle

CPU (vertical)

  echo CPU usage
  top -l 1| awk '/CPU usage/ {print $8, $9}'
  top -l 1| awk '/CPU usage/ {print $10, $11}'
  top -l 1| awk '/CPU usage/ {print $12, $13}'


CPU usage
22.22% user,
71.11% sys,
6.67% idle

Weather

Yweather is recommended for this. Because Yweather creates a local copy of the weather from Yahoo, it needs write permissions. Please place the script somewhere it can do this (ie, /Users/nic/bin/yweather.pl)

Yweather is not included in this package, but you can download it from Google Code. Please read the help file when using this script. I did not write it and will not provide support for it.

Current Temperature

/Users/nic/bin/yweather.pl -ft1

81

Current Conditions


/Users/nic/bin/yweather.pl -ft1

Partly Cloudy

Unread Gmail

This script requires a username and password. You must edit it before use. Replace USERNAME & PASSWORD with your username and password.
Credits to Greg Newman for this script

gmail

3 Unread

IP Address

ipaddress


Ethernet : INACTIVE
Airport : 161.45.27.132

Remember the Milk

More info for this script. There have been instances where users have needed Xcode for Perl to compile modules correctly.

Install

sudo cpan install WebService::RTMAgent

Setup

rtm --authorise

Copy and paste the link into your browser and authorize it. Use rtm --help for more info

Usage

todo
  - Overdue - 
  Turn in Fall Net tech and LTL list to payroll
  Format computers in Smith for Cummings

  - Next 7 Days - 
  Turn in Payroll

  - Other - 
  resnet payroll system
  Internship Journal
  Buy 4 quarts oil

Current Wifi Network

airport

Network: DD-WRT

Timezones

A few examples are provided in the tzones file. You will need to edit this file to add more timezones.

tzones


Hawaii : 04:04 PM Fri
UK : 02:04 AM Sat
London : 03:04 AM Sat
Sweden : 04:04 AM Sat
Germany : 04:04 AM Sat
Maylasia : 10:04 AM Sat

Network Traffic

Credits to Chris Helming

network


In: 598 kb/s
Out: 13 kb/s