From 74624f2dbbb77228d1f3777bb3dc4a6e002de53c Mon Sep 17 00:00:00 2001
From: Richard PALO <richard.palo@free.fr>
Date: Tue, 25 Feb 2025 08:58:25 +0100
Subject: [PATCH] try changing to hatchling builds

---
 .SRCINFO | 6 +++---
 PKGBUILD | 5 +++--
 2 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/.SRCINFO b/.SRCINFO
index cca7570..a31c395 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,15 +1,15 @@
 pkgbase = python-schwifty
 	pkgdesc = Validate/generate IBANS and BICS
 	pkgver = 2024.11.0
-	pkgrel = 2
+	pkgrel = 3
 	url = http://github.com/mdomke/schwifty
 	arch = any
 	license = MIT
 	makedepends = python-build
 	makedepends = python-installer
-	makedepends = python-setuptools
-	makedepends = python-setuptools-scm
 	makedepends = python-wheel
+	makedepends = python-hatchling
+	makedepends = python-hatch-vcs
 	depends = python>=3.9
 	depends = python-iso3166
 	depends = python-pycountry
diff --git a/PKGBUILD b/PKGBUILD
index 64be3a1..74d426f 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,12 +2,12 @@
 pkgname=python-schwifty
 _name=${pkgname#python-}
 pkgver=2024.11.0
-pkgrel=2
+pkgrel=3
 pkgdesc="Validate/generate IBANS and BICS"
 arch=('any')
 url="http://github.com/mdomke/schwifty"
 license=('MIT')
-makedepends=('python-build' 'python-installer' 'python-setuptools' 'python-setuptools-scm' 'python-wheel')
+makedepends=('python-build' 'python-installer' 'python-wheel' 'python-hatchling' 'python-hatch-vcs')
 optdepends=('python-pydantic>=2.0: data validation')
 depends=('python>=3.9' 'python-iso3166' 'python-pycountry' 'python-rstr')
 source=(https://files.pythonhosted.org/packages/source/${_name::1}/${_name}/${_name}-${pkgver}.tar.gz)
@@ -21,4 +21,5 @@ build() {
 package() {
   cd "$srcdir/$_name-$pkgver"
   python -m installer --destdir="$pkgdir" dist/*.whl
+  install -Dm644 "${srcdir}/${_name}-${pkgver}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
 }