mybin

my ~/bin
git clone https://a3nm.net/git/mybin/
Log | Files | Refs | README

commit 79403616d8a6316f047f194f4ca7659600a96ba1
parent 38c020f3b3bf6593e99d6efec5a0c9f170a0e864
Author: Antoine Amarilli <a3nm@a3nm.net>
Date:   Fri, 29 May 2026 19:06:47 +0200

fix hackernews script

Diffstat:
hackernews_top_stories | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hackernews_top_stories b/hackernews_top_stories @@ -4,7 +4,7 @@ # (see stuff that's really interesting, or major security vulnerabilities) # very dirty: TODO better parsing, TODO use the API -curl -s 'https://news.ycombinator.com/news' | grep -B1 'class="score"' | +curl -s 'https://news.ycombinator.com/news' | sed 's_</tr>_\n_g' | grep -B1 'class="score"' | grep -B1 ">.... points<" | grep 'class="title"' | sed 's/.*href="http\([^>]*>[^<]*\).*/http\1/g' | sed 's/">/ /g'