You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by ic...@apache.org on 2021/09/06 11:35:41 UTC
svn commit: r1892988 - in /httpd/dev-tools/v2: README common-lib.sh
make-candidate.sh update-branch.sh
Author: icing
Date: Mon Sep 6 11:35:41 2021
New Revision: 1892988
URL: http://svn.apache.org/viewvc?rev=1892988&view=rev
Log:
* added 'update-branch.sh' to increase the patch level and all depending information after a release
Added:
httpd/dev-tools/v2/update-branch.sh (with props)
Modified:
httpd/dev-tools/v2/README
httpd/dev-tools/v2/common-lib.sh
httpd/dev-tools/v2/make-candidate.sh
Modified: httpd/dev-tools/v2/README
URL: http://svn.apache.org/viewvc/httpd/dev-tools/v2/README?rev=1892988&r1=1892987&r2=1892988&view=diff
==============================================================================
--- httpd/dev-tools/v2/README (original)
+++ httpd/dev-tools/v2/README Mon Sep 6 11:35:41 2021
@@ -31,7 +31,9 @@ Usage overview:
# the SVN tags/candidate-$FULL_VERSION is moved to tags/$VERSION
# send out the announcements
> $BUILD_TOOLS/announce.sh
- > TODO: increment the version in your local branch for development of next
+ > $BUILD_TOOLS/v2/update-branch.sh next_version
+ # the patch information in local checkout is updated, the docs
+ # are built again and CHANGES and STATUS have the new version added.
On failure or when aborting for other reasons:
> $BUILD_TOOLS/v2/reset-candidate.sh version
Modified: httpd/dev-tools/v2/common-lib.sh
URL: http://svn.apache.org/viewvc/httpd/dev-tools/v2/common-lib.sh?rev=1892988&r1=1892987&r2=1892988&view=diff
==============================================================================
--- httpd/dev-tools/v2/common-lib.sh (original)
+++ httpd/dev-tools/v2/common-lib.sh Mon Sep 6 11:35:41 2021
@@ -11,7 +11,7 @@ warn() {
if test -n "$*"; then
echo "WARNING: $*" >&2
fi
- test "$exit_on_warnings" -eq 0 || exit 1
+ test "$exit_on_warnings" = 1 && exit 1
}
is_int() {
Modified: httpd/dev-tools/v2/make-candidate.sh
URL: http://svn.apache.org/viewvc/httpd/dev-tools/v2/make-candidate.sh?rev=1892988&r1=1892987&r2=1892988&view=diff
==============================================================================
--- httpd/dev-tools/v2/make-candidate.sh (original)
+++ httpd/dev-tools/v2/make-candidate.sh Mon Sep 6 11:35:41 2021
@@ -19,8 +19,6 @@ set -e
current_year=`date +%Y`
-exit_on_warnings=0
-
usage () {
cat <<EOF 1>&2
usage: $0 [options] [version]
@@ -152,6 +150,6 @@ popd >/dev/null
echo "changes for candidate-${FULL_VERSION} in ${DIST_DIR}"
svn stat "${DIST_DIR}"
if ask_yes_no "Do you want to commit these?"; then
- svn commit -m "Post $version tag updates" "$DIST_DIR"
+ svn commit -m "Post $FULL_VERSION tag updates" "$DIST_DIR"
echo "release candidate sources created in $SVN_DEST"
fi
Added: httpd/dev-tools/v2/update-branch.sh
URL: http://svn.apache.org/viewvc/httpd/dev-tools/v2/update-branch.sh?rev=1892988&view=auto
==============================================================================
--- httpd/dev-tools/v2/update-branch.sh (added)
+++ httpd/dev-tools/v2/update-branch.sh Mon Sep 6 11:35:41 2021
@@ -0,0 +1,142 @@
+#!/bin/sh
+
+# Create a release candidate for voting in a svn checkout
+#
+# USAGE: make-candidate.sh [version]
+# EXAMPLE: make-candidate.sh 2.4.49
+#
+# This script is called in a built svn checkout of the branch for which
+# a release candidate shall be made:
+# @version the version identifier, major.minor.patch, to use. If not given
+# it will determine the version from the local sources
+#
+
+#Useful for debugging
+#set -x
+
+#Bail when non-zero return codes are encountered
+set -e
+
+current_year=`date +%Y`
+date_string=`date '+%B %d, %Y'`
+
+usage () {
+ cat <<EOF 1>&2
+usage: $0 [options] [version]
+ update the development branch after a release to the next version.
+ If no version is given, the current version in the checkout is used.
+ Arguments:
+ version as 'm.n.p(-suffix)?' the version to use.
+ Options:
+ -h print usage information
+ -y never ask, always assume yes
+EOF
+ exit 1
+}
+
+source `dirname $0`/common-lib.sh
+
+while getopts "hy" opt; do
+ case $opt in
+ h) usage
+ ;;
+ y) ALWAYS_YES=1
+ ;;
+ esac
+done
+
+detect_checkout
+# detect the current version
+detect_version ""
+prev_major=${v_major}
+prev_minor=${v_minor}
+PREV_VERSION="$VERSION"
+
+if test -n "$1"; then
+ detect_version $1
+ NEXT_VERSION="$VERSION"
+ if test "$PREV_VERSION" = "$NEXT_VERSION"; then
+ fail "checkout is already at version $PREV_VERSION."
+ fi
+ if test "${prev_major}" -ne "${v_major}"; then
+ fail "you specified major version ${v_major}, but checkout is at ${prev_major}."
+ fi
+ if test "${prev_minor}" -ne "${v_minor}"; then
+ fail "you specified minor version ${v_minor}, but checkout is at ${prev_minor}."
+ fi
+else
+ next_patch=`expr ${v_patch} + 1`
+ detect_version "${v_major}.${v_minor}.${next_patch}"
+fi
+
+PROJECT=`basename $SVN_BASE`
+
+cat <<EOF
+updating branch:
+ PROJECT: $PROJECT
+ CURRENT: $PREV_VERSION
+ NEXT: $VERSION
+EOF
+
+if test -f include/ap_release.h; then
+ echo "setting patch number in include/ap_release.h"
+ perl -pi -e 's/(#define\s+AP_SERVER_PATCHLEVEL_NUMBER\s+)\d*/${1}'${v_patch}'/g' include/ap_release.h
+ if ! grep -e "^#define *AP_SERVER_PATCHLEVEL_NUMBER *${v_patch}\$" include/ap_release.h >/dev/null 2>&1;then
+ fail "setting of AP_SERVER_PATCHLEVEL_NUMBER did not return expected value of ${v_patch}"
+ fi
+fi
+
+if test -f docs/manual/style/version.ent; then
+ # Set ENTITY httpd.patch in docs/manual/style/version.ent.
+ echo "setting patch version in docs/manual/style/version.ent"
+ perl -pi -e 's/(.*ENTITY httpd.patch ")(\d+)(.*)/${1}'${v_patch}'${3}/g' docs/manual/style/version.ent
+ if ! grep -e "ENTITY *httpd.patch *\"${v_patch}\"" docs/manual/style/version.ent >/dev/null 2>&1;then
+ fail "setting of ENTITY httpd.patch did not return expected value of ${v_patch}"
+ fi
+fi
+
+# Ensure the Copyright date reflects the current year
+for src in NOTICE docs/manual/style/xsl/common.xsl; do
+ if test -f "$src"; then
+ perl -pi -e "s/Copyright \d+ The Apache Software Foundation./Copyright $current_year The Apache Software Foundation./g" "$src"
+ fi
+done
+
+if test -d docs/manual; then
+ # Execute ./build.sh all convmap to ensure that the documentation transformations are up to date.
+ echo "rebuilding manuals"
+ pushd docs/manual >/dev/null
+ #See http://httpd.apache.org/docs-project/docsformat.html for these instructions
+ if test -d build; then
+ svn update
+ else
+ svn checkout https://svn.apache.org/repos/asf/httpd/docs-build/trunk build
+ fi
+ pushd build >/dev/null
+ ./build.sh all convmap
+ ./build.sh validate-xml
+ ./build.sh validate-xhtml
+ popd >/dev/null
+ popd >/dev/null
+fi
+
+# Add the corresponding version placeholder in CHANGES.
+perl -pi -e "s{(.*coding: utf-8.*)}{\$1\nChanges with Apache ${VERSION}\n}" CHANGES
+
+
+# Note the tag date in the STATUS file.
+perl -pi -e '
+ if(/^(\s+)('${PREV_VERSION}'\s+):/){
+ $size = length $2;
+ $newline1 = sprintf("${1}%-${size}s", "'${VERSION}'") . ": In development\n";
+ $newline2 = sprintf("${1}%-${size}s", "'${PREV_VERSION}'") . ": Tagged on '"${date_string}"'\n";
+ $_="${newline1}${newline2}";
+ }
+ ' STATUS
+
+
+echo "changes for patch version bump"
+svn stat
+if ask_yes_no "Do you want to commit these?"; then
+ svn commit -m "Post $VERSION patch updates"
+fi
Propchange: httpd/dev-tools/v2/update-branch.sh
------------------------------------------------------------------------------
svn:executable = *
Re: svn commit: r1892988 - in /httpd/dev-tools/v2: README
common-lib.sh make-candidate.sh update-branch.sh
Posted by "stefan@eissing.org" <st...@eissing.org>.
> Am 06.09.2021 um 17:55 schrieb Ruediger Pluem <rp...@apache.org>:
>
>
>
> On 9/6/21 1:35 PM, icing@apache.org wrote:
>> Author: icing
>> Date: Mon Sep 6 11:35:41 2021
>> New Revision: 1892988
>>
>> URL: http://svn.apache.org/viewvc?rev=1892988&view=rev
>> Log:
>> * added 'update-branch.sh' to increase the patch level and all depending information after a release
>>
>>
>> Added:
>> httpd/dev-tools/v2/update-branch.sh (with props)
>> Modified:
>> httpd/dev-tools/v2/README
>> httpd/dev-tools/v2/common-lib.sh
>> httpd/dev-tools/v2/make-candidate.sh
>>
>
>> Modified: httpd/dev-tools/v2/common-lib.sh
>> URL: http://svn.apache.org/viewvc/httpd/dev-tools/v2/common-lib.sh?rev=1892988&r1=1892987&r2=1892988&view=diff
>> ==============================================================================
>> --- httpd/dev-tools/v2/common-lib.sh (original)
>> +++ httpd/dev-tools/v2/common-lib.sh Mon Sep 6 11:35:41 2021
>
>> +
>> +if test -d docs/manual; then
>> + # Execute ./build.sh all convmap to ensure that the documentation transformations are up to date.
>> + echo "rebuilding manuals"
>> + pushd docs/manual >/dev/null
>> + #See http://httpd.apache.org/docs-project/docsformat.html for these instructions
>> + if test -d build; then
>> + svn update
>
> I guess this needs to be
>
> svn update build
>
> as build is a separate checkout.
Thanks, will fix. These very late scripts are tricky to test without actually doing a release.
>
> Regards
>
> RĂ¼diger
Re: svn commit: r1892988 - in /httpd/dev-tools/v2: README
common-lib.sh make-candidate.sh update-branch.sh
Posted by Ruediger Pluem <rp...@apache.org>.
On 9/6/21 1:35 PM, icing@apache.org wrote:
> Author: icing
> Date: Mon Sep 6 11:35:41 2021
> New Revision: 1892988
>
> URL: http://svn.apache.org/viewvc?rev=1892988&view=rev
> Log:
> * added 'update-branch.sh' to increase the patch level and all depending information after a release
>
>
> Added:
> httpd/dev-tools/v2/update-branch.sh (with props)
> Modified:
> httpd/dev-tools/v2/README
> httpd/dev-tools/v2/common-lib.sh
> httpd/dev-tools/v2/make-candidate.sh
>
> Modified: httpd/dev-tools/v2/common-lib.sh
> URL: http://svn.apache.org/viewvc/httpd/dev-tools/v2/common-lib.sh?rev=1892988&r1=1892987&r2=1892988&view=diff
> ==============================================================================
> --- httpd/dev-tools/v2/common-lib.sh (original)
> +++ httpd/dev-tools/v2/common-lib.sh Mon Sep 6 11:35:41 2021
> +
> +if test -d docs/manual; then
> + # Execute ./build.sh all convmap to ensure that the documentation transformations are up to date.
> + echo "rebuilding manuals"
> + pushd docs/manual >/dev/null
> + #See http://httpd.apache.org/docs-project/docsformat.html for these instructions
> + if test -d build; then
> + svn update
I guess this needs to be
svn update build
as build is a separate checkout.
Regards
RĂ¼diger