我又来了,这次将重构Clash扩展脚本(Clash Verge Rev和Mihomo Party,包括纯内核配置)

前言

这个是之前我写了一个扩展脚本,是基于js的,可能对很多佬来说上手有点难,这次重构为yaml配置,这样佬友们上手就会更加简单,后期我会更新这个配置文件,js那个就不会更新了。

覆写链接

Github链接
https://raw.githubusercontent.com/wanswu/my-backup/refs/heads/main/clash/config.yaml
Jsdelivr链接方便无法访问Github的佬
https://testingcf.jsdelivr.net/gh/wanswu/my-backup@master/clash/config.yaml

配置开始

订阅合并配置

这个可以直接将你的所有的订阅合并一个,这个功能Mihomo Party可以通过 Sub-Store去进行合并,但是有点麻烦。有些佬友有这个需求,所以就将这个单独写在这里。

订阅合并模块

# 机场订阅
proxy-providers:
  p1:
    type: http
    interval: 86400
    url: https://al121.cc/#/register?code=R7vdKxbE
    path: ./proxy_provider/p1.yaml
    override:
      additional-prefix: 'p1 | '
  p2:
    type: http
    interval: 86400
    url: https://al121.cc/#/register?code=R7vdKxbE
    path: ./proxy_provider/p2.yaml
    override:
      additional-prefix: 'p2 | '

全局配置覆写

这个配置文件可以将所有的订阅链接合并在一起,使用统一的规则,方便管理,具体配置佬友们也可以根据自己的需求去更改。
目前完成的功能

  • 将所有请求github的链接转换成CDN链接
  • 所有不在规则内的请求都走代理(一定程度上防止DNS泄露,但是也会导致某些网站访问异常,需要佬友排查连接情况,添加排除规则)
  • 订阅合并

更新有点勤,github获取最新版吧

