tasks/go.py
def cyclo(ctx, targets, limit=15):
    """
    Run gocyclo on targets.
    Use the 'limit' parameter to change the maximum cyclic complexity.

    Example invokation:
        inv cyclo --targets=./pkg/collector/check,./pkg/aggregator
    """
    if isinstance(targets, str):
        # when this function is called from the command line, targets are passed
        # as comma separated tokens in a string
        targets = targets.split(',')

    ctx.run(f"gocyclo -over {limit} " + " ".join(targets))
    # gocyclo exits with status 1 when it finds an issue, if we're here
    # everything went smooth
    print("gocyclo found no issues")

    Run gocyclo on targets.
    Use the 'limit' parameter to change the maximum cyclic complexity.

    Example invokation:
        inv cyclo --targets=./pkg/collector/check,./pkg/aggregator
    
Run gocyclo on targets.
Use the 'limit' parameter to change the maximum cyclic complexity.


Run gocyclo on targets . Use the ' limit ' parameter to change the maximum cyclic complexity .
def cyclo(ctx, targets, limit=15):
    if isinstance(targets, str):
        targets = targets.split(',')
    ctx.run(f"gocyclo -over {limit} " + " ".join(targets))
    print("gocyclo found no issues")
def cyclo ( ctx , targets , limit = 15 ) : if isinstance ( targets , str ) : targets = targets . split ( ',' ) ctx . run ( f"gocyclo -over {limit} " + " " . join ( targets ) ) print ( "gocyclo found no issues" )
Run gocyclo on targets.
Run gocyclo on targets .
"""
    Run gocyclo on targets.
    Use the 'limit' parameter to change the maximum cyclic complexity.

    Example invokation:
        inv cyclo --targets=./pkg/collector/check,./pkg/aggregator
    """ # when this function is called from the command line, targets are passed # as comma separated tokens in a string # gocyclo exits with status 1 when it finds an issue, if we're here # everything went smooth
ctx
targets
limit