import click
from sqltocpp import convert


@click.command()
@click.option('--sql', help='schema file name')
@click.option('--target', default='schema.hpp', help='hpp file name')
def execute(sql, target):
    convert.schema_to_struct(sql, target)



if __name__ == '__main__':
    try:
        execute()
    except:
        execute("--help")

import click
from sqltocpp import convert


@click.command()
@click.argument('sql_schema_file')
@click.option('--target', default='schema.hpp', help='hpp file name')
def execute(sql_schema_file, target):
    convert.schema_to_struct(sql_schema_file, target)



if __name__ == '__main__':
    execute()

Add click based commandline interface script
Add click based commandline interface script

sqltocpp is intended to be a CLI command.
This enables it to be so
