Skip to content

Commit

Permalink
Not only the 'master' prefix but also the 'main' prefix is now stripp…
Browse files Browse the repository at this point in the history
…ed when deriving the version identifier
  • Loading branch information
alexanderpann committed Sep 10, 2024
1 parent 896925d commit 57a0b29
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## 1.28.1

### Fixed

- Not only the 'master' prefix but also the 'main' prefix is now stripped when deriving the version identifier.

## 1.28.0

### Added
Expand Down
2 changes: 1 addition & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ plugins {
id("org.jetbrains.kotlinx.binary-compatibility-validator") version "0.13.2"
}

val baseVersion = "1.28.0"
val baseVersion = "1.28.1"

group = "de.itemis.mps"

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class GitBasedVersioning {
static String getVersion(String branch, String major, String minor, String bugfix = "", int count) {
def hash = getGitShortCommitHash()
def baseVersion = bugfix.isEmpty() ? "$major.$minor.$count.$hash" : "$major.$minor.$bugfix.$count.$hash"
if (branch == 'master' || branch == 'HEAD' /*this happens in detached head situations*/) {
if (branch == 'master' || branch == 'main' || branch == 'HEAD' /*this happens in detached head situations*/) {
return baseVersion
}

Expand Down

0 comments on commit 57a0b29

Please sign in to comment.