migrate to hatch

This commit is contained in:
2026-07-11 12:24:53 +03:00
parent aef7fa5f93
commit 92ac036f78
4 changed files with 29 additions and 18 deletions
+1 -1
View File
@@ -12,7 +12,7 @@ pacman -Syyu --noconfirm
# main dependencies
pacman -S --noconfirm devtools git npm pyalpm python-bcrypt python-filelock python-inflection python-pyelftools python-requests python-systemd sudo
# make dependencies
pacman -S --noconfirm --asdeps base-devel python-build python-flit python-installer python-tox python-wheel
pacman -S --noconfirm --asdeps base-devel python-build python-hatchling python-installer python-tox python-wheel
# optional dependencies
if [[ -z $MINIMAL_INSTALL ]]; then
# web server
+1 -1
View File
@@ -35,7 +35,7 @@ RUN pacman -S --noconfirm --asdeps \
RUN pacman -S --noconfirm --asdeps \
base-devel \
python-build \
python-flit \
python-hatchling \
python-installer \
python-setuptools \
python-tox \
+1 -1
View File
@@ -9,7 +9,7 @@ arch=('any')
url="https://ahriman.readthedocs.io/"
license=('GPL-3.0-or-later')
depends=('devtools>=1:1.0.0' 'git' 'pyalpm' 'python-bcrypt' 'python-filelock' 'python-inflection' 'python-pyelftools' 'python-requests')
makedepends=('npm' 'python-build' 'python-flit' 'python-installer' 'python-wheel')
makedepends=('npm' 'python-build' 'python-hatchling' 'python-installer' 'python-wheel')
source=("https://github.com/arcan1s/ahriman/releases/download/$pkgver/$pkgbase-$pkgver.tar.gz"
"$pkgbase.sysusers"
"$pkgbase.tmpfiles")
+26 -15
View File
@@ -1,6 +1,6 @@
[build-system]
requires = ["flit_core"]
build-backend = "flit_core.buildapi"
requires = ["hatchling"]
build-backend = "hatchling.build"
[project]
name = "ahriman"
@@ -112,21 +112,32 @@ tests = [
"pytest-spec",
]
[tool.flit.sdist]
[tool.hatch.version]
path = "src/ahriman/__init__.py"
[tool.hatch.build.targets.sdist]
include = [
"AUTHORS",
"CONTRIBUTING.md",
"SECURITY.md",
"package",
"frontend",
"subpackages.py",
"web.png",
"/AUTHORS",
"/CONTRIBUTING.md",
"/COPYING",
"/README.md",
"/SECURITY.md",
"/frontend",
"/package",
"/pyproject.toml",
"/src",
"/subpackages.py",
"/web.png",
]
exclude = [
"package/archlinux",
"frontend/node_modules",
"frontend/package-lock.json",
"/package/archlinux",
"/frontend/node_modules",
"/frontend/package-lock.json",
]
[tool.flit.external-data]
directory = "package"
[tool.hatch.build.targets.wheel]
packages = ["src/ahriman"]
[tool.hatch.build.targets.wheel.shared-data]
"package/lib" = "lib"
"package/share" = "share"