From: Junio C Hamano <gitster@pobox.com>
To: Leo Gaspard <leo@gaspard.io>
Cc: git@vger.kernel.org, "Joey Hess" <id@joeyh.name>,
"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
"Johannes Sixt" <j6t@kdbg.org>
Subject: Re: [PATCH 2/2] fetch: add tweak-fetch hook
Date: Fri, 09 Feb 2018 14:40:48 -0800 [thread overview]
Message-ID: <xmqqk1vlvlan.fsf@gitster-ct.c.googlers.com> (raw)
In-Reply-To: <20180209214458.16135-2-leo@gaspard.io> (Leo Gaspard's message of "Fri, 9 Feb 2018 22:44:58 +0100")
Leo Gaspard <leo@gaspard.io> writes:
> +tweak-fetch
> +~~~~~~~~~~~
> +
> +This hook is invoked by 'git fetch' (commonly called by 'git pull'), after refs
> +have been fetched from the remote repository. It is not executed, if nothing was
> +fetched.
Need to tighten explanation of "nothing was fetched". If the only
change I made to my repository is that I created a new branch that
points at an existing object since last time you fetched, you would
obtain no new object when you fetch from me. Would that count as
"nothing was fetched"? Or would it be still fetching something
(i.e. your remote-tracking hierarchy will record the fact that I now
have this new branch)?
> + <sha1> SP not-for-merge|merge|ignore SP <remote-refname> SP <local-refname> LF
> + ...
> +The `<remote-refname>` is the remote's name for the ref that was fetched, and
> +`<local-refname>` is a name of a remote-tracking branch, like
> +"refs/remotes/origin/master". `<local-refname>` can be undefined if the fetched
> +ref is not being stored in a local refname. In this case, it will be set to `@`,
Don't use "@"; leave it empty instead.
> +TODO: Add documentation for the “ignore” parameter. Unfortunately, I'm not
> +really sure I get what this does or what invariants it is supposed to maintain
> +(eg. all “ignore” updates at the end of the refs list?), so this may also
> +require code changes.
If you are not using the feature, wouldn't it make more sense not to
add it in the first place?
next prev parent reply other threads:[~2018-02-09 22:40 UTC|newest]
Thread overview: 38+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-07 21:56 Fetch-hooks Leo Gaspard
2018-02-07 22:51 ` Fetch-hooks Ævar Arnfjörð Bjarmason
2018-02-08 0:06 ` Fetch-hooks Leo Gaspard
2018-02-08 15:30 ` Fetch-hooks Joey Hess
2018-02-08 17:02 ` Fetch-hooks Leo Gaspard
2018-02-08 21:06 ` Fetch-hooks Ævar Arnfjörð Bjarmason
2018-02-08 22:18 ` Fetch-hooks Leo Gaspard
2018-02-09 22:04 ` Fetch-hooks Ævar Arnfjörð Bjarmason
2018-02-09 22:24 ` Fetch-hooks Leo Gaspard
2018-02-09 22:56 ` Fetch-hooks Ævar Arnfjörð Bjarmason
2018-02-09 22:30 ` Fetch-hooks Jeff King
2018-02-09 22:45 ` Fetch-hooks Junio C Hamano
2018-02-09 23:49 ` Fetch-hooks Leo Gaspard
2018-02-10 0:13 ` Fetch-hooks Jeff King
2018-02-10 0:37 ` Fetch-hooks Leo Gaspard
2018-02-10 1:08 ` Fetch-hooks Junio C Hamano
2018-02-10 1:33 ` Fetch-hooks Leo Gaspard
2018-02-10 18:03 ` Fetch-hooks Leo Gaspard
2018-02-10 12:21 ` Fetch-hooks Jeff King
2018-02-10 18:36 ` Fetch-hooks Leo Gaspard
2018-02-12 19:23 ` Fetch-hooks Brandon Williams
2018-02-13 15:44 ` Fetch-hooks Leo Gaspard
2018-02-14 1:38 ` Fetch-hooks Jeff King
2018-02-14 1:35 ` Fetch-hooks Jeff King
2018-02-14 2:02 ` Fetch-hooks Leo Gaspard
2018-02-19 21:23 ` Fetch-hooks Jeff King
2018-02-19 22:50 ` Fetch-hooks Leo Gaspard
2018-02-20 6:10 ` Fetch-hooks Jacob Keller
2018-02-20 7:42 ` Fetch-hooks Jeff King
2018-02-20 21:19 ` Fetch-hooks Leo Gaspard
2018-02-14 1:46 ` Fetch-hooks Jacob Keller
2018-02-09 19:12 ` Fetch-hooks Leo Gaspard
2018-02-09 20:20 ` Fetch-hooks Joey Hess
2018-02-09 21:28 ` [PATCH 0/2] fetch: add tweak-fetch hook Leo Gaspard
2018-02-09 21:44 ` [PATCH 1/2] fetch: preparations for " Leo Gaspard
2018-02-09 21:44 ` [PATCH 2/2] fetch: add " Leo Gaspard
2018-02-09 22:40 ` Junio C Hamano [this message]
2018-02-09 22:34 ` [PATCH 1/2] fetch: preparations for " Junio C Hamano
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=xmqqk1vlvlan.fsf@gitster-ct.c.googlers.com \
--to=gitster@pobox.com \
--cc=avarab@gmail.com \
--cc=git@vger.kernel.org \
--cc=id@joeyh.name \
--cc=j6t@kdbg.org \
--cc=leo@gaspard.io \
/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).