Follow symlink for elements

This allow custom elements to be added with symlink. Without -follow
a symlinked element is valid but scripts in *.d directory aren't used.

Change-Id: If50b7d9c3b1f6fe278c28488146709efe5cf065f
Closes-Bug: 1461124
This commit is contained in:
Tristan Cacqueray 2015-06-02 15:06:36 +00:00
parent 7c47679cf5
commit 356404f229

View File

@ -79,10 +79,10 @@ function generate_hooks () {
for _ELEMENT in $IMAGE_ELEMENT ; do
for dir in ${ELEMENTS_PATH//:/ } ; do
[ -d $dir/$_ELEMENT ] || continue
for _DIR in $(find $dir/$_ELEMENT -mindepth 1 -maxdepth 1 -type d -not -name tests); do
for _DIR in $(find $dir/$_ELEMENT -follow -mindepth 1 -maxdepth 1 -type d -not -name tests); do
copy_hooks_not_overwrite $_DIR
done
for _FILE in $(find $dir/$_ELEMENT -maxdepth 1 -type f); do
for _FILE in $(find $dir/$_ELEMENT -follow -maxdepth 1 -type f); do
cp -t $TMP_HOOKS_PATH -a $_FILE
done
break