net-im/tencent-qq: bump version to 3.2.15_p241224
[gentoo-zh.git] / sys-power / tlpui / tlpui-1.7.1.ebuild
blob78ed017da18833154d11ac53fea1fc0dd3550a35
1 # Copyright 1999-2023 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
4 EAPI=8
6 DISTUTILS_USE_PEP517=poetry
7 PYTHON_COMPAT=( python3_{9..12} )
8 DISTUTILS_SINGLE_IMPL=y
9 inherit distutils-r1 desktop xdg-utils
11 if [[ $(ver_cut 4) == "p" ]] ; then
12 MY_PV="$(ver_cut 1-3)-$(ver_cut 5)"
13 else
14 MY_PV="${PV}"
17 MY_P="${PN}-${MY_PV}"
19 DESCRIPTION="A GTK user interface for TLP written in Python"
20 HOMEPAGE="https://github.com/d4nj1/TLPUI"
21 KEYWORDS="~amd64"
22 SRC_URI="https://github.com/d4nj1/TLPUI/archive/refs/tags/${MY_P}.tar.gz"
24 LICENSE="GPL-2+"
25 SLOT="0"
26 RESTRICT="test"
28 RDEPEND="
29 sys-apps/usbutils
30 sys-power/tlp
31 $(python_gen_cond_dep 'dev-python/pycairo[${PYTHON_USEDEP}] dev-python/pygobject[${PYTHON_USEDEP}]')
32 x11-libs/gtksourceview:3.0
35 S="${WORKDIR}/TLPUI-${MY_P}"
37 python_install_all() {
38 distutils-r1_python_install_all
39 doicon -s scalable "${S}/tlpui/icons/themeable/hicolor/scalable/apps/tlpui.svg"
40 insinto /usr/share/metainfo
41 doins "${S}/AppImage/com.github.d4nj1.tlpui.appdata.xml"
42 domenu "${S}/tlpui.desktop"
45 pkg_postinst() {
46 xdg_icon_cache_update
49 pkg_postrm() {
50 xdg_icon_cache_update