Flutter Architect is an open-source bootstrap CLI for Flutter project initialisation, distributed via NPM (Node Package Manager). It supports the generation of multiple boilerplate features. You are welcome to contribute with features and components yo udeem useful.
You can use this tool to generate Flutter projects for all platforms, but keep in mind that some components might be exclusive to Android and iOS.
To install the CLI, open a terminal and enter the following command.
npm install -g flutter-architect
Use Git Bash to run the following commands. If you're using VSCode, open View > Terminal (Ctrl+`). Click on the dropdown arrow next to the + icon in the terminal panel to pick >a new shell to open. If Git Bash is installed, it will be shown in the list.
dart compile exe lib/architect.dart -o architect.exe alias architect-dev="./architect.exe"You can also use the absolute path.
alias architect-dev="/Users/saynode/Documents/GitHub/flutter-architect/architect.exe" # "/Users/saynode/Documents/GitHub/flutter-architect/" is an example path, and likely not the same as yours.We recommend using the alias "architect-dev", so that it doesn't interfere with any live versions of the Architect instaleld through NPM.
On Mac and Linux add the following to your .bashrc file
alias architect="*absolute path to exe*"On windows edit the aliases file in C:\Program Files\Git\etc\profile.d\aliases.sh (as administrator)
alias architect="*absolute path to exe*"
Let's make an effort of keeping this list of commands updated as the project evolves.
Note
You can always use the help command to find assistance.
architect generate --help
To create a project, navigate to the desired location and use the following command.
architect new --name=<project_name> --ios --android <other_platforms> --org=<package_organization> # Note that a package organization is required.
Adds a service to handle a third-party API, as well as an higher level authentication service.
architect generate api
Complements the authentication service with platform-specific signin options.
architect generate signin --apple --google # You can choose to only add the Google option or only the Apple option.
Adds a service to handle connectivity events.
architect generate connectivity
Sets up Firebase, and adds Crashlytics logging.
architect generate crashlytics
Prepares the app to handle localization.
architect generate localization
Creates the native splash screen for the platforms the project has been initialized for.
architect generate splash
Creates both a secure storage service and a shared storage service.
architect generate storage
Creates both a secure storage service and a shared storage service.
architect generate storage
Imports the theme settings and colors from a Figma project.
architect generate theme
Imports the typography from a Figma project.
architect generate typography
Creates an upgrader service to manage app versioning.
architect generate upgrader
Adds web3 wallet integration.
architect generate wallet
Create a page, according to the MVC (Model-View-Controller) arquitecture.
architect generate page --name Home # The "name" parameter should be in Pascal Case.
Note
Additionally, you can use the parameters "--force" or "--remove".