Use umask

From wiki.network-crawler.de
Jump to: navigation, search

To calculate permissions which will result from specific umask values, subtract the umask from 777.

For example, if you want all files created with permissions of 666, set your umask to 000. If you want all files created with permissions of 000, set your umask to 777 or 666

Example: umask = 022 -> file permissions of 644 (rw-r--r--) and directories to be created with permissions of 755 (rwxr-xr-x).