[Lldb-commits] [lldb] [LLDB-DAP] Send Progress update message over DAP (PR #123837)

Jacob Lalonde via lldb-commits lldb-commits at lists.llvm.org
Wed Jan 22 13:05:38 PST 2025


================
@@ -0,0 +1,85 @@
+import inspect
+import optparse
+import shlex
+import sys
+import time
+
+import lldb
+
+
+class ProgressTesterCommand:
+    program = "test-progress"
+
+    @classmethod
+    def register_lldb_command(cls, debugger, module_name):
+        parser = cls.create_options()
+        cls.__doc__ = parser.format_help()
+        # Add any commands contained in this module to LLDB
+        command = "command script add -c %s.%s %s" % (
+            module_name,
+            cls.__name__,
+            cls.program,
+        )
+        debugger.HandleCommand(command)
+        print(
+            'The "{0}" command has been installed, type "help {0}" or "{0} '
+            '--help" for detailed help.'.format(cls.program)
+        )
+
+    @classmethod
+    def create_options(cls):
+        usage = "usage: %prog [options]"
+        description = "Jacob Lalonde's sbprogress testing tool"
----------------
Jlalond wrote:

Haha! Wow that's embarassing, I copied over my gist and forgot I left that in.

https://github.com/llvm/llvm-project/pull/123837


More information about the lldb-commits mailing list