How to add AndroidStudio in OSX command line

How to add AndroidStudio in OSX command line

1,235

If you prefer command line shortcuts like me, you've probably wanted to have your own shortcuts instead of moving through folders and opening them one by one, today I'll show you how to open your mobile app in android studio by using MacOS command line.

For Mac OS, open ~/.zshrc by this command

sudo nano ~/.zshrc

And then add following line

alias android="open -a /Applications/Android\ Studio.app" 

Now save the file then and reload it by this command

source ~/.zshrc

Now you able to open specific android project with Android Studio from terminal.

Let's try:

android /path/to/your/project

Or you can go to your android folder cd /path/to/your/project then type

android .



- Last updated 1 year ago

Ads

Be the first to leave a comment.

You must login to leave a comment