[Android|Windows|macOS|iOS] Rework flutter build helpers #5

Merged
iGoX merged 11 commits from igox/rework-flutter-build-command into main 2026-03-25 18:55:29 +01:00
2 changed files with 11 additions and 4 deletions
Showing only changes of commit 54691e8837 - Show all commits
+5 -2
View File
@@ -1,8 +1,11 @@
$buildType = if ($args[0]) { $args[0] } else { "debug" } $buildType = if ($args[0]) { $args[0] } else { "release" }
$buildName = if ($args[1]) { $args[1] } else { "0.0.0" }
$buildNumber = "$buildName-$(Get-Date -Format 'yyyyMMddHHmmss')"
$apkDir = "..\build\app\outputs\flutter-apk" $apkDir = "..\build\app\outputs\flutter-apk"
$baseName = "org.igox.apps.android.busylight-buddy" $baseName = "org.igox.apps.android.busylight-buddy"
flutter build apk --$buildType flutter build apk --$buildType --build-name=${buildName} --build-number ${buildNumber} --target-platform android-arm,android-arm64,android-x64
# Rename APK # Rename APK
$oldApk = "$apkDir\app-$buildType.apk" $oldApk = "$apkDir\app-$buildType.apk"
+6 -2
View File
@@ -1,9 +1,13 @@
#!/bin/bash #!/bin/bash
BUILD_TYPE=${1:-debug} BUILD_TYPE=${1:-release}
BUILD_NAME=${2:-0.0.0}
BUILD_NUMBER="$BUILD_NAME-$(date +%Y%m%d%H%M%S)"
APK_DIR="../build/app/outputs/flutter-apk" APK_DIR="../build/app/outputs/flutter-apk"
BASE_NAME="org.igox.apps.android.busylight-buddy" BASE_NAME="org.igox.apps.android.busylight-buddy"
flutter build apk --$BUILD_TYPE flutter build apk --$BUILD_TYPE --build-name=$BUILD_NAME --build-number=$BUILD_NUMBER --target-platform android-arm,android-arm64,android-x64
# Rename APK # Rename APK
OLD_APK="$APK_DIR/app-$BUILD_TYPE.apk" OLD_APK="$APK_DIR/app-$BUILD_TYPE.apk"