unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#52659] Vorta GUI for Borg backup
@ 2021-12-19 17:41 Leo Famulari
  2021-12-19 17:44 ` [bug#52659] [PATCH 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
                   ` (2 more replies)
  0 siblings, 3 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 17:41 UTC (permalink / raw)
  To: 52659

[-- Attachment #1: Type: text/plain, Size: 374 bytes --]

Recently I noticed some discussion on #guix IRC about Vorta, a GUI for
Borg backup.

I actually have some ooooold patches for this, that I've been
maintaining privately for a while. I never submitted them because I
haven't been using Vorta, just Borg via cron.

But since I have this work, I might as well submit it since others are
asking about this program.

Please test!

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH 1/2] gnu: Add python-pytest-faulthandler.
  2021-12-19 17:41 [bug#52659] Vorta GUI for Borg backup Leo Famulari
@ 2021-12-19 17:44 ` Leo Famulari
  2021-12-19 17:44   ` [bug#52659] [PATCH 2/2] gnu: Add Vorta Leo Famulari
  2021-12-19 18:56 ` [bug#52659] [WIP v2 1/4] gnu: Add python-pytest-faulthandler Leo Famulari
  2021-12-19 19:35 ` [bug#52659] [PATCH v3 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
  2 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 17:44 UTC (permalink / raw)
  To: 52659

* gnu/packages/check.scm (python-pytest-faulthandler): New variable.
---
 gnu/packages/check.scm | 23 ++++++++++++++++++++++-
 1 file changed, 22 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
index 0a90a3b167..bdd0eae0aa 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -8,7 +8,7 @@
 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
 ;;; Copyright © 2015, 2016, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
-;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2016, 2017, 2021 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2016 Christine Lemmer-Webber <cwebber@dustycloud.org>
 ;;; Copyright © 2016, 2017 Danny Milosavljevic <dannym+a@scratchpost.org>
 ;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
@@ -1481,6 +1481,27 @@ (define-public python-pytest-forked
 side-effects (such as setting environment variables).")
     (license license:expat)))
 
+;; This package is included in Pytest >=5.0.
+(define-public python-pytest-faulthandler
+  (package
+    (name "python-pytest-faulthandler")
+    (version "2.0.1")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "pytest-faulthandler" version))
+              (sha256
+               (base32
+                "1r8ssxfdib2d2mblmnm34q84lza5d8cq5n5p3sl4sd5chz7bnwpd"))))
+    (build-system python-build-system)
+    (native-inputs
+     `(("python-pytest" ,python-pytest)
+       ("python-setuptools-scm" ,python-setuptools-scm)))
+    (home-page "https://github.com/pytest-dev/pytest-faulthandler")
+    (synopsis "Pytest plugin that activates the faulthandler module for tests")
+    (description "This package provides a pytest plugin that automatically
+enables the @code{faulthandler} module during tests.")
+    (license license:expat)))
+
 (define-public python-scripttest
   (package
     (name "python-scripttest")
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH 2/2] gnu: Add Vorta.
  2021-12-19 17:44 ` [bug#52659] [PATCH 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
@ 2021-12-19 17:44   ` Leo Famulari
  2021-12-19 17:52     ` Leo Famulari
  0 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 17:44 UTC (permalink / raw)
  To: 52659

* gnu/packages/backup.scm (vorta): New variable.
---
 gnu/packages/backup.scm | 58 ++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 57 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm
index fdb84898bb..f683266359 100644
--- a/gnu/packages/backup.scm
+++ b/gnu/packages/backup.scm
@@ -1,7 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2014, 2015, 2020 Eric Bavier <bavier@posteo.net>
 ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
-;;; Copyright © 2015, 2016, 2017 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2015, 2016, 2017, 2021 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
 ;;; Copyright © 2017, 2021 Arun Isaac <arunisaac@systemreboot.net>
@@ -47,6 +47,7 @@ (define-module (gnu packages backup)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system python)
+  #:use-module (guix build-system qt)
   #:use-module (gnu packages)
   #:use-module (gnu packages acl)
   #:use-module (gnu packages autotools)
@@ -76,12 +77,15 @@ (define-module (gnu packages backup)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages protobuf)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages python-check)
   #:use-module (gnu packages python-crypto)
   #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
+  #:use-module (gnu packages qt)
   #:use-module (gnu packages rsync)
   #:use-module (gnu packages serialization)
   #:use-module (gnu packages ssh)
+  #:use-module (gnu packages time)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages valgrind)
   #:use-module (gnu packages xml))
@@ -1181,3 +1185,55 @@ (define-public borgmatic
 your databases too.  Monitor it all with integrated third-party services.
 borgmatic is powered by borg.")
     (license license:gpl3+)))
