mirror of
https://github.com/apache/nuttx.git
synced 2026-05-29 04:19:37 +08:00
fixing problem with trap not removing tempdir
- needs to be in original dir to work
This commit is contained in:
@@ -24,7 +24,7 @@ set -e
|
|||||||
BASE_URL="https://dist.apache.org/repos/dist/dev/incubator/nuttx"
|
BASE_URL="https://dist.apache.org/repos/dist/dev/incubator/nuttx"
|
||||||
TEMPDIR="dist.apache.org"
|
TEMPDIR="dist.apache.org"
|
||||||
ORIGINAL_DIR="$(pwd)"
|
ORIGINAL_DIR="$(pwd)"
|
||||||
trap "rm -rf $TEMPDIR" EXIT
|
trap "{ cd $ORIGINAL_DIR; rm -rf $TEMPDIR; }" EXIT
|
||||||
|
|
||||||
function download_release() {
|
function download_release() {
|
||||||
wget -r -np -R "index.html*" -P . --cut-dirs 7 "$URL"
|
wget -r -np -R "index.html*" -P . --cut-dirs 7 "$URL"
|
||||||
|
|||||||
Reference in New Issue
Block a user