GNU bug report logs - #47968
[PATCH 0/2] Add git-filter-repo

Previous Next

Package: guix-patches;

Reported by: François J <francois-oss <at> avalenn.eu>

Date: Fri, 23 Apr 2021 10:10:02 UTC

Severity: normal

Tags: patch

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 47968 in the body.
You can then email your comments to 47968 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to guix-patches <at> gnu.org:
bug#47968; Package guix-patches. (Fri, 23 Apr 2021 10:10:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to François J <francois-oss <at> avalenn.eu>:
New bug report received and forwarded. Copy sent to guix-patches <at> gnu.org. (Fri, 23 Apr 2021 10:10:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: François J <francois-oss <at> avalenn.eu>
To: guix-patches <at> gnu.org
Subject: [PATCH 0/2] Add git-filter-repo
Date: Fri, 23 Apr 2021 11:01:25 +0200
Just adding git-filter-repo but taking advantage of this to add back a
comment which would have saved me time.

François J (2):
  gnu: git: add a comment on why we don't build manpages
  gnu: Add git-filter-repo

 gnu/packages/version-control.scm | 34 ++++++++++++++++++++++++++++++++
 1 file changed, 34 insertions(+)

-- 
2.31.1





Information forwarded to guix-patches <at> gnu.org:
bug#47968; Package guix-patches. (Fri, 23 Apr 2021 10:25:02 GMT) Full text and rfc822 format available.

Message #8 received at 47968 <at> debbugs.gnu.org (full text, mbox):

From: François J <francois-oss <at> avalenn.eu>
To: 47968 <at> debbugs.gnu.org
Subject: [PATCH 1/2] gnu: git: add a comment on why we don't build manpages
Date: Fri, 23 Apr 2021 09:05:46 +0200
* gnu/packages/version-control.scm (git)[native-inputs]:
    add back comment skipped by commit
    d1cada0450fca54260fd20ab49d0586d147cbeb3

Signed-off-by: François J. <francois-oss <at> avalenn.eu>
---
 gnu/packages/version-control.scm | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index 3992f74644..fddabbcd40 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -188,6 +188,9 @@ as well as the classic centralized workflow.")
       ("bash" ,bash-minimal)
       ("bash-for-tests" ,bash)
       ("gettext" ,gettext-minimal)
+      ;; To build the man pages from the git sources, we would need a dependency
+      ;; on a full XML tool chain, and building it actually takes ages.  So we
+      ;; use this lazy approach and use released tarball.
       ("git-manpages"
        ,(origin
           (method url-fetch)
-- 
2.31.1





Information forwarded to guix-patches <at> gnu.org:
bug#47968; Package guix-patches. (Fri, 23 Apr 2021 10:25:02 GMT) Full text and rfc822 format available.

Message #11 received at 47968 <at> debbugs.gnu.org (full text, mbox):

From: François J <francois-oss <at> avalenn.eu>
To: 47968 <at> debbugs.gnu.org
Subject: [PATCH 2/2] gnu: Add git-filter-repo
Date: Fri, 23 Apr 2021 09:17:17 +0200
I use release tarball (instead of git as I would have liked) because it
contains pre-compiled man-pages which are too hard to build in this
context as it uses git Makefile to do it.

* gnu/packages/version-control.scm (git-filter-repo): New variable.

Signed-off-by: François J <francois-oss <at> avalenn.eu>
---
 gnu/packages/version-control.scm | 31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index fddabbcd40..481cbbb98c 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -3074,3 +3074,34 @@ If several repos are related, it helps to see their status together.")
 makes a directory under a specific root directory (by default @file{~/ghq})
 using the remote repository URL's host and path.")
     (license license:expat)))
+
+(define-public git-filter-repo
+  (package
+    (name "git-filter-repo")
+    (version "2.29.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://github.com/newren/git-filter-repo/releases/"
+                           "download/v" version
+                           "/git-filter-repo-" version ".tar.xz"))
+       (sha256
+        (base32
+         "00nn7k9jqrybb762486fmigsnbcn9lbvimgpfvvarz4ikdp9y9pb"))
+       ))
+    (build-system copy-build-system)
+    (arguments
+     `(#:install-plan
+       '(
+         ("git-filter-repo" "libexec/git-core/")
+         ("Documentation/man1/" "share/man/man1")
+         ("/" "" #:include ())
+         )))
+    (home-page
+     "https://github.com/newren/git-filter-repo")
+    (synopsis
+     "Quickly rewrite git repository history")
+    (description
+     "Quickly rewrite git repository history")
+    (license (list license:expat ;; Main license.
+                   license:gpl2)))) ;; For test harness.
-- 
2.31.1





Information forwarded to guix-patches <at> gnu.org:
bug#47968; Package guix-patches. (Mon, 03 May 2021 16:42:02 GMT) Full text and rfc822 format available.

Message #14 received at 47968 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: François J <francois-oss <at> avalenn.eu>
Cc: 47968 <at> debbugs.gnu.org
Subject: Re: bug#47968: [PATCH 0/2] Add git-filter-repo
Date: Mon, 03 May 2021 18:41:02 +0200
Hi François,

François J <francois-oss <at> avalenn.eu> skribis:

> I use release tarball (instead of git as I would have liked) because it
> contains pre-compiled man-pages which are too hard to build in this
> context as it uses git Makefile to do it.
>
> * gnu/packages/version-control.scm (git-filter-repo): New variable.
>
> Signed-off-by: François J <francois-oss <at> avalenn.eu>

Could you add a copyright line for you at the top?

> +        (base32
> +         "00nn7k9jqrybb762486fmigsnbcn9lbvimgpfvvarz4ikdp9y9pb"))
> +       ))

‘guix lint’ complains about these dangling parens.  :-)

> +    (arguments
> +     `(#:install-plan
> +       '(
> +         ("git-filter-repo" "libexec/git-core/")

Please move this to the previous line.

> +         ("Documentation/man1/" "share/man/man1")
> +         ("/" "" #:include ())
> +         )))

