Skip to content

Commit

Permalink
Merge pull request #255 from hunshcn/clash-meta-rule
Browse files Browse the repository at this point in the history
feat: add CLASH_META_SUPPORTED_RULE
  • Loading branch information
geekdada authored Feb 24, 2024
2 parents ea06e64 + 4e6f600 commit 4c8b8e7
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions src/constant/constant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,37 @@ export const CLASH_SUPPORTED_RULE = [
'PROCESS-NAME',
] as const

// CLASH_META_SUPPORTED_RULE generate by `curl -sf https://raw.githubusercontent.com/MetaCubeX/mihomo/Meta/rules/parser.go | grep case | sed 's/://' | sed 's/case//' | tr '\n' ',' | python3 -c 'print(eval(input()))' | sed 's/, / \n/g' | sed 's/[()]//' | sed 's/[ ]*$/,/'`
export const CLASH_META_SUPPORTED_RULE = [
'DOMAIN',
'DOMAIN-SUFFIX',
'DOMAIN-KEYWORD',
'GEOSITE',
'GEOIP',
'IP-CIDR',
'IP-CIDR6',
'SRC-IP-CIDR',
'IP-SUFFIX',
'SRC-IP-SUFFIX',
'SRC-PORT',
'DST-PORT',
'IN-PORT',
'DSCP',
'PROCESS-NAME',
'PROCESS-PATH',
'NETWORK',
'UID',
'IN-TYPE',
'IN-USER',
'IN-NAME',
'SUB-RULE',
'AND',
'OR',
'NOT',
'RULE-SET',
'MATCH',
] as const

export const QUANTUMULT_X_SUPPORTED_RULE = [
'USER-AGENT',
'HOST',
Expand Down

0 comments on commit 4c8b8e7

Please sign in to comment.