Skip to content

Commit

Permalink
Fix ci (#1020)
Browse files Browse the repository at this point in the history
**Background**
[CI is a bit
broken](https://github.com/flipperdevices/Flipper-Android-App/actions/runs/12936026554)
because of autogenerated app version

**Changes**

- Add validation for desktop version

**Test plan**

- Merge and see green ci
  • Loading branch information
makeevrserg authored Jan 24, 2025
1 parent e74bfb3 commit a4156d1
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
# 1.8.2 - In Progress

- [Feature] Migrate app onto new BLE api
- [Fix] Fix CI for desktop sample app


# 1.8.1
Expand Down
14 changes: 14 additions & 0 deletions components/bridge/connection/sample/desktop/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,20 @@ compose.desktop {
targetFormats(TargetFormat.Dmg, TargetFormat.Msi, TargetFormat.Deb)
packageName = "Flipper App"
packageVersion = project.VERSION_NAME
.split(".")
.let { semVers ->
// minimum major version for desktop is 1
val major = semVers.getOrNull(0)
?.toIntOrNull()
?.coerceAtLeast(1)
?: 1
val minor = semVers.getOrNull(1) ?: 0
// If generated on CI - getting autogenerated last number first
val patch = semVers.getOrNull(3)
?: semVers.getOrNull(2)
?: 0
"${major}.${minor}.${patch}"
}
}
}
}
Expand Down

0 comments on commit a4156d1

Please sign in to comment.