From 7bffb9e0da2bc196061a4559449d9f6d877886bf Mon Sep 17 00:00:00 2001 From: Case Duckworth Date: Sat, 13 Aug 2022 22:50:17 -0500 Subject: Add weeds generation --- weedrc | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 weedrc (limited to 'weedrc') diff --git a/weedrc b/weedrc new file mode 100644 index 0000000..ea22213 --- /dev/null +++ b/weedrc @@ -0,0 +1,31 @@ +# -*- sh -*- + +SFEED="$HOME/.sfeed" +USER_AGENT='Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Firefox/78.0' +sfeedpath="$SFEED/weedsfeeds" +maxjobs="$(nproc)" + +### Feeds ####################################################### + +feeds() { + ## feed NAME FEED_URL BASE_URL ENCODING # defined by sfeedrc(5). + feed dozens "https://tilde.town/~dozens/rsspect/feed.xml" "https://tilde.town/~dozens/" + feed acdw "https://acdw.casa/weed.xml" "https://acdw.casa" + # feed lucidiot +} + +# Fetch ######################################################### + +fetch() { # fetch(name, url, feedfile) + "${NOFETCH:-false}" && return + curl -s -L \ + --max-redirs 3 \ + --header "'User-Agent: $USER_AGENT'" \ + --fail \ + --max-time 15 \ + "$2" +} + +# Local Variables: +# truncate-lines: t +# End: -- cgit 1.4.1-21-gabe81