This commit is contained in:
Horis
2024-07-25 17:23:01 +08:00
parent 9a62cdbf52
commit 79396eec88
2 changed files with 7 additions and 4 deletions
+3 -1
View File
@@ -175,7 +175,9 @@ jobs:
done done
- name: Delete Pre-Release - name: Delete Pre-Release
run: gh release delete beta -y run: |
gh release delete beta -y
exit 0
env: env:
GH_TOKEN: ${{ github.token }} GH_TOKEN: ${{ github.token }}
@@ -22,15 +22,16 @@ enum class AppVariant {
} }
data class GithubRelease( data class GithubRelease(
val assets: List<Asset>, val assets: List<Asset>?,
val body: String, val body: String,
@SerializedName("prerelease") @SerializedName("prerelease")
val isPreRelease: Boolean, val isPreRelease: Boolean,
) { ) {
fun gitReleaseToAppReleaseInfo(): List<AppReleaseInfo> { fun gitReleaseToAppReleaseInfo(): List<AppReleaseInfo> {
return assets return assets
.filter { it.isValid } ?.filter { it.isValid }
.map { it.assetToAppReleaseInfo(isPreRelease, body) } ?.map { it.assetToAppReleaseInfo(isPreRelease, body) }
.orEmpty()
} }
} }