~joshleeb

Recent activity

[PATCH] Simplify Config::load 9 months ago

From Josh Leeb-du Toit to ~garritfra/taurus

Simplify Config::load by using the fs::read_to_string function provided
in std. Additionally, we update the type of the config_path argument to
be generic over AsRef<Path> which is generally preferred over &str for
file path arguments.
---
 src/config.rs | 13 ++++---------
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/src/config.rs b/src/config.rs
index ced5c37..3b42d30 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -1,6 +1,5 @@
use serde::Deserialize;
[message trimmed]

Re: [PATCH] Return TaurusError when failing to parse GeminiRequest 10 months ago

From Josh Leeb-du Toit to ~garritfra/taurus

Sorry about that! Thanks for figuring it out Alexey, and for putting up
a patch. I will be more careful in future.

[PATCH] Return TaurusError when failing to parse GeminiRequest 10 months ago

From Josh Leeb-du Toit to ~garritfra/taurus

This patch adds TaurusError::InvalidRequest` and updates GeminiRequest
to impl FromStr and expose Gemini::parse that will attempt to parse a
string and return an instance of TaurusError::InvalidRequest if an error
occurs - such as the request being malformed, or the url being invalid.

Signed-off-by: Josh Leeb-du Toit <mail@joshleeb.com>
---
 src/error.rs  |  3 +++
 src/gemini.rs | 72 +++++++++++++++++++++++++++++++++++++++++----------
 src/main.rs   | 25 +++++++++---------
 3 files changed, 73 insertions(+), 27 deletions(-)

diff --git a/src/error.rs b/src/error.rs
index 9cbf746..6fddb4c 100644
[message trimmed]

[PATCH] Add TaurusResult type alias 10 months ago

From Josh Leeb-du Toit to ~garritfra/taurus

This patch adds the `TaurusResult` type alias, and replaces instances of
`error::TaurusError` with just `TaurusError`.

Signed-off-by: Josh Leeb-du Toit <mail@joshleeb.com>
---
 src/error.rs  |  2 ++
 src/gemini.rs |  8 +++-----
 src/main.rs   | 18 ++++++++----------
 3 files changed, 13 insertions(+), 15 deletions(-)

diff --git a/src/error.rs b/src/error.rs
index c71f8e9..9cbf746 100644
--- a/src/error.rs
+++ b/src/error.rs
[message trimmed]

[PATCH v3] Impl From<native_tls::Error> to TaurusError::InvalidCertificate 10 months ago

From Josh Leeb-du Toit to ~garritfra/taurus

This patch adds `#[from]` to `TaurusError::InvalidCertificate` which
means that any `native_tls::Error` can be converted (using `From` and
`Into`) to a `TaurusError::InvalidCertificate`.

From what I can see, [here][native_tls_error_docs], the
`native_tls::Error` type is kind of a catch all for errors from that lib
rather than being broken down into suberrors (like `io::Error`)

[native_tls_error_docs]: https://docs.rs/native-tls/0.2.6/native_tls/struct.Error.html

Signed-off-by: Josh Leeb-du Toit <mail@joshleeb.com>
---
Ahh apologies! Updated with `Signed-off-by`.
[message trimmed]

[PATCH v2] Impl From<native_tls::Error> to TaurusError::InvalidCertificate 10 months ago

From Josh Leeb-du Toit to ~garritfra/taurus

This patch adds `#[from]` to `TaurusError::InvalidCertificate` which
means that any `native_tls::Error` can be converted (using `From` and
`Into`) to a `TaurusError::InvalidCertificate`.

From what I can see, [here][native_tls_error_docs], the
`native_tls::Error` type is kind of a catch all for errors from that lib
rather than being broken down into suberrors (like `io::Error`)

[native_tls_error_docs]: https://docs.rs/native-tls/0.2.6/native_tls/struct.Error.html
---
 src/error.rs | 2 +-
 src/main.rs  | 5 ++---
 2 files changed, 3 insertions(+), 4 deletions(-)
[message trimmed]

[PATCH v2] Demonstrate that I can use git send-email 10 months ago

From Josh Leeb-du Toit to ~sircmpwn/email-test-drive

---
 joshleeb | 1 +
 1 file changed, 1 insertion(+)
 create mode 100644 joshleeb

diff --git a/joshleeb b/joshleeb
new file mode 100644
index 0000000..6d0ecfd
--- /dev/null
+++ b/joshleeb
@@ -0,0 +1 @@
I'm about to try git send-email
-- 
2.29.2
[message trimmed]

[PATCH] Demonstrate that I can use git send-email 10 months ago

From Josh Leeb-du Toit to ~sircmpwn/email-test-drive

---
 joshleeb | 1 +
 1 file changed, 1 insertion(+)
 create mode 100644 joshleeb

diff --git a/joshleeb b/joshleeb
new file mode 100644
index 0000000..6d0ecfd
--- /dev/null
+++ b/joshleeb
@@ -0,0 +1 @@
I'm about to try git send-email
-- 
2.29.2
[message trimmed]