# Template file for 'python3-nbclassic'
pkgname=python3-nbclassic
version=1.1.0
revision=2
build_style=python3-pep517
make_build_args="--skip-dependency-check"
hostmakedepends="python3-jupyter_packaging python3-jupyter_server"
depends="mathjax2 python3-notebook_shim"
checkdepends="$depends python3-pytest-jupyter"
short_desc="Jupyter Notebook as a Jupyter Server Extension"
maintainer="dkwo <npiazza@disroot.org>, Gonzalo Tornaría <tornaria@cmat.edu.uy>"
license="BSD-3-Clause"
homepage="https://github.com/jupyter/nbclassic"
changelog="https://raw.githubusercontent.com/jupyter/nbclassic/main/CHANGELOG.md"
distfiles="${PYPI_SITE}/n/nbclassic/nbclassic-${version}.tar.gz"
checksum=77b77ba85f9e988f9bad85df345b514e9e64c7f0e822992ab1df4a78ac64fc1e

post_install() {
	vlicense LICENSE
	mv ${DESTDIR}/usr/etc ${DESTDIR}

	# use system mathjax2
	local _mathjax="${DESTDIR}/${py3_sitelib}/nbclassic/static/components/MathJax"
	rm -r "${_mathjax}"
	ln -s /usr/share/mathjax "${_mathjax}"
}
