diff options
| author | Mitch Riedstra <mitch@riedstra.us> | 2018-04-10 14:45:53 -0400 |
|---|---|---|
| committer | Mitch Riedstra <mitch@riedstra.us> | 2018-04-10 14:45:53 -0400 |
| commit | 66b4b0f37c7923630ea42420b8cfc44210ffb987 (patch) | |
| tree | 683e766eb8849b684bb5c232d6ea15edbeb75cd2 /mkshrc | |
| parent | 2799bb7861773908a6c1870215ce87a6838671d9 (diff) | |
| download | dotfiles-66b4b0f37c7923630ea42420b8cfc44210ffb987.tar.gz dotfiles-66b4b0f37c7923630ea42420b8cfc44210ffb987.tar.xz | |
Speed up the setperms function
Diffstat (limited to 'mkshrc')
| -rw-r--r-- | mkshrc | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -299,8 +299,8 @@ syschroot() { setperms() { dir_perms=$(echo $1 | awk -F: '{print $1}') file_perms=$(echo $1 | awk -F: '{print $2}') - find $2 -type f -exec chmod $file_perms {} \; ; - find $2 -type d -exec chmod $dir_perms {} \; ; + find "$2" -type f | xargs chmod "$file_perms" + find "$2" -type d | xargs chmod "$dir_perms" } timestamp() { |
