| OLD | NEW |
| 1 # Devtools | 1 # Devtools |
| 2 | 2 |
| 3 Unopinionated tools for **running**, **debugging** and **testing** Mojo apps. | 3 Unopinionated tools for **running**, **debugging** and **testing** Mojo apps. |
| 4 | 4 |
| 5 ## Install | 5 ## Install |
| 6 | 6 |
| 7 ``` | 7 ``` |
| 8 git clone https://github.com/domokit/devtools.git | 8 git clone https://github.com/domokit/devtools.git |
| 9 ``` | 9 ``` |
| 10 | 10 |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 50 By default, `mojo_run` uses https://core.mojoapps.io/kiosk_wm.mojo as the window | 50 By default, `mojo_run` uses https://core.mojoapps.io/kiosk_wm.mojo as the window |
| 51 manager. You can pass a different window manager url using the | 51 manager. You can pass a different window manager url using the |
| 52 `--window-manager` flag to override this. | 52 `--window-manager` flag to override this. |
| 53 | 53 |
| 54 ### Debugger | 54 ### Debugger |
| 55 | 55 |
| 56 `mojo_debug` allows you to interactively inspect a running shell, collect | 56 `mojo_debug` allows you to interactively inspect a running shell, collect |
| 57 performance traces and attach a gdb debugger. | 57 performance traces and attach a gdb debugger. |
| 58 | 58 |
| 59 #### Tracing | 59 #### Tracing |
| 60 To collect [performance | 60 In order to collect [performance |
| 61 traces](https://www.chromium.org/developers/how-tos/trace-event-profiling-tool) | 61 traces](https://www.chromium.org/developers/how-tos/trace-event-profiling-tool) |
| 62 and retrieve the result: | 62 interactively through `mojo_debug`, make sure that the app being inspected was |
| 63 run with `--debugger` switch. E.g.: |
| 64 |
| 65 ```sh |
| 66 mojo_run --debugger APP_URL [--android] |
| 67 ``` |
| 68 |
| 69 Then, in another shell, tracing can be orchestrated as follows: |
| 63 | 70 |
| 64 ```sh | 71 ```sh |
| 65 mojo_debug tracing start | 72 mojo_debug tracing start |
| 66 mojo_debug tracing stop [result.json] | 73 mojo_debug tracing stop [result.json] |
| 67 ``` | 74 ``` |
| 68 | 75 |
| 69 The trace file can be then loaded using the trace viewer in Chrome available at | 76 The trace file can be then loaded using the trace viewer in Chrome available at |
| 70 `about://tracing`. | 77 `about://tracing`. |
| 71 | 78 |
| 72 #### GDB | 79 #### GDB |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 ```sh | 114 ```sh |
| 108 mojo_debug device stack | 115 mojo_debug device stack |
| 109 ``` | 116 ``` |
| 110 | 117 |
| 111 ## Development | 118 ## Development |
| 112 | 119 |
| 113 The library is canonically developed [in the mojo | 120 The library is canonically developed [in the mojo |
| 114 repository](https://github.com/domokit/mojo/tree/master/mojo/devtools/common), | 121 repository](https://github.com/domokit/mojo/tree/master/mojo/devtools/common), |
| 115 https://github.com/domokit/devtools is a mirror allowing to consume it | 122 https://github.com/domokit/devtools is a mirror allowing to consume it |
| 116 separately. | 123 separately. |
| OLD | NEW |