20 lines
467 B
Markdown
20 lines
467 B
Markdown
# Rust Chrono LLDB Formatters
|
|
|
|
## How to Use formatters/chrono.py
|
|
|
|
### Raw lldb users
|
|
Put contents under into ~/.lldbinit file, then use lldb to debug, it will automatically format chrono times
|
|
|
|
```
|
|
command script import ~/.lldb/chrono.py
|
|
type summary add -F chrono.GetSummary chrono::datetime::DateTime<chrono::offset::utc::Utc>
|
|
```
|
|
### RustLLDB users
|
|
|
|
In your `launch.json` file add the following line
|
|
```
|
|
"preRunCommands": [
|
|
"command source ~/.lldbinit"
|
|
]
|
|
```
|