I have ubuntu installed on my local computer with apache / php / mysql.
I now have a directory at /var/www - inside which I have several of my ongoing projects. I also work with opensource ( drupal, magento, sugarcrm ).
The problem I am facing is changing file permission with terminal. Sometime I need to change the permission of entire folder and its subsequent sub-folders and files. I have to individually change using
sudo chmod 777 foldername
How can I do this recursively.
Also why do I have to always do it 777, I tried 755 for folders and 644 for files, but that won't work.
chmod -r blablabla
(small -r instead of -R) You might end up removing read permissions for everyone... – Cyril Duchon-Doris Jun 22 '15 at 14:42.htaccess
files with write permissions for apache.find /var/www/ | grep .htaccess | xargs ls -l
. – reynoldsnlp Sep 25 '18 at 02:10