docs: add CI/CD pipeline documentation to README
CI / Lint (pull_request) Failing after 19m20s
CI / Test (pull_request) Skipped
CI / Build Android (pull_request) Skipped
CI / Build iOS (pull_request) Skipped

- Pipeline overview diagram
- Workflow descriptions (CI and Release)
- Required secrets table
- Troubleshooting section
This commit is contained in:
robot
2026-08-01 07:51:47 +00:00
parent c299d46f91
commit 137815ad25
+67
View File
@@ -31,3 +31,70 @@ dart run flutter_name_manager:rename_app --name "KRYZ Go!"
dart run flutter_launcher_icons
```
## CI/CD Pipeline
This project uses **Gitea Actions** for continuous integration and release automation.
### Pipeline Overview
```
┌─────────┐ ┌────────┐ ┌──────────────┐ ┌──────────────┐
│ Lint │───►│ Test │───►│ Build Android │ │ Build iOS │
│ │ │ │ │ (APK + AAB) │ │ (self-hosted)│
└─────────┘ └────────┘ └──────────────┘ └──────────────┘
│ │ │
▼ ▼ ▼
dart fmt flutter test flutter build ios
flutter analyze (--no-codesign fallback)
```
### Workflows
#### CI (`.gitea/workflows/ci.yml`)
Triggers on:
- Push to `main` or `develop`
- Pull requests targeting `main`
Stages:
1. **Lint**`dart format --fix` + `flutter analyze --fatal-warnings`
2. **Test**`flutter test` (coverage on main branch pushes)
3. **Build Android** — APK + AAB release builds with artifact upload
4. **Build iOS**`flutter build ios --release --no-codesign` (runs on self-hosted macOS runner)
#### Release (`.gitea/workflows/release.yml`)
Triggers on:
- Git tags matching `v*` (e.g., `v1.0.0`)
Stages:
1. **Lint**`dart format --set-exit-if-changed` + `flutter analyze --fatal-warnings`
2. **Test**`flutter test`
3. **Build Android Release** — Signed APK + AAB
4. **Build iOS Release** — Signed IPA (or `--no-codesign` fallback)
5. **Publish Release** — Creates Gitea release + uploads artifacts
### Configuration
| Secret | Required | Description |
|---|---|---|
| `ANDROID_KEYSTORE_BASE64` | No | Base64-encoded Android release keystore |
| `ANDROID_KEYSTORE_PASS` | No | Keystore password |
| `ANDROID_KEY_ALIAS` | No | Key alias |
| `ANDROID_KEY_PASS` | No | Key password |
| `APPLE_CERTIFICATE_P12` | No | Base64-encoded Apple signing certificate |
| `APPLE_CERTIFICATE_PASS` | No | Certificate password |
| `APPLE_PROVISION_PROFILE` | No | Base64-encoded provisioning profile |
| `GITEA_TOKEN` | Yes (Release) | Token for creating Gitea releases |
Without signing secrets, builds use debug keys or `--no-codesign`.
### CI Status
![CI](https://git.westerntechnologies.duckdns.org/kfj001/kryz-go-flutter/actions/workflows/ci.yml/badge.svg)
### Troubleshooting
- **Stubs missing**: The `ci_stub_gen.py` script auto-generates `lib/generated/*.dart` stubs when `theme.json` is absent.
- **macOS runner unavailable**: The iOS stage uses `self-hosted` label. Ensure a macOS Gitea runner is registered.
- **Format checks**: CI uses `dart format --fix` (auto-fix). Release uses `--set-exit-if-changed` (gate).