focus-creative-games / luban

luban是一个强大、易用、优雅、稳定的游戏配置解决方案。luban is a powerful, easy-to-use, elegant and stable game configuration solution.
https://code-philosophy.com/
MIT License
3.32k stars 526 forks source link

输出的json文件,可以不要格式化吗? #123

Closed AnYuanLzh closed 6 months ago

AnYuanLzh commented 6 months ago

输出的json文件,可以不要格式化吗?格式化的json文件大了很多,可以的话要如何设置

pirunxi commented 6 months ago

有一个pretty print参数,我们明天看一下

pirunxi commented 6 months ago

-x json.compact=1 就不格式化了,紧凑输出

AnYuanLzh commented 6 months ago

image 像不起作用,结果都一样

AnYuanLzh commented 6 months ago

再看了一下源码,发现写成: -x tableExporter.json.compact=1 或直接简写成: -x compact=1 就可以紧凑输出了

pirunxi commented 6 months ago

确实如此。不过这个参数名不是很妥当,我们在v2.3.1版本调整了此参数,改成了 -x json.compact=1 或 -x compact=1