Files
CoolProp/dev/docker/patch_cloud_sptheme.py
Ian Bell 0a41d0d876 jinja2 is now no longer allowed to be < 3.0 by sphinx.
Patch cloud_sptheme, no longer being developed
2025-04-06 14:50:23 -04:00

10 lines
425 B
Python

from pathlib import Path
import cloud_sptheme
path = Path(cloud_sptheme.__file__).parent / 'ext' / 'index_styling.py'
assert path.exists()
contents = path.open('r').read().replace("from jinja2 import Markup as literal, escape","import jinja2.utils; literal = jinja2.utils.markupsafe.Markup; escape = jinja2.utils.markupsafe.escape")
with path.open('w') as fp:
fp.write(contents)
print('finished patching cloud_sptheme')