unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: Zhu Zihao <all_but_last@163.com>
To: Liliana Marie Prikler <liliana.prikler@ist.tugraz.at>
Cc: 55517@debbugs.gnu.org
Subject: [bug#55517] Acknowledgement ([PATCH]: gnu: emacs-magit: Drop the libgit backend.)
Date: Sun, 22 May 2022 17:46:01 +0800	[thread overview]
Message-ID: <86o7zpaoih.fsf@163.com> (raw)
In-Reply-To: <07286c2df8ffb434e353bdde7bf8d427e9d7d9b2.camel@ist.tugraz.at>


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



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

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-emacs-magit-Use-G-expressions.patch --]
[-- Type: text/x-patch, Size: 5353 bytes --]

From e1d5e1da9229fc317f96e75d4e07e230fa6988fe Mon Sep 17 00:00:00 2001
From: Zhu Zihao <all_but_last@163.com>
Date: Sun, 22 May 2022 17:43:42 +0800
Subject: [PATCH 1/2] gnu: emacs-magit: Use G-expressions.

* gnu/packages/emacs-xyz.scm (emacs-magit)[arguments]: Use G-expressions.
<phases>: In phase 'patch-exec-paths', use search-input-file for perl
executable.
---
 gnu/packages/emacs-xyz.scm | 91 +++++++++++++++++++-------------------
 1 file changed, 46 insertions(+), 45 deletions(-)

diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index eed2f4b71c..8970b2d350 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -869,51 +869,52 @@ (define-public emacs-magit
         (base32 "0cxyvp2aav27znc7mf6c83q5pddpdniaqkrxn1r8dbgr540qmnpn"))))
     (build-system emacs-build-system)
     (arguments
-     `(#:emacs ,emacs-no-x             ;module support is required
-       #:tests? #t
-       #:test-command '("make" "test")
-       #:phases
-       (modify-phases %standard-phases
-         (add-after 'unpack 'build-info-manual
-           (lambda _
-             (invoke "make" "info")
-             ;; Copy info files to the lisp directory, which acts as
-             ;; the root of the project for the emacs-build-system.
-             (for-each (lambda (f)
-                         (install-file f "lisp"))
-                       (find-files "Documentation" "\\.info$"))
-             (chdir "lisp")))
-         (add-after 'build-info-manual 'set-magit-version
-           (lambda _
-             (make-file-writable "magit.el")
-             (emacs-substitute-variables "magit.el"
-               ("magit-version" ,version))))
-         (add-after 'set-magit-version 'patch-exec-paths
-           (lambda* (#:key inputs #:allow-other-keys)
-             (let ((perl (assoc-ref inputs "perl")))
-               (make-file-writable "magit-sequence.el")
-               (emacs-substitute-variables "magit-sequence.el"
-                 ("magit-perl-executable" (string-append perl "/bin/perl"))))))
-         (add-before 'check 'configure-git
-           (lambda _
-             ;; Otherwise some tests fail with error "unable to auto-detect
-             ;; email address".
-             (setenv "HOME" (getcwd))
-             (invoke "git" "config" "--global" "user.name" "toto")
-             (invoke "git" "config" "--global" "user.email"
-                     "toto@toto.com")))
-         (add-after 'configure-git 'disable-tramp-test
-           (lambda _
-             ;; There is an issue causing TRAMP to fail in the build
-             ;; environment.  Setting the tramp-remote-shell parameter of
-             ;; the sudo-method to the file name of the shell didn't help.
-             (chdir "..")
-             (substitute* "t/magit-tests.el"
-               (("^\\(ert-deftest magit-toplevel:tramp.*" all)
-                (string-append all "  (skip-unless nil)")))))
-         (add-before 'install 'enter-lisp-directory
-           (lambda _
-             (chdir "lisp"))))))
+     (list
+      #:emacs emacs-no-x             ;module support is required
+      #:tests? #t
+      #:test-command #~(list "make" "test")
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'unpack 'build-info-manual
+            (lambda _
+              (invoke "make" "info")
+              ;; Copy info files to the lisp directory, which acts as
+              ;; the root of the project for the emacs-build-system.
+              (for-each (lambda (f)
+                          (install-file f "lisp"))
+                        (find-files "Documentation" "\\.info$"))
+              (chdir "lisp")))
+          (add-after 'build-info-manual 'set-magit-version
+            (lambda _
+              (make-file-writable "magit.el")
+              (emacs-substitute-variables "magit.el"
+                ("magit-version" #$version))))
+          (add-after 'set-magit-version 'patch-exec-paths
+            (lambda* (#:key inputs #:allow-other-keys)
+              (let ((perl (search-input-file inputs "/bin/perl")))
+                (make-file-writable "magit-sequence.el")
+                (emacs-substitute-variables "magit-sequence.el"
+                  ("magit-perl-executable" perl)))))
+          (add-before 'check 'configure-git
+            (lambda _
+              ;; Otherwise some tests fail with error "unable to auto-detect
+              ;; email address".
+              (setenv "HOME" (getcwd))
+              (invoke "git" "config" "--global" "user.name" "toto")
+              (invoke "git" "config" "--global" "user.email"
+                      "toto@toto.com")))
+          (add-after 'configure-git 'disable-tramp-test
+            (lambda _
+              ;; There is an issue causing TRAMP to fail in the build
+              ;; environment.  Setting the tramp-remote-shell parameter of
+              ;; the sudo-method to the file name of the shell didn't help.
+              (chdir "..")
+              (substitute* "t/magit-tests.el"
+                (("^\\(ert-deftest magit-toplevel:tramp.*" all)
+                 (string-append all "  (skip-unless nil)")))))
+          (add-before 'install 'enter-lisp-directory
+            (lambda _
+              (chdir "lisp"))))))
     (native-inputs
      (list texinfo))
     (inputs
-- 
2.36.0


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #3: 0002-gnu-emacs-magit-Drop-the-libgit-backend.patch --]
[-- Type: text/x-patch, Size: 1679 bytes --]

From d2f9cc135e51cdde0623b5ffc453efa11f30a5eb Mon Sep 17 00:00:00 2001
From: Zhu Zihao <all_but_last@163.com>
Date: Fri, 20 May 2022 11:51:02 +0800
Subject: [PATCH 2/2] gnu: emacs-magit: Drop the libgit backend.

The libgit backend currently provides next to no features, but
demands extra maintenance overhead.  It is in fact not a usable
backend; thus let's not use it.

* gnu/packages/emacs-xyz.scm (emacs-magit)[arguments]
<emacs>: Remove this argument.
<exclude>: Exclude the magit-libgit.el and magit-libgit-pkg.el.

[inputs]: Remove emacs-libgit.
---
 gnu/packages/emacs-xyz.scm | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm
index 8970b2d350..d3ca00475e 100644
--- a/gnu/packages/emacs-xyz.scm
+++ b/gnu/packages/emacs-xyz.scm
@@ -870,9 +870,11 @@ (define-public emacs-magit
     (build-system emacs-build-system)
     (arguments
      (list
-      #:emacs emacs-no-x             ;module support is required
       #:tests? #t
       #:test-command #~(list "make" "test")
+      #:exclude #~(cons* "magit-libgit.el"
+                         "magit-libgit-pkg.el"
+                         %default-exclude)
       #:phases
       #~(modify-phases %standard-phases
           (add-after 'unpack 'build-info-manual
@@ -920,7 +922,7 @@ (define-public emacs-magit
     (inputs
      (list git perl))
     (propagated-inputs
-     (list emacs-dash emacs-libgit emacs-transient emacs-with-editor))
+     (list emacs-dash emacs-transient emacs-with-editor))
     (home-page "https://magit.vc/")
     (synopsis "Emacs interface for the Git version control system")
     (description
-- 
2.36.0


[-- Attachment #4: Type: text/plain, Size: 100 bytes --]


-- 
Retrieve my PGP public key:

  gpg --recv-keys D47A9C8B2AE3905B563D9135BE42B352A9F6821F

Zihao

  reply	other threads:[~2022-05-22  9:48 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-19  5:08 [bug#55517] [PATCH]: gnu: emacs-magit: Drop the libgit backend Zhu Zihao
     [not found] ` <handler.55517.B.165293698432676.ack@debbugs.gnu.org>
2022-05-19  5:13   ` [bug#55517] Acknowledgement ([PATCH]: gnu: emacs-magit: Drop the libgit backend.) Zhu Zihao
2022-05-19  6:01     ` Liliana Marie Prikler
2022-05-20  3:52       ` Zhu Zihao
2022-05-20  6:04         ` Liliana Marie Prikler
2022-05-22  9:46           ` Zhu Zihao [this message]
2022-05-23  6:46             ` Liliana Marie Prikler
2022-05-28  2:11               ` Zhu Zihao
2022-05-28  6:56                 ` bug#55517: " Liliana Marie Prikler
2022-05-21  2:13     ` [bug#55517] [PATCH]: gnu: emacs-magit: Drop the libgit backend Maxim Cournoyer
2022-05-21  3:45       ` Zhu Zihao
2022-05-22  0:46         ` Maxim Cournoyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86o7zpaoih.fsf@163.com \
    --to=all_but_last@163.com \
    --cc=55517@debbugs.gnu.org \
    --cc=liliana.prikler@ist.tugraz.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).