Skip to content

Instantly share code, notes, and snippets.

View laurentbristiel's full-sized avatar

Laurent Bristiel laurentbristiel

View GitHub Profile
import os
import re
SPLITTER = re.compile(r'\n(?=[^\s])', re.MULTILINE)
def files(path):
for root, dirs, files in os.walk(path):
for f in files:
if f.endswith('.txt') or f.endswith('.robot') or f.endswith('.tsv'):
yield os.path.join(root, f)