Skip to content
Snippets Groups Projects
Verified Commit b697b00a authored by Nicolas KAROLAK's avatar Nicolas KAROLAK
Browse files

fix exit on error check

parent 12e4c8da
No related branches found
No related tags found
No related merge requests found
......@@ -11,8 +11,9 @@ echo "Testing apt-get install."
lock_timeout=120
lock_counter=0
tput sc
set +e
while fuser /var/lib/dpkg/lock >/dev/null 2>&1 ; do
sleep 1 && echo $lock_counter && (( lock_counter++ ))
sleep 1 && echo -n $lock_counter && (( lock_counter++ ))
tput rc
if (( $lock_counter > $lock_timeout )); then
echo "APT is reported as locked for more than $lock_timeout seconds now..."
......@@ -20,6 +21,7 @@ while fuser /var/lib/dpkg/lock >/dev/null 2>&1 ; do
exit 1
fi
done
set -e
echo "Clean repository."
apt-get clean
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment