# Maintainer: Felix Yan <felixonmars@archlinux.org>
# Contributor: Jim Bridgewater <jwbwater at gmail dot com>
# Contributor: delta48 <dark.magician.48[at]gmail[dot]com>
# Adapted to Slint by Didier Spaier diideratslintdotfr

pkgname=python-pyperclip
export commit=e16fa9c33
pkgver=git$commit
pkgrel=1slint
slackdesc="$pkgname (A cross-platform clipboard module for Python)"
url="https://github.com/asweigart/pyperclip"
license=('BSD-3-Clause')
makedepends=('python-build' 'python-installer' 'python-setuptools' 'python-wheel')
# GTK/Qt tests crash xvfb, and Klipper tests require a running klipper
#checkdepends=('xorg-server-xvfb' 'python-pytest' 'xsel' 'xclip')
depends=('python')
optdepends=('xclip: xclip backend'
            'xsel: xsel backend'
            'wl-clipboard: wl-clipboard backend'
            'plasma-workspace: klipper backend')
sha512sums=('ab5e024f54f70bc715406b27827c2a1dff141cd6b7bedb400e53377d0058632056c4f2bc69ef2e2c54ad89405af6d1caef3267a089433cad0a8a843a904c861f')
docs=("LICENSE.txt" "README.html")
build() {
  git clone https://github.com/asweigart/pyperclip.git
  cd pyperclip
  git checkout $commit
  pandoc -f gfm -t html5 -o README.html README.md
  python3 -m build --wheel --skip-dependency-check --no-isolation
  python3 -m installer --destdir="$PKG" dist/*.whl
}

# vim:set ts=2 sw=2 et:
