[Lldb-commits] [lldb] 7345025 - [lldb-dap] Updated README.md for newly added attach properties. (#99926)

via lldb-commits lldb-commits at lists.llvm.org
Fri Jul 26 08:22:35 PDT 2024


Author: Santhosh Kumar Ellendula
Date: 2024-07-26T10:22:33-05:00
New Revision: 73450251497f3880ff90d36d2bb43f02dd022239

URL: https://github.com/llvm/llvm-project/commit/73450251497f3880ff90d36d2bb43f02dd022239
DIFF: https://github.com/llvm/llvm-project/commit/73450251497f3880ff90d36d2bb43f02dd022239.diff

LOG: [lldb-dap] Updated README.md for newly added attach properties. (#99926)

Added "gdb-remote-port" and "gdb-remote-hostname" attach properties
usage in
README.md and updated package.json version to 0.2.3
    
This was missed in PR https://github.com/llvm/llvm-project/pull/91570

---------

Co-authored-by: Santhosh Kumar Ellendula <sellendu at hu-sellendu-hyd.qualcomm.com>
Co-authored-by: Santhosh Kumar Ellendula <sellendu at hu-sellendu-lv.qualcomm.com>

Added: 
    

Modified: 
    lldb/tools/lldb-dap/README.md
    lldb/tools/lldb-dap/package.json

Removed: 
    


################################################################################
diff  --git a/lldb/tools/lldb-dap/README.md b/lldb/tools/lldb-dap/README.md
index 8ecbaf7ce9816..11a14d29ab51e 100644
--- a/lldb/tools/lldb-dap/README.md
+++ b/lldb/tools/lldb-dap/README.md
@@ -157,6 +157,20 @@ locally on port `2345`.
 }
 ```
 
+You can also use the `gdb-remote-port` parameter to send an attach request
+to a debug server running on the current machine,
+instead of using the custom command `attachCommands`.
+
+```javascript
+{
+  "name": "Local Debug Server",
+  "type": "lldb-dap",
+  "request": "attach",
+  "program": "/tmp/a.out",
+  "gdb-remote-port": 2345,
+}
+```
+
 #### Connect to a Debug Server on Another Machine
 
 This connects to a debug server running on another machine with hostname
@@ -173,6 +187,23 @@ port `5678` of that other machine.
 }
 ```
 
+You can also use the `gdb-remote-hostname` and `gdb-remote-port` parameters
+to send an attach request to a debug server running on a 
diff erent machine,
+instead of custom command `attachCommands`.
+The default hostname being used `localhost`.
+
+
+```javascript
+{
+  "name": "Local Debug Server",
+  "type": "lldb-dap",
+  "request": "attach",
+  "program": "/tmp/a.out",
+  "gdb-remote-port": 5678,
+  "gdb-remote-hostname": "hostname",
+}
+```
+
 ## Custom debugger commands
 
 The `lldb-dap` tool includes additional custom commands to support the Debug

diff  --git a/lldb/tools/lldb-dap/package.json b/lldb/tools/lldb-dap/package.json
index fd5de30ed28dd..97e4efe7bac19 100644
--- a/lldb/tools/lldb-dap/package.json
+++ b/lldb/tools/lldb-dap/package.json
@@ -1,7 +1,7 @@
 {
   "name": "lldb-dap",
   "displayName": "LLDB DAP",
-  "version": "0.2.2",
+  "version": "0.2.3",
   "publisher": "llvm-vs-code-extensions",
   "homepage": "https://lldb.llvm.org",
   "description": "LLDB debugging from VSCode",
@@ -353,7 +353,7 @@
                   "number",
                   "string"
                 ],
-                "description": "TCP/IP port to attach to. Specifying both pid and port is an error."
+                "description": "TCP/IP port to attach to a remote system. Specifying both pid and port is an error."
               },
               "gdb-remote-hostname": {
                 "type": "string",


        


More information about the lldb-commits mailing list