How to use the fbs.cmdline.main function in fbs

To help you get started, we’ve selected a few fbs examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github dnkorpushov / libro / build.py View on Github external
call('pyrcc5 {} -o {}'.format(rc_file, py_file), shell=True)


@command
def locale():
    for pro_file in glob('*.pro'):
        call('pylupdate5 -translate-function _tr {}'.format(pro_file), shell=True)

    for ts_file in glob(os.path.join(LOCALE_SRCPATH, '*.ts')):
        dst_file = os.path.join(LOCALE_DSTPATH, os.path.splitext(os.path.split(ts_file)[1])[0] + '.qm')
        call('lrelease {} -qm {}'.format(ts_file, dst_file), shell=True)


if __name__ == '__main__':
    project_dir = os.path.dirname(__file__)
    fbs.cmdline.main(project_dir)
github mherrmann / fbs / fbs / __main__.py View on Github external
def _main():
    """
    Main entry point for the `fbs` command line script.

    We init logging here instead of in fbs.cmdline.main(...) because the latter
    can be called by projects using fbs, and it's bad practice for libraries to
    configure logging. See eg. https://stackoverflow.com/a/26087972/1839209.
    """
    _init_logging()
    fbs.cmdline.main()