Created
December 15, 2016 15:45
-
-
Save gobinathm/53d377fe8314c1a72d09548b2981dcbb to your computer and use it in GitHub Desktop.
Shell Script to Fix Home Folder permissions
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
cd $HOME | |
{ sudo chflags -R nouchg,nouappnd ~ $TMPDIR.. ; \ | |
sudo chown -R $UID:staff ~ $_ ; \ | |
sudo chmod -R -N ~ $_ ; \ | |
sudo chmod -R 755 ~ $_ ; \ | |
sudo chmod 700 Desktop Documents Downloads Dropbox Library Movies Music Pictures Sites $_ ; \ | |
sudo chmod 777 Public ; \ | |
sudo chmod 733 Public/Drop\ Box ; \ | |
} 2> /dev/null |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment