From ea0f4bf8ffade657b1d45152dbc183d4679e75c4 Mon Sep 17 00:00:00 2001 From: Elvis Claros Castro Date: Fri, 12 Jul 2024 11:18:14 -0300 Subject: Feat: PI --- lua/pi/dap/configs/dart.lua | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 lua/pi/dap/configs/dart.lua (limited to 'lua/pi/dap/configs/dart.lua') diff --git a/lua/pi/dap/configs/dart.lua b/lua/pi/dap/configs/dart.lua new file mode 100644 index 0000000..a23c118 --- /dev/null +++ b/lua/pi/dap/configs/dart.lua @@ -0,0 +1,32 @@ +local dap = require('dap') + +dap.adapters.dart = { + type = "executable", + -- As of this writing, this functionality is open for review in https://github.com/flutter/flutter/pull/91802 + command = "flutter", + args = {"debug_adapter"} +} +dap.configurations.dart = { + { + name = "Launch Flutter Program Linux", + type = "dart", + request = "launch", + -- The nvim-dap plugin populates this variable with the filename of the current buffer + program = "${file}", + -- The nvim-dap plugin populates this variable with the editor's current working directory + cwd = "${workspaceFolder}", + -- This gets forwarded to the Flutter CLI tool, substitute `linux` for whatever device you wish to launch + toolArgs = {"-d", "linux"} + }, + { + name = "Launch Flutter Program Motorola", + type = "dart", + request = "launch", + -- The nvim-dap plugin populates this variable with the filename of the current buffer + program = "${file}", + -- The nvim-dap plugin populates this variable with the editor's current working directory + cwd = "${workspaceFolder}", + -- This gets forwarded to the Flutter CLI tool, substitute `linux` for whatever device you wish to launch + toolArgs = {"-d", "192.168.0.33:5555"} + } +} -- cgit v1.2.3