about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorCase Duckworth2022-07-20 09:40:29 -0500
committerCase Duckworth2022-07-20 09:40:29 -0500
commit17794ef8848c06b24bdddd34c78dc8acf2b96d16 (patch)
treec6aaceb30a8e5db7316d9fcbbd82de0a3c51193d
parentAdd Joshua Weissman (diff)
downloadsfeed-17794ef8848c06b24bdddd34c78dc8acf2b96d16.tar.gz
sfeed-17794ef8848c06b24bdddd34c78dc8acf2b96d16.zip
Customize merge()
-rw-r--r--sfeedrc9
1 files changed, 8 insertions, 1 deletions
diff --git a/sfeedrc b/sfeedrc index cc586e1..52a55c9 100644 --- a/sfeedrc +++ b/sfeedrc
@@ -229,7 +229,7 @@ filter_embed_youtube() {
229 229
230filter_filter_links() { 230filter_filter_links() {
231 # shorten feedburner links and strip tracking parameters and pixels 231 # shorten feedburner links and strip tracking parameters and pixels
232 awk -F '\t' 'BEGIN { OFS = "\t"; } 232 awk 'BEGIN { FS= "\t"; OFS = "\t"; }
233function filterlink(s) { 233function filterlink(s) {
234# protocol must start with http, https or gopher. 234# protocol must start with http, https or gopher.
235if (match(s, /^(http|https|gopher):\/\//) == 0) { 235if (match(s, /^(http|https|gopher):\/\//) == 0) {
@@ -280,6 +280,13 @@ fetch() { # fetch(name, url, feedfile)
280 "$2" 280 "$2"
281} 281}
282 282
283# Merge ########################################################
284
285merge() {
286 # merge(name, oldfile, newfile)
287 sort -t ' ' -u -k6,6 -k3,3 "$2" "$3" 2>/dev/null
288}
289
283# Local Variables: 290# Local Variables:
284# truncate-lines: t 291# truncate-lines: t
285# End: 292# End: