How to set aliases in Git Bash for Windows?

For windows 10:
Open folder “C:\Program Files\Git\etc\profile.d”
Edit file “” using Notepad++ or other text editor in Administrator mode.
Add another alias line beneath the present alias lines:
alias ls=’ls -F –color=auto –show-control-chars’
alias ll=’ls -l’
alias ngs=’ng serve –open’

Above is an alias ngs for serving angular development server and open a web browser.
Instead of typing “ng serve –open” in Git bash window you should now be able to just use ngs as an shortcut alias.

Leave a Reply