mirror of
https://github.com/stack-auth/stack.git
synced 2026-06-13 21:01:21 +08:00
fix lint warning + remove invalid local in top-level loop
- Split single-line try/catch to satisfy max-statements-per-line - Remove `local` keyword from top-level for-loop (only valid in functions)
This commit is contained in:
parent
11531ebc4b
commit
7534637021
@ -662,9 +662,8 @@ for arch in "${TARGET_ARCHS[@]}"; do
|
||||
download_cloud_image "$arch" "$local_base"
|
||||
if [ "${SKIP_DOCKER_BUILD:-0}" = "1" ]; then
|
||||
log "SKIP_DOCKER_BUILD=1: reusing pre-built Docker bundle"
|
||||
local expected_bundle="$IMAGE_DIR/emulator-${arch}-docker-images.tar.gz"
|
||||
if [ ! -f "$expected_bundle" ]; then
|
||||
err "Pre-built bundle not found: $expected_bundle"
|
||||
if [ ! -f "$IMAGE_DIR/emulator-${arch}-docker-images.tar.gz" ]; then
|
||||
err "Pre-built bundle not found: $IMAGE_DIR/emulator-${arch}-docker-images.tar.gz"
|
||||
exit 1
|
||||
fi
|
||||
else
|
||||
|
||||
@ -151,7 +151,11 @@ function emulatorScriptsDir(): string {
|
||||
|
||||
// npm pack strips the execute bit from non-`bin` files, so restore it here.
|
||||
function ensureExecutable(scriptsDir: string): string {
|
||||
try { chmodSync(join(scriptsDir, "run-emulator.sh"), 0o755); } catch { /* best-effort */ }
|
||||
try {
|
||||
chmodSync(join(scriptsDir, "run-emulator.sh"), 0o755);
|
||||
} catch {
|
||||
// best-effort
|
||||
}
|
||||
return scriptsDir;
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user