diff options
author | zwelch <zwelch@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2009-09-30 23:19:53 +0000 |
---|---|---|
committer | zwelch <zwelch@b42882b7-edfa-0310-969c-e2dbd0fdcd60> | 2009-09-30 23:19:53 +0000 |
commit | 8624535b8036a245952fabd27108ea681a694f04 (patch) | |
tree | 0fa5b4e3064444b61ddcd05ea0a48b4c2278d90e | |
parent | 32599fab1ac1f77b8f64fde0cd7668bd0f5f1c50 (diff) | |
download | openocd_libswd-8624535b8036a245952fabd27108ea681a694f04.tar.gz openocd_libswd-8624535b8036a245952fabd27108ea681a694f04.tar.bz2 openocd_libswd-8624535b8036a245952fabd27108ea681a694f04.tar.xz openocd_libswd-8624535b8036a245952fabd27108ea681a694f04.zip |
Fix release script bugs after experience from 0.2.0:
- The NEWS step failed due to an empty commit comment.
- The final release step would have failed, because the steps to switch
from the secure to insecure repository (and back again) require both
switch and a URL relocation steps
git-svn-id: svn://svn.berlios.de/openocd/trunk@2782 b42882b7-edfa-0310-969c-e2dbd0fdcd60
-rwxr-xr-x | tools/release.sh | 35 |
1 files changed, 21 insertions, 14 deletions
diff --git a/tools/release.sh b/tools/release.sh index 21f9f04a..5511f101 100755 --- a/tools/release.sh +++ b/tools/release.sh @@ -75,7 +75,7 @@ do_svn() { [ "${RELEASE_DRY_RUN}" ] || svn "$@" } do_svn_switch() { - do_svn switch "$1" + do_svn switch "$@" package_info_load } @@ -440,14 +440,13 @@ do_release_step_branch() { do_version_commit "$(do_release_step_branch_bump micro)" do_svn_switch "${SVN_URL}" } -do_release_step_bump() { - # major and minor releases require branch version update too - [ "${RELEASE_TYPE}" = "micro" ] || do_release_step_branch - # bump the current tree version as required. - do_version_commit "$(do_release_step_branch_bump "${RELEASE_TYPE}")" - - [ "${RELEASE_TYPE}" = "micro" ] && return - +do_release_step_news_msg() { + cat <<MSG +Archive released NEWS file: NEWS -> NEWS-${RELEASE_VERSION} +Create new NEWS file from relesse script template. +MSG +} +do_release_step_news() { # archive NEWS and create new one from template do_svn move "NEWS" "NEWS-${RELEASE_VERSION}" @@ -472,20 +471,28 @@ For more information about contributing test reports, bug fixes, or new features and device support, please read the new Developer Manual (or the BUGS and PATCHES files in the source archive). NEWS + do_svn add NEWS - MSG=<<MSG -Archive released NEWS file: NEWS -> NEWS-${RELEASE_VERSION} -Create new NEWS file from relesse script template. -MSG + local MSG="$(do_release_step_news_msg)" do_svn commit -m "${MSG}" NEWS NEWS-${RELEASE_VERSION} } +do_release_step_bump() { + # major and minor releases require branch version update too + [ "${RELEASE_TYPE}" = "micro" ] || do_release_step_branch + # bump the current tree version as required. + do_version_commit "$(do_release_step_branch_bump "${RELEASE_TYPE}")" + + [ "${RELEASE_TYPE}" = "micro" ] || do_release_step_news +} do_release_step_package() { local A=${PACKAGE_TAG} local B=${A/https/http} local PACKAGE_BUILD=${B/${USER}@/} - do_svn_switch "${PACKAGE_BUILD}" + do_svn_switch "${PACKAGE_TAG}" + do_svn_switch --relocate "${PACKAGE_TAG}" "${PACKAGE_BUILD}" do_stage do_clean + do_svn_switch --relocate "${PACKAGE_BUILD}" "${PACKAGE_TAG}" do_svn_switch "${SVN_URL}" } |