Installing Laravel Globally on macOS Catalina

Installing Laravel Globally on macOS Catalina

Laravel comes with a command-line installer, once installed can be run anywhere from the terminal for installing a new Laravel application. In this post, I will be showing the necessary steps involved in installing with PATH configured properly.

First of all, install laravel installer using composer

composer global require "laravel/installer"


Now, open the zshrc file using nano

nano ~/.zshrc


After the zshrc file is opened add the following path to the bottom of the file

PATH="HOME/.composer/vendor/bin:$PATH"


Exit nano by pressing CTRL + X and save.


Run the following command to also make it available in the current session

source ~/zshrc


Now, the installer can be used anywhere by calling laravel new "your_project_name" without including the quotations.

Recent comments(2)

Milan
Milan
  • December 9, 2020

So, this is how you install Laravel on MacOS globally. I am gonna try installing ASAP!

Kopila
Kopila
  • December 5, 2020

Wow, nice article!

Please, Sign In to leave a reply