MCPcopy Create free account
hub / github.com/webpy/webpy / find_indent

Method find_indent

web/template.py:468–472  ·  view source on GitHub ↗
(text)

Source from the content-addressed store, hash-verified

466 else:
467
468 def find_indent(text):
469 rx = re_compile(" +")
470 match = rx.match(text)
471 first_indent = match and match.group(0)
472 return first_indent or ""
473
474 # find the indentation of the block by looking at the first line
475 first_indent = find_indent(text)[len(begin_indent) :]

Callers

nothing calls this directly

Calls 1

matchMethod · 0.80

Tested by

no test coverage detected