+
+(define-public vorta
+  (package
+    (name "vorta")
+    (version "0.8.2")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "vorta" version))
+              (sha256
+               (base32
+                "1cl7kyh14h38xavbq23b8ifvk8abkiqdkpgaxfxvd223fm02zz26"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:imported-modules ((guix build qt-utils)
+                           (guix build cmake-build-system)
+                           (guix build qt-build-system)
+                           ,@%python-build-system-modules)
+       #:modules ((guix build utils)
+                  (guix build python-build-system)
+                  ((guix build qt-build-system) #:prefix qt:))
+       #:phases
+       (modify-phases %standard-phases
+         ;; XXX This phase tries to write to $HOME
+         (add-before 'sanity-check 'set-HOME
+           (lambda _
+             (setenv "HOME" "/tmp")))
+         ;; Otherwise, the user interface's icons will be missing.
+         (add-after 'wrap 'qt-wrap
+           (assoc-ref qt:%standard-phases 'qt-wrap)))))
+    (native-inputs
+     `(("python-pytest-mock" ,python-pytest-mock)
+       ("python-pytest-qt" ,python-pytest-qt)
+       ("python-pytest-runner" ,python-pytest-runner)
+       ("python-setuptools-git" ,python-setuptools-git)))
+    (inputs
+     `(("python-appdirs" ,python-appdirs)
+       ("python-dateutil" ,python-dateutil)
+       ("python-keyring" ,python-keyring)
+       ("python-paramiko" ,python-paramiko)
+       ("python-peewee" ,python-peewee)
+       ("python-psutil" ,python-psutil)
+       ("python-pyqt" ,python-pyqt)
+       ("python-secretstorage" ,python-secretstorage)
+       ;; XXX This is included so that the qt-wrap phase picks it up.
+       ("qtsvg" ,qtsvg)))
+    (home-page "https://github.com/borgbase/vorta")
+    (synopsis "Graphical backup client based on BorgBackup")
+    (description "Vorta is a graphical backup client based on the Borg backup
+tool.  It supports the use of remote backup repositories.  It can perform
+scheduled backups, and has a graphical tool for browsing and extracting the Borg
+archives.")
+    (license license:gpl3+)))
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH 2/2] gnu: Add Vorta.
  2021-12-19 17:44   ` [bug#52659] [PATCH 2/2] gnu: Add Vorta Leo Famulari
@ 2021-12-19 17:52     ` Leo Famulari
  0 siblings, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 17:52 UTC (permalink / raw)
  To: 52659

On Sun, Dec 19, 2021 at 12:44:13PM -0500, Leo Famulari wrote:
> * gnu/packages/backup.scm (vorta): New variable.

> +    (inputs
> +     `(("python-appdirs" ,python-appdirs)
> +       ("python-dateutil" ,python-dateutil)
> +       ("python-keyring" ,python-keyring)
> +       ("python-paramiko" ,python-paramiko)
> +       ("python-peewee" ,python-peewee)
> +       ("python-psutil" ,python-psutil)
> +       ("python-pyqt" ,python-pyqt)
> +       ("python-secretstorage" ,python-secretstorage)
> +       ;; XXX This is included so that the qt-wrap phase picks it up.
> +       ("qtsvg" ,qtsvg)))

You may notice an important missing dependency: Borg.

The build doesn't require it.

Should we propagate it? Find out where Vorta invokes it and patch the
invocation? Let the user install it (sounds like a recipe for
complaints)?




^ permalink raw reply	[flat|nested] 14+ messages in thread

* [bug#52659] [WIP v2 1/4] gnu: Add python-pytest-faulthandler.
  2021-12-19 17:41 [bug#52659] Vorta GUI for Borg backup Leo Famulari
  2021-12-19 17:44 ` [bug#52659] [PATCH 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
@ 2021-12-19 18:56 ` Leo Famulari
  2021-12-19 18:56   ` [bug#52659] [WIP v2 2/4] gnu: Add Vorta Leo Famulari
                     ` (2 more replies)
  2021-12-19 19:35 ` [bug#52659] [PATCH v3 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
  2 siblings, 3 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 18:56 UTC (permalink / raw)
  To: 52659

* gnu/packages/check.scm (python-pytest-faulthandler): New variable.
---
 gnu/packages/check.scm | 22 +++++++++++++++++++++-
 1 file changed, 21 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
index 0a90a3b167..e3bb53dae0 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -8,7 +8,7 @@
 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
 ;;; Copyright © 2015, 2016, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
-;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2016, 2017, 2021 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2016 Christine Lemmer-Webber <cwebber@dustycloud.org>
 ;;; Copyright © 2016, 2017 Danny Milosavljevic <dannym+a@scratchpost.org>
 ;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
@@ -1481,6 +1481,26 @@ (define-public python-pytest-forked
 side-effects (such as setting environment variables).")
     (license license:expat)))
 
+;; This package is included in Pytest >=5.0.
+(define-public python-pytest-faulthandler
+  (package
+    (name "python-pytest-faulthandler")
+    (version "2.0.1")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "pytest-faulthandler" version))
+              (sha256
+               (base32
+                "1r8ssxfdib2d2mblmnm34q84lza5d8cq5n5p3sl4sd5chz7bnwpd"))))
+    (build-system python-build-system)
+    (native-inputs
+      (list python-pytest python-setuptools-scm))
+    (home-page "https://github.com/pytest-dev/pytest-faulthandler")
+    (synopsis "Pytest plugin that activates the faulthandler module for tests")
+    (description "This package provides a pytest plugin that automatically
+enables the @code{faulthandler} module during tests.")
+    (license license:expat)))
+
 (define-public python-scripttest
   (package
     (name "python-scripttest")
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [WIP v2 2/4] gnu: Add Vorta.
  2021-12-19 18:56 ` [bug#52659] [WIP v2 1/4] gnu: Add python-pytest-faulthandler Leo Famulari
@ 2021-12-19 18:56   ` Leo Famulari
  2021-12-19 18:56   ` [bug#52659] [WIP v2 3/4] Vorta: patch Borg invocation Leo Famulari
  2021-12-19 18:56   ` [bug#52659] [WIP v2 4/4] WIP: Vorta: Use gexps instead of (assoc-ref ...) Leo Famulari
  2 siblings, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 18:56 UTC (permalink / raw)
  To: 52659

* gnu/packages/backup.scm (vorta): New variable.
---
 gnu/packages/backup.scm | 58 ++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 57 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm
index fdb84898bb..5ce6e10bab 100644
--- a/gnu/packages/backup.scm
+++ b/gnu/packages/backup.scm
@@ -1,7 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2014, 2015, 2020 Eric Bavier <bavier@posteo.net>
 ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
-;;; Copyright © 2015, 2016, 2017 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2015, 2016, 2017, 2021 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
 ;;; Copyright © 2017, 2021 Arun Isaac <arunisaac@systemreboot.net>
@@ -47,6 +47,7 @@ (define-module (gnu packages backup)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system python)
+  #:use-module (guix build-system qt)
   #:use-module (gnu packages)
   #:use-module (gnu packages acl)
   #:use-module (gnu packages autotools)
@@ -76,12 +77,15 @@ (define-module (gnu packages backup)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages protobuf)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages python-check)
   #:use-module (gnu packages python-crypto)
   #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
+  #:use-module (gnu packages qt)
   #:use-module (gnu packages rsync)
   #:use-module (gnu packages serialization)
   #:use-module (gnu packages ssh)
+  #:use-module (gnu packages time)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages valgrind)
   #:use-module (gnu packages xml))
@@ -1181,3 +1185,55 @@ (define-public borgmatic
 your databases too.  Monitor it all with integrated third-party services.
 borgmatic is powered by borg.")
     (license license:gpl3+)))
+
+(define-public vorta
+  (package
+    (name "vorta")
+    (version "0.8.2")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "vorta" version))
+              (sha256
+               (base32
+                "1cl7kyh14h38xavbq23b8ifvk8abkiqdkpgaxfxvd223fm02zz26"))))
+    (build-system python-build-system)
+    (arguments
+     `(#:imported-modules ((guix build qt-utils)
+                           (guix build cmake-build-system)
+                           (guix build qt-build-system)
+                           ,@%python-build-system-modules)
+       #:modules ((guix build utils)
+                  (guix build python-build-system)
+                  ((guix build qt-build-system) #:prefix qt:))
+       #:phases
+       (modify-phases %standard-phases
+         ;; XXX This phase tries to write to $HOME
+         (add-before 'sanity-check 'set-HOME
+           (lambda _
+             (setenv "HOME" "/tmp")))
+         ;; Otherwise, the user interface's icons will be missing.
+         (add-after 'wrap 'qt-wrap
+           (assoc-ref qt:%standard-phases 'qt-wrap)))))
+    (native-inputs
+      (list python-pytest-mock
+            python-pytest-qt
+            python-pytest-runner
+            python-setuptools-git))
+    (inputs
+      (list python-appdirs
+            python-dateutil
+            python-keyring
+            python-paramiko
+            python-peewee
+            python-psutil
+            python-pyqt
+            python-secretstorage
+            ;; XXX This is included so that the qt-wrap phase picks it up.
+            qtsvg))
+    (home-page "https://github.com/borgbase/vorta")
+    (synopsis "Graphical backup client based on BorgBackup")
+    (description "Vorta is a graphical backup client based on the Borg backup
+tool.  It supports the use of remote backup repositories.  It can perform
+scheduled backups, and has a graphical tool for browsing and extracting the Borg
+archives.")
+    (license license:gpl3+)))
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [WIP v2 3/4] Vorta: patch Borg invocation
  2021-12-19 18:56 ` [bug#52659] [WIP v2 1/4] gnu: Add python-pytest-faulthandler Leo Famulari
  2021-12-19 18:56   ` [bug#52659] [WIP v2 2/4] gnu: Add Vorta Leo Famulari
@ 2021-12-19 18:56   ` Leo Famulari
  2021-12-19 18:56   ` [bug#52659] [WIP v2 4/4] WIP: Vorta: Use gexps instead of (assoc-ref ...) Leo Famulari
  2 siblings, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 18:56 UTC (permalink / raw)
  To: 52659

---
 gnu/packages/backup.scm | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm
index 5ce6e10bab..e2a37d182b 100644
--- a/gnu/packages/backup.scm
+++ b/gnu/packages/backup.scm
@@ -1207,6 +1207,13 @@ (define-public vorta
                   ((guix build qt-build-system) #:prefix qt:))
        #:phases
        (modify-phases %standard-phases
+         (add-after 'unpack 'patch-borg-path
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((borg (string-append (assoc-ref inputs "borg")
+                                        "/bin/borg")))
+               (substitute* "src/vorta/borg/borg_job.py"
+                 (("which\\('borg'\\)")
+                  (string-append "which('" borg "')"))))))
          ;; XXX This phase tries to write to $HOME
          (add-before 'sanity-check 'set-HOME
            (lambda _
@@ -1220,7 +1227,8 @@ (define-public vorta
             python-pytest-runner
             python-setuptools-git))
     (inputs
-      (list python-appdirs
+      (list borg
+            python-appdirs
             python-dateutil
             python-keyring
             python-paramiko
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [WIP v2 4/4] WIP: Vorta: Use gexps instead of (assoc-ref ...)
  2021-12-19 18:56 ` [bug#52659] [WIP v2 1/4] gnu: Add python-pytest-faulthandler Leo Famulari
  2021-12-19 18:56   ` [bug#52659] [WIP v2 2/4] gnu: Add Vorta Leo Famulari
  2021-12-19 18:56   ` [bug#52659] [WIP v2 3/4] Vorta: patch Borg invocation Leo Famulari
@ 2021-12-19 18:56   ` Leo Famulari
  2 siblings, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 18:56 UTC (permalink / raw)
  To: 52659

---
 gnu/packages/backup.scm | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm
index e2a37d182b..16353682dd 100644
--- a/gnu/packages/backup.scm
+++ b/gnu/packages/backup.scm
@@ -1209,11 +1209,10 @@ (define-public vorta
        (modify-phases %standard-phases
          (add-after 'unpack 'patch-borg-path
            (lambda* (#:key inputs #:allow-other-keys)
-             (let ((borg (string-append (assoc-ref inputs "borg")
-                                        "/bin/borg")))
-               (substitute* "src/vorta/borg/borg_job.py"
-                 (("which\\('borg'\\)")
-                  (string-append "which('" borg "')"))))))
+             (substitute* "src/vorta/borg/borg_job.py"
+               (("which\\('borg'\\)")
+                (string-append "which('" ,#$(this-package-input borg)
+                               "/bin/borg')")))))
          ;; XXX This phase tries to write to $HOME
          (add-before 'sanity-check 'set-HOME
            (lambda _
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH v3 1/2] gnu: Add python-pytest-faulthandler.
  2021-12-19 17:41 [bug#52659] Vorta GUI for Borg backup Leo Famulari
  2021-12-19 17:44 ` [bug#52659] [PATCH 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
  2021-12-19 18:56 ` [bug#52659] [WIP v2 1/4] gnu: Add python-pytest-faulthandler Leo Famulari
@ 2021-12-19 19:35 ` Leo Famulari
  2021-12-19 19:35   ` [bug#52659] [PATCH v3 2/2] gnu: Add Vorta Leo Famulari
  2 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 19:35 UTC (permalink / raw)
  To: 52659

* gnu/packages/check.scm (python-pytest-faulthandler): New variable.
---
 gnu/packages/check.scm | 22 +++++++++++++++++++++-
 1 file changed, 21 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm
index 0a90a3b167..e3bb53dae0 100644
--- a/gnu/packages/check.scm
+++ b/gnu/packages/check.scm
@@ -8,7 +8,7 @@
 ;;; Copyright © 2015 Federico Beffa <beffa@fbengineering.ch>
 ;;; Copyright © 2015 Andreas Enge <andreas@enge.fr>
 ;;; Copyright © 2015, 2016, 2018, 2019, 2020, 2021 Efraim Flashner <efraim@flashner.co.il>
-;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2016, 2017, 2021 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2016 Christine Lemmer-Webber <cwebber@dustycloud.org>
 ;;; Copyright © 2016, 2017 Danny Milosavljevic <dannym+a@scratchpost.org>
 ;;; Copyright © 2016 Roel Janssen <roel@gnu.org>
@@ -1481,6 +1481,26 @@ (define-public python-pytest-forked
 side-effects (such as setting environment variables).")
     (license license:expat)))
 
+;; This package is included in Pytest >=5.0.
+(define-public python-pytest-faulthandler
+  (package
+    (name "python-pytest-faulthandler")
+    (version "2.0.1")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "pytest-faulthandler" version))
+              (sha256
+               (base32
+                "1r8ssxfdib2d2mblmnm34q84lza5d8cq5n5p3sl4sd5chz7bnwpd"))))
+    (build-system python-build-system)
+    (native-inputs
+      (list python-pytest python-setuptools-scm))
+    (home-page "https://github.com/pytest-dev/pytest-faulthandler")
+    (synopsis "Pytest plugin that activates the faulthandler module for tests")
+    (description "This package provides a pytest plugin that automatically
+enables the @code{faulthandler} module during tests.")
+    (license license:expat)))
+
 (define-public python-scripttest
   (package
     (name "python-scripttest")
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH v3 2/2] gnu: Add Vorta.
  2021-12-19 19:35 ` [bug#52659] [PATCH v3 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
@ 2021-12-19 19:35   ` Leo Famulari
       [not found]     ` <87v8zjoed4.fsf@disroot.org>
  2022-01-26 19:18     ` bug#52659: " Leo Famulari
  0 siblings, 2 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-19 19:35 UTC (permalink / raw)
  To: 52659

* gnu/packages/backup.scm (vorta): New variable.
---
 gnu/packages/backup.scm | 67 ++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 66 insertions(+), 1 deletion(-)

diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm
index fdb84898bb..2a47b759d7 100644
--- a/gnu/packages/backup.scm
+++ b/gnu/packages/backup.scm
@@ -1,7 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright © 2014, 2015, 2020 Eric Bavier <bavier@posteo.net>
 ;;; Copyright © 2014 Ian Denhardt <ian@zenhack.net>
-;;; Copyright © 2015, 2016, 2017 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2015, 2016, 2017, 2021 Leo Famulari <leo@famulari.name>
 ;;; Copyright © 2017–2021 Tobias Geerinckx-Rice <me@tobias.gr>
 ;;; Copyright © 2017 Thomas Danckaert <post@thomasdanckaert.be>
 ;;; Copyright © 2017, 2021 Arun Isaac <arunisaac@systemreboot.net>
@@ -40,6 +40,7 @@
 (define-module (gnu packages backup)
   #:use-module (guix packages)
   #:use-module ((guix licenses) #:prefix license:)
+  #:use-module (guix gexp)
   #:use-module (guix git-download)
   #:use-module (guix download)
   #:use-module (guix utils)
@@ -47,6 +48,7 @@ (define-module (gnu packages backup)
   #:use-module (guix build-system gnu)
   #:use-module (guix build-system go)
   #:use-module (guix build-system python)
+  #:use-module (guix build-system qt)
   #:use-module (gnu packages)
   #:use-module (gnu packages acl)
   #:use-module (gnu packages autotools)
@@ -76,12 +78,15 @@ (define-module (gnu packages backup)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages protobuf)
   #:use-module (gnu packages python)
+  #:use-module (gnu packages python-check)
   #:use-module (gnu packages python-crypto)
   #:use-module (gnu packages python-web)
   #:use-module (gnu packages python-xyz)
+  #:use-module (gnu packages qt)
   #:use-module (gnu packages rsync)
   #:use-module (gnu packages serialization)
   #:use-module (gnu packages ssh)
+  #:use-module (gnu packages time)
   #:use-module (gnu packages tls)
   #:use-module (gnu packages valgrind)
   #:use-module (gnu packages xml))
@@ -1181,3 +1186,63 @@ (define-public borgmatic
 your databases too.  Monitor it all with integrated third-party services.
 borgmatic is powered by borg.")
     (license license:gpl3+)))
+
+(define-public vorta
+  (package
+    (name "vorta")
+    (version "0.8.2")
+    (source (origin
+              (method url-fetch)
+              (uri (pypi-uri "vorta" version))
+              (sha256
+               (base32
+                "1cl7kyh14h38xavbq23b8ifvk8abkiqdkpgaxfxvd223fm02zz26"))))
+    (build-system python-build-system)
+    (arguments
+     (list
+      #:imported-modules `((guix build qt-utils)
+                           (guix build cmake-build-system)
+                           (guix build qt-build-system)
+                           ,@%python-build-system-modules)
+      #:modules '((guix build utils)
+                  (guix build python-build-system)
+                  ((guix build qt-build-system) #:prefix qt:))
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'patch-borg-path
+            (lambda* (#:key inputs #:allow-other-keys)
+              (substitute* "src/vorta/borg/borg_job.py"
+                (("which\\('borg'\\)")
+                 (string-append "which('" #$(this-package-input "borg")
+                                "/bin/borg')")))))
+          ;; XXX This phase tries to write to $HOME
+          (add-before 'sanity-check 'set-HOME
+            (lambda _
+              (setenv "HOME" "/tmp")))
+          ;; Otherwise, the user interface's icons will be missing.
+          (add-after 'wrap 'qt-wrap
+            (assoc-ref qt:%standard-phases 'qt-wrap)))))
+    (native-inputs
+     (list python-pytest-mock
+           python-pytest-qt
+           python-pytest-runner
+           python-setuptools-git))
+    (inputs
+     (list borg
+           python-appdirs
+           python-dateutil
+           python-keyring
+           python-paramiko
+           python-peewee
+           python-psutil
+           python-pyqt
+           python-secretstorage
+           ;; XXX This is included so that the qt-wrap phase picks it up.
+           qtsvg))
+    (home-page "https://github.com/borgbase/vorta")
+    (synopsis "Graphical backup client based on BorgBackup")
+    (description "Vorta is a graphical backup client based on the Borg backup
+tool.  It supports the use of remote backup repositories.  It can perform
+scheduled backups, and has a graphical tool for browsing and extracting the Borg
+archives.")
+    (license license:gpl3+)))
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH v3 2/2] gnu: Add Vorta.
       [not found]     ` <87v8zjoed4.fsf@disroot.org>
@ 2021-12-20 17:55       ` Leo Famulari
  2021-12-20 19:40         ` Xinglu Chen
  0 siblings, 1 reply; 14+ messages in thread
From: Leo Famulari @ 2021-12-20 17:55 UTC (permalink / raw)
  To: Xinglu Chen; +Cc: 52659

On Mon, Dec 20, 2021 at 09:43:51AM +0100, Xinglu Chen wrote:
> Result of running `guix review b960924583def5400b477d3eea839c78ec8cf950.1639942526.git.leo@famulari.name': (still a WIP)

What is `guix review`? :)




^ permalink raw reply	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH v3 2/2] gnu: Add Vorta.
  2021-12-20 17:55       ` Leo Famulari
@ 2021-12-20 19:40         ` Xinglu Chen
  2021-12-20 19:51           ` Leo Famulari
  0 siblings, 1 reply; 14+ messages in thread
From: Xinglu Chen @ 2021-12-20 19:40 UTC (permalink / raw)
  To: Leo Famulari; +Cc: 52659

[-- Attachment #1: Type: text/plain, Size: 962 bytes --]

On Mon, Dec 20 2021, Leo Famulari wrote:

> On Mon, Dec 20, 2021 at 09:43:51AM +0100, Xinglu Chen wrote:
>> Result of running `guix review b960924583def5400b477d3eea839c78ec8cf950.1639942526.git.leo@famulari.name': (still a WIP)
>
> What is `guix review`? :)

Hehe, it’s still a WIP (which is why I am testing it), and as the name
suggests, it makes it easier to review packages.  It can read the diff
between two commits and determine the packages that have been changed,
and then it will build and lint those package.  Or it can be given a
message id (as you see above) and use the ‘b4’ program to fetch patches
from a public-inbox archive[1], and then apply them, build and lint the
packages.

I still have some work to do on Guix Home[2], but after that I will
hopefully send some patches for this ‘guix review’ command.  :-)

[1]: Like this one <https://yhetil.org>
[2]: <https://yhetil.org/guix-devel/878rwlu4uz.fsf@inria.fr>

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 861 bytes --]

^ permalink raw reply	[flat|nested] 14+ messages in thread

* [bug#52659] [PATCH v3 2/2] gnu: Add Vorta.
  2021-12-20 19:40         ` Xinglu Chen
@ 2021-12-20 19:51           ` Leo Famulari
  0 siblings, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2021-12-20 19:51 UTC (permalink / raw)
  To: Xinglu Chen; +Cc: 52659

[-- Attachment #1: Type: text/plain, Size: 708 bytes --]

On Mon, Dec 20, 2021 at 08:40:19PM +0100, Xinglu Chen wrote:
> Hehe, it’s still a WIP (which is why I am testing it), and as the name
> suggests, it makes it easier to review packages.  It can read the diff
> between two commits and determine the packages that have been changed,
> and then it will build and lint those package.  Or it can be given a
> message id (as you see above) and use the ‘b4’ program to fetch patches
> from a public-inbox archive[1], and then apply them, build and lint the
> packages.
> 
> I still have some work to do on Guix Home[2], but after that I will
> hopefully send some patches for this ‘guix review’ command.  :-)

Cool, I'm looking forward to it.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 14+ messages in thread

* bug#52659: [PATCH v3 2/2] gnu: Add Vorta.
  2021-12-19 19:35   ` [bug#52659] [PATCH v3 2/2] gnu: Add Vorta Leo Famulari
       [not found]     ` <87v8zjoed4.fsf@disroot.org>
@ 2022-01-26 19:18     ` Leo Famulari
  1 sibling, 0 replies; 14+ messages in thread
From: Leo Famulari @ 2022-01-26 19:18 UTC (permalink / raw)
  To: 52659-done

On Sun, Dec 19, 2021 at 02:35:28PM -0500, Leo Famulari wrote:
> * gnu/packages/backup.scm (vorta): New variable.

Pushed as c11b585a819a908f866d6072075a27fcb4e0e637




^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2022-01-26 19:22 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-19 17:41 [bug#52659] Vorta GUI for Borg backup Leo Famulari
2021-12-19 17:44 ` [bug#52659] [PATCH 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
2021-12-19 17:44   ` [bug#52659] [PATCH 2/2] gnu: Add Vorta Leo Famulari
2021-12-19 17:52     ` Leo Famulari
2021-12-19 18:56 ` [bug#52659] [WIP v2 1/4] gnu: Add python-pytest-faulthandler Leo Famulari
2021-12-19 18:56   ` [bug#52659] [WIP v2 2/4] gnu: Add Vorta Leo Famulari
2021-12-19 18:56   ` [bug#52659] [WIP v2 3/4] Vorta: patch Borg invocation Leo Famulari
2021-12-19 18:56   ` [bug#52659] [WIP v2 4/4] WIP: Vorta: Use gexps instead of (assoc-ref ...) Leo Famulari
2021-12-19 19:35 ` [bug#52659] [PATCH v3 1/2] gnu: Add python-pytest-faulthandler Leo Famulari
2021-12-19 19:35   ` [bug#52659] [PATCH v3 2/2] gnu: Add Vorta Leo Famulari
     [not found]     ` <87v8zjoed4.fsf@disroot.org>
2021-12-20 17:55       ` Leo Famulari
2021-12-20 19:40         ` Xinglu Chen
2021-12-20 19:51           ` Leo Famulari
2022-01-26 19:18     ` bug#52659: " Leo Famulari

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).