Atom editor "permission denied" | OSX 10.9.4 Mavericks - macos

Just switched to OSX from windows, so sorry if this is a simple fix.
Every time I create a new file within Atom I get this error.
EACCES, permission denied '{File Path}.'
I have already changed the permissions of the actual app in the applications folder but does not seem to have worked.
I also noticed when I save files Atom Helper will prompt me for a password at random.
Obviously something is wonky.
Thanks in advance for any help!

Nvm, figured it out.
Turns out the particular folder was generated by Jekyll using "sudo" inside my shell script.
If I generate a new project sans sudo it works fine.

Independent of what has caused the folder content to be not writable, a simple workaround is to open your file in Atom from terminal (like how described here) but prepend sudo to open Atom as super user, e.g.
sudo atom myfile.txt

Related

zsh: permission denied: webstorm - On Attempting to Create Shell Script That Launches WebStorm

I am following the documentation on creating a Shell script that launches the WebStorm application for a given file folder as described on WebStorm Help page. I am currently using an M1 Pro Macbook (2022) that I just got today and has little else installed beyond Homebrew, VSCode, WebStorm, and PyCharm.
Following the example in the docs, I created a file called webstorm (without any extension) in usr/local/bin and added the following code to it:
#!/bin/sh
open -na "WebStorm.app" --args "$#"
After starting up a new terminal, and running webstorm ., I get the following error in my terminal:
zsh: permission denied: webstorm
I have:
Changed sh to zsh as my default shell is zsh, and that made no difference.
Checked my permissions for both usr/local/bin and usr/local/bin/webstorm to ensure that I have the correct permissions to execute files from here. When right clicking on the webstorm file and clicking "Get Info", I can see that I currently have read and write permissions.
Restarted my computer
To add to my confusion, I have used the same script in the same location on my work Macbook, and it has worked without issues.
Any help on this would be hugely appreciated.
Checked my permissions for both usr/local/bin and usr/local/bin/webstorm to ensure that I have the correct permissions to execute files from here. When right clicking on the webstorm file and clicking "Get Info", I can see that I currently have read and write permissions.
Do you have the "execute" permission?
Try:
$ chmod +x /usr/local/bin/webstorm

Mac terminal no acces to files

The terminal of my mac cant acces files in the documents folder. I get the following error:
zsh: permission denied
In system preferences I have given the terminal full disk acces. And when I go to the documents folder -> get info -> my username has read and write rights.
I have also ran chmod 777 on the folder but nothing seems to work. Does someone know what causes this problem?
Edit: it turns out that I cant acces a single file with te terminal. It looks like my terminal doesn't have the rights it should.
I fixed the issue! Nothing seemed to work so I wanted to reset the terminal. To do that I had te remove the following file:
~/Library/Preferences/com.apple.Terminal.plist
Then I restarted the terminal and now I can acces my files again!

Basic terminal commands not working after trying to install Composer

My mac terminal is completely dysfunctional! Every time I open terminal I get this message:
-bash: export: `/Applications/MAMP/bin/php/php5.5.10/bin/:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/opt/X11/bin': not a valid identifier
The problem came about a while ago, I believe I was attempting to install composer to work with MAMP.
Today I started a beginner tutorial on how to use the Terminal and almost every command does not work such as the basic mkdir , ls , and touch (to make folder, list items, and make a file respectively), (screenshot attached).
I have already tried deleting the ~/Library/Preferences/com.apple.Terminal.plist file. Your help is greatly appreciated.
I am working with Mac OS X 10.10.2
screenshot of terminal after making basic commands
It looks like you have an error in your .bash_profile or other startup script. Open it on terminal using vi ~/.bash_profile or some other editor of your choice and comment out that line, then type source .bash_profile to reload it.

I can't get ShoesRB to install in Ubuntu 14. Is the issue the .run or .install file types?

Whenever I attempt to open the ShoesRB install files for Linux, which are both "script.run" and "script.install" files, they open in a text editor instead of an installer. When I attempt to run them in the terminal, I'm getting strange root authentication errors. I know the root password is correct.
Does anybody know how to correctly install ShoesRB in Ubuntu 14?
First of all download the executable from http://shoesrb.com/downloads/ according to your linux machine. This you have already done. On double clicking the downloaded .run file (say filename.run), you might not be able to run it because it would not be having executable permission -
This you can change by right clicking the script -> properties -> permissions -> Check the 'Allow executing file permission'
Or
from terminal by
chmod +x filename.run
Next you need to run this by:
sudo ./filename.run
Enter correct root password and you are good to go. This script actually make a hidden .shoes directory in your home and all shoes related files and executable are present in there. It also copies a desktop entry for shoes to /user/share/application, which you open to open shoes applications.
Moreover you can copy that desktop entry to your desktop and make it executable by:
cp /usr/share/applications/shoes.desktop ~/Desktop/shoes.desktop
chmod +x ~/Desktop/shoes.desktop
All done! Just double click the shoes icon on your desktop you can open your shoes apps now.
Hope it Helps :)

Where is this file supposed to be?

When I looked on my desktop I noticed the file "git-credential-osxkeychain" is on there.
I'm assuming it's a git file, but don't know how it managed to end up on my desktop. Where is it supposed to be?
I believe it's supposed to be in /usr/local/bin/git-credential-osxkeychain
Look at this post:
Trying to install git on OSX: cannont exec 'git-credential-osxkeychain': Permission denied`

Resources