#!/usr/bin/env bash # Builds the firmware with the credentials from .env (see .env.example). # # ESP-IDF location comes from .cargo/config.toml (IDF_PATH / # ESP_IDF_TOOLS_INSTALL_DIR), so no ESP-IDF activation is needed here as long as # those point at an installation you already have. Drop them to let esp-idf-sys # fetch its own pinned ESP-IDF. set -euo pipefail cd "$(dirname "$0")/.." if [ -f .env ]; then set -a # shellcheck disable=SC1091 . ./.env set +a fi : "${WIFI_SSID:?set WIFI_SSID in .env (or export it) before building}" export WIFI_PASS="${WIFI_PASS:-}" cargo build --release "$@"