ref: ebd636e4d5f475d4b5d9047580e61ff7c2bf2fb5
parent: 4d1989d59c5abc9712b66c628c6742e58f7daf99
author: Bjørn Erik Pedersen <[email protected]>
date: Sat May 20 07:11:23 EDT 2017
releaser: Delay the version bumping So we can do the release notes in its own branch if needed.
--- a/releaser/releaser.go
+++ b/releaser/releaser.go
@@ -119,14 +119,6 @@
}
if r.shouldPrepare() {
- if err := bumpVersions(newVersion); err != nil {
- return err
- }
-
- if _, err := git("commit", "-a", "-m", fmt.Sprintf("%s Bump versions for release of %s\n\n[ci skip]", commitPrefix, newVersion)); err != nil {
- return err
- }
-
releaseNotesFile, err := writeReleaseNotesToDocsTemp(version, gitCommits)
if err != nil {
return err
@@ -143,6 +135,14 @@
if !r.shouldRelease() {
fmt.Println("Skip release ... Use --state=2 to continue.")
return nil
+ }
+
+ if err := bumpVersions(newVersion); err != nil {
+ return err
+ }
+
+ if _, err := git("commit", "-a", "-m", fmt.Sprintf("%s Bump versions for release of %s\n\n[ci skip]", commitPrefix, newVersion)); err != nil {
+ return err
}
releaseNotesFile := getRelaseNotesDocsTempFilename(version)