To run scripts, we use a Makefile. To execute a script in the project's root directory, open your terminal and enter the command.
For example, the command make all
will display a list of available commands to run.
make all
# Available tasks:
# - init_app: flutter clean, clean_ios, pub get, pub run build_runner, dart format -l 120
# - clean_ios: Clears local dependencies for iOS.
# - fvm_vscode: The script creates (or overwrites, if it already exists) a settings file for Visual Studio Code with a specific set of FVM parameters.
# - version: Installing the desired version of fvm and run pub get
# - codegen: build_runner build & dart format
# - intl_with_format: Intl generation with formatting
# - reset_goldens: Deletes all created golden tests and re-generates them.
# - check_coverage: The script allows you to automate the process of testing the coverage of the source code of the Flutter project and generating the corresponding report.
# - spider_build: Runs spider build, formats the code, runs golden tests.
# - umbrella_gen: As a result of the script, an umbrella file with export instructions will be created or updated for all DTO files in a certain directory, excluding those that were generated (i.e. file names with .g.dart). The directory is set by the user.
# - format: fvm dart format -l 120 lib test
It starts before the first start. Does:
- flutter clean
- clean_ios
- flutter pub get
- flutter pub run build_runner
- dart format -l 120 lib test
Clears local dependencies for iOS.
The script creates (or overwrites, if it already exists) a settings file for Visual Studio Code with a specific set of FVM parameters.
Runs spider build, formats the code, runs golden tests.
Installing the desired version of fvm and run pub get
Generate API layer from Swagger.
build_runner build & dart format
Intl generation with formatting
Deletes all created golden tests and re-generates them.
The script allows you to automate the process of testing the coverage of the source code of the Flutter project and generating the corresponding report.
fvm dart format -l 120 lib test