yazi/yazi-fm
Solomon Jacobs fd455a1ae4
feat: readable toml parsing error (#854)
Previously, the yazi displayed the following error.
```
Backtrace omitted. Run with RUST_BACKTRACE=1 to display it.
Run with RUST_BACKTRACE=full to include source snippets.

The application panicked (crashed).
  called `Result::unwrap()` on an `Err` value: Error { inner: Error { inner: TomlError { message: "invalid key", raw: Some("{ mime = \"application/octet-stream\",\nuse = [ \"extract_zlib\", \"reveal\" ] }\n"), keys: [], span: Some(0..1) } } }
in yazi-config/src/preset.rs, line 42
thread: main
```

It now displays the following message instead:

```
Error: Loading "/home/solo/.config/yazi/yazi.toml"

Caused by:
    TOML parse error at line 1, column 1
      |
    1 | { mime = "application/octet-stream",
      | ^
    invalid key
```

For more information see issue GH-847.

---------

Co-authored-by: sxyazi <sxyazi@gmail.com>
2024-03-31 21:44:17 +08:00
..
src feat: readable toml parsing error (#854) 2024-03-31 21:44:17 +08:00
Cargo.toml feat: DDS (Data Distribution Service) (#826) 2024-03-29 23:30:30 +08:00