mirror of
https://gitlab.com/shorewall/code.git
synced 2025-08-09 15:41:19 +02:00
Allow AUTOMAKE=<depth> to specify search depth
Signed-off-by: Tom Eastep <teastep@shorewall.net>
This commit is contained in:
@ -281,10 +281,15 @@ get_config() {
|
||||
|
||||
case $AUTOMAKE in
|
||||
Yes|yes)
|
||||
AUTOMAKE=1
|
||||
;;
|
||||
No|no)
|
||||
AUTOMAKE=
|
||||
;;
|
||||
[1-9])
|
||||
;;
|
||||
[1-9][0-9])
|
||||
;;
|
||||
*)
|
||||
if [ -n "$AUTOMAKE" ]; then
|
||||
fatal_error "Invalid AUTOMAKE setting ($AUTOMAKE)"
|
||||
@ -397,10 +402,10 @@ uptodate() {
|
||||
#
|
||||
# Busybox 'find' doesn't support -quit.
|
||||
#
|
||||
if [ -n "$(${find} ${dir} -maxdepth 1 -type f -newer $1 -print)" ]; then
|
||||
if [ -n "$(${find} ${dir} -maxdepth $AUTOMAKE -type f -newer $1 -print)" ]; then
|
||||
return 1;
|
||||
fi
|
||||
elif [ -n "$(${find} ${dir} -maxdepth 1 -type f -newer $1 -print -quit)" ]; then
|
||||
elif [ -n "$(${find} ${dir} -maxdepth $AUTOMAKE -type f -newer $1 -print -quit)" ]; then
|
||||
return 1;
|
||||
fi
|
||||
done
|
||||
|
Reference in New Issue
Block a user