Skip to content

quick_regexp(input_line, regex, **kwargs)

Simplified implementation for matching regular expressions. Utility for python's built_in module re . Previously named QuickRegexp

Tip

Design your patterns easily at Regex101

Parameters:

Name Type Description Default
input_line str

Source on wich the pattern will be searched.

required
regex str

Regex pattern to match on the source.

required
**kwargs optional
  • groupidx : (int) group index in case there is groups. Defaults to None (first group returned)
  • matchid : (int) match index in case there is multiple matchs. Defaults to None (first match returned)
  • case : (bool) False / True : case sensitive regexp matching (default False)
{}

Returns:

Type Description
Bool , str

False or string containing matched content.

Warning

This function returns only one group/match.

Back to top