emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Ihor Radchenko <yantar92@posteo.net>
To: Bastien Guerry <bzg@gnu.org>
Cc: Sacha Chua <sacha@sachachua.com>,
	emacs list <emacs-orgmode@gnu.org>,
	Timothy <orgmode@tec.tecosaur.net>
Subject: Re: [DISCUSSION] Add "Recent News" to orgmode.org
Date: Fri, 08 Mar 2024 10:30:09 +0000	[thread overview]
Message-ID: <87ttlhhv7y.fsf@localhost> (raw)
In-Reply-To: <87wmqdxmds.fsf@bzg.fr>

[-- Attachment #1: Type: text/plain, Size: 351 bytes --]

Bastien Guerry <bzg@gnu.org> writes:

>> Also, it looks like https://tracker.orgmode.org/index.org does not sort
>> links by date. It would be nice if top 5 links were also the most recent.
>
> Yes, indeed. I'll see when I can hack on this. Help from Clojure
> hackers is welcome here: https://git.sr.ht/~bzg/woof

Something like the attached maybe.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-src-bzg-data.clj-get-data-Sort-list-of-entries-by-da.patch --]
[-- Type: text/x-patch, Size: 1050 bytes --]

From 2e170f073ae258d27680baf16f8db1aa2dcf9b78 Mon Sep 17 00:00:00 2001
Message-ID: <2e170f073ae258d27680baf16f8db1aa2dcf9b78.1709893748.git.yantar92@posteo.net>
From: Ihor Radchenko <yantar92@posteo.net>
Date: Fri, 8 Mar 2024 13:28:12 +0300
Subject: [PATCH] src/bzg/data.clj (get-data): Sort list of entries by date
 (latest first)

Link: https://orgmode.org/list/87wmqdxmds.fsf@bzg.fr
---
 src/bzg/data.clj | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/bzg/data.clj b/src/bzg/data.clj
index 99ab66d..333dd6a 100644
--- a/src/bzg/data.clj
+++ b/src/bzg/data.clj
@@ -74,6 +74,8 @@
                     :requests (fetch/requests source-id search)
                     :patches  (fetch/patches source-id search)
                     :news     (fetch/news source-id search))
+        ;; Display the latest first.
+        resources (reverse (sort resources))
         headers   (condp = format
                     "rss"  {"Content-Type" "application/xml"}
                     "md"   {"Content-Type" "text/plain; charset=utf-8"}
-- 
2.43.0


[-- Attachment #3: Type: text/plain, Size: 224 bytes --]


-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

  reply	other threads:[~2024-03-08 10:27 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-04 19:41 [DISCUSSION] Add "Recent News" to orgmode.org Ihor Radchenko
2024-02-04 19:57 ` Thomas Dye
2024-02-04 20:24 ` Juan Manuel Macías
2024-02-04 20:49 ` Juergen Fenn
2024-02-04 21:02 ` Sacha Chua
2024-02-24 14:32   ` Bastien Guerry
2024-02-25 11:11     ` Ihor Radchenko
2024-02-26 10:01       ` Bastien Guerry
2024-02-26 10:59         ` Ihor Radchenko
2024-02-26 13:00           ` Bastien Guerry
2024-03-08  6:17           ` Bastien Guerry
2024-03-08  6:27             ` Ihor Radchenko
2024-03-08  6:34               ` Bastien Guerry
2024-03-08 10:30                 ` Ihor Radchenko [this message]
2024-03-08 10:31                   ` Ihor Radchenko
2024-03-08 15:41                   ` Bastien Guerry
2024-03-09  8:33     ` Ihor Radchenko
2024-03-09  8:35       ` Bastien Guerry
2024-03-23 14:25         ` Ihor Radchenko
2024-03-23 17:17           ` Bastien Guerry
2024-03-25  8:44             ` Ihor Radchenko
2024-04-28 13:28               ` Bastien Guerry
2024-06-08 19:07         ` Ihor Radchenko
2024-06-09  8:29           ` Bastien Guerry
2024-06-09 11:36             ` Ihor Radchenko
2024-06-10  8:56               ` Bastien Guerry
2024-06-11 10:10                 ` Ihor Radchenko
2024-02-05 21:52 ` Jean Louis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87ttlhhv7y.fsf@localhost \
    --to=yantar92@posteo.net \
    --cc=bzg@gnu.org \
    --cc=emacs-orgmode@gnu.org \
    --cc=orgmode@tec.tecosaur.net \
    --cc=sacha@sachachua.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).