From: TJ Luoma <luomat@gmail.com>
To: Bart Schaefer <schaefer@brasslantern.com>
Cc: Zsh-Users List <zsh-users@zsh.org>
Subject: Re: only run if X seconds have elapsed (time differences in seconds)
Date: Sat, 29 Dec 2012 20:00:03 -0500 [thread overview]
Message-ID: <CADjGqHt-2aFKFYQkf+4A0_j_oQwWhxMjsAskQmdFny1m5=q_mA@mail.gmail.com> (raw)
In-Reply-To: <121229153449.ZM7616@torch.brasslantern.com>
On Sat, Dec 29, 2012 at 6:34 PM, Bart Schaefer
<schaefer@brasslantern.com> wrote:
> One other note -- there is a potential race condition during the short
> time between doing the glob and writing to the file. Two runs of the
> script that are close enough to simultaneous might both find the file
> to be "old enough".
True enough, but I intend to run this via `launchd` every ~4 hours. I
don't want it to run more often than once a day, but since the
computer might be asleep at times, I figured doing a "how long since
this last ran?" check was a good alternative.
TjL
prev parent reply other threads:[~2012-12-30 2:07 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-29 19:40 TJ Luoma
2012-12-29 23:34 ` Bart Schaefer
2012-12-30 1:00 ` TJ Luoma [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CADjGqHt-2aFKFYQkf+4A0_j_oQwWhxMjsAskQmdFny1m5=q_mA@mail.gmail.com' \
--to=luomat@gmail.com \
--cc=schaefer@brasslantern.com \
--cc=zsh-users@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).