chore: Apply shellcheck/shfmt suggestions
This commit is contained in:
parent
4095a83511
commit
f819f63559
2 changed files with 6 additions and 7 deletions
|
@ -195,10 +195,9 @@ until [[ $((nt + limit)) -gt ${dbcount} ]]; do
|
||||||
printf "\r"
|
printf "\r"
|
||||||
#for space in $(seq 1 "${COLUMNS}")
|
#for space in $(seq 1 "${COLUMNS}")
|
||||||
#do
|
#do
|
||||||
#printf " "
|
#printf " "
|
||||||
#done
|
#done
|
||||||
for space in $(seq 1 "${COLUMNS}")
|
for space in $(seq 1 "${COLUMNS}"); do
|
||||||
do
|
|
||||||
printf "\b"
|
printf "\b"
|
||||||
done
|
done
|
||||||
done < <(echo "${dbid}")
|
done < <(echo "${dbid}")
|
||||||
|
|
|
@ -12,10 +12,10 @@ loop() {
|
||||||
ky=$(echo "${y}" | sed -e "s/${folderescaped}/https:\/\/${url}/g" -e "s/-[0-9]*\..*\$//g")
|
ky=$(echo "${y}" | sed -e "s/${folderescaped}/https:\/\/${url}/g" -e "s/-[0-9]*\..*\$//g")
|
||||||
f=$(mariadb "${db}" -N -B -q -e "select photo from contact where photo like '${ky}%' limit 1")
|
f=$(mariadb "${db}" -N -B -q -e "select photo from contact where photo like '${ky}%' limit 1")
|
||||||
if [[ $? -eq 0 && -z ${f} && -f ${y} ]]; then
|
if [[ $? -eq 0 && -z ${f} && -f ${y} ]]; then
|
||||||
( ls -lh "${y}" && rm -rf "${y}" ) &
|
(ls -lh "${y}" && rm -rf "${y}") &
|
||||||
if [[ $(jobs -r -p | wc -l) -ge $(($(getconf _NPROCESSORS_ONLN) * 2)) ]]; then
|
if [[ $(jobs -r -p | wc -l) -ge $(($(getconf _NPROCESSORS_ONLN) * 2)) ]]; then
|
||||||
wait -n
|
wait -n
|
||||||
fi
|
fi
|
||||||
|
|
||||||
d=$((d + 1))
|
d=$((d + 1))
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Add table
Reference in a new issue