12

We have monorepo, my team responsible for 3 of 20 packages/folder of repository, but sometimes we need to touch others packages/folders. For reviewing teammates changes every member should add “team_label” for ability to filter by this label or to keep opened several tabs with merge requests for each author/team member.

Preferable could be filtering MRs something like this by one of the author:

author: username1 OR author:username2 OR author:username3

We are using GitLab Enterprise Edition 12.6.2-ee

upd: discussed in gitlab docs comments and there is no ability to filter merge requests even with advanced search

Advanced Search does currently not have the facets available that you use in the dedicated issue or MR search

https://docs.gitlab.com/ee/user/search/index.html#comment-4776091890

Feature proposal:

https://gitlab.com/gitlab-org/gitlab/issues/7826

Alex
  • 329
  • 2
  • 17
  • If there's an open feature request, the answer is basically always "no, there's no way to do it". Obviously, you could pull the data via API and build yourself something, but there's nothing built into GitLab. – Arty-chan Sep 07 '22 at 16:57

2 Answers2

2

Unfortunately to date you can't search merge requests with an OR query - and although gitlab states that successive clauses should be ANDed together a quick test suggests that in fact an arbitrary single clause is applied.

See e.g. https://forum.gitlab.com/t/mr-filtering-by-multiple-authors/33864

Tim Barrass
  • 4,813
  • 2
  • 29
  • 55
0

To filter merge request and all the other kind of thing you want to search for you can read this guide on how to search with filters: GitLab Filter Guide

Anyway if you want a quick suggestion you have to go in the "Merge request" section of your sidebar menu. After that, you can see on the upper part of the tables where all the merge request are listed a little search bar that says "Search or filter results..." if you click on that a little dropdown opens up to suggest you how to use the search bar.

To search in a list of all the authors you have to input the following: author: (this will let you see a little dropdown with all the authors) or you can search directly with an author name putting a "@" before his name.

If you want to concatenate more filter criteria you have to put AND or OR as you would do in a SQL query. But anything is well explained in the guide.

Devolux
  • 146
  • 1
  • 8
  • 4
    AND/OR doesn't work on "Merge request" filter field. There is possible to filter by several label with AND conditions like this: label:label_name1 label:label_name2 – Alex Jan 29 '20 at 12:41
  • By default the conditions in the filter criteria are divided by and and but if you put an "OR" followed by ":" you can filter with the "OR". – Devolux Jan 29 '20 at 15:03
  • can you please provide example of query string for this case? Example from gitlab: "jacopo-beschi" has merged MRs and "stanhu" has merged MRs. How to find MRs of both? Link below returns only requests of "stanhu" https://gitlab.com/gitlab-org/gitlab-foss/-/merge_requests?scope=all&utf8=%E2%9C%93&state=merged&author_username=jacopo-beschi&author_username=stanhu&search=OR – Alex Jan 29 '20 at 20:54