Skip to content

Instantly share code, notes, and snippets.

@LinuxDragon57
Created December 9, 2023 03:36
Show Gist options
  • Save LinuxDragon57/980a17ae496d7d265e8366bc3dcd27d5 to your computer and use it in GitHub Desktop.
Save LinuxDragon57/980a17ae496d7d265e8366bc3dcd27d5 to your computer and use it in GitHub Desktop.
Script to recursively change the permissions of all files within a directory without changing the permissions of subdirectories themselves
#!/usr/bin/bash
/usr/bin/sudo find $1 -type f -exec chmod $2 {} \;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment