Signed-off-by: Fam Zheng <famz@redhat.com>
---
api/search.py | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/api/search.py b/api/search.py
index 0be435f..9ab6e0b 100644
--- a/api/search.py
+++ b/api/search.py
@@ -110,6 +110,16 @@ Compare the address info of message. Example:
---
+### Search by maintainer associated with the changeset
+
+ - Syntax: maintained-by:NAME
+ - Syntax: maint:NAME
+
+NAME can be the name, email or a substring of MAINTAINERS file entries of the
+maintainer.
+
+---
+
### Search by result
Syntax:
@@ -303,6 +313,11 @@ Search text keyword in the email message. Example:
cond = term[term.find(":") + 1:]
self._projects.add(cond)
return Q(project__name=cond) | Q(project__parent_project__name=cond)
+ elif term.startswith("maintained-by:") or term.startswith("maint:"):
+ cond = term[term.find(":") + 1:]
+ if cond == "me" and user:
+ cond = user.email
+ return Q(maintainers__icontains=cond)
# Keyword in subject is the default
return self._make_filter_keywords(term)
--
2.17.2
_______________________________________________
Patchew-devel mailing list
Patchew-devel@redhat.com
https://www.redhat.com/mailman/listinfo/patchew-devel