Re: what's the best way to get today at 00:00:00?

Liste des GroupesRevenir à cl tcl 
Sujet : Re: what's the best way to get today at 00:00:00?
De : rich (at) *nospam* example.invalid (Rich)
Groupes : comp.lang.tcl
Date : 24. Jul 2025, 14:55:59
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <105te1f$1g0k5$1@dont-email.me>
References : 1
User-Agent : tin/2.6.1-20211226 ("Convalmore") (Linux/5.15.139 (x86_64))
Mark Summerfield <m.n.summerfield@gmail.com> wrote:
I have a function that returns today's date/time at 00:00:00, e.g.,
2025-07-24T00:00:00, returned as seconds:
 
proc start_of_day {} {
    clock scan "[clock format now -format %Y]-[clock format now \
            -format %m]-[clock format now -format %d]" -format "%Y-%m-%d"
}
 
Is there a better way?

proc start_of_day {} {
  return [clock format [clock seconds] -format "%Y-%m-%dT00:00:00"]
}

Date Sujet#  Auteur
24 Jul09:02 * what's the best way to get today at 00:00:00?8Mark Summerfield
24 Jul09:24 +- Re: what's the best way to get today at 00:00:00?1rene
24 Jul10:19 +- Re: what's the best way to get today at 00:00:00?1EvoTcl
24 Jul14:55 +* Re: what's the best way to get today at 00:00:00?2Rich
24 Jul17:31 i`- Re: what's the best way to get today at 00:00:00?1Rich
24 Jul17:48 `* Re: what's the best way to get today at 00:00:00?3saito
24 Jul17:51  `* Re: what's the best way to get today at 00:00:00?2saito
24 Jul21:02   `- Re: what's the best way to get today at 00:00:00?1Rich

Haut de la page

Les messages affichés proviennent d'usenet.

NewsPortal