Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to give Sublime Text 3 write permission to files in web server's DocumentRoot?

I use Mac OS operating system for doing some local development and I don't want to change the default document root of Apache, which is /Library/WebServer/Documents/

I put my projects under that directory. But when I editing files, Sublime Text usually asks for the password when saving the changes. Without moving the projects to a less protected location, how can I let Sublime Text access those folders and files with full permission? What about changing the owner group to something and adding Sublime Text into that group? Apache user also must be in that group in order to allow it do file operations? Another option could be adding Sublime Text to _www group and chown'ing document root for _www group?

like image 806
hswner Avatar asked Nov 16 '13 13:11

hswner


People also ask

How do I fix Permission denied in Sublime Text?

Simply right click on that file and choose end process tree and then proceed with deleting or try to run your code again and if fails again then simply delete .exe and do build process again, and you are good to go.

How do I publish Sublime Text?

Publishing files to the server with SublimeStart Sublime Text. On the File menu, click Open Folder. Select the folder on your local computer where you want to want edit files, and then click OK. In the sidebar, right-click the name of the folder you selected in step 3, click SFTP/FTP, and then click Map to Remote.


1 Answers

The non command line is:

  • Open Finder
  • Go to the folder
  • Right Click
  • Get Info
  • There is a Sharing & Permissions area
  • If everything is grey out, just click on the padlock
  • Click on the Plus Sign
  • Add your mac user
  • Set Read & Write Permission

Done. Sublime text can save stuff now

like image 180
Ives.me Avatar answered Oct 02 '22 17:10

Ives.me