Date: Sunday, April 9, 2023 @ 18:59:45
  Author: felixonmars
Revision: 1443464

archrelease: copy trunk to community-staging-any

Added:
  python-qdarkstyle/repos/community-staging-any/
  python-qdarkstyle/repos/community-staging-any/PKGBUILD
    (from rev 1443463, python-qdarkstyle/trunk/PKGBUILD)

----------+
 PKGBUILD |   37 +++++++++++++++++++++++++++++++++++++
 1 file changed, 37 insertions(+)

Copied: python-qdarkstyle/repos/community-staging-any/PKGBUILD (from rev 
1443463, python-qdarkstyle/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD                              (rev 0)
+++ community-staging-any/PKGBUILD      2023-04-09 18:59:45 UTC (rev 1443464)
@@ -0,0 +1,37 @@
+# Maintainer: Bruno Pagani <[email protected]>
+
+_pkg=QDarkStyle
+pkgname=python-${_pkg,,}
+pkgver=3.1
+pkgrel=2
+pkgdesc="Dark style sheet for QtWidgets application"
+arch=(any)
+url="https://github.com/ColinDuquesnoy/QDarkStyleSheet";
+license=(MIT CCPL)
+depends=(python-helpdev python-qtpy)
+makedepends=(python-setuptools)
+checkdepends=(python-pyqt5 pyside2 python-pytest python-pytest-qt)
+# Pypi tarballs do not provide tests files anymore
+#source=(https://files.pythonhosted.org/packages/source/${_pkg::1}/${_pkg}/${_pkg}-${pkgver}.tar.gz)
+source=(${url}/archive/v${pkgver}/${pkgname}-${pkgver}.tar.gz)
+sha256sums=('ce22fb44a8115bad4b0ae409688568cccbee99fe3d284407719c899c360bcf2e')
+
+build() {
+  cd ${_pkg}Sheet-${pkgver}
+  python setup.py build
+}
+
+check() {
+  cd ${_pkg}Sheet-${pkgver}
+  # PyQt5 tests
+  python -m qdarkstyle.example --qt_from=pyqt5 --test --offscreen
+  # PySide2 tests, https://github.com/ColinDuquesnoy/QDarkStyleSheet/issues/275
+  sed -i 
's|dw_buttons.checkBoxTristate.setCheckState(1)|dw_buttons.checkBoxTristate.setCheckState(QtCore.Qt.Unchecked)|'
 qdarkstyle/example/__main__.py
+  python -m qdarkstyle.example --qt_from=pyside2 --test --offscreen
+}
+
+package() {
+  cd ${_pkg}Sheet-${pkgver}
+  python setup.py install --prefix=/usr --root="${pkgdir}" --skip-build 
--optimize=1
+  install -Dm644 LICENSE.rst -t "${pkgdir}"/usr/share/licenses/${pkgname}
+}

Reply via email to