Skip to content

Commit

Permalink
jar signer removed
Browse files Browse the repository at this point in the history
  • Loading branch information
HemantKArya committed Jul 18, 2024
1 parent e003c0c commit 252c3f1
Show file tree
Hide file tree
Showing 3 changed files with 32 additions and 32 deletions.
40 changes: 20 additions & 20 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,28 +31,28 @@ jobs:
- name: Create .env file
run: echo "CLIENT_ID = XXXXX\nCLIENT_SECRET = XXXX EOF" > assets/.env

- name: Create keystore file
run: |
$b64 = "${{ secrets.KEY_STORE }}"
$filename = "./android/bloomee.jks"
$bytes = [Convert]::FromBase64String($b64)
[IO.File]::WriteAllBytes($filename, $bytes)
# - name: Create keystore file
# run: |
# $b64 = "${{ secrets.KEY_STORE }}"
# $filename = "./android/bloomee.jks"
# $bytes = [Convert]::FromBase64String($b64)
# [IO.File]::WriteAllBytes($filename, $bytes)
# run: echo "${{ secrets.KEY_STORE }}" | base64 --decode > ./android/bloomee.jks

- name: Create Keystore properties
run: |
echo keyPassword=\${{ secrets.KEY_PASSWORD }} > ./android/key.properties
echo storePassword=\${{ secrets.STORE_PASSWORD }} >> ./android/key.properties
echo keyAlias=\${{ secrets.KEY_ALIAS }} >> ./android/key.properties
# - name: Create Keystore properties
# run: |
# echo keyPassword=\${{ secrets.KEY_PASSWORD }} > ./android/key.properties
# echo storePassword=\${{ secrets.STORE_PASSWORD }} >> ./android/key.properties
# echo keyAlias=\${{ secrets.KEY_ALIAS }} >> ./android/key.properties

- name: Build App files
run: flutter build apk --release --build-number ${{github.run_number}}

- name: Verify Sign
run: jarsigner --verify --verbose build/app/outputs/flutter-apk/app-release.apk
# - name: Verify Sign
# run: jarsigner --verify --verbose build/app/outputs/flutter-apk/app-release.apk

- name: Rename APK file
run: Rename-Item -Path "build/app/outputs/flutter-apk/app-release.apk" -NewName "bloomee_tunes_android_v2.8.1+${{github.run_number}}.apk"
run: Rename-Item -Path "build/app/outputs/flutter-apk/app-release.apk" -NewName "bloomee_tunes_android_v2.8.2+${{github.run_number}}.apk"

- name: Build Windows App
run: flutter build windows --release --build-number ${{github.run_number}}
Expand All @@ -61,22 +61,22 @@ jobs:
run: Rename-Item -Path "build/windows/x64/runner/Release/bloomee.exe" -NewName "Bloomee.exe"

- name: ZIP build
run: Compress-Archive -Path build/windows/x64/runner/Release/* -Destination build/windows/x64/bloomee_tunes_windows_x64_v2.8.1+${{github.run_number}}.zip
run: Compress-Archive -Path build/windows/x64/runner/Release/* -Destination build/windows/x64/bloomee_tunes_windows_x64_v2.8.2+${{github.run_number}}.zip

- name: Upload Artifacts
uses: actions/upload-artifact@v2
with:
name: Release
path: |
build/app/outputs/flutter-apk/bloomee_tunes_android_v2.8.1+${{github.run_number}}.apk
build/windows/x64/bloomee_tunes_windows_x64_v2.8.1+${{github.run_number}}.zip
build/app/outputs/flutter-apk/bloomee_tunes_android_v2.8.2+${{github.run_number}}.apk
build/windows/x64/bloomee_tunes_windows_x64_v2.8.2+${{github.run_number}}.zip
- name: Create Release
uses: ncipollo/release-action@v1
with:
artifacts: |
build/windows/x64/bloomee_tunes_windows_x64_v2.8.1+${{github.run_number}}.zip
build/app/outputs/flutter-apk/bloomee_tunes_android_v2.8.1+${{github.run_number}}.apk
tag: v2.8.1+${{github.run_number}}
build/windows/x64/bloomee_tunes_windows_x64_v2.8.2+${{github.run_number}}.zip
build/app/outputs/flutter-apk/bloomee_tunes_android_v2.8.2+${{github.run_number}}.apk
tag: v2.8.2+${{github.run_number}}
token: ${{secrets.SECRET_KEY}}


22 changes: 11 additions & 11 deletions android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,10 @@ if (flutterVersionName == null) {
}


def keystoreProperties = new Properties()
def keystorePropertiesFile = rootProject.file('key.properties')
if (keystorePropertiesFile.exists()) {
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))}
// def keystoreProperties = new Properties()
// def keystorePropertiesFile = rootProject.file('key.properties')
// if (keystorePropertiesFile.exists()) {
// keystoreProperties.load(new FileInputStream(keystorePropertiesFile))}

android {
namespace "ls.bloomee.musicplayer"
Expand Down Expand Up @@ -59,16 +59,16 @@ android {
}

signingConfigs {
release {
keyAlias keystoreProperties['keyAlias']
keyPassword keystoreProperties['keyPassword']
storeFile rootProject.file('bloomee.jks')
storePassword keystoreProperties['storePassword']
}
// release {
// keyAlias keystoreProperties['keyAlias']
// keyPassword keystoreProperties['keyPassword']
// storeFile rootProject.file('bloomee.jks')
// storePassword keystoreProperties['storePassword']
// }
}
buildTypes {
release {
signingConfig signingConfigs.release
// signingConfig signingConfigs.release
}
}

Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix.
version: 2.8.1+0
version: 2.8.2+0

environment:
sdk: '>=3.0.6 <4.0.0'
Expand Down

0 comments on commit 252c3f1

Please sign in to comment.