GET STARTED
Installation
Ready to build with Codika? We'll guide you through setting up your development environment, installing the Codika CLI, and getting your access token - all you need to start building in minutes.
Prepare Your Machine
If you've already worked with Flutter development most of the tools should already be installed. If you're new to Flutter development you'll have to install some tools first. Here's what you'll need:
-
The standard version control system for managing your codebase. To verify that Git is installed, run the following command in your terminal:
git --version
While git comes preinstalled on most machines, if it's not installed, you can download it from the official website.
-
FVM (Flutter Version Management)
The Flutter SDK version manager to help you manage multiple Flutter versions. You simply need to install it by following the instructions here. Make sure to set a global Flutter version once installed.
-
The brick templating tool used by Codika to generate components and features. To install Mason, follow the instructions here.
-
A powerful tool that enables code push functionality for Flutter apps. Install it by following the instructions here. Once installed, you'll need to log in to your Shorebird account using the
shorebird login
command. -
The command-line interface for managing your Firebase projects and deploying cloud functions. Install it using npm with the following command or follow the instructions here:
npm install -g firebase-tools
Then authenticate with:
firebase login
-
The command-line tool for advanced Firebase and Google Cloud Platform management. Install it using Homebrew with the following command or follow the instructions here:
brew install google-cloud-sdk
Then authenticate with:
gcloud auth login
Install Codika
Codika is composed of a CLI and a component library. The CLI is an executable that you can run in your terminal. The component library is a collection of Mason bricks that you can use in your projects.
Install the CLI
To download and install Codika on your machine, run the following curl
command.
The script will verify that your setup is correct and install Codika globally on your machine.
curl -fsSL https://install.codika.dev/install | bash
Once the installation is complete you should be able to use the codika command.
Open a new terminal session and verify the installation by running the codika -h
command.
This should display all the commands available in the CLI.
Install the Codika Component Library
We still need to download the Codika Components. Those components are Mason bricks that are open source. To install them on your machine you'll have to run the following command :
codika install
What does it do?
This command will download the GitHub repository containing a bundled version of the mason bricks at : .codika/codika_bundled_blocks
.
It will also unbundle the blocks and add them globally to your mason environnement.
Verify Installation
To verify that the installation is complete codika provides a doctor command. This command will check that the CLI and the component library are installed correctly. It will also check that your machine is ready to build apps with Codika.
Run the following command to verify the installation:
codika doctor
Get Your Access Token
Time to get your Codika access token. During beta, we're working closely with our early users to ensure the best possible experience. Running any Codika command will prompt you for authentication - here's how to set it up:
- Run
codika configure
in your terminal and select 'Codika API Key' from the options. - Get in touch with our support team and send them the pin code shown in the terminal.
- Our team will handle the creation of the API key and automatically add it to your machine.
Next Steps
With Codika installed and configured, you're ready to start building! We recommend starting by going through the Quickstart Guide to create your first dummy project to get familiar with the CLI.
Then, you can start building your own app by following the Building Your First App guide. You'll learn how to create a new project with Firebase, add your first components and publish your app to the stores.
To follow the guide you'll need some additional configuration in order to complete the store publishing step. You can find a detailed guide here.