First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Cameron La » Fri, 24 Oct 2008 20:11:42


> QOTW: "... in addition to being easier to unit-test than thread[ing
.
.
.
My apologies, folks; through an all-too-typical sequence of
mistakes, this week's "Tcl-URL!" didn't include the most
important notice of all: this is the week of the Conference!
While those who weren't aware of it have already missed much,
there's still much more to come, as you can see and hear for
yourself through <URL: http://www.yqcomputer.com/ ;.
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Ralf Fasse » Fri, 24 Oct 2008 21:28:57

* Cameron Laird < XXXX@XXXXX.COM >
| this is the week of the Conference! While those who weren't aware
| of it have already missed much, there's still much more to come, as
| you can see and hear for yourself through <URL:
| http://www.yqcomputer.com/ ;.

Would it make sense to announce the time zone and offset to UTC of the
conference location there? 10:20am in Manassas is *when* in my office?

R'

 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by clair » Fri, 24 Oct 2008 23:04:28

In article < XXXX@XXXXX.COM >,


A. http://www.yqcomputer.com/ %20in%20manassas%20 *** ia&ie=UTF-8&oe=UTF-8
B. EDT
C. UTC - 4h
D. clock format [clock seconds] -timezone :America/New_York

Kevin et al., please help me with D. (or perhaps E.). Is there an elegant
way to map

EDT -> UTC - 4h

with 8.5 of [clock]?
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Donal K. F » Sat, 25 Oct 2008 02:32:08


Manassas is in *** ia, USA. Which is EDT at this time of year, so
UTC-04:00. (Or is it +4? I can never remember what the sign of the
offset means...)

Donal.
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by clair » Sat, 25 Oct 2008 05:01:30

In article < XXXX@XXXXX.COM >,


A. http://www.yqcomputer.com/ %20in%20manassas%20 *** ia&ie=UTF-8&oe=UTF-8
B. EDT
C. UTC - 4h
D. clock format [clock seconds] -timezone :America/New_York

Kevin et al., please help me with D. (or perhaps E.). Is there an elegant
way to map

EDT -> UTC - 4h

with 8.5 of [clock]?
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Alexandre » Sat, 25 Oct 2008 06:47:50

On Oct 23, 7:32m, "Donal K. Fellows"



To help you remember: they're still partying when you're turning in in
the UK ;-)

-Alex
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Larry W. V » Sat, 25 Oct 2008 09:31:54

On Oct 23, 5:47m, Alexandre Ferrieux < XXXX@XXXXX.COM >



currently many of them are at the Wine BOF...
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Donal K. F » Sat, 25 Oct 2008 15:09:23


That's the part I can remember. It's how to convert to a sign that
confuses me every time. :-)

Donal.
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by suchenw » Sat, 25 Oct 2008 20:16:32


> with 8.5 of [clock]?

Like this? (works correct only for integer hour distances)

% proc tzdiff {tz1 {tz2 UTC}} {
expr {[scan [clock format [clock sec] -timezone $tz1 -format %H]
%d]
-[scan [clock format [clock sec] -timezone $tz2 -format %H]
%d]}
}
% tzdiff :America/New_York
-4
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Ralf Fasse » Sat, 25 Oct 2008 20:49:39

* XXXX@XXXXX.COM (Cameron Laird)
| A. http://www.yqcomputer.com/ %20in%20manassas%20 *** ia&ie=UTF-8&oe=UTF-8
| B. EDT
| C. UTC - 4h
| D. clock format [clock seconds] -timezone :America/New_York

Yes, but....

time {
http://www.yqcomputer.com/ %20in%20manassas%20 *** ia&ie=UTF-8&oe=UTF-8
EDT
UTC - 4h
clock format [clock seconds] -timezone :America/New_York
} 10
=> 125768374 microseconds per iteration

time {
set fd [open $tcl_conference_page_on_screen r]
set offset [read $fd]
close $eyes
} 10
=> 936768 microseconds per iteration

R', reducing my CO2 footprint wherever possible ;-)
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Alexandre » Sat, 25 Oct 2008 22:22:44

On Oct 24, 1:16m, suchenwi <richard.suchenwirth-


> > E>T -> UTC - >h >>> > > with 8.5 of [clock>? >>
> Like this? (works correct only for integer hour distance>) >>
> % proc tzdiff {tz1 {tz2 UTC}}>{
> xpr {[scan [clock format [clock sec] -timezone $tz1 -format >H]
> >d]
> -[scan [clock format [clock sec] -timezone $tz2 -for>at %H]
>
> % tzdiff America/>ew_York
> -4

You may want to compute [clock sec] just once to be robust to "lack of
luck" ;-)
You may also feed a constant time there (choose in January or July of
1970 according to your DST preferences).

-Alex
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by suchenw » Sat, 25 Oct 2008 22:30:44

On 24 Okt., 15:22, Alexandre Ferrieux < XXXX@XXXXX.COM >


The reason why tzdata are so big is that they change so often (mostly
because of different dates for switching between "winter" and
"sumjmer" (daylight saving) time, and a difference between two
locations in January 1970 might not be the same in February 2008, so
one should ask for it with a concrete point in time. But that could of
course better be passed in as an argument, instead of using [clock
seconds].
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Ron Fo » Tue, 28 Oct 2008 20:23:14

And I should report that the lack of Donal's scotch was mostly made up
by a beer tasting presided over by kbk.

Ron.





--
Ron Fox
NSCL
Michigan State University
East Lansing, MI 48824-1321
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by Kevin Kenn » Wed, 29 Oct 2008 20:45:54


Does the following do what you seek?

% clock format [clock seconds] -format "%Z %z" \
-timezone :America/New_York
EDT -0400

--
73 de ke9tv/2, Kevin
 
 
 

First-ever SUPPLEMENTARY Tcl-URL! - weekly Tcl news and links (Oct 23)

Post by clair » Thu, 30 Oct 2008 05:57:24


.
.
.
.
.
.
Indeed! That's more of the symmetry I was after. Thank you.

You can guess what's next: how do I ask clock what -timezone-s it recognizes?