1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
6 PYTHON_COMPAT=( python3_{6,7} )
8 DISTUTILS_USE_SETUPTOOLS="rdepend"
11 DESCRIPTION="Automatically create, prune and verify backups with borgbackup"
12 HOMEPAGE="https://torsion.org/borgmatic/"
13 SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
19 DEPEND="${PYTHON_DEPS}
20 dev-python/colorama[${PYTHON_USEDEP}]
21 >=dev-python/pykwalify-1.6.0[${PYTHON_USEDEP}]
22 dev-python/requests[${PYTHON_USEDEP}]
23 <dev-python/ruamel-yaml-0.17.0"[${PYTHON_USEDEP}]
25 app-backup/borgbackup"
28 dev-python/flexmock[${PYTHON_USEDEP}]
32 "${FILESDIR}"/${PN}-1.5.1-no_test_coverage.patch
35 distutils_enable_tests pytest
38 distutils-r1_src_prepare
40 # Unlike the other two test files in integration/commands, which use the
41 # relevant modules' respective APIs, test_borgmatic.py tries to call the
42 # 'borgmatic' executable - which has not even been created by now.
43 # Seeing as the only test run from this file as of 2020-03-25 is the
44 # parsing of contents of 'borgmatic --version', just skip it for now.
45 rm -f "${S}"/tests/integration/commands/test_borgmatic.py
49 distutils-r1_src_install
50 keepdir /etc/borgmatic
51 # TODO: install systemd units (and explain them in postinst); need patching
55 if [[ -z "${REPLACING_VERSIONS}" ]]; then
56 elog "To generate a sample configuration file, run:"
57 elog " generate-borgmatic-config"
59 elog "To upgrade your configuration file to the current version, run:"
60 elog " upgrade-borgmatic-config"