lmi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [lmi] Creating end-user packages for msw


From: Greg Chicares
Subject: Re: [lmi] Creating end-user packages for msw
Date: Sat, 29 May 2010 15:49:30 +0000
User-agent: Thunderbird 2.0.0.24 (Windows/20100228)

Anyone?

On 2010-05-22 17:51Z, Greg Chicares wrote:
> On 2010-05-14 18:10Z, Vadim Zeitlin wrote:
[...]
> As for this part of the patch:
> 
>> -  d2=`$(DATE) --utc --date="$$d0 + 2 months - 1 day" +%s`; \
>> +  d2=`$(DATE) --utc --date="$$d0 + 2 months" +%s`; \
> 
> can we say where the following example (with '- 1 day') was misleading?
> 
> On 2010-03-19 19:17Z, Greg Chicares wrote:
> |
> | $date
> | Fri Mar 19 19:17:37 GMTST 2010
> | $d0=`date +%Y-%m-01`
> | $date --utc --date="$d0 + 1 month         "
> | Thu Apr  1 00:00:00 UTC 2010
> | $date --utc --date="$d0 + 2 months - 1 day"
> | Fri Apr 30 00:00:00 UTC 2010
> 
> Now let's step back and ask whether we've handled timezone correctly.
> I live in UTC, so a mistake here could easily escape my notice. With
> your patch applied, we would have:
> 
> fardel_date_script := \
>   d0=`$(DATE) +%Y-%m-01`; \
>   d1=`$(DATE) --utc --date="$$d0 + 1 month " +%s`; \
>   d2=`$(DATE) --utc --date="$$d0 + 2 months" +%s`; \
>   j1=`expr 2440588 + $$d1 / 86400`; \
>   j2=`expr 2440588 + $$d2 / 86400`; \
>   echo -n "$$j1 $$j2" >expiry; \
> 
> It looks like 'd0' is local time, but 'd1' and 'd2' have '--utc'
> in their formulas; we need to understand whether '--utc' is helpful
> or harmful here, and why. (I suspect it's correct because of what
> '%s' means, but it seems best to ask for another opinion because,
> for me, timezone vanishes.)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]