commit:     18f63a7b434dea6ac2184fcdecb12cf0edf88c73
Author:     Mathieu Roberge <robergem2008 <AT> gmail <DOT> com>
AuthorDate: Wed Dec 24 22:06:33 2025 +0000
Commit:     Mathieu Roberge <contact.techoraye <AT> gmail <DOT> com>
CommitDate: Wed Dec 24 22:07:54 2025 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=18f63a7b

app-misc/gentoo-update: add version 0.2 with systemd support

Signed-off-by: Mathieu Roberge <robergem2008 <AT> gmail.com>

 app-misc/gentoo-update/gentoo-update-0.2.ebuild | 105 ++++++++++++++++++++++++
 1 file changed, 105 insertions(+)

diff --git a/app-misc/gentoo-update/gentoo-update-0.2.ebuild 
b/app-misc/gentoo-update/gentoo-update-0.2.ebuild
new file mode 100644
index 0000000000..574fff5191
--- /dev/null
+++ b/app-misc/gentoo-update/gentoo-update-0.2.ebuild
@@ -0,0 +1,105 @@
+# Copyright 1999-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v3
+
+EAPI=8
+
+inherit cmake
+
+DESCRIPTION="An update notifier & applier for Gentoo Linux that assists with 
pre/post update tasks"
+HOMEPAGE="https://github.com/Techoraye/gentoo-update";
+SRC_URI="https://github.com/Techoraye/gentoo-update/archive/v${PV}.tar.gz";
+
+S="${WORKDIR}/${PN}-${PV}"
+
+LICENSE="GPL-3"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~x86"
+IUSE="notification python systemd"
+
+DEPEND="
+       >=dev-cpp/cpp-base:0
+"
+
+RDEPEND="${DEPEND}
+       notification? ( x11-libs/libnotify )
+       python? ( 
+               dev-python/pyqt6[gui,network]
+       )
+       app-portage/gentoolkit
+       sys-apps/portage[python]
+       systemd? ( sys-apps/systemd )
+"
+
+src_configure() {
+       local mycmakeargs=(
+               -DCMAKE_INSTALL_LOCALSTATEDIR="${EPREFIX}/var"
+               -DENABLE_SYSTEMD=$(usex systemd)
+       )
+       cmake_src_configure
+}
+
+src_install() {
+       cmake_src_install
+       
+       # Install documentation
+       einstalldocs
+       
+       # Install configuration example
+       insinto /etc/gentoo-update
+       newins res/config/gentoo-update.conf.example gentoo-update.conf
+       
+       # Install shell completions
+       insinto /usr/share/bash-completion/completions
+       doins res/completions/gentoo-update.bash
+       
+       insinto /usr/share/zsh/site-functions
+       newins res/completions/gentoo-update.zsh _gentoo-update
+       
+       insinto /usr/share/fish/vendor_completions.d
+       doins res/completions/gentoo-update.fish
+       
+       # Install desktop entry files
+       insinto /usr/share/applications
+       doins res/desktop/gentoo-update.desktop
+       doins res/desktop/gentoo-update-tray.desktop
+       
+       # Install service files
+       if use systemd; then
+               insinto /etc/systemd/system
+               doins res/systemd/gentoo-update.service
+               doins res/systemd/gentoo-update.timer
+               doins res/systemd/gentoo-update-tray.service
+       else
+               insinto /etc/init.d
+               newins res/openrc/gentoo-update gentoo-update
+       fi
+}
+
+pkg_postinst() {
+       elog "Gentoo-Update has been installed successfully!"
+       elog ""
+       elog "Usage: gentoo-update [OPTIONS]"
+       elog ""
+       elog "For help: gentoo-update --help"
+       elog ""
+       elog "Configuration file: ~/.config/gentoo-update/gentoo-update.conf"
+       elog "Generate default config: gentoo-update --gen-config"
+       elog ""
+       
+       if use python; then
+               elog "Python support enabled. You can use the system tray 
applet:"
+               elog "  gentoo-update --tray"
+       fi
+       
+       if use notification; then
+               elog "Desktop notifications enabled."
+       fi
+       
+       if use systemd; then
+               elog "Systemd support enabled. Enable auto-updates with:"
+               elog "  systemctl enable --now gentoo-update.timer"
+       else
+               elog "For automatic updates with OpenRC, add gentoo-update to 
default runlevel:"
+               elog "  rc-update add gentoo-update default"
+       fi
+}

Reply via email to