Skip to content

Commit

Permalink
Trap cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
bahner committed Mar 3, 2024
1 parent 30bf860 commit d0507e2
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions termux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@

set -eu

trap cleanup EXIT

BINDIR="${PREFIX}/bin"
WGET_OPTS="-qO"

Expand All @@ -17,6 +19,11 @@ GO_MA_ACTOR_URL="https://github.com/bahner/go-ma-actor/releases/download/${GO_MA
export GO_MA_ACTOR_ACTOR_NICK="${GO_MA_ACTOR_ACTOR_NICK:-termux}"
export GO_MA_ACTOR_API_MADDR="/ip4/127.0.0.1/tcp/5001"

cleanup() {
rm -rf "${GO_MA_ACTOR}"*
rm -rf i"${KUBO_TARBALL}"*
}

install_wget() {
pkg install wget
}
Expand Down

0 comments on commit d0507e2

Please sign in to comment.