The --insecure global flag was removed in arduino-cli 1.0, causing the command parser to fail with "unknown command update-index". Detect support at runtime so the script works with both old and new versions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>