Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add CLASH_META_SUPPORTED_RULE #255

Merged
merged 1 commit into from
Feb 24, 2024

Conversation

hunshcn
Copy link
Contributor

@hunshcn hunshcn commented Feb 20, 2024

close #254

在 clash core 消失的情况下以 meta 作为继任者 的角度,直接修改我认为还算合理

Copy link

netlify bot commented Feb 20, 2024

Deploy Preview for surgio-documentation ready!

Name Link
🔨 Latest commit 4e6f600
🔍 Latest deploy log https://app.netlify.com/sites/surgio-documentation/deploys/65d959b69b1c48000835b857
😎 Deploy Preview https://deploy-preview-255--surgio-documentation.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Copy link

codecov bot commented Feb 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 76.60%. Comparing base (ea06e64) to head (4e6f600).

Additional details and impacted files
@@           Coverage Diff           @@
##           master     #255   +/-   ##
=======================================
  Coverage   76.60%   76.60%           
=======================================
  Files          62       62           
  Lines        2347     2347           
  Branches      584      584           
=======================================
  Hits         1798     1798           
  Misses        359      359           
  Partials      190      190           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@hunshcn
Copy link
Contributor Author

hunshcn commented Feb 23, 2024

@geekdada 看看是给clash.meta一个单独的filter还是继续沿用clash ?

@geekdada
Copy link
Member

感谢贡献代码!

我觉得目前版本使用单独 filter 比较合适,下个大版本再考虑将 meta 作为默认引擎。另外我还有个想法,除了提供单独的 filter,还可以在模板引擎 getEngine 方法中读取 Surgio 配置 clashConfig.clashCore,这样即可让 clash 对应不同的 filter。你觉得怎么样。

@geekdada
Copy link
Member

我配置 Code Reviewers 自动分配,今后不会没人理了……

@hunshcn
Copy link
Contributor Author

hunshcn commented Feb 23, 2024

感谢贡献代码!

我觉得目前版本使用单独 filter 比较合适,下个大版本再考虑将 meta 作为默认引擎。另外我还有个想法,除了提供单独的 filter,还可以在模板引擎 getEngine 方法中读取 Surgio 配置 clashConfig.clashCore,这样即可让 clash 对应不同的 filter。你觉得怎么样。

嗯,确实这样感觉是最好的方案。我修改pr支持一下吧。对项目不太熟,读配置有点复杂,我支持不了。

@geekdada
Copy link
Member

那麻烦你新增一个 filter clashMeta 对应 CLASH_META_SUPPORTED_RULE。我会支持我提到的那个特性。感谢。

@hunshcn
Copy link
Contributor Author

hunshcn commented Feb 24, 2024

已修改

@hunshcn hunshcn changed the title feat: sync clash meta supported rules feat: add CLASH_META_SUPPORTED_RULE Feb 24, 2024
@@ -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/[ ]*$/,/'`
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

非常棒

@geekdada geekdada merged commit 4c8b8e7 into surgioproject:master Feb 24, 2024
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[FR] 支持 clash meta RULE
2 participants