app-backup/snapper-rollback: new package, add 1.0.0

Signed-off-by: Keita Urashima <ursm@ursm.jp>
This commit is contained in:
Keita Urashima
2026-07-20 16:36:23 +09:00
parent daf3f8bab9
commit 9d7d9a0760
3 changed files with 55 additions and 0 deletions

View File

@@ -0,0 +1 @@
DIST snapper-rollback-1.0.0.tar.gz 16926 BLAKE2B 51a8dae60ecf4c2badd9abfae810545f2b37b9d2d7f0f1f05330dce3687270c373ad3cc5507f56d22eb1cf32f3d582508a65993411e9081ef1e141b48e09e112 SHA512 8aa1052b1b552a0987885cdc4e52f1b351765a8e9ecdd13751c95e145781cd13d44f4c329dea55e84aeca92bb5918c15cc668bf83fe76d9c20a464a00482e1e0

View File

@@ -0,0 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>ursm@ursm.jp</email>
<name>Keita Urashima</name>
</maintainer>
<upstream>
<remote-id type="github">jrabinow/snapper-rollback</remote-id>
</upstream>
</pkgmetadata>

View File

@@ -0,0 +1,43 @@
# Copyright 2026 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
PYTHON_COMPAT=( python3_{11..14} )
inherit python-single-r1
DESCRIPTION="Rollback to a snapper btrfs snapshot using the flat subvolume layout"
HOMEPAGE="https://github.com/jrabinow/snapper-rollback"
SRC_URI="https://github.com/jrabinow/${PN}/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="GPL-3"
SLOT="0"
KEYWORDS="~amd64"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
RDEPEND="
${PYTHON_DEPS}
$(python_gen_cond_dep '
dev-python/btrfsutil[${PYTHON_USEDEP}]
')
app-backup/snapper
"
src_prepare() {
default
# python_fix_shebang cannot parse "env -S python3", so drop the -S flag.
sed -i -e '1s|/usr/bin/env -S python3|/usr/bin/env python3|' "${PN}.py" || die
}
src_install() {
newsbin "${PN}.py" "${PN}"
python_fix_shebang "${ED}/usr/sbin/${PN}"
insinto /etc
doins "${PN}.conf"
einstalldocs
}