Personal sing-box rule-set sources and generated artifacts.
src/*.list: source rules in Clash-styleTYPE,VALUE[,no-resolve]format.rule_json/*.json: generated sing-box source rule sets.rule_srs/*.srs: generated binary sing-box rule sets.scripts/convert_rules.py: strict converter and validator used by CI.
The converter supports only rule types that can be represented in a sing-box headless rule set:
DOMAINDOMAIN-SUFFIXDOMAIN-KEYWORDIP-CIDRIP-CIDR6IP-ASN
Unsupported types such as GEOIP and USER-AGENT are intentionally rejected instead of being silently dropped. Put those rules in the main sing-box configuration layer if needed.
The optional third field no-resolve is accepted for compatibility with Clash-style lists, but it is not emitted into the generated sing-box rule set.
Install sing-box, then run:
python scripts/convert_rules.pyTo validate and generate JSON only:
python scripts/convert_rules.py --skip-compileWeChat public-account article domains are pinned in src/my_direct.list so article pages and Tencent image/CDN assets stay direct:
mp.weixin.qq.comweixin.qq.comres.wx.qq.comqpic.cnqlogo.cngtimg.comqq.comwechat.comservicewechat.comtencent.com
Current Gist configs consume the custom rules as source JSON rule sets, for example rule_json/my_direct.json and rule_json/my_proxy.json. The generated .srs files are still available for configs that prefer binary rule sets.
Make sure the my_direct rule set is placed before broad proxy/final rules in the consuming sing-box config.