p≡p for Python
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

9 lines
266 B

from . import constants
import pathlib
def data_file_contents(name) -> str:
"""grab the contents of a file in the data folder"""
path = pathlib.Path(__file__).parent / constants.DATADIR / name
with path.open(mode='r') as fid:
return fid.read()