New answers tagged

2

Navigate to your user folder in Finder: /Users/username/ Make hidden files visible (the shortcut is ShiftCmd.) Right click .bash_profile and Open With... your text editor of choice. ShiftCmd. one more time in Finder to make hidden files invisible again. (Not required, just a good idea.)


3

There are a couple of things wrong in your ~/.zprofile: You have hard-wrapped (i.e., inserted newline characters inside) the alias lines, causing bin to start its own separate line. You need to keep everything on one line. Shell aliases that include whitespace need to be enclosed in quotes. You have multiple identical lines, which is generally not useful. ...


0

I had the same problem—installed brew, used it, but now it doens't work, ie, brew command not recognized anymore. The context of my brew-not-recognized-anymore problem is a bit more specific: I'm using iTerm instead of Terminal, I installed brew in the standard way to the standard place, I used brew to install zsh and oh-my-zsh, and at that point the brew ...


0

bash and zsh use different profile files. Instead of switching your shell you can add your export PATH line to ~/.zshrc for the change to take effect in zsh.


1

The best way in your case is to cd to the projects directory that you are looking at and run the shell command from there. executables can be run from the PATH as you have tried but also it you give the path to them. So for project1 cd /Users/My_Name/desktop/projects/project1 then run the script using a path ./scriptname.sh or use the shell directly sh ...


0

I realized that I was using zsh. To change I executed chsh -s /bin/bash to change my shell to bash.


0

I think Ted Wingly's answer is less likely to throw errors than the accepted answer ! It's always a good idea to use "quoted form of" in a path, in case names have spaces in them. The System Events version would actually throw up an error as it's written, if the file filename doesn't exist. to avoid the error, you'd need to write it like this : ...


Top 50 recent answers are included