#!/usr/bin/env bash

source 'bin/config'
FILE='bin/fix'

echo ""

if npm --version > /dev/null; then
    info "Running npm"
    npm install
else
    warn "You need to run `brew install npm` first"
fi

echo ""

if composer --version > /dev/null; then
    info "Running composer"
    composer install
else
    warn "You need to run `brew install composer` first"
fi

echo ""
info "Copying .env"
cp .env.example .env

echo ""
info "Make sure to update your .env file!"

start .env

echo ""
info "Rodando o npm run dev"

npm run dev

echo ""
info "Fim!"