What's cooking (2014/08 #01)
[git/jrn.git] / Announce
blob58336565564702080388682624299b75c14ab019
1 #!/bin/sh
2 # Announcement message skelton
4 branch=${1?branch}
5 previous=${2?previous}
6 commit=${3-"$1"}
8 relname=$(git describe "$commit") &&
9 vername=$(expr "$relname" : 'v\(.*\)') || exit $?
11 git rev-parse --verify "$previous" >/dev/null || exit $?
13 case "$branch" in
14 maint)
15 kind="The latest maintenance release" ;;
16 mainto/* | maint-[0-9]*)
17 kind="A maintenance release" ;;
18 master)
19 kind="The latest feature release" ;;
20 esac
22 case "$vername" in
23 *-rc[0-9]*)
24 rpmroot=testing
25 case "$vername" in
26 *-rc0)
27 kind="An early preview release"
30 kind="A release candidate"
32 esac
33 for_testing=" for testing"
36 for_testing=
37 rpmroot='RPMS/$arch'
39 esac
41 vername=$(echo "$vername" | tr "-" ".")
43 cat <<EOF
44 To: git@vger.kernel.org
45 Cc: Linux Kernel <linux-kernel@vger.kernel.org>
46 Bcc: lwn@lwn.net
47 Subject: [ANNOUNCE] Git $relname
49 EOF
51 fmt -68 <<EOF
52 $kind Git $relname is now available$for_testing at the usual places.
53 EOF
55 cat <<EOF
57 The tarballs are found at:
59 https://www.kernel.org/pub/software/scm/git/${for_testing:+testing/}
61 The following public repositories all have a copy of the '$relname'
62 tag and the '$branch' branch that the tag points at:
64 url = https://kernel.googlesource.com/pub/scm/git/git
65 url = git://repo.or.cz/alt-git.git
66 url = https://code.google.com/p/git-core/
67 url = git://git.sourceforge.jp/gitroot/git-core/git.git
68 url = git://git-core.git.sourceforge.net/gitroot/git-core/git-core
69 url = https://github.com/gitster/git
71 EOF
73 RelNotes=$(git cat-file blob "${branch}:RelNotes") &&
74 git cat-file blob "${branch}:$RelNotes" |
75 case "$relname" in
76 *-rc[0-9]*)
77 sed -e 's/^Git .* Release Notes$/& (draft)/' \
78 -e 's/^=============/&========/'
81 cat
83 esac
85 cat <<EOF
87 ----------------------------------------------------------------
89 Changes since $previous are as follows:
91 EOF
93 git log --no-merges "$previous".."$branch" |
94 git shortlog