summaryrefslogtreecommitdiff
path: root/scripts/common
diff options
context:
space:
mode:
authorSerge Schneider <serge@raspberrypi.org>2018-10-15 09:12:13 +0100
committerSerge Schneider <serge@raspberrypi.org>2018-10-15 09:12:13 +0100
commitf8b629d6c7a3aec33edb3e0a60231e431eeaa8b7 (patch)
treefb5615434709515555f3924404ce8dfa731ecee1 /scripts/common
parent33e94c46f32fb2e9b1f7106d7a790f074815dfd1 (diff)
Check /debootstrap exists before trying to remove
Diffstat (limited to 'scripts/common')
-rw-r--r--scripts/common4
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/common b/scripts/common
index f3b5950..ad095b8 100644
--- a/scripts/common
+++ b/scripts/common
@@ -19,7 +19,9 @@ bootstrap(){
--arch armhf \
--keyring "${STAGE_DIR}/files/raspberrypi.gpg" \
"$1" "$2" "$3" || true
- rmdir "$2/debootstrap"
+ if [ -d "$2/debootstrap" ]; then
+ rmdir "$2/debootstrap"
+ fi
}
export -f bootstrap