#!/bin/sh
# Cogitator Planner. Opens the board in its own window.
# Nothing is installed. This just starts the browser you already use.
URL="https://cogidemo.mullinsit.tech/?view=plan"
for b in "/Applications/Microsoft Edge.app/Contents/MacOS/Microsoft Edge" \
         "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome" \
         microsoft-edge microsoft-edge-stable google-chrome google-chrome-stable chromium chromium-browser; do
  if [ -x "$b" ]; then exec "$b" --app="$URL"; fi
  if command -v "$b" >/dev/null 2>&1; then exec "$b" --app="$URL"; fi
done
echo "No Chrome or Edge found. Open $URL in a browser."
