From 93581983549f11df75dbf8358eca5856ae65cc71 Mon Sep 17 00:00:00 2001 From: Tlaster Date: Fri, 24 Dec 2021 22:46:28 +0800 Subject: [PATCH 1/3] update package to 1.6.0-dev01 --- buildSrc/src/main/kotlin/Package.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/buildSrc/src/main/kotlin/Package.kt b/buildSrc/src/main/kotlin/Package.kt index b6c794e70..1ebc2f120 100644 --- a/buildSrc/src/main/kotlin/Package.kt +++ b/buildSrc/src/main/kotlin/Package.kt @@ -2,6 +2,6 @@ object Package { const val group = "com.twidere" const val name = "Twidere X" const val id = "$group.twiderex" - const val versionName = "1.5.1" - const val versionCode = 55 + const val versionName = "1.6.0-dev01" + const val versionCode = 56 } From 9f9720a86cd2688844c8465a108304a7849e6d71 Mon Sep 17 00:00:00 2001 From: Tlaster Date: Sat, 25 Dec 2021 11:03:52 +0800 Subject: [PATCH 2/3] update desktop packages --- buildSrc/src/main/kotlin/Package.kt | 14 ++++++++++++-- desktop/build.gradle.kts | 4 +++- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/buildSrc/src/main/kotlin/Package.kt b/buildSrc/src/main/kotlin/Package.kt index 1ebc2f120..767ddd9bc 100644 --- a/buildSrc/src/main/kotlin/Package.kt +++ b/buildSrc/src/main/kotlin/Package.kt @@ -2,6 +2,16 @@ object Package { const val group = "com.twidere" const val name = "Twidere X" const val id = "$group.twiderex" - const val versionName = "1.6.0-dev01" - const val versionCode = 56 + val versionName = + "${Version.main}.${Version.mirror}.${Version.patch}${if (Version.revision.isNotEmpty()) "-${Version.revision}" else ""}" + const val copyright = "Copyright (C) TwidereProject and Contributors" + const val versionCode = Version.build + + object Version { + const val main = "1" + const val mirror = "6" + const val patch = "0" + const val revision = "dev01" + const val build = 56 + } } diff --git a/desktop/build.gradle.kts b/desktop/build.gradle.kts index 72f29d451..02002f141 100644 --- a/desktop/build.gradle.kts +++ b/desktop/build.gradle.kts @@ -39,7 +39,9 @@ compose { nativeDistributions { targetFormats(TargetFormat.Dmg, TargetFormat.Msi, TargetFormat.Deb) packageName = Package.name - packageVersion = Package.versionName.split("-").firstOrNull() + packageVersion = "${Package.Version.main}.${Package.Version.mirror}.${Package.versionCode}" + copyright = Package.copyright + licenseFile.set(rootProject.file("LICENSE")) modules("java.sql") // https://github.com/JetBrains/compose-jb/issues/381 modules("jdk.unsupported") modules("jdk.unsupported.desktop") From 446d382afbf911bc0c9f1c88382754c78e438c70 Mon Sep 17 00:00:00 2001 From: Tlaster Date: Sat, 25 Dec 2021 11:40:46 +0800 Subject: [PATCH 3/3] update ci config --- .github/workflows/release.yml | 67 ++++++----------------------------- 1 file changed, 10 insertions(+), 57 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index cd34e8e6c..e04987843 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -108,60 +108,13 @@ jobs: steps: - uses: actions/download-artifact@v2 - - name: Check if is prelease - if: startsWith(github.ref, 'refs/tags/') - id: check-tag - run: | - if [[ ${{ github.event.ref }} =~ ^refs/tags/[0-9]+\.[0-9]+\.[0-9]+\-(dev|beta)[0-9]+$ ]]; then - echo ::set-output name=prelease::true - fi - - - name: Create Prerelease - if: startsWith(github.ref, 'refs/tags/') && steps.check-tag.outputs.prelease == 'true' - run: | - set -x - assets=() - for asset in $(find -name *.deb); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.msi); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.dmg); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.apk); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.aab); do - assets+=("-a" "$asset") - done - tag_name="${GITHUB_REF##*/}" - hub release create "${assets[@]}" -m "$tag_name" "$tag_name" -p - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Create Release - if: startsWith(github.ref, 'refs/tags/') && steps.check-tag.outputs.prelease != 'true' - run: | - set -x - assets=() - for asset in $(find -name *.deb); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.msi); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.dmg); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.apk); do - assets+=("-a" "$asset") - done - for asset in $(find -name *.aab); do - assets+=("-a" "$asset") - done - tag_name="${GITHUB_REF##*/}" - hub release create "${assets[@]}" -m "$tag_name" "$tag_name" - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + - name: Draft a new release + uses: softprops/action-gh-release@v1 + with: + draft: true + files: | + **/*.deb + **/*.msi + **/*.dmg + **/*.apk + **/*.aab