summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README26
1 files changed, 25 insertions, 1 deletions
diff --git a/README b/README
index d2b7400..3cc7ca2 100644
--- a/README
+++ b/README
@@ -552,7 +552,7 @@ Now you can view feeds in mutt(1) for example.
- - -
-Incremental data updates
+Incremental data updates using If-Modified-Since
For servers that support it some incremental updates and bandwidth-saving can
be done by using the "If-Modified-Since" HTTP header.
@@ -573,6 +573,30 @@ vector of the local modification date of the feed file.
- - -
+Incremental data updates using ETag caching
+
+For servers that support it some incremental updates and bandwidth-saving can
+be done by using the "ETag" HTTP header.
+
+Create a directory for storing the ETags per feed:
+
+ mkdir -p ~/.sfeed/etags/
+
+The curl ETag options can be used to send the previous ETag header value. You
+can do this by overriding the fetch() function in the sfeedrc file and adding
+the --etag-save and --etag-compare options:
+
+ # fetch(name, url, feedfile)
+ fetch() {
+ etag="$HOME/.sfeed/etags/$1"
+ curl --etag-save "${etag}" --etag-compare "${etag}" "$2"
+ }
+
+This comes at a cost of some privacy. For example there can be a unique
+generated ETag.
+
+- - -
+
CDN's blocking requests due to missing User-Agent
sfeed_update will not send the "User-Agent" header by default for privacy