Finch CLI
Finch provides a command-line interface (CLI) for managing and interacting with your Finch applications. The CLI offers a range of commands to simplify common tasks, making it easier to develop, test, and deploy your applications.
In addition to the commands provided by Finch, you can also use any other Dart CLI commands. For example, you can use the dart pub get command to get the dependencies of your project. its optional to use the Finch CLI or you can use the Dart CLI directly.
Install Finch CLI
dart pub global activate finch
Run Finch CLI
To see the list of available commands, run the following command:
finch -h
✔ templates
Show the list of available templates
✔ create
Make new project
-p, --path Path of the project
-n, --name Name of project
-d, --docker Use docker
-t, --template Project template [simple, example,...]
✔ get
Get packages of project, (dart pub get)
✔ runner
Build runner of project, (dart pub run build_runner build)
✔ run
Run project, (dart run)
-p, --path Path of app file
-a, --args Arguments for app file
✔ serve
Serve project with file watcher
-p, --path Path of app file
-a, --args Arguments for app file
✔ build
Build Project (dart compile exe)
-c, --cli Build for cli
-a, --appPath Path of app file
-l, --langPath Languages path
-p, --publicPath Public path
-w, --widgetPath Widgets path
-e, --envPath Envitoment file (.env) path
-o, --output Output path
-t, --type Type of build (zip, exe)
✔ migrate
Migrate project to new version of Finch
-c, --create Create new project and move files
-n, --name Name of migration file (only for create option)
-s, --sqlite Migrate SQLite files
✔ test
Unit test of project, (dart test)
-r, --reporter Set how to print test results
-h, --help Show the help
-v, --version Finch Version
-u, --update Update Finch