为提升您的使用体验,本站正在维护,部分功能暂时无法使用。如果本站文章无法解决您的问题,您想要向社区提问的话,请到 Twitter 上的 @FirefoxSupport 或 Reddit 上的 /r/firefox 提问,我们的支持社区将会很快回复您的疑问。

搜索 | 用户支持

防范以用户支持为名的诈骗。我们绝对不会要求您拨打电话或发送短信,及提供任何个人信息。请使用“举报滥用”选项报告涉及违规的行为。

详细了解

How do I filter by the presence/absence of a field?

more options

Gitlab adds a "X-GitLab-NotificationReason" field to the email headers, but only sometimes. I want to filter out messages that do not contain this header. How do I do it? The only operators I can see in the GUI are "contains", "doesn't contain", "is", "isn't", "begins with" and "ends with".

They don't take regexes or wildcards, do they? In that case maybe "is *" would work?

Gitlab adds a "X-GitLab-NotificationReason" field to the email headers, but only sometimes. I want to filter out messages that do not contain this header. How do I do it? The only operators I can see in the GUI are "contains", "doesn't contain", "is", "isn't", "begins with" and "ends with". They don't take regexes or wildcards, do they? In that case maybe "is *" would work?

所有回复 (4)

more options

You might get a regex via the filtaquilla addon. It adds a lot of powerful options to filters, including Regex on subjects and header and javascript actions. It is like many advanced tools assuming you know what you are doing with a regex and javascript. https://addons.thunderbird.net/en-US/thunderbird/addon/filtaquilla/

有帮助吗?

more options

Ok, so in filterquilla does "property doesn't contain this regex" mean it'll match when the header property isn't present at all?

有帮助吗?

more options

I have no idea. I did not write the thing, nor do I actually claim to know what a regex is or does. If it was me I would just test it on a small collection of email to determine what is does.

Did you consult the documentation? https://quickfilters.quickfolders.org/filtaquilla.html Have a look at the open issues? https://github.com/RealRaven2000/FiltaQuilla/issues Use the support email in the link I provided? axel.grude@gmail.com

Alternatively you could simply check for the existence of the five possible values of the header rather than the simple presence of the header. Probably my preferred choice as it has so few possible values although a criteria specifying the header being not equal to " " may be enough or begins with is not "Z" would also work as none of the valid values begins with a Z. https://docs.gitlab.com/ee/user/profile/notifications.html#x-gitlab-notificationreason

X-GitLab-NotificationReason The X-GitLab-NotificationReason header contains the reason for the notification. The value is one of the following, in order of priority: own_activity assigned review_requested mentioned subscribed The reason for the notification is also included in the footer of the notification email. For example, an email with the reason assigned has this sentence in the footer:

有帮助吗?

more options

> nor do I actually claim to know what a regex is or does

See https://en.wikipedia.org/wiki/Regular_expression#POSIX_basic_and_extended

Anyway, filterquilla has turned out to be too slow, probably because regexes can be quite slow to run. I've ended up using two filters, one to filter by project and apply a tag for "peer review" and the specific project, and then another filter to move messages that have "peer review" but don't mention me.

有帮助吗?

我要提问

您需要登录才能回复。如果您还没账号,可以提出新问题