diff options
author | Yutaka Kamei <kamei@yykamei.me> | 2021-04-30 23:35:12 +0900 |
---|---|---|
committer | Yutaka Kamei <kamei@yykamei.me> | 2021-05-02 06:18:40 +0900 |
commit | 168deabea7825f1b2bf81ec79de9f4bfaab8413e (patch) | |
tree | dd413499bb1a77d1af25705217bfab86ce2f18b4 /Cargo.toml | |
parent | 69d34c3e093f30df38f3eea30877e0292f3bd785 (diff) |
Load config before start()
Previously, a config file was loaded within `start()`, and if the config
file is invalid, Zellij was supposed to show a user what's wrong with
it. However, since `start()` starts setting up its terminal with an
alternative screen buffer, neither standard output nor standard error
could display such an error.
This change intends to address this issue by making Zellij load a config
file before `start()`.
In addition, the patch also includes some refactorings:
* Redefine `from_cli_config` with `TryFrom`, which was introduced in
Rust 1.34
* Remove conditional declaration `cfg(not(test))` because `start()` now
receive a `Config` as the third argument
* Introduce [`tempfile`](https://crates.io/crates/tempfile) in order to
run tests with actual files
* Typo?: "Deserialisation" -> "Deserialization"
Diffstat (limited to 'Cargo.toml')
-rw-r--r-- | Cargo.toml | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/Cargo.toml b/Cargo.toml index d712b3724..743379b28 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -44,6 +44,7 @@ features = ["unstable"] [dev-dependencies] insta = "1.6.0" +tempfile = "3.2.0" [build-dependencies] structopt = "0.3" |