splitAndStripLines¶
- emlib.textlib.splitAndStripLines(text, regexp=None)[source]¶
Splits text into lines and removes empty lines at the beginning and end
Returns the split lines in between
- Parameters:
text (
str
) – the text to splitregexp (
Optional
[str
]) – if given, use this regexp to split the lines. Otherwise usesstr.splitlines
- Return type:
list
[str
]- Returns:
the list of lines