Exemplo n.º 1
0
ROOTDIR = normpath(
    abspath(realpath(join(dirname(__file__), '..', 'skeletons'))))
APP_SKELETON = join(ROOTDIR, 'project')
RESOURCE_SKELETON = join(ROOTDIR, 'resource')

ENV_OPTIONS = {
    'autoescape': False,
    'block_start_string': '[%',
    'block_end_string': '%]',
    'variable_start_string': '[[',
    'variable_end_string': ']]',
}

FILTER = ('.pyc', '.DS_Store', '.pyo')

manager = Manager()


@manager.command
def new(app_path='.', skeleton=APP_SKELETON, **options):
    """APP_PATH='.' [SKELETON_PATH]

    The 'shake new' command creates a new Shake application with a default
    directory structure at the path you specify.

    Example:
        shake new projects/wiki

    By default it uses Shake's built-in skeleton, but you can provide a custom
    one if you want.
    """
Exemplo n.º 2
0
from pyceo import Manager, param, option


cli = Manager("Welcome to Proper v1.2.3")


@cli.command(help="Creates a new Proper application at `path`.")
@param("path", help="Where to create the new application.")
@option("quiet", help="Supress all output.")
def new(path):
    """The `proper new` command creates a new Proper application with a default
    directory structure and configuration at the path you specify.

    Example: `proper new ~/Code/blog`
    This generates a skeletal Proper application at `~/Code/blog`.
    """
    pass


@cli.command()
def fizzbuzz():
    """The infamous fizz buzz."""
    pass


@cli.command(group="db")
@option("message", help="Revision message")
@option("sql", help="Dont emit SQL to database - dump to standard output instead")
@option("head", help="Specify head or <branchname>@head to base new revision on")
@option("splice", help="Allow a non-head revision as the 'head' to splice onto")
@option("branch-label", help="Specify a branch label to apply to the new revision")