Home > Software design >  How can I make a program executable from everywhere in a MACOS Monterey 12.01
How can I make a program executable from everywhere in a MACOS Monterey 12.01

Time:11-29

I want to make nextflow https://www.nextflow.io/ or any other program executable from every directory in my MAC termninal.

I have done my research which says find the ~/.bashrc file and write in there

export PATH=$PATH:</path/to/file/>

In my MACOS Monterey 12.01 there is no ~/.bashrc file but a ~/.zshrc file. Shall I add the command on the ~/.zshrc or I have to create a ~/.bashrc. If I have to create a ~/.bashrc how do I do this?

Sorry for the basic question

CodePudding user response:

In the past, you had to decide, which of the terminal types you want to choose. Your tutorial is maybe already deprecated, because the change of the terminal system already appeared. Now it should be the ~/.zshrc or maybe the ~/.zshenv file, that does what you want.

On my MacOS Monterey 12.1 Beta the zshenv file is used to setup global things

CodePudding user response:

Why don't you add it to the ~/.zshrc and see if it works? My guess is that it does the job.

  • Related