How to use the flupy.__version__ function in flupy

To help you get started, we’ve selected a few flupy 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 olirice / flupy / flupy / cli / cli.py View on Github external
def parse_args(args: List[str]):
    """Parse input arguments"""
    parser = argparse.ArgumentParser(
            description="flupy: a fluent interface for python",
            formatter_class=argparse.RawTextHelpFormatter)
    parser.add_argument('-v', '--version', action='version', version='%(prog)s ' + __version__)
    parser.add_argument("command", help="command to execute against input")
    parser.add_argument("-f", "--file", help="path to input file")
    parser.add_argument(
            "-i",
            "--import",
            nargs="*",
            default=[],
            help="modules to import\n" \
                 "Syntax: ::\n" \
                 "Examples:\n" \
                 "\t'import os' = '-i os'\n" \
                 "\t'import os as op_sys' = '-i os::op_sys'\n" \
                 "\t'from os import environ' = '-i os:environ'\n" \
                 "\t'from os import environ as env' = '-i os:environ:env'\n"
                 )
    return parser.parse_args(args)

flupy

Method chaining built on generators

MIT
Latest version published 4 months ago

Package Health Score

71 / 100
Full package analysis