Search Members Help

» Welcome Guest
[ Log In :: Register ]

Mini-ITX Boards Sale, Fanless BareBones Mini-ITX, Bootable 1G DSL USBs, 533MHz Fanless PC <-- SALE $200 each!
Get The Official Damn Small Linux Book. DSL Market , Great VPS hosting provided by Tektonic
Pages: (7) </ 1 2 [3] 4 5 6 7 >/

[ Track this topic :: Email this topic :: Print this topic ]

reply to topic new topic new poll
Topic: Looking for World Time Application, Anybody know of a good one?< Next Oldest | Next Newest >
mikshaw Offline





Group: Members
Posts: 4856
Joined: July 2004
Posted: Sep. 24 2007,14:01 QUOTE

I assume you would be allowed to format the outpoot slightly if it's causing display troubles. The timeanddate people would have to be mightily spitely to have a problem with that. Try just inserting a newline:
Code Sample
print "Getting time from\n $URL\n"; # legal

The information remains unchanged, but your display is not messed up.


--------------
http://www.tldp.org/LDP/intro-linux/html/index.html
Back to top
Profile PM WEB 
WDef Offline





Group: Members
Posts: 798
Joined: Sep. 2005
Posted: Sep. 24 2007,14:04 QUOTE

Juanito: Did you notice I've added a width control switch to citytime.pl with some other stuff?

Eg set 20 chars output width before 5-char time is displayed (so total width is 25 chars):

Code Sample
citytime.pl -w 20 Tokyo London


Also, the data is now justified uniformly. You have Tokyo printed out twice; I'm doing (eg):

Code Sample
${color red}$hr
${color grey}$color${execi 180 ~/.citytime.pl 'San Francisco' Sydney Tokyo}


Mikshaw:  I've shortened the message to the minimum:

Quote
timeanddate.com:


Quote
a site that didn't require the url to be stated.


Another source might be nice - some of these have additional info eg weather.

I'm only guessing it is necessary to flag the source to the user. It is not clear to me and I'm not a lawyer.  There's no EULA on the web site that I can find, and I am wondering if they could enforce rights over "the time", public domain data if ever there was any.  Their notice is not in plain view - it is buried in the html source. And just how do they prevent people from accessing the web page data using whatever technology they feel like?  Tell them it's "forbidden?"
Back to top
Profile PM 
Juanito Offline





Group: Members
Posts: 1601
Joined: Sep. 2005
Posted: Sep. 24 2007,15:19 QUOTE

One way around it could be to comment out the url in citytime.pl and use something like this in torsmorc:
Code Sample
${color red}$hr
${color grey}Time by www.timeanddate.com
${color grey}$color${execi 180 ~/.citytime.pl Singapore}
${color grey}$color${execi 180 ~/.citytime.pl Paris}
${color grey}$color${execi 180 ~/.citytime.pl London}
${color grey}$color${execi 180 ~/.citytime.pl Seattle}

On a minor level, aesthetically it might be better to put the time first (with a leading zero if required) or align the time output, but that's just splitting hairs.
Back to top
Profile PM 
WDef Offline





Group: Members
Posts: 798
Joined: Sep. 2005
Posted: Sep. 24 2007,15:35 QUOTE

You need to try the 'latest version' - I updated it already to add leading zeroes and to justify columns, and to check args and options.

For me, torsmo is looking very good without multiple calls to citytime.pl  (means multiple downloads).  No need to comment out the (shortened) message.

Also, have changed the source to www.whatisthetime.com , which does not seem to have evil notices anywhere that I can find, in case anyone is worried.  The same regex worked on their list.

Feedback about new server speed of download etc?
Back to top
Profile PM 
Juanito Offline





Group: Members
Posts: 1601
Joined: Sep. 2005
Posted: Sep. 24 2007,17:15 QUOTE

Quote
You need to try the 'latest version'

- We must have been typing the last posts at the same time. This seems to do the trick now:
Code Sample
${color red}$hr
${color grey}$color${execi 180 ~/.citytime.pl Singapore Paris London 'San Francisco'}

About the only thing I notice (and it was the same for both url's) is that torsmo is very slow to start now and blinks occasionally (but I did see something about double-buffering somewhere).

Thanks - learnt something more there, now I'm going to try at adding some cpu info, etc to the display.
Back to top
Profile PM 
30 replies since Sep. 23 2007,11:40 < Next Oldest | Next Newest >

[ Track this topic :: Email this topic :: Print this topic ]

Pages: (7) </ 1 2 [3] 4 5 6 7 >/
reply to topic new topic new poll
Quick Reply: Looking for World Time Application

Do you wish to enable your signature for this post?
Do you wish to enable emoticons for this post?
Track this topic
View All Emoticons
View iB Code