{"thread":{"id":"18467","subject":"[PATCH] githooks documentation: post-checkout hook is also called after clone","startedAt":"2009-03-22T16:44:51Z","lastAt":"2009-03-22T16:56:04Z","messageCount":2,"participants":["Jens Lehmann","Pat Notz"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"108907","messageId":"49C66B03.6020908@web.de","threadId":"18467","inReplyTo":null,"subject":"[PATCH] githooks documentation: post-checkout hook is also called after clone","fromName":"Jens Lehmann","fromEmail":"jens.lehmann@web.de","sentAt":"2009-03-22T16:44:51Z","receivedAt":"2009-03-22T16:44:51Z","isPatch":true,"sender":{"key":"jens.lehmann@web.de","avatar":"https://avatars.githubusercontent.com/u/135220?v=4"},"body":"The documentation of the post-checkout hook just talks\nabout git-checkout. But recently git-clone was changed to\ncall it too, so we have to document that in githooks.txt.\n\nSigned-off-by: Jens Lehmann <Jens.Lehmann@web.de>\n---\n Documentation/githooks.txt |    3 +++\n 1 files changed, 3 insertions(+), 0 deletions(-)\n\ndiff --git a/Documentation/githooks.txt b/Documentation/githooks.txt\nindex 1fd512b..76deefc 100644\n--- a/Documentation/githooks.txt\n+++ b/Documentation/githooks.txt\n@@ -151,6 +151,9 @@ indicating whether the checkout was a branch checkout (changing branches,\n flag=1) or a file checkout (retrieving a file from the index, flag=0).\n This hook cannot affect the outcome of 'git-checkout'.\n \n+It is also run after 'git-clone'. The first parameter given to the hook is\n+the null-ref, the second the ref of the new HEAD and the flag is always 1.\n+\n This hook can be used to perform repository validity checks, auto-display\n differences from the previous HEAD if different, or set working dir metadata\n properties.\n-- \n1.6.2.1.275.ga797b\n"},{"id":"108908","messageId":"1cd1989b0903220956w47ca2521s8945a4c71225909c@mail.gmail.com","threadId":"18467","inReplyTo":"49C66B03.6020908@web.de","subject":"Re: [PATCH] githooks documentation: post-checkout hook is also called after clone","fromName":"Pat Notz","fromEmail":"patnotz@gmail.com","sentAt":"2009-03-22T16:56:04Z","receivedAt":"2009-03-22T16:56:04Z","isPatch":true,"sender":{"key":"patnotz@gmail.com","avatar":"https://avatars.githubusercontent.com/u/45364?v=4"},"body":"On Sun, Mar 22, 2009 at 10:44 AM, Jens Lehmann <Jens.Lehmann@web.de> wrote:\n> The documentation of the post-checkout hook just talks\n> about git-checkout. But recently git-clone was changed to\n> call it too, so we have to document that in githooks.txt.\n>\n> Signed-off-by: Jens Lehmann <Jens.Lehmann@web.de>\n> ---\n>  Documentation/githooks.txt |    3 +++\n>  1 files changed, 3 insertions(+), 0 deletions(-)\n>\n> diff --git a/Documentation/githooks.txt b/Documentation/githooks.txt\n> index 1fd512b..76deefc 100644\n> --- a/Documentation/githooks.txt\n> +++ b/Documentation/githooks.txt\n> @@ -151,6 +151,9 @@ indicating whether the checkout was a branch checkout (changing branches,\n>  flag=1) or a file checkout (retrieving a file from the index, flag=0).\n>  This hook cannot affect the outcome of 'git-checkout'.\n>\n> +It is also run after 'git-clone'. The first parameter given to the hook is\n> +the null-ref, the second the ref of the new HEAD and the flag is always 1.\n> +\n\nI don't think that's true if you clone with the --no-checkout (-n)\noption though.\n\n>  This hook can be used to perform repository validity checks, auto-display\n>  differences from the previous HEAD if different, or set working dir metadata\n>  properties.\n> --\n> 1.6.2.1.275.ga797b\n> --\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n>\n"}]}