# Ensure matplotlib has font from cursive font family
# https://stackoverflow.com/q/65649122/8931942
if [ ! -d "${HOME}/.local/share/fonts/truetype/felipa" ]; then
    mkdir -p "${HOME}/.local/share/fonts/truetype/felipa"
    wget --no-clobber https://github.com/google/fonts/blob/master/ofl/felipa/Felipa-Regular.ttf?raw=true -O "${HOME}/.local/share/fonts/truetype/felipa/Felipa-Regular.ttf"
    fc-cache --force --verbose # force system font cache rebuild
fi

# Install library
python -m pip install --upgrade .

# Create example JSON
python tests/example_files.py
mv example.root examples/example.root
jupyter nbconvert --inplace --to notebook --execute examples/dev-example.ipynb
