Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions docs/iamb.5
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,10 @@ Defaults to 30.
.It Sy tabstop
Number of spaces that a <Tab> counts for.
Defaults to 4.

.It Sy ssl_verify
Enable SSL verification for the HTTP requests.
Defaults to true.
.El

.Ss Example 1: Avoid showing Emojis (useful for terminals w/o support)
Expand Down
4 changes: 4 additions & 0 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -581,6 +581,7 @@ pub struct TunableValues {
pub user_gutter_width: usize,
pub external_edit_file_suffix: String,
pub tabstop: usize,
pub ssl_verify: bool,
}

#[derive(Clone, Default, Deserialize)]
Expand Down Expand Up @@ -609,6 +610,7 @@ pub struct Tunables {
pub user_gutter_width: Option<usize>,
pub external_edit_file_suffix: Option<String>,
pub tabstop: Option<usize>,
pub ssl_verify: Option<bool>,
}

impl Tunables {
Expand Down Expand Up @@ -643,6 +645,7 @@ impl Tunables {
.external_edit_file_suffix
.or(other.external_edit_file_suffix),
tabstop: self.tabstop.or(other.tabstop),
ssl_verify: self.ssl_verify.or(other.ssl_verify),
}
}

Expand Down Expand Up @@ -673,6 +676,7 @@ impl Tunables {
.external_edit_file_suffix
.unwrap_or_else(|| ".md".to_string()),
tabstop: self.tabstop.unwrap_or(4),
ssl_verify: self.ssl_verify.unwrap_or(true),
}
}
}
Expand Down
1 change: 1 addition & 0 deletions src/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,7 @@ pub fn mock_tunables() -> TunableValues {
image_preview: None,
user_gutter_width: 30,
tabstop: 4,
ssl_verify: true,
}
}

Expand Down
1 change: 1 addition & 0 deletions src/worker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -717,6 +717,7 @@ async fn create_client_inner(
.pool_idle_timeout(Duration::from_secs(60))
.pool_max_idle_per_host(10)
.tcp_keepalive(Duration::from_secs(10))
.danger_accept_invalid_certs(!settings.tunables.ssl_verify)
.build()
.unwrap();

Expand Down