#!/usr/bin/env bash

# omarchy:summary=Install the Arduino CLI
# omarchy:requires-sudo=true

# Based: Debian carries no arduino-cli, so it comes through asdf from the
# reviewed plugin bundle; a Mac brews it. The Arduino editor extension
# comes with it.

set -eo pipefail

echo "Installing the Arduino CLI..."
case $(omarchy-os) in
darwin)
  omarchy-pkg-add arduino-cli
  ;;
*)
  omarchy-pkg-add asdf
  omarchy-dev-env-tool arduino-cli
  ;;
esac

omarchy-code-extensions vsciot-vscode.vscode-arduino
