@Another_username to [email protected] • edit-28 months agoneed help restoring permissions on my downloads folderimagemessage-square49arrow-up162arrow-down18file-text
arrow-up154arrow-down1imageneed help restoring permissions on my downloads folder@Another_username to [email protected] • edit-28 months agomessage-square49file-text
I removed my permissions on my downloads folder using chmod. can anyone help restore back to default? Thanks!
minus-squareEager EaglelinkEnglish11•8 months agouseful for chown, less so for chmod: I almost never want my dirs and files with the same permissions, and I made this mistake a few times. find dir -type f -exec chmod 644 -- {} + find dir -type d -exec chmod 755 -- {} +
minus-square@toynbeelink3•8 months agoIf all you need is to restore read permissions, you could use symbolic rather than octal: chmod -R a+r $DIR If you don’t want to grant read permissions to everyone you can replace the a with whichever applies of ugo for user, group or other.
minus-square@[email protected]linkfedilink0•8 months agoGo over it with a second chmod -R but with -X to add execute but only to directories
useful for
chown
, less so forchmod
: I almost never want my dirs and files with the same permissions, and I made this mistake a few times.find dir -type f -exec chmod 644 -- {} + find dir -type d -exec chmod 755 -- {} +
If all you need is to restore read permissions, you could use symbolic rather than octal:
chmod -R a+r $DIR
If you don’t want to grant read permissions to everyone you can replace the
a
with whichever applies ofugo
for user, group or other.Go over it with a second chmod -R but with -X to add execute but only to directories