Created
June 16, 2014 21:24
-
-
Save jeremyjs/5310cf8f0a767672fffb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Create file | |
$ touch /tmp/file.tmp | |
$ l /tmp/file.tmp | |
-rw-r--r-- 1 jmeyer1 wheel 0B Jun 16 15:59 /tmp/file.tmp | |
# Change owner to root | |
$ sudo chown root /tmp/file.tmp | |
$ l /tmp/file.tmp | |
-rw-r--r-- 1 root wheel 0B Jun 16 15:59 /tmp/file.tmp | |
# Change permissions | |
$ sudo chmod 755 /tmp/file.tmp | |
$ l /tmp/file.tmp | |
-rwxr-xr-x 1 root wheel 0B Jun 16 15:59 /tmp/file.tmp | |
# Change permissions for root | |
$ sudo chmod g=rx /tmp/file.tmp | |
$ l /tmp/file.tmp | |
-r-xr-xr-x 1 root wheel 0B Jun 16 15:59 /tmp/file.tmp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment