- Dart 72.1%
- C++ 13.3%
- CMake 10.4%
- Kotlin 1.4%
- Swift 1.3%
- Other 1.5%
Explain that the KGP warning is expected on Flutter 3.47: the Flutter Gradle plugin isn't compatible with the new AGP DSL, so built-in Kotlin cannot be enabled without breaking the build. Note when/how to migrate later. |
||
|---|---|---|
| .agents/skills | ||
| android | ||
| ios | ||
| lib | ||
| linux | ||
| macos | ||
| test | ||
| web | ||
| windows | ||
| .gitignore | ||
| .metadata | ||
| analysis_options.yaml | ||
| DEVELOPER_GUIDE.md | ||
| devtools_options.yaml | ||
| pubspec.lock | ||
| pubspec.yaml | ||
| README.md | ||
| skills-lock.json | ||
| version.json | ||
Shopping List App
A personal Flutter shopping list app for keeping track of products, quantities, prices, tax, and totals.
The app is designed for personal sideloaded Android use and includes a lightweight in-app update check that can download a newer APK and open Android's installer.
Features
- Create and switch between multiple shopping lists
- Add products with:
- Product name
- Quantity selector
- Price
- Edit existing products
- Mark products as purchased
- Swipe products to delete them with undo support
- Search and sort products
- Clear the current list with confirmation
- Calculate subtotal, purchased subtotal, tax, and final total automatically
- Enter IVU/tax percentage
- Set an optional budget and see remaining/over-budget status
- Save lists, products, tax, budget, and theme preference locally
- Responsive layout for phone, tablet, and desktop-sized windows
- Settings/About screen with manual update check
- Light, dark, and system theme modes
- Android sideload update flow:
- Checks
version.jsonon startup - Prompts when a newer version is available
- Downloads the APK directly
- Opens Android's package installer
- Checks
- One-time “App Updated” message after a successful version upgrade
Tech Stack
- Flutter / Dart
- Provider for app state
flutter_slidablefor swipe-to-delete actionshttpfor update/version checkspackage_info_plusfor reading the installed app versionpath_providerfor temporarily storing downloaded APKsshared_preferencesfor local app persistence and theme settings- Android platform channel for launching the APK installer
Getting Started
Prerequisites
Install Flutter and confirm your environment is ready:
flutter doctor
Install dependencies
flutter pub get
Run the app
flutter run
Build an Android APK
flutter build apk
The APK is generated at:
build/app/outputs/flutter-apk/app-release.apk
Update System
This app is not distributed through Google Play. Instead, it uses a custom version.json file hosted in this repository:
https://raw.githubusercontent.com/SirSlader/shopping_list_app/main/version.json
Example version.json:
{
"version": "1.0.2",
"download_url": "https://github.com/SirSlader/shopping_list_app/releases/download/v1.0.2/shopping_list.apk",
"release_notes": "Initial release"
}
When the app opens, it compares the installed version from pubspec.yaml with the remote version.json. If the remote version is newer, it shows an update dialog.
On Android, tapping Update Now downloads the APK into the app cache and opens Android's installer. Android still requires the user to confirm installation manually.
The Settings screen also includes a Check for updates action for manually checking the hosted version.json.
After a user installs an update and opens the app again, the app shows a one-time message confirming the installed version, for example:
Shopping List has been updated to version 1.0.3.
Android install permission
Because this is a sideloaded app, Android may ask the user to allow this app to install unknown apps:
Settings → Install unknown apps → Shopping List → Allow from this source
The app will open that settings screen automatically if permission is missing.
Release Workflow
For each new app release:
-
Update the app version in
pubspec.yaml:version: 1.0.3 -
Build the release APK:
flutter build apk -
Rename/copy the APK to the release filename:
shopping_list.apk -
Create a GitHub Release with a matching tag, for example:
v1.0.3 -
Upload
shopping_list.apkas a release asset. -
Update
version.json:{ "version": "1.0.3", "download_url": "https://github.com/SirSlader/shopping_list_app/releases/download/v1.0.3/shopping_list.apk", "release_notes": "Describe what changed" } -
Commit and push the
pubspec.yamlandversion.jsonchanges.
Users with an older installed version will be prompted to update the next time they open the app.
Important Notes
- Silent self-updates are not allowed for normal Android apps. The app can download the APK, but Android requires the user to approve installation.
- Future APKs must use the same Android package name.
- Future APKs must be signed with the same signing key as the installed version.
- The version in
version.jsonmust be higher than the installed app version for the update prompt to appear.
Repository
GitHub: SirSlader/shopping_list_app