Closed
Description
Describe the problem
In addition to opening them via the Arduino IDE GUI, sketches can be opened directly either via file association or by passing their path to the IDE command line invocation.
🐛 This only works once per IDE session. After that, attempting to open additional sketches in this manner has no effect.
To reproduce
- Select File > Quit from the Arduino IDE menus if it is running.
- Open a sketch via file association or command line argument:
🙂 The IDE starts up with the specified sketch open, as expected.
& ".\Arduino IDE" "C:\Users\per\Documents\Arduino\Foo"
- Open a different sketch via file association or command line argument:
& ".\Arduino IDE" "C:\Users\per\Documents\Arduino\Bar"
🐛 The command exits immediately with no effect. The specified sketch is not opened in an IDE window.
Expected behavior
Additional sketches can be opened via file association or command line argument when the IDE is already running.
Arduino IDE version
2.0.1
Operating system
- Windows
- Linux
Operating system version
- Windows 10
- Ubuntu 20.04
Additional context
I bisected the regression to 2b2463b / #1563
Originally reported at https://forum.arduino.cc/t/arduino-ide-2-0-1-is-now-available/1046764/7
Issue checklist
- I searched for previous reports in the issue tracker
- I verified the problem still occurs when using the latest nightly build
- My report contains all necessary details