Home | History | Annotate | only in /external/lldb/examples/customization/pwd-cd-and-system
Up to higher level directory
NameDateSize
.lldbinit04-Nov-2014251
README04-Nov-20141.3K
utils.py04-Nov-20141.5K

README

      1 Files in this directory:
      2 
      3 o .lldbinit:
      4 
      5 An example lldb init file that imports the utils.py module and adds the
      6 following commands: 'pwd', 'cd', and 'system'.
      7 
      8 o utils.py:
      9 
     10 Python module which provides implementation for the 'cd' and 'system' commands.
     11 
     12 o README:
     13 
     14 The file you are reading now.
     15 
     16 ================================================================================
     17 The following terminal output shows an interaction with lldb using the .lldbinit
     18 and the utils.py files which are located in my HOME directory.  The lldb init
     19 file imports the utils Python module and adds the 'pwd', 'cd', and 'system'
     20 commands.
     21 
     22 Johnnys-MacBook-Pro:multiple_threads johnny$ pwd
     23 /Volumes/data/lldb/svn/trunk/test/functionalities/watchpoint/multiple_threads
     24 Johnnys-MacBook-Pro:multiple_threads johnny$ lldb
     25 (lldb) pwd
     26 /Volumes/data/lldb/svn/trunk/test/functionalities/watchpoint/multiple_threads
     27 (lldb) cd ..
     28 Current working directory: /Volumes/data/lldb/svn/trunk/test/functionalities/watchpoint
     29 (lldb) help system
     30 
     31 Execute the command (a string) in a subshell.
     32 Syntax: system
     33 (lldb) system ls -l
     34 total 0
     35 drwxr-xr-x  7 johnny  admin  238 Oct 11 17:24 hello_watchlocation
     36 drwxr-xr-x  7 johnny  admin  238 Oct 11 17:24 hello_watchpoint
     37 drwxr-xr-x  7 johnny  admin  238 Oct 11 17:24 multiple_threads
     38 drwxr-xr-x  7 johnny  admin  238 Oct 11 17:24 watchpoint_commands
     39 
     40 retcode: 0
     41 (lldb) 
     42