jvoisin
19ce519836
reader/rewrite: add a rule for oglaf.com
...
By default, Oglaf show some disclaimer/warning about its content, and this
doesn't play well with rss readers, so let's rewrite it to show the actual
comic instead of a placeholder.
2024-04-01 21:05:01 -07:00
Frédéric Guillot
b1e73fafdf
Enable go-critic linter and fix various issues detected
2024-03-17 13:52:34 -07:00
jvoisin
c29ca0e313
Minor simplifications of the rewriter
...
- Online some one-line functions
- Transform a free-standing function into a method
- Massively simplify `removeClickbait`
- Use a proper constant instead of a magic number in `applyFuncOnTextContent`
2024-03-17 12:15:46 -07:00
Frédéric Guillot
c493f8921e
Add missing regex anchor detected by CodeQL
2024-02-28 20:50:17 -08:00
jvoisin
c4e5dad549
Remove superfluous escaping in a regex
2024-02-28 19:47:30 -08:00
jvoisin
fa12c23d79
Use strings.ReplaceAll instead of strings.Replace(…, -1)
2024-02-28 19:47:30 -08:00
jvoisin
b04550e2f2
Use %q
instead of "%s"
2024-02-28 19:47:30 -08:00
jvoisin
db6ae707ef
Add some tests for add_image_title
...
I'm not sure if the behaviour is expected, but I didn't manage to
get the content injection to work in my browser, so I guess it's alright?
2024-02-27 20:41:15 -08:00
Dave
1159dd6982
Add addDynamicIframe
rewrite function.
...
Add unit tests for `add_dynamic_iframe` rewrite.
2024-01-23 19:23:57 -08:00
dzaikos
d68f2306c6
Add attribute to add_dynamic_image rewrite candidates.
2024-01-21 14:27:06 -08:00
Frédéric Guillot
c0e954f19d
Implement structured logging using log/slog package
2023-09-24 22:37:33 -07:00
Adriano Di Luzio
54cb8fa028
Added new rewrite rules add_hn_links_using_hack
and add_hn_links_using_opener
to open HN comments with iOS apps
2023-09-23 13:54:48 -07:00
Magnus Åhall
69738bce84
Add replace_title
write rule to adjust entry titles
2023-09-06 20:09:54 -07:00
Frédéric Guillot
e5d9f2f5a0
Rename internal url package to avoid overlap with net/url
2023-08-13 19:57:04 -07:00
Frédéric Guillot
168a870c02
Move internal packages to an internal folder
...
For reference: https://go.dev/doc/go1.4#internalpackages
2023-08-10 20:29:34 -07:00