From: Mark Levedahl <mlevedahl@gmail.com>
To: Junio C Hamano <junkio@cox.net>
Cc: Johannes Schindelin <Johannes.Schindelin@gmx.de>, git@vger.kernel.org
Subject: Re: [PATCH 2/3] git-bundle: die if a given ref is not included in bundle
Date: Fri, 09 Mar 2007 08:40:04 -0500 [thread overview]
Message-ID: <45F163B4.2000905@gmail.com> (raw)
In-Reply-To: <7vejny7umx.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano wrote:
> Mark Levedahl <mlevedahl@gmail.com> writes:
> I am not sure if the above is true. How are you preventing the
> command from bundling everything? You must have some limiter at
> the bottom, something like --since=25.hours (to account for cron
> schedule skew), not just <list of refs>.
>
Sorry, I trimmed too much. My typical command usage is something like
git bundle create foo --since=10.days.ago --all
I include a very generous date range so that folks don't have to update
daily, can cover a vacation with a single bundle, etc. I think this
usage renders moot all practical issues with clock skew. I am being
loose, if the bundle won't apply then get one from the previous week,
apply, and go forward.
BTW, shouldn't git check for clock skew when creating a commit to assure
the parents predate the child? Clock skew could allow this circumstance
which would look suspicious when exploring a history.
> In any case, the semantics of --since=25.hours limiter is not
> "show everything newer than 25.hours that are reachable from any
> of these refs"; it is "start digging from these tips, and stop
> exploring the path as soon as you hit something that is newer
> than 25.hours".
>
I presume you mean "older than 2.5" hours in the above.
> If I were doing a nightly script, I would probably be doing
> something like this:
>
> #!/bin/sh
> yesterday=$(git bundle list-heads yesterday.bdl | sed -e 's/ .*//')
> git bundle create today.bdl --all --not $yesterday
> # mail it out
>
> After sending today's bundle out, you will rotate it out to
> yesterday.bdl in order to prepare for the next round. It is
> likely that you would want to keep a few day's worth of bundles
> for other reasons _anyway_ (say, some project members might be
> out of office, or mail gets dropped, or whatever), I think the
> above is a reasonably clean and easy thing to arrange.
>
>
This is certainly a reliable method, but has the difficulty of how to
get started and of course requires that history be kept for the entire
range covered by each bundle. The first bundle is either a) the entire
repository, or b) crafted by trying each and every ref to find which are
legal to define. While all of this can be done, I think this cure is
worse than the disease (seconds to minutes of clock skew).
I would prefer to just add a warning to the manual that when limiting by
date, be generous to allow for all possible clock skew across the
distributed set of computers.
Mark
next prev parent reply other threads:[~2007-03-09 13:40 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-03-09 2:48 [PATCH 2/3] git-bundle: die if a given ref is not included in bundle Johannes Schindelin
2007-03-09 3:17 ` Mark Levedahl
2007-03-09 7:17 ` Junio C Hamano
2007-03-09 13:40 ` Mark Levedahl [this message]
2007-03-09 15:36 ` Mark Levedahl
2007-03-09 16:30 ` [PATCH] git-bundle: only die if pack would be empty, warn if ref is skipped Johannes Schindelin
2007-03-10 5:44 ` Mark Levedahl
2007-03-09 23:37 ` [PATCH 2/3] git-bundle: die if a given ref is not included in bundle Junio C Hamano
2007-03-10 5:48 ` Mark Levedahl
2007-03-10 15:39 ` Johannes Schindelin
2007-03-10 16:14 ` Mark Levedahl
2007-03-10 16:53 ` Johannes Schindelin
2007-03-10 18:30 ` Mark Levedahl
2007-03-11 1:08 ` Johannes Schindelin
2007-03-11 1:29 ` Junio C Hamano
2007-03-11 1:54 ` Johannes Schindelin
2007-03-11 14:51 ` Mark Levedahl
2007-03-11 19:58 ` Junio C Hamano
2007-03-11 22:28 ` Johannes Schindelin
2007-03-13 3:16 ` Mark Levedahl
2007-03-09 3:51 ` [PATCH] git-bundle: die if the bundle is empty Mark Levedahl
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=45F163B4.2000905@gmail.com \
--to=mlevedahl@gmail.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
--cc=junkio@cox.net \
/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.
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).