summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-10-09 21:27:57 (EDT)
committer P. J. McDermott <pjm@nac.net>2012-10-09 21:27:57 (EDT)
commit5c42b5e4fa5562616cddc7f18d368f147b04966b (patch)
tree8e8c545c3da7c46b1558f6a4c537a8006d42cb15
parentf4bce206f6119f8d4e2dac4aa92150a5ff16195d (diff)
Simplify and improve pathname pattern matching.
-rw-r--r--src/oh-installfiles.sh11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/oh-installfiles.sh b/src/oh-installfiles.sh
index 082aae5..3a19928 100644
--- a/src/oh-installfiles.sh
+++ b/src/oh-installfiles.sh
@@ -44,12 +44,11 @@ main()
chmod 755 "${pkg}.data"
while IFS="${files_ifs}" read -r pattern; do
- find 'dest' -path "${pattern}" | \
- while IFS="${files_ifs}" read -r file; do
- file="${file#dest}"
- mkdir -p "${pkg}.data/${file%/*}"
- ln "${PWD}/dest/${file}" "${pkg}.data/${file}"
- done
+ for file in dest/${pattern}; do
+ file="${file#dest}"
+ mkdir -p "${pkg}.data/${file%/*}"
+ ln "${PWD}/dest/${file}" "${pkg}.data/${file}"
+ done
done <"../${pkg}.pkg/files"
done
}