Skip to content

Commit

Permalink
Fix bug with handling minor releases after major releases in the buil…
Browse files Browse the repository at this point in the history
…d script.
  • Loading branch information
jeresig committed May 2, 2011
1 parent 53f2750 commit c0d9939
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion build/release.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ function setNextVersion( newVersion ) {

} else if ( /^\d+\.\d+\.?(\d*)$/.test( newVersion ) ) {
newVersion = newVersion.replace( /^(\d+\.\d+\.?)(\d*)$/, function( all, pre, num ) {
return pre + (num ? parseFloat( num ) + 1 : 1) + "pre";
return pre + (pre.charAt( pre.length - 1 ) !== "." ? "." : "") + (num ? parseFloat( num ) + 1 : 1) + "pre";
});

isFinal = true;
Expand Down

0 comments on commit c0d9939

Please sign in to comment.