From 927312d894dfb572797c3c217440e0fb13a0f6aa Mon Sep 17 00:00:00 2001 From: Popolon Date: Fri, 17 Jan 2025 22:22:07 +0100 Subject: [PATCH] add Lemmy accounts from wikidata search --- searx/data/external_urls.json | 7 +++++++ searx/engines/wikidata.py | 2 ++ 2 files changed, 9 insertions(+) diff --git a/searx/data/external_urls.json b/searx/data/external_urls.json index 9eca6a1b9..09cd5ee11 100644 --- a/searx/data/external_urls.json +++ b/searx/data/external_urls.json @@ -41,6 +41,13 @@ "default": "https://fedirect.toolforge.org/?id=$1" } }, + "lemmy_profile": { + "category_name": "Lemmy", + "url_name": "Lemmy profile", + "urls": { + "default": "https://fedirect.toolforge.org/?id=$1" + } + }, "peertube_profile": { "category_name": "Peertube", "url_name": "Peertube profile", diff --git a/searx/engines/wikidata.py b/searx/engines/wikidata.py index 8314313e5..7366c5211 100644 --- a/searx/engines/wikidata.py +++ b/searx/engines/wikidata.py @@ -61,6 +61,7 @@ WIKIDATA_PROPERTIES = { 'P2013': 'Facebook', 'P2003': 'Instagram', 'P4033': 'Mastodon', + 'P11947': 'Lemmy', 'P12622': 'PeerTube', } @@ -478,6 +479,7 @@ def get_attributes(language): add_url('P2013', url_id='facebook_profile') add_url('P2003', url_id='instagram_profile') add_url('P4033', url_id='mastodon_profile') + add_url('P11947', url_id='lemmy_profile') add_url('P12622', url_id='peertube_profile') # Map