Notice: You're viewing an old version of the Nylo documentation.
Consider upgrading your project to Nylo 5.20.0.
Getting Started

Installation



Install

You should have Flutter installed from the previous step

git clone https://github.com/nylo-core/nylo.git nylo_app

You will need to run flutter pub get on the project to fetch all the packages.


Adding your .env file

You will also need to add a .env file to your project at the root level. If you've downloaded Nylo through our site or on GitHub then this might already be there.

From the terminal, you can run the below command.

cp .env-example .env

Or if you have the Metro Cli tool alias you can do the below

flutter pub run nylo_framework:main project:init

You must add this because the project won't build without it.



Running the project

Once you have done the above steps, try to run the project.

You should be greeted with Nylo's default landing screen for new projects.



Metro CLI tool

Nylo provides a useful CLI tool called Metro. It's been built to make creating things in your project easier, the below list shows what you can create:

  • Models
  • Controllers
  • Pages
  • Stateful widgets and stateless widgets
  • Building your app icons

You can use Metro by running the following command:

  • flutter pub run nylo_framework:main

This command is long to type and hard to remember so you can also add a bash alias into your bash_profile.


Installation for Mac guide


  1. Open your bash_profile
sudo open ~/.bash_profile
  1. Add this alias to your bash_profile
...
alias metro='flutter pub run nylo_framework:main'
  1. Then run the following
source ~/.bash_profile

Can't find your bash_profile?

If you are unsure about where to add the above, check out some guides online for where to find your bash_profile. The above example assumes it's in your ~/ location but it could be in a different location or missing from your setup.