Johann150
b9d07ed9fb
better error for missing certificate files
...
made config::path pub(crate) to avoid code duplication
but not pub so it is not part of the public API
2021-01-14 18:07:28 +01:00
Aaron Weiss
e9d18b7f48
increased default ping timeout to 20 seconds
2020-07-23 13:41:01 -04:00
Théo Gaillard
67e61e0606
feature: add TLS as feature and support multiples TLS backends (currently native-tls and rustls)
2020-03-31 09:48:57 +08:00
Théo Gaillard
5bf3909d46
feature: add proxy config
2020-03-04 22:00:48 +08:00
Kaleb Elwert
dd09555537
Make serde optional
2020-01-29 11:06:58 -08:00
John-John Tedro
b08e2a89ae
Avoid synchronously resolving server address
2019-12-29 19:08:31 +01:00
Aaron Weiss
71a703c762
Merge pull request #186 from udoprog/config
...
Simplify Config structure
2019-12-27 16:57:09 -05:00
John-John Tedro
5189b69e7e
Simplify Config structure
...
This simplifies some of the `Config` structure, in particular this
means:
Parameters which are meaningfully equivalent longer stored in
an `Option<T>`, an example of this is `channels`. If you don't
want to join any channels you simply leave it as empty instead.
In effect, `None` is behaviorally equivalent to `vec![]`.
We don't allocate when accessing certain configuration options.
For example, when accessing `channels` we used to allocate a
vector to handle the "empty case", we simply return the slice
corresponding to the list of channels instead.
We skip serializing empty or optional configuration fields.
From a deserialization perspective this is already something
that was mostly supported through use of `Option<T>` and
`#[serde(default)]`.
2019-12-27 17:12:46 +01:00
John-John Tedro
f200a9f281
Switch to modern error handling
2019-12-27 17:01:03 +01:00
John-John Tedro
549e2e8722
Port to tokio 0.2
2019-12-18 21:06:04 +01:00
Aaron Weiss
f109c10475
Fixed a warning in config.rs (for some tests) and the README example.
2018-09-17 18:08:21 -04:00
Alex S. Glomsaas
e80a0f3a89
Implement CertFP
...
resolves #131
2018-03-31 21:09:42 +02:00
Aaron Weiss
f2e10001c0
Improved the documentation for Config
.
2018-03-31 16:22:07 +02:00
Aaron Weiss
4509336d74
Fixed config tests after Config::get_option API change.
2018-02-21 12:23:54 +01:00
Aaron Weiss
7d744529e6
Eliminated possible panics in Config::get_option.
2018-02-21 12:17:41 +01:00
Aaron Weiss
3847bcb5a6
Always skip serializing config's path.
2018-02-18 21:39:06 +01:00
Aaron Weiss
5266e4098d
Refactored the whole crate to use failure.
2018-01-28 00:52:11 +01:00
Aaron Weiss
ce158fc612
Made unspecified server or nickname into errors instead of simply panics.
2018-01-27 20:26:56 +01:00
Aaron Weiss
a0d0d3e249
Cleaned up a bunch of code with clippy.
2018-01-01 22:25:25 -05:00
Aaron Weiss
16292fcc2c
Improved documentation for message throttling configuration.
2018-01-01 21:47:28 -05:00
Jokler
9ec7356d10
Improved error-handling in config ( fixes #98 )
2017-10-17 00:38:59 +02:00
Aaron Weiss
20e7f2fdf5
Reordered Config for TOML compatibility and improved error handling for saves/loads.
2017-08-04 20:23:07 -04:00
Aaron Weiss
c749146d5c
Added support for toml and yaml configurations.
2017-06-29 00:31:27 -07:00
Aaron Weiss
a0f43cb80b
Added support for message throttling.
2017-06-28 23:07:02 -07:00
Aaron Weiss
f0fa03e70a
Updated documentation for ping_time and ping_timeout.
2017-06-28 20:44:22 -07:00
Aaron Weiss
1c0ccd11a9
Updated docs for ping_time and ping_timeout.
2017-06-25 05:45:30 -04:00
Aaron Weiss
196d6425bd
Purged try! from code (replaced with ?).
2017-06-25 05:06:35 -04:00
Aaron Weiss
2055603a5d
Changed CTCP VERSION to include the real version number by default.
2017-06-22 15:04:27 -04:00
Aaron Weiss
ec8fdeb2e9
Reorganized imports into a consistent style.
2017-06-22 14:15:55 -04:00
Aaron Weiss
d9f4f82051
Implemented new Mode API ( fixes #48 ).
2017-06-22 13:59:18 -04:00
Aaron Weiss
b277db71e0
Fixed test compilation.
2017-06-21 23:24:11 -04:00
Aaron Weiss
254f5bb048
Added ability to specify SSL certificate in DER format ( fixes #67 ).
2017-06-21 23:21:03 -04:00
Aaron Weiss
77d44a5055
Added two config fields for testing purposes.
2017-06-21 19:19:58 -04:00
Aaron Weiss
3369ef5ff2
Cleaned up code and added documentation.
2017-06-21 17:15:30 -04:00
Aaron Weiss
cc1aa5717e
Migrated to using error_chain.
2017-06-20 14:54:06 -04:00
Aaron Weiss
cf3ee671ed
Merge branch 'master' into async
2017-06-19 14:33:02 -04:00
Aaron Weiss
f0f0b95038
Ran rustfmt on all the code.
2017-06-19 13:59:26 -04:00
Torbjörn Lönnemark
e33248f043
Replace rustc-serialize with serde
...
rustc-serialize is deprecated.
Fixes #84 .
2017-06-14 22:20:31 +02:00
Dominik Miedziński
fcb0c1da64
Use CTCP VERSION and SOURCE replies from Config
2017-03-22 22:06:43 +01:00
Aaron Weiss
fbeeaed874
Changed implementation of socket_addr on Config.
2017-03-15 12:42:15 -04:00
Aaron Weiss
d9fc586b8c
Added socket_addr() helper to Config.
2017-01-15 17:32:41 -05:00
Aaron Weiss
5b8f320050
Implemented channel keys for autojoined channels ( fixes #51 ).
2016-07-05 16:21:21 -04:00
Aaron Weiss
e4495940fc
Made a whole lot of linting changes to improve code.
...
Small API changes:
1. Message::into_string -> Message:to_string
2. NetStream::UnsecuredTcpStream -> NetStream::Unsecured
3. NetStream::SslTcpStream -> NetStream::Ssl
2016-03-17 21:35:35 -04:00
Aaron Weiss
3314c93c3e
Implemented a major redesign to simplify API and eliminate
...
overly-complicated generics usage.
2016-02-10 00:15:08 -05:00
angelsl
5f20e715fd
Add NickServ GHOST functionality
2016-02-09 18:41:52 +08:00
Aaron Weiss
20338f881f
Renamed getter functions to not include get as is common practice.
2016-01-30 12:00:25 -05:00
Aaron Weiss
8113c47842
Fixed test execution.
2016-01-16 11:47:25 -05:00
Aaron Weiss
3dc15449a8
Implemented ping-sending on inactivity.
2016-01-15 12:37:16 -05:00
Aaron Weiss
b866785c89
Added a function to save a Config.
2015-09-16 12:21:58 -04:00
Zetok Zalbavar
ee2deea79c
Allow to encode Config
2015-09-13 13:49:15 +01:00