aboutsummaryrefslogtreecommitdiff
path: root/mkshrc
diff options
context:
space:
mode:
authorMitch Riedstra <mitch@riedstra.us>2018-04-10 14:45:53 -0400
committerMitch Riedstra <mitch@riedstra.us>2018-04-10 14:45:53 -0400
commit66b4b0f37c7923630ea42420b8cfc44210ffb987 (patch)
tree683e766eb8849b684bb5c232d6ea15edbeb75cd2 /mkshrc
parent2799bb7861773908a6c1870215ce87a6838671d9 (diff)
downloaddotfiles-66b4b0f37c7923630ea42420b8cfc44210ffb987.tar.gz
dotfiles-66b4b0f37c7923630ea42420b8cfc44210ffb987.tar.xz
Speed up the setperms function
Diffstat (limited to 'mkshrc')
-rw-r--r--mkshrc4
1 files changed, 2 insertions, 2 deletions
diff --git a/mkshrc b/mkshrc
index eb03e26..18ffb71 100644
--- a/mkshrc
+++ b/mkshrc
@@ -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() {