Source code for quixote.build.output
from contextlib import contextmanager
_output = list()
def _reset_output():
_output.clear()
[docs]@contextmanager
def new_output() -> list:
"""
Create a new output for the duration of a with-block
"""
try:
yield get_output()
finally:
_reset_output()