diff options
| author | Ellie Huxtable <ellie@elliehuxtable.com> | 2023-09-18 08:39:19 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-09-18 08:39:19 +0100 |
| commit | 351b3e8a57c9e0143b7b6f3ed2160dcdce00225e (patch) | |
| tree | b8d91a569daf2d819eea7a92e977458a3f3394a6 /atuin-client/src/settings.rs | |
| parent | feat(keyup): Configure SearchMode for KeyUp invocation #1216 (#1224) (diff) | |
| download | atuin-351b3e8a57c9e0143b7b6f3ed2160dcdce00225e.zip | |
Add connect timeout and overall timeout (#1238)
* Add connect timeout and overall timeout
* Make it configurable
* Fix test
* Add docs
Diffstat (limited to 'atuin-client/src/settings.rs')
| -rw-r--r-- | atuin-client/src/settings.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/atuin-client/src/settings.rs b/atuin-client/src/settings.rs index e2d22e93..e49ab0cb 100644 --- a/atuin-client/src/settings.rs +++ b/atuin-client/src/settings.rs @@ -176,6 +176,9 @@ pub struct Settings { pub workspaces: bool, pub ctrl_n_shortcuts: bool, + pub network_connect_timeout: u64, + pub network_timeout: u64, + // This is automatically loaded when settings is created. Do not set in // config! Keep secrets and settings apart. pub session_token: String, @@ -372,6 +375,8 @@ impl Settings { .set_default("workspaces", false)? .set_default("ctrl_n_shortcuts", false)? .set_default("secrets_filter", true)? + .set_default("network_connect_timeout", 5)? + .set_default("network_timeout", 30)? .add_source( Environment::with_prefix("atuin") .prefix_separator("_") |
