# Maintainer: Antonio Rojas <arojas@archlinux.org>

#Included in Slint by Didier Spaier didieratslintdotfr
pkgname=yt-dlp-ejs
pkgver=0.3.2
pkgrel=1slint
export commit=06d7145
export srcname=ejs
slackdesc="$pkgname (External JavaScript for yt-dlp supporting many runtimes)"
url='https://github.com/yt-dlp/ejs'
license=(Unlicense)
depends=(deno
         python)
makedepends=(git
             python-build
             python-hatch-vcs
             python-hatchling
             python-installer)
checkdepends=(python-pytest)
#source=(https://github.com/yt-dlp/ejs/archive/refs/tags/${pkgver}.tar.gz)
sha256sums=('742c88b0af94ef76a8690cba6d344d4e09c55a36cdd2e8312f445eaf30dfc785')
docs=("LICENSE" "README.md")
build() {
  git clone https://github.com/yt-dlp/ejs.git	
  cd $srcname
  git checkout $commit
  sed -i '/3\.14/d' pyproject.toml
  sed -i '/3\.13/d' pyproject.toml
  python3.11 -m build --wheel --no-isolation
  python3.11 -m installer --destdir="$PKG" dist/*.whl
}
