Overview

This guide walks you through setting up your local development environment and running the FieldForce app for the first time.

Prerequisites

Before you begin, install the following tools:
iOS builds require macOS. If you are on Linux or Windows you can still build for Android; iOS requires a Mac (or Codemagic CI — see the CI/CD guide).

1. Install Melos

Melos is the tool that coordinates commands across all packages in the workspace.
Add the Dart pub global binaries to your PATH if not already there:

2. Navigate to the mobile workspace

The Flutter workspace lives inside the monorepo:
All commands below are run from this directory.

3. Install dependencies


4. Run code generation

The project uses code generators (Freezed, Riverpod, slang). Generated files are committed to Git, so you normally don’t need to run this on first checkout — but if you see .freezed.dart or .g.dart files missing or out of date, run:

5. Run the app

Config files live alongside the app. For local development, use the dev flavor:
The dev.json file points to:
  • API_BASE_URL: your local Go backend
  • POWERSYNC_URL: your local PowerSync service
The backend must be running for auth and sync to work. Check the Go backend and PowerSync getting-started guides if you need to spin those up locally.
For a specific device, list connected devices first:

6. Verify everything works

Once running, you should be able to:
  • See the login screen
  • Sign in with a dev account
  • See the tasks list (may be empty on a fresh database)
If you see sync errors, check that the PowerSync service is running and that POWERSYNC_URL in config/dev.json is correct.

Key daily commands

Run these from mobile/flutter/:

Project structure at a glance


Next steps