Improve exit code handling

This commit is contained in:
Michael De Roover 2020-11-15 09:53:25 +01:00
parent a7708b7545
commit 35450e026f
Signed by: vim
GPG Key ID: 075496E232CE04CB
1 changed files with 8 additions and 3 deletions

11
cv
View File

@ -117,6 +117,11 @@ else
result
fi
# FIXME: Dirty patch, needs to be improved asap
[ ! -f $data/$date-$country ] && rm $data/$date-$country-out
true
# Cleanup and exit code handling.
if [ ! -f $data/$date-$country ]
then
rm $data/$date-$country-out
exit 1
else
exit 0
fi