mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-21 03:25:36 +00:00
Merge pull request #190823 from DamienCassou/borgmatic-improve
This commit is contained in:
commit
5f326e2a40
@ -1,4 +1,4 @@
|
||||
{ borgbackup, coreutils, lib, python3Packages, systemd }:
|
||||
{ borgbackup, coreutils, lib, python3Packages, systemd, installShellFiles, borgmatic, testers }:
|
||||
|
||||
python3Packages.buildPythonApplication rec {
|
||||
pname = "borgmatic";
|
||||
@ -17,6 +17,8 @@ python3Packages.buildPythonApplication rec {
|
||||
"test_borgmatic_version_matches_news_version"
|
||||
];
|
||||
|
||||
nativeBuildInputs = [ installShellFiles ];
|
||||
|
||||
propagatedBuildInputs = with python3Packages; [
|
||||
borgbackup
|
||||
colorama
|
||||
@ -27,6 +29,9 @@ python3Packages.buildPythonApplication rec {
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
installShellCompletion --cmd borgmatic \
|
||||
--bash <($out/bin/borgmatic --bash-completion)
|
||||
|
||||
mkdir -p $out/lib/systemd/system
|
||||
cp sample/systemd/borgmatic.timer $out/lib/systemd/system/
|
||||
substitute sample/systemd/borgmatic.service \
|
||||
@ -36,6 +41,8 @@ python3Packages.buildPythonApplication rec {
|
||||
--replace sleep ${coreutils}/bin/sleep
|
||||
'';
|
||||
|
||||
passthru.tests.version = testers.testVersion { package = borgmatic; };
|
||||
|
||||
meta = with lib; {
|
||||
description = "Simple, configuration-driven backup software for servers and workstations";
|
||||
homepage = "https://torsion.org/borgmatic/";
|
||||
|
Loading…
Reference in New Issue
Block a user