I removed my permissions on my downloads folder using chmod.

can anyone help restore back to default?

Thanks!

    • Eager Eagle
      link
      English
      119 months ago

      useful 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 -- {} +
      
      • @toynbee
        link
        39 months ago

        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 of ugo for user, group or other.

    • Possibly linux
      link
      fedilink
      English
      3
      edit-2
      8 months ago

      Don’t give all your files execution permissions.

      chmod 644 -R Downloads
      chmod +x Downloads