MCPcopy
hub / github.com/google/python-fire / _IsSingleCharFlag

Function _IsSingleCharFlag

fire/core.py:949–951  ·  view source on GitHub ↗

Determines if the argument is a single char flag (e.g. '-a').

(argument)

Source from the content-addressed store, hash-verified

947
948
949def _IsSingleCharFlag(argument):
950 """Determines if the argument is a single char flag (e.g. '-a')."""
951 return re.match('^-[a-zA-Z]$', argument) or re.match('^-[a-zA-Z]=', argument)
952
953
954def _IsMultiCharFlag(argument):

Callers 1

_IsFlagFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected