Install one or more resources.

def install(opts):
    """
    Install one or more resources.
    """
    resources = _load(opts.resources, opts.output_dir)
    if opts.all:
        opts.resource_names = ALL
    success = _install(resources, opts.resource_names, opts.mirror_url,
                       opts.destination, opts.skip_top_level)
    if success:
        if not opts.quiet:
            print("All resources successfully installed")
        return 0
    else:
        if not opts.quiet:
            invalid = _invalid(resources, opts.resource_names)
            print("Unable to install some resources: {}".format(', '.join(invalid)))
        return 1