def require_invoke_minversion(min_version, verbose=False):
 try:
  import invoke
  invoke_version = invoke.__version__
 except ImportError:
  invoke_version = '__NOT_INSTALLED'
 if (invoke_version < min_version):
  message = ('REQUIRE: invoke.version >= %s (but was: %s)' % (min_version, invoke_version))
  message += ('\nUSE: pip install invoke>=%s' % min_version)
  raise VersionRequirementError(message)
 INVOKE_VERSION = os.environ.get('INVOKE_VERSION', None)
 if (verbose and (not INVOKE_VERSION)):
  os.environ['INVOKE_VERSION'] = invoke_version
  print(('USING: invoke.version=%s' % invoke_version))

def require_invoke_minversion ( min_version , verbose = False ) : try : import invoke invoke_version = invoke . __version__ except ImportError : invoke_version = '__NOT_INSTALLED' if ( invoke_version < min_version ) : message = ( 'REQUIRE: invoke.version >= %s (but was: %s)' % ( min_version , invoke_version ) ) message += ( '\nUSE: pip install invoke>=%s' % min_version ) raise VersionRequirementError ( message ) INVOKE_VERSION = os . environ . get ( 'INVOKE_VERSION' , None ) if ( verbose and ( not INVOKE_VERSION ) ) : os . environ [ 'INVOKE_VERSION' ] = invoke_version print ( ( 'USING: invoke.version=%s' % invoke_version ) )
ensures that :mod:invoke has at the least the .