# Copyright 2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=8

PYTHON_COMPAT=( python3_{11..14} )
DISTUTILS_USE_PEP517=hatchling
EPYTEST_PLUGINS=( pytest-mock )
PYPI_NO_NORMALIZE=1

inherit distutils-r1

DESCRIPTION="Hyprland shader configuration tool"
HOMEPAGE="https://github.com/loqusion/hyprshade"

if [[ "${PV}" == "9999" ]]; then
	EGIT_REPO_URI="https://github.com/loqusion/${PN}.git"
	inherit git-r3
else
	SRC_URI="https://github.com/loqusion/${PN}/archive/refs/tags/${PV}.tar.gz -> ${P}.gh.tar.gz"
	KEYWORDS="~amd64"
fi

LICENSE="MIT"
SLOT="0/$(ver_cut 1-2)"

RDEPEND="
	${PYTHON_DEPS}
	dev-python/chevron
	dev-python/click
	dev-python/more-itertools
	gui-wm/hyprland
"

distutils_enable_tests pytest