lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Announcing release of json2lua v0.3.3.

This is a command-line tool to convert JSON data to Lua.

Usage:

`json2lua [options] < data.json > data.lua`

Options:

    -h    Print help
    -v    Print script version
    -n    Do not pretty-print Lua code (default: do pretty-print)
    -wN   Set maximum pretty-print width to N chars (default: 80)
    -iStr Set pretty-print indent to string (default: two spaces, '  ')
    -N    Force object keys to be transformed to numbers
          whenever possible (default: off)
    -e    Do not print terminating EOL (default: do print)
    -r    Prefix data with 'return' (default: off)

This is a bugfix release, fixing compatibility with luajson v1.3+ See
the list of changes here:

https://github.com/agladysh/json2lua/blob/v0.3.3/HISTORY

Rockspec for the new version:

https://github.com/agladysh/json2lua/raw/master/rockspec/json2lua-0.3.3-1.rockspec

Alexander.