Skip to content

Instantly share code, notes, and snippets.

@Bunn
Last active October 25, 2021 18:53
Show Gist options
  • Star 20 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Bunn/1f7c04b62851152e2aece93e18c01245 to your computer and use it in GitHub Desktop.
Save Bunn/1f7c04b62851152e2aece93e18c01245 to your computer and use it in GitHub Desktop.
import lldb
def __lldb_init_module(debugger, internal_dict):
debugger.HandleCommand('command script add -f SwiftPrinter.printer pjson')
def printer(debugger, command, result, internal_dict):
debugger.HandleCommand('p print(String(data: try! JSONSerialization.data(withJSONObject:' + command + ', options: .prettyPrinted), encoding: .utf8 )!)')
@eneko
Copy link

eneko commented Jun 25, 2021

Great, thanks 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment