Extending conffiles to allow config/., config/., as well as config/, config/. and config/..
This commit is contained in:
parent
e40202da69
commit
3773ed2765
|
@ -11,8 +11,13 @@ set -e
|
|||
|
||||
Read_conffile ()
|
||||
{
|
||||
FILE="${1}"
|
||||
FILES="${1} ${1}.${LH_ARCHITECTURE} ${1}.${DISTRIBUTION}"
|
||||
FILES="${FILES} config/$(echo ${PROGRAM} | sed -e 's/^lh_//')"
|
||||
FILES="${FILES} config/$(echo ${PROGRAM} | sed -e 's/^lh_//').${ARCHITECTURE}"
|
||||
FILES="${FILES} config/$(echo ${PROGRAM} | sed -e 's/^lh_//').${DISTRIBUTION}"
|
||||
|
||||
for FILE in ${FILES}
|
||||
do
|
||||
if [ -f "${FILE}" ]
|
||||
then
|
||||
if [ -r "${FILE}" ]
|
||||
|
@ -23,4 +28,5 @@ Read_conffile ()
|
|||
Echo_warning "Failed to read configuration file ${FILE}"
|
||||
fi
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue