lj - detect json from logfile and prettify it
% echo '2015-01-31 [21:06:22] json: {"key": "value", "array": [1,2,3]}' | lj [--no-color]' 2015-01-31 [21:06:22] json: { "array": [ 1, 2, 3 ], "key": "value" }
lj is command line utility for prettify the log containing JSON.
% cpanm App::LJ
or you can get single packed executable file.
% curl -L https://raw.githubusercontent.com/Songmu/App-LJ/master/lj > /usr/local/bin/lj; chmod +x /usr/local/bin/lj
Copyright (C) Songmu.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Songmu <y.songmu@gmail.com>
To install App::LJ, copy and paste the appropriate command in to your terminal.
cpanm
cpanm App::LJ
CPAN shell
perl -MCPAN -e shell install App::LJ
For more information on module installation, please visit the detailed CPAN module installation guide.