2

I'm trying to build a Flutter app in Android Studio. We're using VSCode with quite many dart-define's in .vscode\launch.json. In Android Studio, I think, we should use Build Configuration - Additional run args. The problem with it, however, is that it's a single line edit and it's too cumbersome to manage the many defines that in VSCode are easily accessible via regular text editor enter image description here Is there a better way to do this? Like, reference an external file and load the defines from there? The IDE saves the entire string as an xml attribute in workspace.iml, so I can't just edit that as well.

Anton Duzenko
  • 2,366
  • 1
  • 21
  • 26
  • 1
    only for tough guys: use `flutter run [args]` from the shell script - this is how i always run flutter apps - only from a command line – pskink Nov 17 '21 at 10:59
  • @pskink How do you debug it? – Anton Duzenko Nov 17 '21 at 12:51
  • you mean with a debugger session? if so, its maybe less than 1% of whole cases so it shouldnt be an issue – pskink Nov 18 '21 at 05:52
  • btw when you launch `flutter run ...` you are also greeted with: `[+2216 ms] The Flutter DevTools debugger and profiler on Linux is available at: http://127.0.0.1:9101?uri=http://127.0.0.1:44933/ZKqlRC69VKw=/` log message, so you can use that uri where you have full web based debugger (with you source files, data inspector, breakpoints, step / step in / step return / continue buttons etc) - more: https://docs.flutter.dev/development/tools/devtools/debugger – pskink Nov 18 '21 at 07:13

1 Answers1

1

In that window, you will see a small expansion array on the far end of the textbox. You should click it to get a multi - line sort of view for the args

Configurations dialog

Nana Yaw
  • 38
  • 4