Skip to content

Commit

Permalink
release.pl: allow tagging branches as ltr on point releases and
Browse files Browse the repository at this point in the history
bypass pre-commit hooks

(cherry picked from commit 84cc377)
  • Loading branch information
jef-n committed Feb 21, 2017
1 parent 64819bc commit 4a74176
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions scripts/release.pl
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,6 @@ ($$)
$i++ if defined $dopoint;
pod2usage("Exactly one of -major, -minor or -point expected") if $i!=1;
pod2usage("Release name for major and minor releases expected") if !$dopoint && !defined $newreleasename;
pod2usage("Long term releases only for major and minor releases") if $doltr && $dopoint;
pod2usage("Pre-major releases can only be minor releases") if $dopremajor && !$dominor;
pod2usage("No CMakeLists.txt in current directory") unless -r "CMakeLists.txt";

Expand Down Expand Up @@ -155,7 +154,7 @@ ($$)
print "Pulling transifex translations...\n";
run( "scripts/pull_ts.sh", "pull_ts.sh failed" );
run( "git add i18n/*.ts", "adding translations failed" );
run( "git commit -a -m \"translation update for $release from transifex\"", "could not commit translation updates" );
run( "git commit -n -a -m \"translation update for $release from transifex\"", "could not commit translation updates" );
} else {
print "TRANSIFEX UPDATE SKIPPED!\n";
}
Expand All @@ -167,7 +166,7 @@ ($$)
unless( $dopoint ) {
run( "scripts/update-news.pl $newmajor $newminor '$newreleasename'", "could not update news" ) if $major>2 || ($major==2 && $minor>14);

run( "git commit -a -m \"changelog and news update for $release\"", "could not commit changelog and news update" );
run( "git commit -n -a -m \"changelog and news update for $release\"", "could not commit changelog and news update" );

print "Creating and checking out branch...\n";
run( "git checkout -b $relbranch", "git checkout release branch failed" );
Expand All @@ -190,14 +189,15 @@ ($$)
print "WARNING: NO images/splash/splash-release.xcf.bz2\n";
}

run( "git commit -a -m 'Release of $release ($newreleasename)'", "release commit failed" );
run( "git commit -n -a -m 'Release of $release ($newreleasename)'", "release commit failed" );
run( "git tag $reltag -m 'Version $release'", "release tag failed" );
run( "git tag $ltrtag -m 'Long term release $release'", "ltr tag failed" ) if $doltr;
} else {
run( "git commit -a -m 'Release of $version'", "release commit failed" );
run( "git commit -n -a -m 'Release of $version'", "release commit failed" );
run( "git tag $reltag -m 'Version $version'", "tag failed" );
}

run( "git tag $ltrtag -m 'Long term release $release'", "ltr tag failed" ) if $doltr;

print "Producing archive...\n";
run( "git archive --format tar --prefix=qgis-$version/ $reltag | bzip2 -c >qgis-$version.tar.bz2", "git archive failed" );
run( "md5sum qgis-$version.tar.bz2 >qgis-$version.tar.bz2.md5", "md5sum failed" );
Expand All @@ -216,7 +216,7 @@ ($$)
run( "cp /tmp/changelog debian", "restore changelog failed" );
run( "dch -r ''", "dch failed" );
run( "dch --newversion $newmajor.$newminor.0 'New development version $newmajor.$newminor after branch of $release'", "dch failed" );
run( "git commit -a -m 'New development branch for interim $newmajor.x releases'", "bump version failed" );
run( "git commit -n -a -m 'New development branch for interim $newmajor.x releases'", "bump version failed" );

push @topush, "master_$newmajor";

Expand All @@ -228,7 +228,7 @@ ($$)
run( "cp /tmp/changelog debian", "restore changelog failed" );
run( "dch -r ''", "dch failed" );
run( "dch --newversion $newmajor.$newminor.0 'New development version $newmajor.$newminor after branch of $release'", "dch failed" );
run( "git commit -a -m 'Bump version to $newmajor.$newminor'", "bump version failed" );
run( "git commit -n -a -m 'Bump version to $newmajor.$newminor'", "bump version failed" );

push @topush, $branch;
}
Expand All @@ -238,7 +238,7 @@ ($$)

print "Push dry-run...\n";
run( "git push -n --follow-tags origin $topush", "push dry run failed" );
print "Now manually push and upload the tarballs :\n\tgit push --follow-tags origin $topush\n\trsync qgis-$version.tar.bz2* qgis.org:/var/www/downloads/\n\n";
print "Now manually push and upload the tar balls:\n\tgit push --follow-tags origin $topush\n\trsync qgis-$version.tar.bz2* ssh.qgis.org:/var/www/downloads/\n\n";
print "WARNING: TRANSIFEX UPDATE SKIPPED!\n" if $skipts;


Expand Down

0 comments on commit 4a74176

Please sign in to comment.