1
0
mirror of https://git.sr.ht/~adnano/go-gemini synced 2024-11-23 08:32:02 +01:00
Commit Graph

507 Commits

Author SHA1 Message Date
adnano
13d4ba5708 Update examples/client.go 2021-02-24 19:21:31 -05:00
adnano
3255b024e9 Remove ResponseWriter.Close method 2021-02-24 19:00:09 -05:00
adnano
c5bd598947 response: Revert to using fields instead of methods 2021-02-24 18:50:40 -05:00
adnano
a27dfdc3a9 examples/client: Fix display of response status 2021-02-24 16:16:42 -05:00
adnano
6d8f1dc95f Revert "Replace uses of ioutil with io"
This reverts commit 0aa995c78c6afca5707d776c6175833fb2fca93c.
2021-02-24 14:45:57 -05:00
adnano
7495060134 Don't require Go 1.16 2021-02-24 14:29:29 -05:00
adnano
d9382ef950 Add missing import 2021-02-24 14:28:47 -05:00
adnano
76e42344ae Move mimetype registration to gemini.go 2021-02-24 14:27:49 -05:00
adnano
0aa995c78c Replace uses of ioutil with io 2021-02-24 11:11:10 -05:00
adnano
158e5002af fs: Remove build constraint 2021-02-24 11:01:02 -05:00
adnano
85fea6646a Add NewResponse function 2021-02-24 10:48:17 -05:00
adnano
f5c5b362a7 examples/server: Cancel context 2021-02-24 10:27:28 -05:00
adnano
f5e5f71474 examples/server: Add logging middleware 2021-02-24 10:25:08 -05:00
adnano
249b13c191 ResponseWriter: Remove unexported method 2021-02-24 10:01:46 -05:00
adnano
77c862c821 client: Fix copying of request 2021-02-24 09:48:23 -05:00
adnano
1dc3a2009d examples/client: Use Response methods 2021-02-24 09:22:25 -05:00
adnano
f86a79ff20 examples/auth: Use Request.TLS method 2021-02-24 09:22:01 -05:00
adnano
75a8109ea7 fs: Fix Go build constraint comment 2021-02-24 09:00:28 -05:00
adnano
55e921883d response: Move to methods 2021-02-24 08:43:57 -05:00
adnano
94b185b049 server: Fix comment 2021-02-24 08:38:08 -05:00
adnano
b3a84facce TimeoutHandler: Mention returned error 2021-02-24 08:37:52 -05:00
adnano
0ad54cc7ab Add unexported method to timeout writer 2021-02-24 08:34:26 -05:00
adnano
5126abe562 Move ResponseWriter Conn and TLS methods to Request 2021-02-24 08:24:49 -05:00
adnano
6741248fe4 Remove ResponseWriter.Hijack method 2021-02-24 08:22:12 -05:00
adnano
6a0151c60b Implement TimeoutHandler by wrapping ResponseWriter 2021-02-24 08:18:23 -05:00
Kaleb Elwert
0431ad1d45 Only use fs.go when fs.FS is available 2021-02-24 07:41:53 -05:00
adnano
36a67255e0 Make ResponseWriter an interface
Make ResponseWriter an interface with an unexported method. Implementors
must embed a ResponseWriter from elsewhere. This gives us the
flexibility of an interface while allowing us to add new methods in the
future.
2021-02-24 00:13:46 -05:00
adnano
06dc7eed08 Remove ErrHandlerTimeout 2021-02-23 22:15:19 -05:00
adnano
2d5b0df001 Move TimeoutHandler to handler.go 2021-02-23 22:12:04 -05:00
adnano
5bb9ae237d Unexport NewResponseWriter 2021-02-23 22:02:47 -05:00
adnano
29a2789434 Reimplement TimeoutHandler 2021-02-23 21:59:16 -05:00
adnano
b21522f6cb response: Change field names 2021-02-23 21:51:42 -05:00
adnano
ea7415e9af Add ResponseWriter.Hijack method 2021-02-23 21:36:29 -05:00
adnano
d3856730ab ResponseWriter: Add TLS and Conn methods 2021-02-23 20:59:04 -05:00
adnano
c27c934ec1 request: Remove TLS and Conn methods 2021-02-23 20:57:53 -05:00
adnano
5641fb7415 Move I/O utilities to io.go 2021-02-23 20:49:55 -05:00
adnano
06d65b8154 Make ResponseWriter a struct
Make ResponseWriter a struct again so that it can be extended in a
backwards-compatible way.
2021-02-23 20:41:16 -05:00
adnano
feb0535483 handler: Mention when the context is canceled 2021-02-23 19:01:12 -05:00
adnano
f8c7820d0f handler: Mention ResponseWriter.Close method 2021-02-23 18:59:20 -05:00
adnano
3e8cd2465e client: Clarify usage of contexts 2021-02-23 18:56:18 -05:00
adnano
6e16497812 Use HandlerFunc to implement StatusHandler 2021-02-23 18:52:00 -05:00
adnano
4d7bb87110 Update documentation 2021-02-23 18:45:58 -05:00
adnano
4864d2ad67 Update documentation 2021-02-23 17:52:47 -05:00
adnano
81803e8a44 Update examples/client.go 2021-02-23 17:52:34 -05:00
adnano
8b7bd5b2d7 Make Response an io.ReadCloser 2021-02-23 17:50:47 -05:00
adnano
6d49b91ab7 response: Add Close method 2021-02-23 17:32:23 -05:00
adnano
45ba4cc219 request: Fix documentation for TLS 2021-02-23 17:30:46 -05:00
adnano
45e432a71b request: Add Conn and TLS methods 2021-02-23 17:29:50 -05:00
adnano
b2bbb83827 response: Add Conn and TLS methods 2021-02-23 16:36:17 -05:00
adnano
c0544f3038 server: Cancel context on IO errors 2021-02-23 16:06:57 -05:00