Ignore `(directory override for ` in active-toolchain name
@@ -7,7 +7,7 @@ SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd -P)"
ROOT_DIR="$(cd "$(dirname "$SCRIPT_DIR")" && pwd)"
BIN_DIR="${ROOT_DIR}/bin"
OUTPUT_DIR="${ROOT_DIR}/target/debug"
-RUST_TOOLCHAIN="$(rustup show active-toolchain | sed -e 's/ (default)//')"
+RUST_TOOLCHAIN="$(rustup show active-toolchain | sed -e 's/ (default)//' | sed -e 's/ (directory override for.*$//')"
RUSTC_PATH="$(rustup which --toolchain "$RUST_TOOLCHAIN" rustc)"
TOOLCHAIN_BIN_PATH="$(cd "$(dirname "$RUSTC_PATH")" && pwd -P)"
TOOLCHAIN_LIB_PATH="$(cd "$TOOLCHAIN_BIN_PATH"/../lib && pwd -P)"
