file_migration_tool 1.0.0
file_migration_tool: ^1.0.0 copied to clipboard
A CLI tool to migrate Flutter projects (dependencies, lib, assets).
file_migration_tool #
A Dart CLI tool to help migrate Flutter projects easily by handling dependencies, copying lib/
and assets/
folders, and updating pubspec.yaml
.
β¨ Features #
- π¦ Dependency Migration
- Merge dependencies from an old Flutter project (
--merge
) - Rewrite dependencies with the old projectβs ones (
--rewrite
)
- Merge dependencies from an old Flutter project (
- π Code Migration
- Copy the entire
lib/
folder (--copy-lib
)
- Copy the entire
- π¨ Assets Migration
- Copy the entire
assets/
folder (--copy-assets
)
- Copy the entire
π₯ Installation #
Activate globally from pub.dev:
dart pub global activate file_migration_tool
π Usage #
Run the tool inside your new Flutter project directory.
file_migration_tool --path <OLD_PROJECT_PATH> [options]
Options #
flags | functionality |
---|---|
--path , -p |
Path to the old Flutter project (required) |
--merge |
Merge dependencies from the old project into the new one |
- --rewrite |
Rewrite dependencies with the old projectβs dependencies |
--copy-lib |
Replace the lib/ folder with the one from the old project |
--copy-assets |
Copy the assets/ folder from the old project |
--help, -h |
Show usage information |
Example Usage #
Merge dependencies and copy lib folder #
file_migration_tool --path ../old_project --merge --copy-lib
Rewrite dependencies and copy assets #
file_migration_tool --path ../old_project --rewrite --copy-assets
Full migration #
file_migration_tool --path ../old_project --merge --copy-lib --copy-assets
π Changelog #
See CHANGELOG.md for details.
π¨βπ» Credits
Developed by Santosh Varma Addala
π License
This project is licensed under the MIT License - see the LICENSE file for details.