Commits


Merge pull request #9 from ollytom/main rss: handle more timestamp variants


internal/db: return error on channel not found Defining a new error as I imagine we'll be wanting to handle this explicitly e.g. by trying to look up a feed on the web.


Rename some templates Make the channel template re-usable Add handler for channel page List episode titles


internal/service: add a primitive error page Onwards and upwards from a panic


Add initial channel handler


rss: add MIME type Helps in feed type detection, autodiscovery


Wrap channel results so we can add extra data Link to channel


readme: add pkg.go.dev link


Rename "Feeds" to Channels as that's what they are Make button link styles reuseable Add button that will link to the channel


rss: handle more timestamp variants I parsed every feed listed in opml/otl.opml and found a bunch of variants of RFC 822 and RFC 1123 timestamps used.


Merge pull request #8 from ollytom/main rss: handle valid empty fields


rss: handle valid empty fields Ran into a problem when trying to parse the feed at https://hnrss.org/frontpage. That feed's channel has no pubdate element set; UnmarshalXML errors on timestamp parsing with as it gets an empty string. Reading the spec I found very few fields are actually required. Funnily enough testdata/empty.xml is a valid RSS feed - I even verified using the official RSS validator at https://www.rssboard.org/rss-validator !


Display most appropriate channel data Improve channel styling


Merge pull request #7 from ollytom/js service: support queries without javascript


Merge pull request #6 from ollytom/time rss: store pubdate etc. as native time.Time


service: support queries without javascript I was curious how it all worked if I disabled javascript entirely. Pretty cool how it all "just worked" once I set the usual `action` attr in the form element. While here fix little nit about using a boolean type for a boolean condition


rss: store pubdate etc. as native time.Time This uses a technique I've used a few times to work with loosely typed data in XML and JSON. The original idea is from [icholy]. It's a little tricky, but it's easy to test. [icholy]: https://choly.ca/post/go-json-marshalling/


Improve parsing of additional rss channel meta data Initial rendering of channel results Move handlers into their own file


Create DB package for reading/writing data Implement URL detection for search and lookup RSS feed


Merge pull request #4 from ollytom/main rss: use built-in RFC 1123 time format


rss: use built-in RFC 1123 time format Numeric timezone variant. Timestamps :(


Move handlers to their own service


Add RSS decoder


Merge pull request #3 from ollytom/main add opml package


add opml package Feed readers use OPML to exchange lists of feeds, which is what any applications developed here may do at some point, too. This package only does decoding for now; I dumped my own feeds out of my own feed reader app as a quick test to see how tricky this would be!