rewrite client demo by lua, remove old C version client demo

This commit is contained in:
Cloud Wu
2014-04-14 17:00:42 +08:00
parent 1e9a27232b
commit 904b68b5a5
45 changed files with 11717 additions and 12 deletions

14
3rd/lua-cjson/lua/json2lua.lua Executable file
View File

@@ -0,0 +1,14 @@
#!/usr/bin/env lua
-- usage: json2lua.lua [json_file]
--
-- Eg:
-- echo '[ "testing" ]' | ./json2lua.lua
-- ./json2lua.lua test.json
local json = require "cjson"
local util = require "cjson.util"
local json_text = util.file_load(arg[1])
local t = json.decode(json_text)
print(util.serialise_value(t))