#!/usr/bin/env python
from clitools import _main
import json

def check(filepath):
    '''Verify a json file at `filepath`

    :param filepath: the json file to verify
    '''
    out = json.load(open(filepath))
    print 'json file OK'

def prettify(filepath):
    '''Load json file at `filepath` and reformat prettily'''
    out = json.load(open(filepath))
    print json.dumps(out, indent=2)


if __name__ == '__main__':
    _main(locals())


