From: Matthew Wilcox <matthew@wil.cx>
To: git@vger.kernel.org
Cc: Linus Torvalds <torvalds@osdl.org>
Subject: default update hook broken
Date: Mon, 21 Nov 2005 07:09:14 -0700 [thread overview]
Message-ID: <20051121140914.GB1598@parisc-linux.org> (raw)
There's two syntax errors and one good-netizen error in the hooks/update
file created when cloning Linus' linux-2.6.git repo. I don't know
if that file is created fresh or if it gets pulled from Linus' tree.
Here's a patch to fix it
--- .git/hooks/update 2005-11-21 06:31:51.000000000 -0700
+++ /home/willy/replacement-update 2005-11-21 07:01:37.000000000 -0700
@@ -8,14 +8,14 @@
# (2) make this file executable by "chmod +x update".
#
-recipient="commit-list@mydomain.xz"
+recipient="commit-list@example.com"
if expr "$2" : '0*$' >/dev/null
then
echo "Created a new ref, with the following commits:"
git-rev-list --pretty "$3"
else
- $base=$(git-merge-base "$2" "$3")
+ base=$(git-merge-base "$2" "$3")
case "$base" in
"$2")
echo "New commits:"
@@ -24,8 +24,7 @@
echo "Rebased ref, commits from common ancestor:"
;;
esac
-fi
-git-rev-list --pretty "$3" "^$base"
+ git-rev-list --pretty "$3" "^$base"
fi |
mail -s "Changes to ref $1" "$recipient"
exit 0
next reply other threads:[~2005-11-21 14:09 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-11-21 14:09 Matthew Wilcox [this message]
2005-11-21 18:08 ` default update hook broken Andreas Ericsson
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=20051121140914.GB1598@parisc-linux.org \
--to=matthew@wil.cx \
--cc=git@vger.kernel.org \
--cc=torvalds@osdl.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.
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).