Likewise: lonely parens.  :-)

> +    (synopsis
> +     "Quickly rewrite git repository history")
> +    (description
> +     "Quickly rewrite git repository history")

Please capitalize “Git” and expound the description, using full
sentences, as per:

  https://guix.gnu.org/manual/en/html_node/Synopses-and-Descriptions.html

Could you send an updated patch?

(The patch 1/2 LGTM.)

Thanks,
Ludo’.




Information forwarded to guix-patches <at> gnu.org:
bug#47968; Package guix-patches. (Mon, 03 May 2021 19:40:01 GMT) Full text and rfc822 format available.

Message #17 received at 47968 <at> debbugs.gnu.org (full text, mbox):

From: François J <francois-oss <at> avalenn.eu>
To: 47968 <at> debbugs.gnu.org
Cc: Ludovic Courtès <ludo <at> gnu.org>
Subject: [PATCH] gnu: Add git-filter-repo
Date: Fri, 23 Apr 2021 09:17:17 +0200
I use release tarball (instead of git as I would have liked) because it
contains pre-compiled man-pages which are too hard to build in this
context as it uses git Makefile to do it.

* gnu/packages/version-control.scm (git-filter-repo): New variable.

Signed-off-by: François J <francois-oss <at> avalenn.eu>
---
 gnu/packages/version-control.scm | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

I changed the description by taking a more complete one from upstream. I
have chosen to not capitalize the "git" in "git filter-repo" to respect
upstream capitalization but have no opinion on the matter.

diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index fddabbcd40..4460c1c548 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -38,6 +38,7 @@
 ;;; Copyright © 2021 Léo Le Bouter <lle-bout <at> zaclys.net>
 ;;; Copyright © 2021 LibreMiami <packaging-guix <at> libremiami.org>
 ;;; Copyright © 2021 Xinglu Chen <public <at> yoctocell.xyz>
+;;; Copyright © 2021 François J. <francois-oss <at> avalenn.eu>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -3074,3 +3075,31 @@ If several repos are related, it helps to see their status together.")
 makes a directory under a specific root directory (by default @file{~/ghq})
 using the remote repository URL's host and path.")
     (license license:expat)))
+
+(define-public git-filter-repo
+  (package
+    (name "git-filter-repo")
+    (version "2.29.0")
+    (source
+     (origin
+       (method url-fetch)
+       (uri (string-append "https://github.com/newren/git-filter-repo/releases/"
+                           "download/v" version
+                           "/git-filter-repo-" version ".tar.xz"))
+       (sha256
+        (base32
+         "00nn7k9jqrybb762486fmigsnbcn9lbvimgpfvvarz4ikdp9y9pb"))))
+    (build-system copy-build-system)
+    (arguments
+     `(#:install-plan
+       '(("git-filter-repo" "libexec/git-core/")
+         ("Documentation/man1/" "share/man/man1")
+         ("/" "" #:include ()))))
+    (home-page
+     "https://github.com/newren/git-filter-repo")
+    (synopsis
+     "Quickly rewrite Git repository history")
+    (description
+     "git filter-repo is a versatile tool for rewriting history, which roughly falls into the same space of tool like git filter-branch but with more capabilities. git filter-repo is now recommended by the Git project instead of git filter-branch.")
+    (license (list license:expat ;; Main license.
+                   license:gpl2)))) ;; For test harness.
-- 
2.31.1





Reply sent to Ludovic Courtès <ludo <at> gnu.org>:
You have taken responsibility. (Mon, 03 May 2021 20:48:01 GMT) Full text and rfc822 format available.

Notification sent to François J <francois-oss <at> avalenn.eu>:
bug acknowledged by developer. (Mon, 03 May 2021 20:48:01 GMT) Full text and rfc822 format available.

Message #22 received at 47968-done <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: François J <francois-oss <at> avalenn.eu>
Cc: 47968-done <at> debbugs.gnu.org
Subject: Re: bug#47968: [PATCH 0/2] Add git-filter-repo
Date: Mon, 03 May 2021 22:46:46 +0200
François J <francois-oss <at> avalenn.eu> skribis:

> I use release tarball (instead of git as I would have liked) because it
> contains pre-compiled man-pages which are too hard to build in this
> context as it uses git Makefile to do it.
>
> * gnu/packages/version-control.scm (git-filter-repo): New variable.
>
> Signed-off-by: François J <francois-oss <at> avalenn.eu>

Applied with minor changes: addressing remaining ‘guix lint’ complaints,
tweaking indentation, and adding ‘python’ as an input so that the
shebang of ‘git-filter-repo’ gets patched (otherwise it’d remain
“#!/usr/bin/env python3”.)

Thanks!

Ludo’.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 01 Jun 2021 11:24:11 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 329 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.