Skip to content

Setup the project

Let’s setup the project, but before make sure you have everything ready.

Prerequisites

ShipFlutter uses Flutter and Firebase. Before you start, make sure you have:

  1. Download and Setup Flutter

  2. Setup VS Code

  3. Setup Firebase CLI (more info)

    1. Install Firebase CLI

    2. Log into Firebase

      Terminal window
      firebase login
    3. Install the FlutterFire CLI by running the following command from any directory:

      Terminal window
      dart pub global activate flutterfire_cli

Initial setup

To setup the project and workspace follow these steps:

  1. Download project (either from the email or within the builder)

  2. Unzip and extract contents to your workspace

  3. Open with VSCode or Android Studio

  4. Run setup script

    Terminal window
    cd app && sh setup.sh
  5. The project should run but might not work yet since its missing Firebase configuration. Try it out!

    Terminal window
    flutter run

Firebase setup

In order to use Firebase in your project you will need to create or select a project, configure the app and the different services you need.

  1. Setup Firebase for your app (from within the app folder). This will start the setup process.

    Terminal window
    flutterfire config
  2. When prompted, say yes to override the firebase_options.dart.

  3. Select or create a Firebase Project

  4. Select the platform you want to support.

  5. A firebase_options.dart file will be created and all targets will be registered in your Firebase project.

  6. Now select the project you just created by running:

    Terminal window
    firebase use --add
  7. It will prompt for an alias. Just give it default

After these setps, the firebase setup is ready and the app can run but some Firebase service might not work yet. Additionally, each module might require additional configuration to work.

Running the app

Run the app by running:

Terminal window
flutter run

You can also select a target or run the app via VSCode or Android Studio (more info).