ann_flutter_flavor
Multi-flavor Flutter toolkit. Reads annspec.yaml, generates typed flavor classes, and wires Android, iOS, Firebase, AdMob and RevenueCat.
1.0.0
1.0K downloads/mo
#571 most downloaded on pub.dev
anntech-dev/ann-flavor-flutter
What this package is like to depend on
Last release today
23 Aug 2026
Release timing varies
gaps range from 8 days to 5 weeks
Nearly every release is documented
notes for 37 of 40 stable releases
1 version withdrawn
withdrawn after publishing
2 months old
41 releases · first in 2026
41 releases in the last 12 months
see the full history below
Release timeline
41 releases · Jun 2026 to Aug 2026Releases
latest 41-
4.0.624 Jun 2026 withdrawnNothing published for this version
-
1.0.023 Aug 2026Release notes
Open source →Added
tooling:section inannspec.yaml— declaregradle_plugin,cocoapods_plugin, andfastlane_pluginversion constraints.syncreads these to patchandroid/settings.gradle.ktsandGemfilewith the specified versions.upgradeCLI command — resolves the latest matching version for eachtooling:field from Maven Central (Gradle) or RubyGems (CocoaPods/Fastlane), patchesannspec.yaml, and runssync. Exact pins (x.y.z) are skipped; absent fields are skipped.
Changed
kGradlePluginVersionis now a fallback used only whentooling.gradle_pluginis absent fromannspec.yaml. Settooling.gradle_pluginin your spec to manage the version explicitly.syncGemfile patching for CocoaPods and Fastlane now writes pessimistic version constraints (~> x.y.z) when a version is declared intooling:.
-
0.7.1122 Aug 2026Release notes
Open source →Fixed
- Bumped bundled Gradle plugin version to 2.3.6 —
FirebaseCopyTasknow correctly handlesprofilebuild type by reusing thereleaseFirebase config (fixes #45). - Bumped bundled CocoaPods plugin version to 0.1.17 — Firebase plist build phase path corrected (fixes #46).
- Bumped bundled Gradle plugin version to 2.3.6 —
-
0.7.1022 Aug 2026Release notes
Open source →Fixed
- Bumped bundled Gradle plugin version to 2.3.5 —
google-services.jsonis no longer deleted after each build, preventing missing file errors on subsequent runs.
- Bumped bundled Gradle plugin version to 2.3.5 —
-
0.7.922 Aug 2026 -
0.7.822 Aug 2026Release notes
Open source →Changed
- Bumped bundled Gradle plugin version to 2.3.4 —
AndroidManifest.xmlis no longer rewritten on every build when there are no logical changes (fixes #44).
- Bumped bundled Gradle plugin version to 2.3.4 —
-
0.7.715 Aug 2026Release notes
Open source →Fixed
- Gemfile duplicate detection for
ann-flavor-flutternow recognises both single and double quote styles, preventing duplicate gem lines.
- Gemfile duplicate detection for
-
0.7.614 Aug 2026Release notes
Open source →Fixed
sync specnow writes bothrequire 'ann-flavor-cocoapods'andrequire 'annai-flutter-flavor'in the Podfile header instead of aplugindirective.
-
0.7.514 Aug 2026Release notes
Open source →Fixed
sync specnow writesplugin 'ann-flavor-cocoapods'in the Podfile instead ofplugin 'ann-ios-flavorize', matching the actual gem name in the Gemfile.
-
0.7.414 Aug 2026 -
0.7.314 Aug 2026Release notes
Open source →Fixed
sync: Gemfile duplicate detection now recognises both single and double quote styles forgem "cocoapods".
-
0.7.214 Aug 2026Release notes
Open source →Changed
sync-web: removed web icon generation — use the app icons command instead.sync: removed automatic.gitignoremutation for web flavor outputs (manifest.json,index.html,version.jsonare intentionally tracked).
-
0.7.114 Aug 2026Release notes
Open source →Added
- Plan 027:
sync-web_copyToWebnow excludeswrangler.toml(alongside*.tmpl.*files) so the rendered Cloudflare Workers config never entersweb/. WebTemplateRendereradds{{output_dir}}template variable — resolves tobuild/web/<flavor>when a flavor is set, orbuild/webwhen no flavor is used.
- Plan 027:
-
0.6.012 Aug 2026Release notes
Open source →Added
AnnFlavorConfig.appleId— exposes thestores.app_store.apple_idvalue fromannspec.yamlin the generatedann_flavor.g.dart. Returnsnullwhen the field is not set. Access at runtime:AnnFlavor.current.appleId.
-
0.5.112 Aug 2026Nothing published for this version
-
0.5.012 Aug 2026Release notes
Open source →Added
- Plan 011:
iconfield added toAnnspecFlavorand platform defaults in the CLI model and reader. Parsed for android and iOS platforms. - Plan 011:
IosIconGeneratorgenerates per-flavor iOS icon sets viaflutter_launcher_icons. Source PNG is validated (must be 1024×1024). - Plan 011:
wireXcconfigpatches<flavor>Release.xcconfigand<flavor>Debug.xcconfigwithASSETCATALOG_COMPILER_APPICON_NAMEso Xcode picks up the generated icon set. - Plan 011:
synccommand now includes step 4 — iOS icon generation for all flavors with aniconconfigured, inserted between iOS wiring (step 3) and Firebase (step 5). - All three cores (Kotlin, Dart, Ruby) updated:
iconfield parsed and resolved with cascade (flavor.icon ?? default.icon);effectiveIcon/effective_iconexposed onResolvedBuildOutput.
- Plan 011:
-
0.4.1209 Aug 2026Release notes
Open source →Fixed
- DEF-024:
_writeAuthGetternow correctly applies platform default auth for all fourAnnPlatformvalues. Previouslywebandwindowsdefaults were never applied (always emittingreturn null;), and android/ios defaults were also silently ignored when no flavor entry existed for that platform. Auth configured under<platform>.default.build_types.release/debug.authinannspec.yamlis now emitted correctly for all platforms.
- DEF-024:
-
0.4.1106 Aug 2026Release notes
Open source →Fixed
- DEF-023: Generated
AnnPlatformswitch statements inauthRelease,authDebug,optionsRelease, andoptionsDebugare now exhaustive. All fourAnnPlatformarms (android,ios,web,windows) are always emitted; platforms without config emitreturn null;. Removes the Dart 3 non-exhaustive switch compile error in consumer projects that only configureandroidandios. - Lint: Generated file now emits
// ignore: depend_on_referenced_packagesbefore thefirebase_coreimport to suppress the lint warning for transitive dependencies.
- DEF-023: Generated
-
0.4.1007 Jul 2026Release notes
Open source →Added
- Three firebase helper functions:
flavorFirebaseOptions()(auto-selects by build type),flavorFirebaseOptionsRelease()(always release),flavorFirebaseOptionsDebug()(always debug). The previous singleflavorFirebaseOptions()function is replaced by this trio. auth()concrete default onAnnFlavorConfig: dispatches toauthRelease()orauthDebug()based onAnnFlavor.buildType. Consumers no longer need to implementauth()themselves.
Breaking
auth()renamed toauthRelease()inAnnFlavorConfig. Any class that overridesauth()must rename the override toauthRelease(). Theann_flutter_flavor synccommand regeneratesann_flavor.g.dartwith the correct method name automatically.- The
_<Flavor>Firebaseprivate class now exposesoptionsRelease()instead ofoptions(). Generated code is updated automatically on next sync.
Fixed
- DEF-021 (Gradle 2.0.16):
PostBuildProcessingTaskannotation fix —FirebaseCopyTasknow runs reliably before cleanup. Update the Gradle plugin version in your project to 2.0.16. - Version sync — bundled Gradle plugin reference (
kGradlePluginVersion) updated to2.0.16.
- Three firebase helper functions:
-
0.4.906 Jul 2026Release notes
Open source →Version sync — updated bundled Gradle plugin reference (
kGradlePluginVersion) to2.0.15(DEF-020:google-services.jsoncopy path fix).
-
0.4.806 Jul 2026Release notes
Open source →Fixed
- DEF-019:
--targetflag corrected to--ios-target— the flag name used byflutterfire configurev1.4.0.
- DEF-019:
-
0.4.706 Jul 2026Release notes
Open source →Added
- DEF-019 (
targetfield): New optionaltargetfield insidefirebaseblocks (iOS only) — names the Xcode target passed toflutterfire configure --target. Resolves via a 4-level cascade identical toservice_account. Defaults to"Runner"when absent at all cascade levels. Valid indefault.firebase,default.build_types.<bt>.firebase,flavor.<n>.firebase, andflavor.<n>.build_types.<bt>.firebase.
Fixed
- DEF-019: iOS
flutterfire configurenow passes--ios-out ios/Runner/GoogleService-Info.plist(exact basename required by flutterfire v1.4.0) and&&-chains acpto the stable committed path atlib/generated/firebase/GoogleService-Info-{flavor}-{buildType}.plistfollowed byrm. Previously--ios-outwas set to the stable path directly, causing flutterfire v1.4.0 to throwValidationException: --ios-out basename must be exactly GoogleService-Info.plist.
- DEF-019 (
-
0.4.604 Jul 2026Release notes
Open source →Added
- DEF-017: New
validate-testspecCLI command — validatesanntestspec.yamlstandalone, exits 1 if not found or if the file contains errors. Supports--format jsonfor machine consumption (CI-friendly). Thevalidatecommand also runs testspec validation automatically and includes atestspeckey in its JSON output. - DEF-017:
syncnow addsgem 'ann-flavor-cocoapods'to the Gemfile when iOS is configured inannspec.yaml. Previously the CocoaPods plugin gem was never added automatically, causingpod installto fail with "pluginann-ios-flavorizenot installed".
Fixed
-
DEF-018: Generated
firebase.shnow setsexport CI=trueat the top of the script. This suppressesflutterfire's ANSI escape codes and spinner sequences ([A[2K⠹ …) when the script is run in an IDE terminal or any non-TTY context. -
DEF-014:
firebase.shnow writesgoogle-services.jsonandGoogleService-Info.plisttolib/generated/firebase/with stable flavor/buildType-scoped filenames instead of routing them to$ANN_TEMP_DIR. These files are safe to commit and are read by the Gradle and CocoaPods build plugins on every build.syncnow appends.gitignoreentries to prevent the build-plugin target copies (android/app/src/**/google-services.jsonandios/**/GoogleService-Info.plist) from being committed.The script cleanup step is narrowed from
rm -rf lib/generated/firebase/*torm -f lib/generated/firebase/*_firebase_options.dartso committed JSON/plist sources are not wiped on re-run.
- DEF-017: New
-
0.4.504 Jul 2026Release notes
Open source →Fixed
- DEF-006:
_patchSettings()now updates the Gradle plugin version in-place when the entry already exists but carries a stale version, for both KTS and Groovy DSL. Previously only the first-time insertion path wrote the correct version.
Changed
-
--firebase-modedefault changed fromruntoscript(breaking change in default behaviour)dart run ann_flutter_flavor syncnow generateslib/generated/scripts/firebase.shby default instead of executingflutterfire configureinline. This prevents the sync step from hanging when Firebase auth is not available at sync time.Migration: if you relied on the old inline-execution default, add
--firebase-mode inlineexplicitly. The--firebase-mode runvalue has been removed — useinlineinstead.Old New dart run ann_flutter_flavor syncEquivalent to --firebase-mode inline(old) → now--firebase-mode script(default)dart run ann_flutter_flavor sync --firebase-mode runUse --firebase-mode inlinedart run ann_flutter_flavor sync --firebase-mode scriptUnchanged
- DEF-006:
-
0.4.303 Jul 2026Release notes
Open source →Version sync — updated bundled Gradle plugin reference (
kGradlePluginVersion) to 2.0.11 (firebase android default fix). No Flutter CLI behaviour changes.
-
0.4.201 Jul 2026Release notes
Open source →Comments in generated Podfile and Gemfile —
plugin 'ann-ios-flavorize'inios/Podfileandgem "ann-flavor-flutter"inGemfileare now preceded by a comment explaining they were added byann_flutter_flavor, making it clear these lines should not be removed manually.applicationIdandminSdkno longer overwritten —syncno longer rewritesdefaultConfig.applicationIdorminSdkinandroid/app/build.gradle(.kts). These values are owned by the developer; per-flavorapplicationIdis managed by the ANN Gradle plugin at Gradle sync time.Firebase script improvements —
--firebase-mode scriptnow generates a more robust shell script: old generated files are cleaned before re-running, eachflutterfire configurecall reports success/failure individually, and a summary is printed at the end. The script exits with a non-zero code if any command failed.Accurate
flutterfire configurearguments — the generated commands (bothrunmode andscriptmode) now include-i/-a(bundle ID) and--ios-build-config(e.g.Release-ledger_in), ensuring flutterfire targets the correct registered app and Xcode build configuration in multi-flavor projects. -
0.4.101 Jul 2026Release notes
Open source →service_account4-level cascade —service_accountcan now be placed atdefault.firebase.service_accountorflavor.<n>.firebase.service_accountto share one key across all build types without repetition. Full cascade (most-specific wins):flavor.<n>.build_types.<bt>.firebase.service_accountflavor.<n>.firebase.service_accountdefault.build_types.<bt>.firebase.service_accountdefault.firebase.service_account
-
0.4.001 Jul 2026Release notes
Open source →--firebase-mode script—syncaccepts--firebase-mode scriptto writelib/generated/scripts/firebase.shinstead of runningflutterfire configureinline. Use when Firebase auth is unavailable at sync time (e.g. the service account is decoded in a later CI step). The generated script navigates to the project root automatically.iOS
config_fileguard — sync now aborts with a clear error when an iOS firebase block hasconfig_filewithoutproject_id. iOS must useproject_idmode; config_file is Android-only.syncpre-flight validation —syncnow runsvalidatebefore generating any files. If the spec has errors, sync aborts immediately with exit 1 and no files are written. Warnings are printed but generation continues.Step reorder — Firebase (
flutterfire configure) now runs after the fast deterministic steps (Dart → Android → iOS) instead of second. New step order:[0]validate →[1]Dart →[2]Android →[3]iOS →[4]Firebase →[5]Fastlane →[6]Melos.--format json—syncandvalidateaccept--format jsonto emit the pre-flight result as machine-readable JSON on stdout. All other output goes to stderr. Useful for IDE integrations and CI pipelines.doctorcommand — replacesversion. Shows theann_flutter_flavorversion and checks each linked plugin's installed version against the expected target. The oldversioncommand has been removed.Firebase:
config_fileon iOS is now a hard error —syncexits 1 immediately when an iOS firebase block containsconfig_file. iOS must useproject_id(which triggersflutterfire configureto generate the options file). See the Firebase Setup section in the README for setup guidance. -
0.3.001 Jul 2026Release notes
Open source →Firebase service account auth —
flutterfire configurenow authenticates exclusively via theservice_accountfield inannspec.yaml. ADC (gcloud auth) andfirebase loginare no longer used or supported. Setservice_accountin your firebase block alongsideproject_id;syncwill warn ifproject_idis set without a service account.validate --format json— thevalidatecommand now accepts--format json, emitting a single JSON object on stdout with all errors and warnings. Exit code 1 when any error is present. Used by the Studio plugin (1.1.0) for IDE-integrated validation.versioncommand — new command that readspubspec.lock,android/settings.gradle.kts, andGemfile.lockto compare installed plugin versions against expected targets. Exits 1 when any detectable plugin is outdated.Firebase validation improvements — new checks:
- Error:
firebase.filekey (renamed toconfig_filein 0.1.6) is now a hard error with a migration hint - Warning:
project_idset without aservice_account - Warning:
service_accountset alongsideconfig_file(ineffective) - Warning:
integrations.firebase: trueset but no firebase blocks configured in spec
- Error:
-
0.2.501 Jul 2026 -
0.2.430 Jun 2026Release notes
Open source →120-second timeout on
flutterfire configure— prevents sync from hanging indefinitely when auth prompts or network issues stall the FlutterFire CLI.Signing path resolution — relative cert/key paths in
credentials.signingare now resolved to absolute paths before being passed to Gradle, preventing build failures whenpod installorgradleare invoked from a different working directory. -
0.2.227 Jun 2026Release notes
Open source →Redesigned
summarycommand — output is now organised by flavor × build type, showing fully resolved (cascaded) values for every field:- Each flavor has a block per build type (
release,debug, …) - Every field shown is the effective value after the default → flavor → build type cascade: id, name, version, firebase, auth, admob, stores, custom, and Android build-type flags
- When no flavors are defined, the default values are shown per build type
- The old top-level "default" block is removed
- Each flavor has a block per build type (
-
0.2.127 Jun 2026Release notes
Open source →enabled: falsesupport in validate — ifannspec.yamlsetsenabled: false, thevalidatecommand now shows a warning at the top explaining that all plugins will ignore the file, while still running full structural validation on the rest of the spec.Improved
validateoutput — every error and warning now shows:- The exact YAML path where the problem is (e.g.
app.android.flavor.free.stores.google_play.priority) - A precise description of what is wrong
- A
→fix hint telling you what to add, change, or remove
Also: parse-time errors (missing
app:root key, oldannai_app:key) now print a clear message with a migration hint instead of a raw Dart type error. - The exact YAML path where the problem is (e.g.
-
0.2.027 Jun 2026Release notes
Open source →Breaking:
annai_app:root key renamed toapp:—annspec.yamlfiles using the oldannai_app:root key must be updated. The CLI shows a clear migration hint if the old key is detected. -
0.1.927 Jun 2026Release notes
Open source →Internal pub.dev score improvements (documentation, example, analysis options). No user-facing behaviour changes.
-
0.1.727 Jun 2026Release notes
Open source →Expanded
validatecommand — comprehensive field-level checks across the entire spec: bundle IDs, version formats, firebase mode conflicts, store IDs, signing paths, and unknown field detection. -
0.1.626 Jun 2026Release notes
Open source →buildTypeauto-detection —AnnFlavor.buildTypeis now derived automatically from Dart'skDebugMode/kReleaseMode. ThebuildTypeparameter is no longer needed inAnnFlavor.init().flutterfire configureinvoked directly during sync — removes the generatedfirebase.shshell script. Firebase configuration is now driven entirely by theproject_idfield inannspec.yaml.Firebase config refactored —
path,firebase_app_id, andbuild_targetfields are replaced by two mutually exclusive modes:config_file— path to a staticgoogle-services.json/GoogleService-Info.plistproject_id— runsflutterfire configureduring sync to generate options files
Example app added — a real
flutter createexample withfree/proflavors is included in the package. -
0.1.526 Jun 2026Nothing published for this version
-
0.1.426 Jun 2026Release notes
Open source →integrationsblock — new top-levelintegrations:key inannspec.yamlwithfastlaneandmelosflags. When enabled:fastlane: true—syncgenerates aGemfilewiring the Fastlane pluginmelos: true—syncpatches a managed block inpubspec.yamlwith Melos scripts
The managed block uses start/end markers so user-authored content outside the block is never overwritten.
-
0.1.325 Jun 2026Release notes
Open source →Internal publish pipeline improvements (per-plugin tagging, unified workflow). No user-facing behaviour changes.
-
0.1.015 Jun 2026Nothing published for this version