Skip to content

Commit b52a703

Browse files
authored
Update build.sh
1 parent afa0e59 commit b52a703

1 file changed

Lines changed: 14 additions & 4 deletions

File tree

cross-platform/build.sh

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,23 +36,33 @@ if ! command -v npm &> /dev/null; then
3636
fi
3737
fi
3838

39-
# --- Ensure Flutter ---
39+
# --- Ensure Flutter 3.35.5 ---
4040
FLUTTER_DIR="$HOME/flutter"
41+
FLUTTER_VERSION="3.35.5"
4142

4243
if ! command -v flutter &> /dev/null; then
44+
echo "Installing Flutter ${FLUTTER_VERSION}..."
4345
git clone -q https://github.com/flutter/flutter.git -b stable "$FLUTTER_DIR"
46+
cd "$FLUTTER_DIR"
47+
git checkout "$FLUTTER_VERSION"
48+
cd -
49+
else
50+
echo "Flutter found, checking version..."
51+
cd "$FLUTTER_DIR"
52+
git fetch --tags
53+
git checkout "$FLUTTER_VERSION"
54+
cd -
4455
fi
4556

4657
export PATH="$PATH:$FLUTTER_DIR/bin"
4758

4859
# --- Flutter build steps ---
4960
cd lam7a
50-
flutter pub get --verbose
61+
flutter pub get
5162

5263
flutter pub run build_runner build --delete-conflicting-outputs
5364

54-
55-
flutter build apk --release --verbose
65+
flutter build apk --profile --verbose
5666

5767
# --- Platform-specific builds ---
5868
if [ "$OS_TYPE" = "macos" ]; then

0 commit comments

Comments
 (0)