Skip to content

Commit

Permalink
make removal more robust
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewwall committed Jul 4, 2024
1 parent ad6330d commit 7ccb5a1
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions pkg/debian/prerm
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,14 @@ remove|upgrade)
invoke-rc.d weewx stop > /dev/null || true
fi
# remove any bytecompiled code
find /usr/share/weewx -name '*.pyc' -delete
find /usr/share/weewx -name __pycache__ -delete
find /etc/weewx/bin -name '*.pyc' -delete
find /etc/weewx/bin -name __pycache__ -delete
if [ -d /usr/share/weewx ]; then
find /usr/share/weewx -name '*.pyc' -delete
find /usr/share/weewx -name __pycache__ -delete
fi
if [ -d /etc/weewx/bin ]; then
find /etc/weewx/bin -name '*.pyc' -delete
find /etc/weewx/bin -name __pycache__ -delete
fi
;;
esac

Expand Down

0 comments on commit 7ccb5a1

Please sign in to comment.