Adium

Profile: Woei Shyang (woeishyang)

Website http://woeishyang.com
Comment Count 2 comments
0 xtras

Latest comments

# by woeishyang on 09/13/07 at 21:06:34

Hmm...

Oh well, seems like the post got truncated.

Simple change all instances of

open(timefile,"w").write(Time.now.to_s)

to

open(timefile,"w").write(Time.now.strftime("%a %b %d %H:%M:%S %Y"))

and replace the lines

timefile = "/tmp/TwitterAdium.time"
twitterfile = "/tmp/TwitterAdium.twitter"

with
timefile = "/tmp/.#{ENV["LOGNAME"]}_TwitterAdium.time"
twitterfile = "/tmp/.#{ENV["LOGNAME"]}_TwitterAdium.twitter"

Works great now :)

# by woeishyang on 09/13/07 at 21:04:02

I have made a small fix that enables South Australian users (who also have the same time zone as CST) to use this script properly. Also added a tiny modification so each user on a multi user system has their temp files named differently.

Simply replace the contents of twitter.rb with the following:

#TwitterAdium
#Jesse Newland
#jnewland@gmail.com

require 'yaml'
require 'rexml/document'
require 'fileutils'
require 'net/http'
require 'timeout'
require 'Time'

#handle first run config file creation
begin
configfile = open(ENV["HOME"]+"/.twitter")
config = YAML::load configfile
rescue
begin
Fileutils.mv(ENV["HOME"]+"/.twitterc",ENV["HOME"]+"/.twitter")
rescue
template =