main: add -programmer flag

This flag is overloaded. It can be used in two ways:

  * Choosing the flash method to use (openocd, msd, command).
  * Choosing the OpenOCD programmer name.

For example, you can use one of these to use OpenOCD instead of the
mass-storage device programmer:

    tinygo flash -target=microbit -programmer=openocd
    tinygo flash -target=microbit -programmer=cmsis-dap
This commit is contained in:
Ayke van Laethem
2019-11-12 11:40:16 +01:00
committed by Ron Evans
parent c6255e4d0a
commit d2d78d3d0a
4 changed files with 60 additions and 37 deletions
+1
View File
@@ -19,4 +19,5 @@ type Options struct {
WasmAbi string
HeapSize int64
TestConfig TestConfig
Programmer string
}