基于json-schema.org的验证和格式化

dev-master 2015-09-20 11:28 UTC

This package is auto-updated.

Last update: 2024-08-28 06:39:32 UTC


README

Build Status SensioLabs Insight Coverage Status Scrutinizer Code Quality Total Downloads

A command line tool that helps you validating and formatting JSON configuration files. File formatting is based on a JSON schema file.

支持的快捷键(验证和格式化)

安装

通过将emanueleminotto/schemer添加到全局composer.json或从CLI安装schemer CLI工具

$ composer global require emanueleminotto/schemer

注意!请记住将$COMPOSER_HOME/vendor/bin添加到$PATH中(参考)。

使用方法

# validation ...
$ schemer validate https://raw.githubusercontent.com/composer/composer/master/res/composer-schema.json composer.json
# ... with use shortcuts
$ schemer validate:bower bower.json

# formatting ...
$ schemer format https://raw.githubusercontent.com/composer/composer/master/res/composer-schema.json composer.json
# ... with use shortcuts
$ schemer format:bower bower.json

# schemer available commands
$ schemer list

测试

$ vendor/bin/phpunit

许可证

The MIT License (MIT). Please see License File for more information.