[ale] Adding 'uptime' to python sig

Trey Sizemore trey at fastmail.fm
Sat Feb 14 18:21:44 EST 2004

I have a python script that I use currently in my sig and wanted to add
a line to show the output of the 'uptime' command.

Would someone be able to tell me how to do this?  Such as add it as a
line under the current sig?  Here's the script I'm using:


# change this to point to your file of quotes
aff_file = "/home/trey/quotes.txt"

import string, random

# hack this at will
print "-- <br>"
print "Cheers,<br>"
print "Trey<br>"
print "---<br>"
print "<br>"

# cryptic python stuff which pulls a line from a text file
# at random
affs = open(aff_file,"r")
affs = affs.readlines()
aff = affs[int(random.random() * len(affs))].split("\n")[0]

# print the randomly selected line
print aff

men fear thought as they fear nothing else on earth
--more than ruin
--more even than death.
thought is subversive and revolutionary,
destructive and terrible,
thought is merciless
to privilege,
established institutions, and comfortable habit.

thought looks into the pit of hell and is not afraid.
thought is great and swift and free,
the light of the world, and the chief glory of man.
--bertrand russell

More information about the Ale mailing list