From d6c2daee51fa90f000c106492141baf3824931d2 Mon Sep 17 00:00:00 2001 From: Alexandre Alapetite Date: Sat, 25 Jan 2025 09:16:13 +0100 Subject: Add search operator intext: (#7228) * Add search operator intext: fix https://github.com/FreshRSS/FreshRSS/issues/6188 https://github.com/FreshRSS/FreshRSS/discussions/7220 * Add example to doc --- docs/en/users/10_filter.md | 5 ++++- docs/fr/users/03_Main_view.md | 3 +++ 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'docs') diff --git a/docs/en/users/10_filter.md b/docs/en/users/10_filter.md index 0aecfbaa0..7ca1aefff 100644 --- a/docs/en/users/10_filter.md +++ b/docs/en/users/10_filter.md @@ -48,6 +48,7 @@ You can use the search field to further refine results: * by feed ID: `f:123` or multiple feed IDs (*or*): `f:123,234,345` * by author: `author:name` or `author:'composed name'` * by title: `intitle:keyword` or `intitle:'composed keyword'` +* by text (content): `intext:keyword` or `intext:'composed keyword'` * by URL: `inurl:keyword` or `inurl:'composed keyword'` * by tag: `#tag` or `#tag+with+whitespace` or `#'tag with whitespace'` * by free-text: `keyword` or `'composed keyword'` @@ -97,7 +98,7 @@ Some operators can be used negatively, to exclude articles, with the same syntax `!f:234`, `-author:name`, `-intitle:keyword`, `-inurl:keyword`, `-#tag`, `!keyword`, `!date:2019`, `!date:P1W`, `!pubdate:P3d/`. It is also possible to combine keywords to create a more precise filter. -For example, you can enter multiple instances of `f:`, `author:`, `intitle:`, `inurl:`, `#`, and free-text. +For example, you can enter multiple instances of `f:`, `author:`, `intitle:`, `intext:`, `inurl:`, `#`, and free-text. Combining several search criteria implies a logical *and*, but the keyword ` OR ` can be used to combine several search criteria with a logical *or* instead: `author:Dupont OR author:Dupond` @@ -132,6 +133,8 @@ Supports multiline mode with `m` modifier, like: `/^Alice/m` Example to search entries, which title starts with the *Lol* word, with any number of *o*: `intitle:/^Lo+l/i` +Example to search empty entries (where the body of articles is blank): `intext:/^\s*$/` + As opposed to normal searches, special XML characters `<&">` are not escaped in regex searches, to allow searching HTML code, like: `/Hello world<\/span>/` > ℹ️ A literal slash needs to be escaped, like `\/` diff --git a/docs/fr/users/03_Main_view.md b/docs/fr/users/03_Main_view.md index e1be4ca3d..8e8444dd2 100644 --- a/docs/fr/users/03_Main_view.md +++ b/docs/fr/users/03_Main_view.md @@ -207,6 +207,7 @@ Il est possible d’utiliser le champ de recherche pour raffiner les résultats * par ID de flux : `f:123` ou plusieurs flux (*ou*) : `f:123,234,345` * par auteur : `author:nom` ou `author:'nom composé'` * par titre : `intitle:mot` ou `intitle:'mot composé'` +* par texte (contenu) : `intext:mot` ou `intext:'mot composé'` * par URL : `inurl:mot` ou `inurl:'mot composé'` * par tag : `#tag` ou `#'tag avec espace'` * par texte libre : `mot` ou `'mot composé'` @@ -291,6 +292,8 @@ Le mode multilignes peut être activé avec l’option de recherche `m` comme : Exemple pour rechercher des articles dont le titre commence par le mot *Lol* avec un nombre indéterminé de *o*: `intitle:/^Lo+l/i` +Exemple pour rechercher des articles dont le contenu est vide : `intext:/^\s*$/` + Contrairement aux recherches normales, les caractères spéciaux XML `<&">` ne sont pas encodés dans les recherches regex, afin de permettre de chercher du code HTML, comme : `/Bonjour à tous<\/span>/` > ℹ️ Une barre oblique (slash) doit être échappée comme suit : `\/` -- cgit v1.2.3