GithubHelp home page GithubHelp logo

fluttershortcuts's Introduction

Shortcuts to quickly start Flutter project on simulators/emulators

This oh-my-zsh plugin add shortcuts for Flutter to your terminal

How to install

Prerequisites

  1. zsh
  2. oh-my-zsh

Installation

Open terminal and paste the following lines. This will clone the repository to the right location, add flutter to the plugins located in ~/.zshrc and restart your shell.

git clone https://github.com/Schroefdop/flutterShortcuts.git ~/.oh-my-zsh/custom/plugins/flutter
while read line; do; if [[ $line == plugins* ]]; then; sed -i -e 's/plugins=(/plugins=(flutter /g' ~/.zshrc; fi;  done < ~/.zshrc
exec zsh

Configuration

For now there are two variables to configure.

FLUTTER_FLAVOR_NAME="staging"
FLUTTER_START_FILE="lib/main_staging.dart"

These variables should be set in ~/.zshrc. If these variables are not set, vanilla flutter run -d <deviceId> will run.

How to use

There are some aliases which shorten some of the longer Flutter commands

alias fa='flutter analyze'
alias fd='flutter devices'
alias fpg='flutter packages get'
alias frb='flutter pub run build_runner build --delete-conflicting-outputs' # Auto generate files
alias frw='flutter pub run build_runner watch' # Auto generate files continuous

The command fra, short for flutter run all will build and launch the application on all booted simulators/emulators.

The command fr, short for flutter run lets you choose on which device you want to build and launch your application. When only one simulator/emulator is active, it will build and launch on this one.

fluttershortcuts's People

Contributors

woutervermeijelements avatar schroefdop avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.