iens

Manager of links to read
git clone https://git.instinctive.eu/iens.git
Log | Files | Refs | README | LICENSE

commit 39ce128a3b6821447c5e9464554382d7a76dc0df
parent 1c32c62d4b91c054bc904b328773071d18ad0e0c
Author: Natasha Kerensikova <natgh@instinctive.eu>
Date:   Fri,  8 Mar 2024 19:19:20 +0000

Feed mtime is displayed and updatable
Diffstat:
Msrc/iens.scm | 12+++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)

diff --git a/src/iens.scm b/src/iens.scm @@ -308,7 +308,7 @@ "" "Display all feeds" (query (map-rows* - (lambda (id filename url selector title active-int) + (lambda (id filename url selector title active-int mtime) (write-line (conc (if (zero? active-int) (conc "(" id ")") (conc "#" id)) @@ -317,14 +317,20 @@ " - " title)) (write-line (conc " " url)) - (write-line (conc " " selector)))) - (sql db "SELECT id,filename,url,selector,title,active FROM feed;"))) + (write-line (conc " " selector)) + (unless (null? mtime) + (write-line (conc " Updated " (rfc-3339 mtime)))))) + (sql db "SELECT id,filename,url,selector,title,active,mtime FROM feed;"))) (defcmd (remove-feed feed-id) "feed-id" "Remove the given feed" (trace `(remove-feed ,feed-id)) (exec (sql db "DELETE FROM feed WHERE id=?;") feed-id)) +(define (touch-feed mtime feed-id) + (trace `(touch-feed ,mtime ,feed-id)) + (exec (sql db "UPDATE feed SET mtime=? WHERE id=?;") mtime feed-id)) + ;; Tag Management (define (set-tag-auto name auto)