This is a simple wrapper script to validate data packages in the command line. It uses the excellent datapackage-validate-py library to do all the work.
make install. A virtualenv with all necessary dependencies will be created in the project directory.
Be sure to load the virtualenv before running the script. This is done after installation, but if you are opening a new shell or terminal, you need to activate the virtualenv prior to running
After this, to run the script just indicate the location of the data package -- either a
datapackage.json file or a directory containing one:
validate-dpkg ~/datasets/cpi # or pointing to the file itself validate-dpkg ~/datasets/cpi/datapackage.json
If the JSON file is fine, there will be no output. Otherwise, a list with the errors will be printed to standard output.