Many thanks, Antoine! The number of JSON files has increased considerable
in the past week[1].
[1]
https://gerrit.wikimedia.org/r/#/q/status:merged+topic:json-i18n,n,z
Cheers!
On Mon, Mar 31, 2014 at 2:24 PM, Antoine Musso <hashar+wmf(a)free.fr> wrote:
Le 10/03/2014 17:26, Antoine Musso a écrit :
Hello,
I wrote a PHP based JSON linter which would bail out whenever a json
file can't be understood by PHP json_decode().
The linter will be able to the jslint Jenkins jobs which are already
running jshint. It would be nice to pass it on your repositories to
avoid failure when the job is enable which I plan to do next Monday on
March 17th.
The lint script is in integration/jenkins.git bin/json-lint.php which
you can fetch with:
curl
'
http://git.wikimedia.org/raw/integration%2Fjenkins.git/master/bin%2Fjson-li…
'> /tmp/json-lint.php
Usage:
json-lint.php .
Example output:
./node_modules/es6-shim/bower.json: Syntax error
./node_modules/es6-shim/component.json: Syntax error
They are missing comma in dictionaries structures of the git repository
mediawiki/services/parsoid/deploy
I have passed the scripts against mediawiki/extensions/* and mw/core but
other repository would need to be verified if they have a jslint job
running.
Forgot to deploy the json linter last week. This is now deployed on all
275 jslint jobs currently configured.
If there is any error report, do fix the json files!
--
Antoine "hashar" Musso
_______________________________________________
Wikitech-l mailing list
Wikitech-l(a)lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikitech-l
--
Siebrand Mazeland
Kitano ICT
M: +31 6 50 69 1239
Skype: siebrand