How to create your own alias for “php artisan” command on cmder

Don Ejeh
2 min readApr 1, 2021

--

If there is one out of many pain in the A** laravel developer faces especially when building laravel project is continuously typing **php artisan** command for almost laravel artisan command via terminal. This step also can be applied to any repeatable command you normally type when developing an application or working via terminal.

Lets get started:-

STEP 1
=> Get **Cmder** [Download link](https://cmder.net/) or if you have **Laragon** already installed cmder comes preinstalled.

STEP 2
=> Go to your Laragon installation folder as for me, I install my laragon app at **C:\laragon** as shown below :-

laragon location

STEP 3
=> To locate cmder goto `C:\laragon\bin\cmder`

cmder path

STEP 4
=> To add an **alias** `C:\laragon\bin\cmder\config`

cmder user_aliases locaton

Locate a file `user_aliases.cmd` and open it.

Adding Aliases
You can add aliases using the alias command. Aliases added using the alias command will be immediately available and persist across Cmder sessions. For our case type `pa=php artisan $*` as shown below:-

adding php artisan alies

After following all the steps above down to writing down all your aliases aka nickname or pseudo-name you can save your changes. Then open your *cmder* and type `pa` as shown below:-

pa alies commad working

Congratulation for solving one pain out of many you have when working with repeatable command on cmder.

Thanks for reading!

Remember the like

Any question? drop it at the comment box let see how we can resolve it….

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Don Ejeh
Don Ejeh

Written by Don Ejeh

Techpreneur | Developer | Content Creator | Software Developer @uniccongroup

No responses yet

Write a response