Skip to content

singbox配置文件为jsonc【带注释的json】时无法自动修改入站配置 #17

@M-ls

Description

@M-ls

需求:
目前使用的部分singbox订阅信息包含注释,在存在注释时无法自动修改入站配置部分内容及无法对JSON文件格式化,但在入站配置正确时jsonc文件可以正常使用,请问作者会不会考虑对jsonc配置的支持

复现:
下载一个带//注释的配置文件或对一个现有的配置文件添加注释

网络模式: tun / tproxy / redirect / mixed / enhance

network_mode="tun"
修改为enhance
此时log中不会出现:
15:03 [Debug]: 已为 /data/adb/box/sing-box/config.json 添加 [Tproxy] 配置
15:03 [Debug]: 已为 /data/adb/box/sing-box/config.json 添加 [Redirect] 配置
并且整个JSON文件不会被格式化,入站配置不会修改

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions