* default update hook broken
@ 2005-11-21 14:09 Matthew Wilcox
2005-11-21 18:08 ` Andreas Ericsson
0 siblings, 1 reply; 2+ messages in thread
From: Matthew Wilcox @ 2005-11-21 14:09 UTC (permalink / raw)
To: git; +Cc: Linus Torvalds
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
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: default update hook broken
2005-11-21 14:09 default update hook broken Matthew Wilcox
@ 2005-11-21 18:08 ` Andreas Ericsson
0 siblings, 0 replies; 2+ messages in thread
From: Andreas Ericsson @ 2005-11-21 18:08 UTC (permalink / raw)
To: git
Matthew Wilcox wrote:
> 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
>
Good thing I read new list entries before I send things. I did this
exact same patch too. :)
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-11-21 18:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-11-21 14:09 default update hook broken Matthew Wilcox
2005-11-21 18:08 ` Andreas Ericsson
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).