@@ -54,6 +54,9 @@ func NewCommand(srv rpc.ArduinoCoreServiceServer) *cobra.Command {
54
54
Long : i18n .Tr ("Debug Arduino sketches. (this command opens an interactive gdb session)" ),
55
55
Example : " " + os .Args [0 ] + " debug -b arduino:samd:mkr1000 -P atmel_ice /home/user/Arduino/MySketch" ,
56
56
Args : cobra .MaximumNArgs (1 ),
57
+ PreRun : func (cmd * cobra.Command , args []string ) {
58
+ arguments .CheckFlagsConflicts (cmd , "input-dir" , "build-path" )
59
+ },
57
60
Run : func (cmd * cobra.Command , args []string ) {
58
61
runDebugCommand (cmd .Context (), srv , args , & portArgs , & fqbnArg , interpreter , importDir , & programmer , printInfo , & profileArg , debugProperties )
59
62
},
@@ -65,6 +68,7 @@ func NewCommand(srv rpc.ArduinoCoreServiceServer) *cobra.Command {
65
68
programmer .AddToCommand (debugCommand , srv )
66
69
profileArg .AddToCommand (debugCommand , srv )
67
70
debugCommand .Flags ().StringVar (& interpreter , "interpreter" , "console" , i18n .Tr ("Debug interpreter e.g.: %s" , "console, mi, mi1, mi2, mi3" ))
71
+ debugCommand .Flags ().StringVarP (& importDir , "build-path" , "" , "" , i18n .Tr ("Directory containing binaries for debug." ))
68
72
debugCommand .Flags ().StringVarP (& importDir , "input-dir" , "" , "" , i18n .Tr ("Directory containing binaries for debug." ))
69
73
debugCommand .Flags ().BoolVarP (& printInfo , "info" , "I" , false , i18n .Tr ("Show metadata about the debug session instead of starting the debugger." ))
70
74
debugCommand .Flags ().StringArrayVar (& debugProperties , "debug-property" , []string {},
0 commit comments