Hey Victor,
> Isn't (at least some part of) the point of a command line invocation that
> you should be able to run it headless? I figure I can't be the first person
> to run into this, so:
>
> (1) Am I doing something wrong?
Nope.
> (2) Is there already an issue about this or should one be created?
Yes:
https://github.com/arduino/Arduino/issues/1981
> (3) Is there a known workaround?
You can run a dummy X server (can't remember if any instructions for
that are available there). Alternatively, you can call arduino-builder
directly, bypassing the IDE altogether, but that does require more info
on where things are installed.
Ideally, I'd see this issue fixed, but the IDE was clearly not designed
with this usecase in mind, so there is a lot of mixing of GUI and
non-GUI code. A big refactor in this area was done last year, but there
is still a lot of stuff to refactor before this issue can be properly
fixed, unfortunately.
Gr.
Matthijs