Skip to content

Instantly share code, notes, and snippets.

@samirfor
Last active August 29, 2015 14:23
Show Gist options
  • Save samirfor/41e930013ee5a1d670bd to your computer and use it in GitHub Desktop.
Save samirfor/41e930013ee5a1d670bd to your computer and use it in GitHub Desktop.
#!/bin/bash
# As permissões são setadas recursivamente, ou seja,
# todos os arquivos/pastas dentro do local onde o script
# vai ser executado (no caso, ./) e tudo que está abaixo
# deste local.
echo "Setando permissoes 755 em diretorios..."
find $1 -type d -exec chmod 755 {} \;
echo "Setando permissoes 644 em arquivos..."
find $1 -type f -exec chmod 644 {} \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment