fix: revert filter separator from alternation to backtick - #196
Open
MakostaDev wants to merge 1 commit into
Open
fix: revert filter separator from alternation to backtick#196MakostaDev wants to merge 1 commit into
filter separator from alternation to backtick#196MakostaDev wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mihomo has special handling for the backtick character in
filter/exclude-filter. This lets you control the order ofproxieswithin aproxy-grouporproxy-providerby separating patterns with a backtick:https://github.com/MetaCubeX/mihomo/blob/1e62d55418ea55f221ae8523135c1440667fd935/adapter/outboundgroup/groupbase.go#L64-L78
https://github.com/MetaCubeX/mihomo/blob/e928ef59c1aaa5b7db01a3a01f2c97730f0d0d16/adapter/provider/provider.go#L349-L367
However, in this commit the backtick separator was replaced with
|:b2f28dd#diff-f205c072e6e58ba4f1dce50461e4ac10c93a2fd6ac4f878fb52ec20744dd895c
But
|is itself a regex metacharacter. It denotes alternation, which the docs even link to.