[suggestion] Header to sketch to identify board settings

Bit of context/background - I work on various boards, ESP8266, Arduino Uno, Lolin, ESP32. Therefore I have sketches with lots of different board types.
Each sketch I keep a note in comments of what board settings to use. Perhaps create a way of setting this within the sketch.

My suggestion would be like a 'shebang' line in Bash, so the first line of the sketch contains a comment that is parsed by the IDE to determine settings for the board, compiler, etc.

A rough guess:

/* ##board:WeMos D1 R1##uploadspeed:19200##cpu:80##flash:4mb##debug:disabled## */

Or similar that is machine parsable when 'compile' is hit.

Hopefully this is the right place for suggestions! If not point me in the right direction.

I use the Geany editor for all my programming including for the Arduino.

I have written a simple Python program to compile and upload Arduino code using the command-line IDE. I have a menu option in Geany to call the Python program. The Python program can also be used without Geany.

The top of my Arduino programs contains some comments like this that the Python program uses to identify the various settings for the call to the Arduino IDE

// python-build-start
// action, verify
// board, arduino:avr:uno
// port, /dev/ttyACM0
// ide, 1.8.6
// python-build-end


Please check this thread for some discussion on the subject and links to more information: