From 26f4ef498a8ce1aa456c7f25931107eee0dca563 Mon Sep 17 00:00:00 2001 From: Michael Richters Date: Sat, 31 Oct 2020 11:23:25 -0500 Subject: [PATCH] Set BOARD_HARDWARE_PATH correctly for run-docker on macOS Because ARDUINO_LOCAL_LIB_PATH was being set to a default value for other operating systems before checking the OS version, it would never get set correctly for macOS (unless it was already set externally). This change fixes that problem so that it's no longer necessary to set BOARD_HARDWARE_PATH externally when executing `run-docker`. Signed-off-by: Michael Richters --- bin/run-docker | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bin/run-docker b/bin/run-docker index ead78f1d..3f7e1bb0 100755 --- a/bin/run-docker +++ b/bin/run-docker @@ -4,12 +4,12 @@ set -e uname_S=$(uname -s 2>/dev/null || echo not) -ARDUINO_LOCAL_LIB_PATH="${ARDUINO_LOCAL_LIB_PATH:-${HOME}/Arduino}" - if [ "${uname_S}" = "Darwin" ]; then ARDUINO_LOCAL_LIB_PATH="${ARDUINO_LOCAL_LIB_PATH:-${HOME}/Documents/Arduino}" # This stops macos from copying resource forks into thigns like tar export COPYFILE_DISABLE=true +else + ARDUINO_LOCAL_LIB_PATH="${ARDUINO_LOCAL_LIB_PATH:-${HOME}/Arduino}" fi BOARD_HARDWARE_PATH="${BOARD_HARDWARE_PATH:-${ARDUINO_LOCAL_LIB_PATH}/hardware}"