# 订阅锚点,排除了一些节点,例如 包含剩余,官网,到期,也可以在exclude-filter添加你需要排除的节点
Providers: &Providers { exclude-filter: "套餐到期|重置|剩余|国内|永久|基础|教学|资源", type: http, interval: 86400, health-check: { enable: true, url: https://www.gstatic.com/generate_204, interval: 300 } }
# 官方配置文档: https://wiki.metacubex.one/config/proxy-providers/
proxy-providers:
  p1:
    <<: *Providers
    url: https://al121.cc/#/register?code=R7vdKxbE
    path: ./proxy_provider/p1.yaml
    override:
      additional-prefix: 'p1 | '  # 订阅节点前缀,方便区分该节点属于哪个订阅链接 例如`p1 | 香港🇭🇰

  p2:
    <<: *Providers
    url: https://al121.cc/#/register?code=R7vdKxbE
    path: ./proxy_provider/p2.yaml
    override:
      additional-prefix: 'p2 | '

# 通用配置
mode: rule
ipv6: true
mixed-port: 7890
allow-lan: true
bind-address: 0.0.0.0
log-level: info
unified-delay: true
find-process-mode: strict
global-client-fingerprint: chrome
# 规则选择缓存
profile:
  store-selected: true
  store-fake-ip: true
tcp-concurrent: true
keep-alive-interval: 15
keep-alive-idle: 15
disable-keep-alive: true


# dns配置
dns:
  enable: true
  ipv6: true
  prefer-h3: false
  use-hosts: false
  use-system-hosts: false
  enhanced-mode: fake-ip
  fake-ip-range: 198.18.0.1/16
  fake-ip-filter:
    - "*"
    - "+.lan"
    - "+.local"
    - "+.msftconnecttest.com"
    - "+.msftncsi.com"
    - "localhost.ptlogin2.qq.com"
    - "localhost.sec.qq.com"
    - "localhost.work.weixin.qq.com"
    - "market.xiaomi.com"
    - "*.xiaomi.com"
    - "*.mi.com"
    - "*.miui.com"
    - "*.xiaomi.net"
    - "*.mi.net"
    - "*.miui.net"
    - "*.pcbeta.com"
  default-nameserver:
    - tls://223.5.5.5
    - tls://119.29.29.29
  nameserver:
    - https://doh.pub/dns-query
    - https://dns.alidns.com/dns-query


# GEO配置
geodata-mode: true
geo-auto-update: true
geo-update-interval: 24
geodata-loader: memconservative
geox-url:
  geoip: "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@release/geoip.dat"
  geosite: "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@release/geosite.dat"
  mmdb: "https://testingcf.jsdelivr.net/gh/MetaCubeX/meta-rules-dat@release/country.mmdb"
  asn: "https://github.com/xishang0128/geoip/releases/download/latest/GeoLite2-ASN.mmdb"

# 时间同步

ntp:
  enable: true
  write-to-system: false
  server: time.apple.com
  port: 123
  interval: 30

# 入站
tun:
  enable: false
  stack: gvisor
  auto-route: true
  strict-route: false
  auto-detect-interface: true
  dns-hijack:
  - any:53

# 嗅探
sniffer:
  enable: false
  force-dns-mapping: true
  parse-pure-ip: true
  override-destination: false
  sniff:
    TLS:
      ports:
        - 443
        - 8443
    HTTP:
      ports:
        - 80
        - 8080-8880
      override-destination: true
    QUIC:
      ports:
        - 443
        - 8443
  force-domain: []
  skip-domain:
    - +.oray.com
    - "Mijia Cloud"
    - "+.push.apple.com"

# 面板设置
external-controller: 127.0.0.1:9090
secret: ""
external-ui: "./ui"
external-ui-name: zashboard
external-ui-url: "https://github.com/Zephyruso/zashboard/archive/refs/heads/gh-pages.zip"

# 代理组锚点,是为了减少重复配置
SelectALL: &SelectALL { type: url-test, proxies: [ 香港, 澳门, 台湾, 日本, 韩国, 美国, 英国, 德国, 法国, 印度, 新加坡, 印尼, 越南, 泰国, 澳洲, 巴西, 其他, DIRECT, REJECT ], interval: 300, tolerance: 50, url: 'https://www.gstatic.com/generate_204', disable-udp: false, timeout: 700, include-all: true }
SelectHK: &SelectHK { type: select, proxies: [ 自动选择, 香港, 澳门, 台湾, 日本, 韩国, 美国, 英国, 德国, 法国, 印度, 新加坡, 印尼, 越南, 泰国, 澳洲, 巴西, 其他, DIRECT, REJECT ], include-all: true }
SelectTW: &SelectTW { type: select, proxies: [ 台湾, 手动选择, 香港, 澳门, 日本, 韩国, 美国, 英国, 德国, 法国, 印度, 新加坡, 印尼, 越南, 泰国, 澳洲, 巴西, 其他, DIRECT, REJECT ] }
SelectDirect: &SelectDirect { type: select, proxies: [ DIRECT, 手动选择, 香港, 澳门, 台湾, 日本, 韩国, 美国, 英国, 德国, 法国, 印度, 新加坡, 印尼, 越南, 泰国, 澳洲, 巴西, 其他, REJECT ] }
SelectProxy: &SelectProxy { type: select, proxies: [ 手动选择, 香港, 澳门, 台湾, 日本, 韩国, 美国, 英国, 德国, 法国, 印度, 新加坡, 印尼, 越南, 泰国, 澳洲, 巴西, 其他, DIRECT, REJECT ] }
# hidden: true 是为了隐藏地区分组,有需要显示出来的佬友可以删除
UrlTest: &UrlTest { type: url-test, interval: 300, tolerance: 50, url: 'https://www.gstatic.com/generate_204', disable-udp: false, timeout: 700, hidden: true, include-all: true }
Fallback: &Fallback { type: fallback, interval: 300, tolerance: 50, url: 'https://www.gstatic.com/generate_204', disable-udp: false, timeout: 700, hidden: true, include-all: true }

# 代理组
proxy-groups:
  - { name: 手动选择, <<: *SelectHK, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Rocket.png }
  - { name: 自动选择, <<: *SelectALL, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Auto.png }
  # - { name: GLOBAL, <<: *SelectDirect,include-all: true, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Global.png }
  - { name: Apple, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Apple.png }
  - { name: Telegram, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Telegram.png }
  - { name: YouTube, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/YouTube.png}
  - { name: BiliBili, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/bilibili_4.png }
  - { name: Github, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/GitHub.png }
  - { name: OpenAI, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/ChatGPT.png }
  - { name: Gemini, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/guaishouxiaoqi/icons@master/Color/Gemini.png }
  - { name: Claude, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/ke1ewang/Qi@master/Claude.png }
  - { name: TikTok, <<: *SelectTW, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/TikTok.png }
  - { name: Spotify, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Spotify.png }
  - { name: Netflix, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Netflix.png }
  - { name: Disney, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Disney.png }
  - { name: Google, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Google_Search.png }
  - { name: OneDrive, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/OneDrive.png }
  - { name: Microsoft, <<: *SelectDirect, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Microsoft.png }
  - { name: Twitter, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Twitter.png }
  - { name: Emby, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Emby.png }
  - { name: Steam, <<: *SelectProxy, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Steam.png }
  - { name: 漏网之鱼, <<: *SelectHK, icon: https://testingcf.jsdelivr.net/gh/aihdde/Rules@master/icon/fish.png }
  - { name: 直连, <<: *SelectDirect, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Direct.png }
  # 这里只匹配了一些常用地区的分组
  - { name: 香港, <<: *UrlTest, filter: 🇭🇰|香港|港|HK|hongkong|hong kong, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Hong_Kong.png }
  - { name: 澳门, <<: *UrlTest, filter: 🇲🇴|澳门|门|MO|macao, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Macao.png }
  - { name: 台湾, <<: *UrlTest, filter: 🇹🇼|台湾|台|TW|taiwan|taipei, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Taiwan.png }
  - { name: 日本, <<: *UrlTest, filter: 🇯🇵|日本|JP|japan|tokyo|osaka, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Japan.png }
  - { name: 韩国, <<: *UrlTest, filter: 🇰🇷|韩国|韩|KR|korea|seoul, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Korea.png }
  - { name: 美国, <<: *UrlTest, filter: 🇺🇸|美国|美|US|united states|america|los angeles|san jose|silicon valley, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/United_States.png }
  - { name: 英国, <<: *UrlTest, filter: 🇬🇧|英国|英|UK|united kingdom|london, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/United_Kingdom.png }
  - { name: 德国, <<: *UrlTest, filter: 🇩🇪|德国|德|DE|germany|frankfurt, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Germany.png }
  - { name: 法国, <<: *UrlTest, filter: 🇫🇷|法国|法|FR|france|paris, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/France.png }
  - { name: 印度, <<: *UrlTest, filter: 🇮🇳|印度|IN|india|mumbai, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/France.png }
  - { name: 新加坡, <<: *UrlTest, filter: 🇸🇬|新加坡|新|SG|singapore, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Singapore.png }
  - { name: 印尼, <<: *UrlTest, filter: 🇮🇩|印尼|印度尼西亚|ID|indonesia|jakarta, icon: https://testingcf.jsdelivr.net/gh/wanswu/my-backup@master/IconSet/Country/Indonesia.png }
  - { name: 越南, <<: *UrlTest, filter: 🇻🇳|越南|VN|vietnam, icon: https://testingcf.jsdelivr.net/gh/wanswu/my-backup@master/IconSet/Country/Vietnam.png }
  - { name: 泰国, <<: *UrlTest, filter: 🇹🇭|泰国|TH|thailand|bangkok, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Thailand.png }
  - { name: 澳洲, <<: *UrlTest, filter: 🇦🇺|澳大利亚|AU|australia|sydney, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Australia.png }
  - { name: 巴西, <<: *UrlTest, filter: 🇧🇷|巴西|brazil, icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Brazil.png }
  # 除了常用的地区,其他地区都放这里
  - { name: 其他, <<: *UrlTest, filter: '(?i)^(?!.*(香港|台湾|日本|韩国|新加坡|美国|英国|德国|法国|印度|泰国|越南|印尼|澳大利亚|巴西|港|台|日|韩|新|美|英|德|法|印|泰|越|尼|澳|巴|hk|tw|jp|kr|sg|us|uk|de|fr|in|th|vn|id|au|br)).*', icon: https://testingcf.jsdelivr.net/gh/Koolson/Qure@master/IconSet/Color/Global.png }

# 规则锚点,是为了减少重复配置
rule-anchor:
  DomainYaml: &DomainYaml { behavior: domain, interval: 86400, proxy: 手动选择, type: http }
  ClassicalYaml: &ClassicalYaml { behavior: classical, interval: 86400, proxy: 手动选择, type: http }

# 官方配置文档: https://wiki.metacubex.one/config/rule-providers/
rule-providers:
  # 这里是blackmatrix7大佬的一些规则常用的都在这里 有需要的佬友在这里添加就好了
  Apple: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Apple/Apple_Classical.yaml}
  Telegram: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Telegram/Telegram.yaml }
  YouTube: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/YouTube/YouTube.yaml }
  BiliBili: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/BiliBili/BiliBili.yaml }
  TikTok: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/TikTok/TikTok.yaml }
  Spotify: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Spotify/Spotify.yaml }
  Netflix: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Netflix/Netflix.yaml }
  Disney: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Disney/Disney.yaml }
  Google: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Google/Google.yaml }
  OpenAI: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/OpenAI/OpenAI.yaml }
  Microsoft: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Microsoft/Microsoft.yaml }
  Twitter: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Twitter/Twitter.yaml }
  Steam: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Steam/Steam.yaml }
  OneDrive: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/OneDrive/OneDrive.yaml }
  Emby: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Emby/Emby.yaml }
  Gemini: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Gemini/Gemini.yaml }
  Claude: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Claude/Claude.yaml }
  Github: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/GitHub/GitHub.yaml }
  LanNoResolve: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/Lan/Lan_No_Resolve.yaml }
  DNSNoResolve: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/DNS/DNS_No_Resolve.yaml }
  ChinaMaxNoResolve: { <<: *ClassicalYaml, url: https://testingcf.jsdelivr.net/gh/blackmatrix7/ios_rule_script@master/rule/Clash/ChinaMax/ChinaMax_Classical_No_Resolve.yaml }

# 官方配置文档: https://wiki.metacubex.one/config/rules/
rules:
  # 额外添加的规则,佬友也可以自己添加
  # DOMAIN-SUFFIX: 用来匹配域名; DIRECT: 这是直连,不走代理的配置
  # 介绍一下如何配置
  # 匹配规则,分组,规则 例如下面这个
  # [域名匹配],[linux.do],[直连]
  - DOMAIN-SUFFIX,linux.do,直连
  - DOMAIN-SUFFIX,portal101.cn,直连
  - DOMAIN-SUFFIX,javasec.org,直连
  # [进程匹配],[Parallels Desktop],[漏网之鱼]
  - PROCESS-NAME,prl_naptd,漏网之鱼
  - PROCESS-NAME,prl_disp_service,漏网之鱼
  - PROCESS-NAME,com.parallels.naptd,漏网之鱼
  # 分流规则,这里的分流规则是根据blackmatrix7大佬的配置
  # [规则匹配],[局域网],[直连],[不解析]  这里不使用GEOIP,private,是因为我测试下来感觉使用GEO会让clash内存变高所以就没使用了
  - RULE-SET,LanNoResolve,直连,no-resolve
  - RULE-SET,DNSNoResolve,直连,no-resolve
  - RULE-SET,ChinaMaxNoResolve,直连,no-resolve
  - RULE-SET,Telegram,Telegram
  - RULE-SET,YouTube,YouTube
  - RULE-SET,BiliBili,BiliBili
  - RULE-SET,TikTok,TikTok
  - RULE-SET,Spotify,Spotify
  - RULE-SET,Netflix,Netflix
  - RULE-SET,Disney,Disney
  - RULE-SET,Google,Google
  - RULE-SET,OpenAI,OpenAI
  - RULE-SET,Microsoft,Microsoft
  - RULE-SET,OneDrive,OneDrive
  - RULE-SET,Twitter,Twitter
  - RULE-SET,Gemini,Gemini
  - RULE-SET,Claude,Claude
  - RULE-SET,Github,Github
  - RULE-SET,Steam,Steam
  - RULE-SET,Emby,Emby
  # 没有匹配到规则的全部走[漏网之鱼]的这个规则
  - MATCH,漏网之鱼

Mihomo Party配置过程

1、导入覆写

两种方法

  1. 这里可以将我的配置文件直接下载下来,然后导入
  2. 直接将覆写链接填入文本框然后点击导入
    Github链接
    Jsdelivr链接方便无法访问Github的佬
    Jsdelivr连接

2、编辑覆写配置

Clash Verge配置过程

1、导入配置

点击订阅

编辑全局覆写配置
将其它的订阅地址写在这里,如果没有就不需要动

2、自定义订阅链接

Mihomo内核配置(Mac)

额外插播,这是我Mac中纯裸核配置,也是之前写的文章
MacBook使用clash内核(裸核)
直接将配置文件写入config.yaml,然后将你的订阅链接填入重载就完成了

168 个赞

感谢分享,我用clash verge 试试

5 个赞

感谢分享

2 个赞

大佬太强了

9 个赞

感谢大佬,我要是不需要订阅合并,只想对导入的机场订阅使用覆写功能,能直接使用吗?

2 个赞

直接将全部config.yaml导入就好了,订阅合并没事的,直接用覆写不影响

2 个赞

大佬,好像我前几天用过你的“ clash-script.js # 修改自dahaha-365大佬的脚本”,覆写不生效,但是用dahaha-365大佬原版的脚本就可以生效,用另一个clash.js也可以生效。

用这个试试呢

直接导入覆写订阅链接也不改是不是直接用了佬的订阅:tieba_025: ,原本的订阅没加入到p1p2p3…中是不是不生效了

1 个赞

这个试了也没问题,就是想知道为什么那个会不生效,代码看不太懂,也找不出问题 :joy_cat:

直接导入,无需改任何东西,我可没有把我的订阅链接写在链接里面 :joy:

可能有点小bug,没事,用这个就行了,那个不更新了,我也编辑不了了

:tieba_025: 那proxy-provider里的url是干嘛的,后续需要自己添加吗?

1 个赞

等佬自己添加或者修改的,如果你订阅足够多,那就需要添加了

太强了,大佬!

2 个赞

订阅合并好用的

1 个赞

原来全局扩展覆写配置和全局扩展脚本分别对应的就是mihomo-party的yaml覆写和js覆写

1 个赞

我之前以为js才是通用的,后来发现yaml也是通用的,所以才搞的这个配置,这个我一直在用,后来那个js就不更新了

1 个赞

感谢分享

只是覆写,原来的你订阅还在,订阅合并只是扩展功能不会影响你的订阅的,有没有都无所谓,除非你需要

1 个赞