diff options
author | cracyc <cracyc@users.noreply.github.com> | 2016-04-28 21:17:09 -0500 |
---|---|---|
committer | cracyc <cracyc@users.noreply.github.com> | 2016-04-28 21:17:09 -0500 |
commit | 6bbd290d315b20be75fa52465803d7e76466736f (patch) | |
tree | 99b42c8325fb024d5bf2cbe9d51eda8f9dc6cec1 /plugins | |
parent | 7e394b5dbe91b30c689782908a3aeb3619fed988 (diff) |
plugins/cheat*: indent the output (nw)
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/cheat/conv_cheat.lua | 2 | ||||
-rw-r--r-- | plugins/cheat/init.lua | 2 | ||||
-rw-r--r-- | plugins/cheatfind/init.lua | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/plugins/cheat/conv_cheat.lua b/plugins/cheat/conv_cheat.lua index afc87bc55b6..6f583a0178a 100644 --- a/plugins/cheat/conv_cheat.lua +++ b/plugins/cheat/conv_cheat.lua @@ -8,4 +8,4 @@ function readAll(file) return content end -print(json.stringify(xml.conv_cheat(readAll(arg[1])))) +print(json.stringify(xml.conv_cheat(readAll(arg[1])), {indent = true})) diff --git a/plugins/cheat/init.lua b/plugins/cheat/init.lua index 0e5abf447ab..4755d8106cd 100644 --- a/plugins/cheat/init.lua +++ b/plugins/cheat/init.lua @@ -477,7 +477,7 @@ function cheat.startplugin() cheats = load_cheats() local json = require("json") local file = io.open(manager:machine():options().entries.cheatpath:value() .. "/output.json", "w") - file:write(json.stringify(cheats)) + file:write(json.stringify(cheats, {indent = true})) file:close() for num, cheat in pairs(cheats) do parse_cheat(cheat) diff --git a/plugins/cheatfind/init.lua b/plugins/cheatfind/init.lua index a14b1504765..dd9e358dbe5 100644 --- a/plugins/cheatfind/init.lua +++ b/plugins/cheatfind/init.lua @@ -518,7 +518,7 @@ function cheatfind.startplugin() local filename = string.format("%s/%s_%08X_cheat", manager:machine():options().entries.cheatpath:value(), emu.romname(), match.addr) local json = require("json") local file = io.open(filename .. ".json", "w") - file:write(json.stringify({[1] = cheat})) + file:write(json.stringify({[1] = cheat}, {indent = true})) file:close() file = io.open(filename .. ".xml", "w") file:write(xmlcheat) |