Flutter App

This commit is contained in:
2025-12-14 21:53:46 -05:00
parent 383e2e07bd
commit 7ed7a2470d
108 changed files with 7077 additions and 130 deletions

View File

@@ -1,49 +1,89 @@
# Gitea Actions - Release Workflow
# Gitea Actions - Flutter Release Workflow
This workflow automatically builds and releases rmtPocketWatcher for Windows and Linux when you push a version tag.
This workflow automatically builds and releases rmtPocketWatcher Flutter app for Windows and Android when you push a version tag.
## 🚀 Current Build Targets
- **Windows**: Native desktop application (.zip)
- **Android**: APK package (.apk)
## 📱 Migration from Electron
**⚠️ ELECTRON VERSION DEPRECATED**: The Electron version has been replaced with Flutter for better cross-platform support, native performance, and mobile compatibility.
## How to Trigger a Release
1. Update version in `electron-app/package.json`:
```bash
cd electron-app
npm version patch # or minor, or major
1. Update version in `flutter_app/pubspec.yaml`:
```yaml
version: 1.2.3+4 # Update this line
```
2. Push the tag to Gitea:
2. Push changes to main branch:
```bash
git add flutter_app/pubspec.yaml
git commit -m "Bump version to 1.2.3"
git push origin main
git push origin --tags
```
3. The workflow will automatically:
- Build Windows installer (.exe)
- Build Linux AppImage and .deb package
- Create a GitHub/Gitea release
- Upload all binaries to the release
- Build Windows desktop application
- Build Android APK
- Create a GitHub/Gitea release with both binaries
- Include release notes with download instructions
## Requirements
## 🔧 Manual Development Build
- Gitea Actions must be enabled on your repository
- Runners must be configured for `windows-latest` and `ubuntu-latest`
- Repository must have write permissions for releases
To trigger a manual dev build (debug versions):
## Manual Build
1. Go to Actions tab in your repository
2. Select "Flutter Dev Build" workflow
3. Click "Run workflow"
To build locally without releasing:
This will create debug builds for both Windows and Android.
## 🏗️ Local Development
### Windows
```bash
cd electron-app
npm run electron:build -- --win # Windows
npm run electron:build -- --linux # Linux
cd flutter_app
flutter pub get
flutter run -d windows
```
Outputs will be in `electron-app/release/`
### Android
```bash
cd flutter_app
flutter pub get
flutter run -d android # Requires connected device/emulator
```
## Troubleshooting
### Build Release Locally
```bash
cd flutter_app
flutter build windows --release # Windows
flutter build apk --release # Android
```
## 📋 Requirements
- Gitea Actions enabled on repository
- Runners configured for `windows-latest` and `ubuntu-latest`
- Repository write permissions for releases
- Flutter 3.24.0+ installed on runners
- Java 17 for Android builds
## 🔍 Troubleshooting
If the workflow fails:
- Check that Node.js 20 is available on runners
- Verify all dependencies install correctly
- Check Flutter version compatibility
- Verify all dependencies in `pubspec.yaml`
- Ensure Android SDK is properly configured
- Check Gitea Actions logs for specific errors
- Ensure GITHUB_TOKEN has proper permissions
- Verify GITHUB_TOKEN permissions
## 📦 Release Assets
Each release includes:
- `rmtPocketWatcher-Windows-v{version}.zip` - Windows desktop app
- `rmtPocketWatcher-Android-v{version}.apk` - Android mobile app
- Detailed release notes with installation instructions