How to make all files under a directory world readable on linux?

Rorchackh picture Rorchackh · Oct 29, 2012 · Viewed 59.5k times · Source

I want to make all files (and directories) under a certain directory world readable without having to chmod each file on its own. it would be great if there is an option to also do this recursively (look under folders and chmod 666 all files under it)

Answer

user529758 picture user529758 · Oct 29, 2012

man 3 chmod contains the information you are looking for.

chmod -R +r directory

the -R option tells chmod to operate recursively.