blob: c438a5e0c2eab3b6320d87f9d7525a401bc1d16c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
# Copyright 2019-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{10..11} )
DISTUTILS_USE_PEP517=poetry
DISTUTILS_SINGLE_IMPL=1
inherit distutils-r1 desktop optfeature
MY_PN="Brightness"
DESCRIPTION="Qt Brightness Controller in Python"
HOMEPAGE="https://github.com/lordamit/Brightness"
SRC_URI="https://github.com/lordamit/${MY_PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${MY_PN}-${PV}/brightness-controller-linux"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64 ~x86"
RDEPEND="$(python_gen_cond_dep \
'dev-python/QtPy[${PYTHON_USEDEP},gui,network,pyqt5,widgets]'
)"
distutils_enable_tests pytest
python_prepare_all() {
distutils-r1_python_prepare_all
sed "/readme.md/d" -i pyproject.toml || die
}
python_install_all () {
distutils-r1_python_install_all
doicon -s scalable brightness_controller_linux/icons/brightness-controller.svg
make_desktop_entry brightness-controller "Brightness Controller" brightness-controller Settings
}
pkg_postinst() {
optfeature "direct control" app-misc/ddcutil
}
|