Example #1
0
def build(argv=None, completer=None):

    op = OptionParser(usage="Usage: amp build [options]", add_help_option=False)

    op.add_option('--role', dest='role', default='default',
                  help="specify a non-default role to build")

    options, args = parse_options(op, argv, completer)

    load_role(options.role)
    install_packages()
Example #2
0
def build(argv=None, completer=None):

    op = OptionParser(usage="Usage: amp build [options]", add_help_option=False)

    op.add_option('--role', dest='role', default='default',
                  help="specify a non-default role to build")

    options, args = parse_options(op, argv, completer)

    load_role(options.role)
    install_packages()

    _, retcode = run_command(
        [sys.executable, join(AMPIFY_ROOT, 'environ', 'assetgen')],
        retcode=True, redirect_stdout=False, redirect_stderr=False
        )

    if retcode:
        sys.exit(retcode)