flutter_compat 0.1.1 copy "flutter_compat: ^0.1.1" to clipboard
flutter_compat: ^0.1.1 copied to clipboard

Analyze Flutter project compatibility across environment, dependencies, Android, and iOS before adding packages or upgrading. Like flutter doctor and dart pub outdated, with deeper cross-platform checks.

flutter_compat #

Analyze Flutter project compatibility across environment, dependencies, Android, and iOS — before you add packages or upgrade.

Like flutter doctor and dart pub outdated, with deeper cross-platform checks.

Install #

dart pub global activate flutter_compat

Or run from source:

dart pub get
dart run flutter_compat doctor

Commands #

doctor #

Scan the complete project and print a human-readable report.

flutter_compat doctor
flutter_compat doctor --packages
flutter_compat doctor -v

Example:

✓ Flutter 3.44.9 (stable)
✓ Dart 3.12.2
✓ Gradle 8.14
✓ AGP 8.8.2
✓ Kotlin 2.1.20
✓ JDK 17
✓ Xcode 16.0
✓ Swift 6.0
✓ CocoaPods 1.16.0

Warnings:
⚠ Package X requires Dart >=3.12

Errors:
✗ Kotlin incompatible with AGP

check #

CI/CD validation with exit codes:

Code Meaning
0 Success
1 Warnings
2 Errors
flutter_compat check
flutter_compat check --packages --quiet

add #

Pre-flight check a package, then optionally run flutter pub add.

flutter_compat add firebase_core
flutter_compat add firebase_core --dry-run
flutter_compat add http --dev -y

Flow:

  1. Fetch pub.dev metadata
  2. Check Flutter / Dart / Android / iOS constraints
  3. Detect conflicts & native requirements
  4. Ask for confirmation
  5. Run flutter pub add

update #

Check whether upgrades look safe for the current toolchain.

flutter_compat update

scan #

Raw scanner / environment dump (useful for debugging).

flutter_compat scan
flutter_compat scan --json

report #

Write JSON, Markdown, and HTML reports.

flutter_compat report
flutter_compat report -o build/reports --packages

Outputs:

  • compatibility_report.json
  • compatibility_report.md
  • compatibility_report.html

fix #

Apply safe upgrades for Flutter Android toolchain warnings (Gradle / AGP / Kotlin / minSdk).

flutter_compat fix --dry-run
flutter_compat fix -y

This is the same class of issues Flutter prints as:

Warning: Flutter support for your project's Gradle version will soon be dropped…

Confidence levels #

Symbol Meaning
Compatible
Possible conflict
Confirmed issue
? Unknown

Architecture #

CLI (args / cli_util)
  └── AnalysisService
        ├── Scanners (Flutter, Dart, Pubspec, Gradle, AGP, Kotlin, JDK, Android, iOS, Xcode, Swift, Pods, Packages)
        ├── CompatibilityEngine + Rules matrix
        └── PubDevRepository
              └── ReportWriter / DoctorPrinter

Compatibility rules #

  • Flutter ↔ Dart
  • Flutter ↔ Packages
  • Dart ↔ Packages
  • AGP ↔ Gradle
  • AGP ↔ Kotlin
  • Kotlin ↔ JDK
  • Gradle ↔ JDK
  • Package ↔ Native SDK
  • Xcode ↔ Swift
  • Pods ↔ Deployment Target

Development #

dart pub get
dart analyze
dart test
dart run flutter_compat doctor -C example

Future #

  • VS Code / Cursor extensions
  • GitHub Action
  • Auto-fix expansions
  • Interactive TUI / web dashboard

License #

MIT

2
likes
0
points
220
downloads

Documentation

Documentation

Publisher

unverified uploader

Weekly Downloads

Analyze Flutter project compatibility across environment, dependencies, Android, and iOS before adding packages or upgrading. Like flutter doctor and dart pub outdated, with deeper cross-platform checks.

Repository (GitHub)
View/report issues

Topics

#flutter #cli #compatibility #android #ios

License

unknown (license)

Dependencies

args, cli_util, http, io, meta, path, pub_semver, yaml

More

Packages that depend on flutter_compat