mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-23 12:40:17 +00:00
Release tag script: add -revision option
It seems useful to be able to create the branch at a revision that looks good on the buildbots. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@225736 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
ab860e7a08
commit
589d1a16b5
@ -19,18 +19,20 @@ rc=""
|
||||
rebranch="no"
|
||||
projects="llvm cfe dragonegg test-suite compiler-rt libcxx libcxxabi clang-tools-extra polly lldb lld openmp"
|
||||
dryrun=""
|
||||
revision="HEAD"
|
||||
|
||||
base_url="https://llvm.org/svn/llvm-project"
|
||||
|
||||
function usage() {
|
||||
echo "usage: `basename $0` -release <num> [-rebranch] [-dry-run]"
|
||||
echo "usage: `basename $0` -release <num> [-rebranch] [-revision <num>] [-dry-run]"
|
||||
echo "usage: `basename $0` -release <num> -rc <num> [-dry-run]"
|
||||
echo " "
|
||||
echo " -release <num> The version number of the release"
|
||||
echo " -rc <num> The release candidate number"
|
||||
echo " -rebranch Remove existing branch, if present, before branching"
|
||||
echo " -final Tag final release candidate"
|
||||
echo " -dry-run Make no changes to the repository, just print the commands"
|
||||
echo " -release <num> The version number of the release"
|
||||
echo " -rc <num> The release candidate number"
|
||||
echo " -rebranch Remove existing branch, if present, before branching"
|
||||
echo " -final Tag final release candidate"
|
||||
echo " -revision <num> Revision to branch off (default: HEAD)"
|
||||
echo " -dry-run Make no changes to the repository, just print the commands"
|
||||
}
|
||||
|
||||
function tag_version() {
|
||||
@ -43,7 +45,8 @@ function tag_version() {
|
||||
${dryrun} svn remove -m "Removing old release_$branch_release branch for rebranching." \
|
||||
$base_url/$proj/branches/release_$branch_release
|
||||
fi
|
||||
${dryrun} svn copy -m "Creating release_$branch_release branch" \
|
||||
${dryrun} svn copy -m "Creating release_$branch_release branch off revision ${revision}" \
|
||||
-r ${revision} \
|
||||
$base_url/$proj/trunk \
|
||||
$base_url/$proj/branches/release_$branch_release
|
||||
done
|
||||
@ -81,6 +84,10 @@ while [ $# -gt 0 ]; do
|
||||
-final | --final )
|
||||
rc="final"
|
||||
;;
|
||||
-revision | --revision )
|
||||
shift
|
||||
revision="$1"
|
||||
;;
|
||||
-dry-run | --dry-run )
|
||||
dryrun="echo"
|
||||
;;
|
||||
@ -110,6 +117,13 @@ tag_release=`echo $release | sed -e 's,\.,,g'`
|
||||
if [ "x$rc" = "x" ]; then
|
||||
tag_version
|
||||
else
|
||||
if [ "x$revision" != "x" ]; then
|
||||
echo "error: cannot use -revision with -rc"
|
||||
echo
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
|
||||
tag_release_candidate
|
||||
fi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user