Skip to content

Instantly share code, notes, and snippets.

View cyberlightdev's full-sized avatar

Mike cyberlightdev

View GitHub Profile
@cyberlightdev
cyberlightdev / Global Artisan
Last active February 10, 2019 01:32
Run Artisan commands from anywhere inside a Laravel Project Hierarchy.
#! /bin/bash
# NOTE: Artisan commands are run relative to the actual location of the `artisan` file, regardless of your Working Directory. This
# should have a negligible affect on functionality.
function artisan() {
CURRENT=`pwd`
FAIL=true
#This assumes all the laravel project(s) are located somewhere within your home directory (i.e. /Users/JefferyWay/Code/Project)