~alcinnz/hurl

4dca15c41ad280ff3baa27991ac8ee3315023d88 — Adrian Cochrane 4 years ago 3cd2277
Note that Gemini is now supported!
2 files changed, 1 insertions(+), 13 deletions(-)

M ISSUES/new-protocols.md
M README.md
M ISSUES/new-protocols.md => ISSUES/new-protocols.md +0 -12
@@ 14,18 14,6 @@ will be appreciated.
There's a `bittorrent` package, but it appears to be unmaintained and not up to
scratch for my needs.

## gemini:
The Network.Connection module allows me to open a TLS connection, write a line
from it, and read a line from it.

mWhile (connectionWaitForInput -1) connectionGetChunk should read the full file.

May want to parse response header (after converter to UTF-8) via uncons & strip.

Since the protocol takes a URL and returns a mimetype, error code, & data it
should fit right in. And it's markdown looks trivial to parse into HTML the
rest of Rhapsode can handle. It should slot right in!

## gopher:
Would need more conversion effort, to extract from the URL and convert them to
MIMEtypes. And if we want decent audio output, those would need to be parsed

M README.md => README.md +1 -1
@@ 9,6 9,7 @@ initialized by `Data.Network.Fetch.newSession`.
## Supported URI schemes
HURL can resolve the following URL schemes:
* `http(s):` - via [http-client](https://hackage.haskell.org/package/http-client)
* [`gemini:`](https://gopher.tildeverse.org/zaibatsu.circumlunar.space/1/~solderpunk/gemini) - being developed by [@solderpunk@tilde.zone](https://tilde.zone/@solderpunk)
* `file:`
* `data:` - via [bytestring-base64](https://hackage.haskell.org/package/bytestring-base64)
* Native apps on [FreeDesktop.Org](https://www.freedesktop.org/wiki/Specifications/)-compliant systems (including basically any non-Android Linux system)


@@ 23,7 24,6 @@ Integration of the following URL schemes would be appreciated:
* `magnet:` - Outdated/incomplete Haskell implementation exists.
* `gopher:` - Would want to pair with a [Markdown-to-HTML](https://hackage.haskell.org/package/pandoc) parser to restore semantics lost in Rhapsode's conversion to audio.
* `xdg-icon:` - Custom, looks up images according to [icon-theme-spec](https://www.freedesktop.org/wiki/Specifications/icon-theme-spec/)
* [`gemini:`](https://gopher.tildeverse.org/zaibatsu.circumlunar.space/1/~solderpunk/gemini) - being developed by [@solderpunk@tilde.zone](https://tilde.zone/@solderpunk).
* [`idsc:`/`mdsc:`](https://datashards.net/) - being developed by [@cwebber@octodon.social](https://octodon.social/@cwebber).
* Dispatch to apps on Mac OS X, Windows, Android, and/or iOS.