| 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 21 matching lines...) Expand all Loading... |
| 32 mojo_run "APP_URL APP_ARGUMENTS" # Run an app with startup arguments | 32 mojo_run "APP_URL APP_ARGUMENTS" # Run an app with startup arguments |
| 33 ``` | 33 ``` |
| 34 | 34 |
| 35 Unless running within a Mojo checkout, we need to indicate the path to the shell | 35 Unless running within a Mojo checkout, we need to indicate the path to the shell |
| 36 binary: | 36 binary: |
| 37 | 37 |
| 38 ```sh | 38 ```sh |
| 39 mojo_run --shell-path path/to/shell/binary APP_URL | 39 mojo_run --shell-path path/to/shell/binary APP_URL |
| 40 ``` | 40 ``` |
| 41 | 41 |
| 42 Some applications are running embedded inside a window manager. To start such an | 42 Some applications are meant to be run embedded in a **window manager**. To run |
| 43 app, you have to first start the window manager app, then have it embed the app | 43 these, you can pass the app url using the `--embed` flag. This will run the |
| 44 you are interested in. It is done as follows using the default window manager: | 44 window manager and pass the given url to it: |
| 45 | 45 |
| 46 ```sh | 46 ```sh |
| 47 mojo_run "mojo:window_manager APP_URL" | 47 mojo_run --embed APP_URL [--android] |
| 48 ``` | 48 ``` |
| 49 | 49 |
| 50 By default, `mojo_run` uses `mojo:kiosk_wm` as the default window manager. It | 50 By default, `mojo_run` uses https://core.mojoapps.io/kiosk_wm.mojo as the window |
| 51 can be changed using the `--window-manager` flag. | 51 manager. You can pass a different window manager url using the |
| 52 `--window-manager` flag to override this. |
| 52 | 53 |
| 53 ### Debugger | 54 ### Debugger |
| 54 | 55 |
| 55 `mojo_debug` allows you to interactively inspect a running shell, collect | 56 `mojo_debug` allows you to interactively inspect a running shell, collect |
| 56 performance traces and attach a gdb debugger. | 57 performance traces and attach a gdb debugger. |
| 57 | 58 |
| 58 #### Tracing | 59 #### Tracing |
| 59 To collect [performance | 60 To collect [performance |
| 60 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) |
| 61 and retrieve the result: | 62 and retrieve the result: |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 ```sh | 107 ```sh |
| 107 mojo_debug device stack | 108 mojo_debug device stack |
| 108 ``` | 109 ``` |
| 109 | 110 |
| 110 ## Development | 111 ## Development |
| 111 | 112 |
| 112 The library is canonically developed [in the mojo | 113 The library is canonically developed [in the mojo |
| 113 repository](https://github.com/domokit/mojo/tree/master/mojo/devtools/common), | 114 repository](https://github.com/domokit/mojo/tree/master/mojo/devtools/common), |
| 114 https://github.com/domokit/devtools is a mirror allowing to consume it | 115 https://github.com/domokit/devtools is a mirror allowing to consume it |
| 115 separately. | 116 separately. |
| OLD | NEW |