1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
3 ;;; Copyright © 2013 Cyril Roelandt <tipecaml@gmail.com>
4 ;;; Copyright © 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès <ludo@gnu.org>
5 ;;; Copyright © 2013, 2014 Andreas Enge <andreas@enge.fr>
6 ;;; Copyright © 2015, 2016 Mathieu Lirzin <mthl@gnu.org>
7 ;;; Copyright © 2014, 2015, 2016 Mark H Weaver <mhw@netris.org>
8 ;;; Copyright © 2014, 2016, 2019 Eric Bavier <bavier@member.fsf.org>
9 ;;; Copyright © 2015, 2016, 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
10 ;;; Copyright © 2015, 2018 Kyle Meyer <kyle@kyleam.com>
11 ;;; Copyright © 2015, 2017, 2018, 2020 Ricardo Wurmus <rekado@elephly.net>
12 ;;; Copyright © 2016, 2017 Leo Famulari <leo@famulari.name>
13 ;;; Copyright © 2016, 2017, 2018 ng0 <ng0@n0.is>
14 ;;; Copyright © 2017, 2018, 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
15 ;;; Copyright © 2017 Vasile Dumitrascu <va511e@yahoo.com>
16 ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
17 ;;; Copyright © 2017 André <eu@euandre.org>
18 ;;; Copyright © 2017, 2018, 2020 Marius Bakke <mbakke@fastmail.com>
19 ;;; Copyright © 2017 Stefan Reichör <stefan@xsteve.at>
20 ;;; Copyright © 2017 Oleg Pykhalov <go.wigust@gmail.com>
21 ;;; Copyright © 2018 Sou Bunnbu <iyzsong@member.fsf.org>
22 ;;; Copyright © 2018 Christopher Baines <mail@cbaines.net>
23 ;;; Copyright © 2018 Timothy Sample <samplet@ngyro.com>
24 ;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
25 ;;; Copyright © 2019 Jovany Leandro G.C <bit4bit@riseup.net>
26 ;;; Copyright © 2019 Kei Kebreau <kkebreau@posteo.net>
27 ;;; Copyright © 2019 Alex Griffin <a@ajgrf.com>
28 ;;; Copyright © 2020 Roel Janssen <roel@gnu.org>
29 ;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
31 ;;; This file is part of GNU Guix.
33 ;;; GNU Guix is free software; you can redistribute it and/or modify it
34 ;;; under the terms of the GNU General Public License as published by
35 ;;; the Free Software Foundation; either version 3 of the License, or (at
36 ;;; your option) any later version.
38 ;;; GNU Guix is distributed in the hope that it will be useful, but
39 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
40 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
41 ;;; GNU General Public License for more details.
43 ;;; You should have received a copy of the GNU General Public License
44 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
46 (define-module (gnu packages version-control)
47 #:use-module ((guix licenses) #:prefix license:)
48 #:use-module (guix utils)
49 #:use-module (guix packages)
50 #:use-module (guix download)
51 #:use-module (guix git-download)
52 #:use-module (guix build-system cmake)
53 #:use-module (guix build-system gnu)
54 #:use-module (guix build-system go)
55 #:use-module (guix build-system python)
56 #:use-module (guix build-system trivial)
57 #:use-module (gnu packages apr)
58 #:use-module (gnu packages autotools)
59 #:use-module (gnu packages documentation)
60 #:use-module (gnu packages base)
61 #:use-module (gnu packages bash)
62 #:use-module (gnu packages bison)
63 #:use-module (gnu packages boost)
64 #:use-module (gnu packages check)
65 #:use-module (gnu packages cook)
66 #:use-module (gnu packages curl)
67 #:use-module (gnu packages docbook)
68 #:use-module (gnu packages ed)
69 #:use-module (gnu packages file)
70 #:use-module (gnu packages flex)
71 #:use-module (gnu packages gettext)
72 #:use-module (gnu packages gl)
73 #:use-module (gnu packages groff)
74 #:use-module (gnu packages guile)
75 #:use-module (gnu packages image)
76 #:use-module (gnu packages linux)
77 #:use-module (gnu packages mail)
78 #:use-module (gnu packages maths)
79 #:use-module (gnu packages nano)
80 #:use-module (gnu packages ncurses)
81 #:use-module (gnu packages ssh)
82 #:use-module (gnu packages web)
83 #:use-module (gnu packages openstack)
84 #:use-module (gnu packages pcre)
85 #:use-module (gnu packages perl)
86 #:use-module (gnu packages perl-check)
87 #:use-module (gnu packages pkg-config)
88 #:use-module (gnu packages python)
89 #:use-module (gnu packages python-web)
90 #:use-module (gnu packages python-xyz)
91 #:use-module (gnu packages readline)
92 #:use-module (gnu packages rsync)
93 #:use-module (gnu packages sqlite)
94 #:use-module (gnu packages admin)
95 #:use-module (gnu packages xml)
96 #:use-module (gnu packages emacs)
97 #:use-module (gnu packages compression)
98 #:use-module (gnu packages sdl)
99 #:use-module (gnu packages swig)
100 #:use-module (gnu packages sync)
101 #:use-module (gnu packages tcl)
102 #:use-module (gnu packages textutils)
103 #:use-module (gnu packages time)
104 #:use-module (gnu packages tls)
105 #:use-module (gnu packages)
106 #:use-module (ice-9 match)
107 #:use-module (srfi srfi-1))
109 (define-public bazaar
116 (uri (string-append "https://launchpad.net/bzr/"
117 (version-major+minor version) "/" version
118 "/+download/bzr-" version ".tar.gz"))
119 (patches (search-patches "bazaar-CVE-2017-14176.patch"))
122 "1cysix5k3wa6y7jjck3ckq3abls4gvz570s0v0hxv805nwki4i8d"))))
123 (build-system python-build-system)
125 ;; Note: 'tools/packaging/lp-upload-release' and 'tools/weavemerge.sh'
127 `(("gettext" ,gettext-minimal)))
129 `(#:tests? #f ; no test target
130 #:python ,python-2 ; Python 3 apparently not yet supported, see
131 ; https://answers.launchpad.net/bzr/+question/229048
133 (modify-phases %standard-phases
134 (add-after 'unpack 'fix-mandir
136 (substitute* "setup.py"
137 (("man/man1") "share/man/man1"))
139 (home-page "https://gnu.org/software/bazaar")
140 (synopsis "Version control system supporting both distributed and centralized workflows")
142 "GNU Bazaar is a version control system that allows you to record
143 changes to project files over time. It supports both a distributed workflow
144 as well as the classic centralized workflow.")
145 (license license:gpl2+)))
147 (define git-cross-configure-flags
148 '("ac_cv_fread_reads_directories=yes"
149 "ac_cv_snprintf_returns_bogus=no"))
154 ;; XXX When updating Git, check if the special 'git-source' input to cgit
155 ;; needs to be updated as well.
159 (uri (string-append "mirror://kernel.org/software/scm/git/git-"
163 "09lzwa183nblr6l8ib35g2xrjf9wm9yhk3szfvyzkwivdv69c9r2"))))
164 (build-system gnu-build-system)
166 `(("native-perl" ,perl)
167 ;; Add bash-minimal explicitly to ensure it comes before bash-for-tests,
168 ;; see <https://bugs.gnu.org/39513>.
169 ("bash" ,bash-minimal)
170 ("bash-for-tests" ,bash)
171 ("gettext" ,gettext-minimal)
176 "mirror://kernel.org/software/scm/git/git-manpages-"
180 "15pfm7j4wq8ryp9n9d81h8v0arl15yq9i6cigw45walnq5r6721h"))))
181 ;; For subtree documentation.
182 ("asciidoc" ,asciidoc-py3)
183 ("docbook-xsl" ,docbook-xsl)
190 ("python" ,python) ; for git-p4
193 ;; For PCRE support in git grep (USE_LIBPCRE2).
197 ("perl-cgi" ,perl-cgi)
200 ("subversion" ,subversion)
201 ("perl-term-readkey" ,perl-term-readkey)
203 ;; For 'git-send-email'.
204 ("perl-authen-sasl" ,perl-authen-sasl)
205 ("perl-net-smtp-ssl" ,perl-net-smtp-ssl)
206 ("perl-io-socket-ssl" ,perl-io-socket-ssl)
208 ;; For 'git gui', 'gitk', and 'git citool'.
211 (outputs '("out" ; the core
212 "send-email" ; for git-send-email
214 "credential-netrc" ; git-credential-netrc
215 "subtree" ; git-subtree
216 "gui")) ; gitk, git gui
218 `(#:make-flags `("V=1" ;more verbose compilation
220 ,(string-append "SHELL_PATH="
221 (assoc-ref %build-inputs "bash")
224 ;; Tests require a bash with completion support.
225 ,(string-append "TEST_SHELL_PATH="
226 (assoc-ref %build-inputs "bash-for-tests")
231 ;; By default 'make install' creates hard links for
232 ;; things in 'libexec/git-core', which leads to huge
233 ;; nars; see <https://bugs.gnu.org/21949>.
234 "NO_INSTALL_HARDLINKS=indeed")
236 ;; Make sure the full bash does not end up in the final closure.
237 #:disallowed-references (,bash)
241 ;; Tests fail randomly when parallel: <https://bugs.gnu.org/29512>.
244 ;; The explicit --with-tcltk forces the build system to hardcode the
245 ;; absolute file name to 'wish'.
246 #:configure-flags (list (string-append "--with-tcltk="
247 (assoc-ref %build-inputs "tk")
248 "/bin/wish8.6") ; XXX
249 ,@(if (%current-target-system)
250 git-cross-configure-flags
253 #:modules ((srfi srfi-1)
255 ,@%gnu-build-system-modules)
257 (modify-phases %standard-phases
258 (add-after 'unpack 'modify-PATH
259 (lambda* (#:key inputs #:allow-other-keys)
260 (let ((path (string-split (getenv "PATH") #\:))
261 (bash-full (assoc-ref inputs "bash-for-tests")))
262 ;; Drop the test bash from PATH so that (which "sh") and
263 ;; similar does the right thing.
264 (setenv "PATH" (string-join
265 (remove (cut string-prefix? bash-full <>) path)
268 ;; Add cross curl-config script to PATH when cross-compiling.
269 ,@(if (%current-target-system)
270 '((add-before 'configure 'add-cross-curl-config
271 (lambda* (#:key inputs #:allow-other-keys)
273 (string-append (assoc-ref inputs "curl") "/bin:"
277 (add-after 'configure 'patch-makefiles
279 (substitute* "Makefile"
280 (("/usr/bin/perl") (which "perl"))
281 (("/usr/bin/python") (which "python3")))
283 (add-after 'configure 'add-PM.stamp
285 ;; Add the "PM.stamp" to avoid "no rule to make target".
286 (call-with-output-file "perl/PM.stamp" (const #t))
288 (add-after 'build 'build-subtree
289 (lambda* (#:key inputs #:allow-other-keys)
290 (with-directory-excursion "contrib/subtree"
291 (substitute* "Makefile"
292 ;; Apparently `xmlto' does not bother to looks up the stylesheets
293 ;; specified in the XML, unlike the above substitution. Instead it
294 ;; uses a hard-coded URL. Work around it here, but if this is
295 ;; common perhaps we should hardcode this path in xmlto itself.
296 (("\\$\\(XMLTO\\) -m \\$\\(MANPAGE_XSL\\) man")
297 (string-append "$(XMLTO) -x "
298 (string-append (assoc-ref inputs "docbook-xsl")
299 "/xml/xsl/docbook-xsl-"
300 ,(package-version docbook-xsl))
301 "/manpages/docbook.xsl -m $(MANPAGE_XSL) man")))
303 (invoke "make" "install")
304 (invoke "make" "install-doc")
305 (substitute* "git-subtree"
306 (("/bin/sh") (which "sh"))))
308 (add-before 'check 'patch-tests
310 (let ((store-directory (%store-directory)))
311 ;; These files contain some funny bytes that Guile is unable
312 ;; to decode for shebang patching. Just delete them.
313 (for-each delete-file '("t/t4201-shortlog.sh"
314 "t/t7813-grep-icase-iso.sh"))
315 ;; Many tests contain inline shell scripts (hooks etc).
316 (substitute* (find-files "t" "\\.sh$")
317 (("#!/bin/sh") (string-append "#!" (which "sh"))))
318 ;; Un-do shebang patching here to prevent checksum mismatch.
319 (substitute* '("t/t4034/perl/pre" "t/t4034/perl/post")
320 (("^#!.*/bin/perl") "#!/usr/bin/perl"))
321 (substitute* "t/t5003-archive-zip.sh"
322 (("cp /bin/sh") (string-append "cp " (which "sh"))))
323 (substitute* "t/t6030-bisect-porcelain.sh"
324 (("\"/bin/sh\"") (string-append "\"" (which "sh") "\"")))
325 ;; FIXME: This test runs `git commit` with a bogus EDITOR
326 ;; and empty commit message, but does not fail the way it's
327 ;; expected to. The test passes when invoked interactively.
328 (substitute* "t/t7508-status.sh"
329 (("\tcommit_template_commented") "\ttrue"))
330 ;; More checksum mismatches due to odd shebangs.
331 (substitute* "t/t9100-git-svn-basic.sh"
332 (((string-append "\"#!" store-directory ".*/bin/sh")) "\"#!/bin/sh") )
333 (substitute* "t/t9300-fast-import.sh"
334 (((string-append "\t#!" store-directory ".*/bin/sh")) "\t#!/bin/sh")
335 (((string-append "'#!" store-directory ".*/bin/sh")) "'#!/bin/sh"))
336 ;; FIXME: Some hooks fail with "basename: command not found".
337 ;; See 't/trash directory.t9164.../svn-hook.log'.
338 (delete-file "t/t9164-git-svn-dcommit-concurrent.sh")
340 ;; XXX: These tests fail intermittently for unknown reasons:
341 ;; <https://bugs.gnu.org/29546>.
342 (for-each delete-file
343 '("t/t9128-git-svn-cmd-branch.sh"
344 "t/t9167-git-svn-cmd-branch-subproject.sh"
345 "t/t9141-git-svn-multiple-branches.sh"))
347 (add-after 'install 'install-shell-completion
348 (lambda* (#:key outputs #:allow-other-keys)
349 (let* ((out (assoc-ref outputs "out"))
350 (completions (string-append out "/etc/bash_completion.d")))
351 ;; TODO: Install the tcsh and zsh completions in the right place.
352 (mkdir-p completions)
353 (copy-file "contrib/completion/git-completion.bash"
354 (string-append completions "/git"))
356 (add-after 'install 'install-credential-netrc
357 (lambda* (#:key outputs #:allow-other-keys)
358 (let* ((netrc (assoc-ref outputs "credential-netrc")))
359 (install-file "contrib/credential/netrc/git-credential-netrc"
360 (string-append netrc "/bin"))
361 ;; Previously, Git.pm was automatically found by netrc.
362 ;; Perl 5.26 changed how it locates modules so that @INC no
363 ;; longer includes the current working directory (the Perl
364 ;; community calls this "dotless @INC").
365 (wrap-program (string-append netrc "/bin/git-credential-netrc")
366 `("PERL5LIB" ":" prefix
367 (,(string-append (assoc-ref outputs "out") "/share/perl5"))))
369 (add-after 'install 'install-subtree
370 (lambda* (#:key outputs #:allow-other-keys)
371 (let ((subtree (assoc-ref outputs "subtree")))
372 (install-file "contrib/subtree/git-subtree"
373 (string-append subtree "/bin"))
374 (install-file "contrib/subtree/git-subtree.1"
375 (string-append subtree "/share/man/man1"))
377 (add-after 'install 'split
378 (lambda* (#:key inputs outputs #:allow-other-keys)
379 ;; Split the binaries to the various outputs.
380 (let* ((out (assoc-ref outputs "out"))
381 (se (assoc-ref outputs "send-email"))
382 (svn (assoc-ref outputs "svn"))
383 (gui (assoc-ref outputs "gui"))
384 (gitk (string-append out "/bin/gitk"))
385 (gitk* (string-append gui "/bin/gitk"))
386 (git-gui (string-append out "/libexec/git-core/git-gui"))
387 (git-gui* (string-append gui "/libexec/git-core/git-gui"))
388 (git-cit (string-append out "/libexec/git-core/git-citool"))
389 (git-cit* (string-append gui "/libexec/git-core/git-citool"))
390 (git-se (string-append out "/libexec/git-core/git-send-email"))
391 (git-se* (string-append se "/libexec/git-core/git-send-email"))
392 (git-svn (string-append out "/libexec/git-core/git-svn"))
393 (git-svn* (string-append svn "/libexec/git-core/git-svn"))
394 (git-sm (string-append out
395 "/libexec/git-core/git-submodule")))
396 (mkdir-p (string-append gui "/bin"))
397 (mkdir-p (string-append gui "/libexec/git-core"))
398 (mkdir-p (string-append se "/libexec/git-core"))
399 (mkdir-p (string-append svn "/libexec/git-core"))
401 (for-each (lambda (old new)
405 (list gitk git-gui git-cit git-se git-svn)
406 (list gitk* git-gui* git-cit* git-se* git-svn*))
408 ;; Tell 'git-svn' where Subversion and perl-term-readkey are.
409 (wrap-program git-svn*
411 (,(string-append (assoc-ref inputs "subversion")
413 `("PERL5LIB" ":" prefix
414 ,(map (lambda (i) (string-append (assoc-ref inputs i)
415 "/lib/perl5/site_perl"))
416 '("subversion" "perl-term-readkey")))
418 ;; XXX: The .so for SVN/Core.pm lacks a RUNPATH, so
419 ;; help it find 'libsvn_client-1.so'.
420 `("LD_LIBRARY_PATH" ":" prefix
421 (,(string-append (assoc-ref inputs "subversion")
424 ;; Tell 'git-send-email' where perl modules are.
425 (wrap-program git-se*
426 `("PERL5LIB" ":" prefix
427 ,(map (lambda (o) (string-append o "/lib/perl5/site_perl"))
429 ,@(transitive-input-references
432 (assoc l (package-inputs this-package)))
435 "perl-io-socket-ssl")))))))
437 ;; Tell 'gitweb.cgi' where perl modules are.
438 (wrap-program (string-append out "/share/gitweb/gitweb.cgi")
439 `("PERL5LIB" ":" prefix
440 ,(map (lambda (o) (string-append o "/lib/perl5/site_perl"))
442 ,@(transitive-input-references
445 (assoc l (package-inputs this-package)))
448 ;; Tell 'git-submodule' where Perl is.
451 (,(string-append (assoc-ref inputs "perl")
455 (add-after 'split 'install-man-pages
456 (lambda* (#:key inputs outputs #:allow-other-keys)
457 (let* ((out (assoc-ref outputs "out"))
458 (man (string-append out "/share/man"))
459 (manpages (assoc-ref inputs "git-manpages")))
461 (with-directory-excursion man
462 (invoke "tar" "xvf" manpages))))))))
465 ;; For HTTPS access, Git needs a single-file certificate bundle, specified
466 ;; with $GIT_SSL_CAINFO.
467 (list (search-path-specification
468 (variable "GIT_SSL_CAINFO")
470 (separator #f) ;single entry
471 (files '("etc/ssl/certs/ca-certificates.crt")))
472 (search-path-specification
473 (variable "GIT_EXEC_PATH")
474 (separator #f) ;single entry
475 (files '("libexec/git-core")))))
477 (synopsis "Distributed version control system")
479 "Git is a free distributed version control system designed to handle
480 everything from small to very large projects with speed and efficiency.")
481 (license license:gpl2)
482 (home-page "https://git-scm.com/")))
484 (define-public git-minimal
485 ;; The size of the closure of 'git-minimal' is two thirds that of 'git'.
486 ;; Its test suite runs slightly faster and most importantly it doesn't
487 ;; depend on packages that are expensive to build such as Subversion.
492 (substitute-keyword-arguments (package-arguments git)
494 `(modify-phases ,phases
495 (replace 'patch-makefiles
497 (substitute* "Makefile"
498 (("/usr/bin/perl") (which "perl")))
500 (delete 'build-subtree)
502 (delete 'install-man-pages)
503 (delete 'install-subtree)
504 (delete 'install-credential-netrc)
505 (add-before 'check 'delete-svn-test
507 ;; This test cannot run since we are not building 'git-svn'.
508 (delete-file "t/t9020-remote-svn.sh")
510 (add-after 'install 'remove-unusable-perl-commands
511 (lambda* (#:key outputs #:allow-other-keys)
512 (let* ((out (assoc-ref outputs "out"))
513 (bin (string-append out "/bin"))
514 (libexec (string-append out "/libexec")))
515 (for-each (lambda (file)
516 (delete-file (string-append libexec
518 '("git-svn" "git-cvsimport" "git-archimport"
519 "git-cvsserver" "git-request-pull"
520 "git-add--interactive" "git-cvsexportcommit"
521 "git-instaweb" "git-send-email"))
522 (delete-file (string-append bin "/git-cvsserver"))
524 ;; These templates typically depend on Perl. Remove them.
525 (delete-file-recursively
526 (string-append out "/share/git-core/templates/hooks"))
528 ;; Gitweb depends on Perl as well.
529 (delete-file-recursively
530 (string-append out "/share/gitweb"))
532 ((#:make-flags flags)
533 `(delete "USE_LIBPCRE2=yes" ,flags))
534 ((#:configure-flags flags)
536 ,@(if (%current-target-system)
537 git-cross-configure-flags
539 ((#:disallowed-references lst '())
543 `(("bash" ,bash-minimal)
544 ("bash-for-tests" ,bash)
545 ("native-perl" ,perl)
546 ("gettext" ,gettext-minimal)))
548 `(("curl" ,curl) ;for HTTP(S) access
549 ("expat" ,expat) ;for 'git push' over HTTP(S)
554 (define-public libgit2
561 (url "https://github.com/libgit2/libgit2.git")
562 (commit (string-append "v" version))))
563 (file-name (git-file-name name version))
566 "0qxzv49ip378g1n7hrbifb9c6pys2kj1hnxcafmbb94gj3pgd9kg"))
567 (patches (search-patches "libgit2-mtime-0.patch"))
569 ;; Remove bundled software. Keep "http-parser" because it
570 ;; contains patches that are not available in the system version.
572 (with-directory-excursion "deps"
573 (for-each (lambda (dir)
574 (delete-file-recursively dir))
575 (lset-difference equal?
577 '("." ".." "http-parser"))))
579 (modules '((guix build utils)
582 (build-system cmake-build-system)
583 (outputs '("out" "debug"))
586 (list "-DUSE_NTLMCLIENT=OFF" ;TODO: package this
587 "-DREGEX_BACKEND=pcre2"
588 ,@(if (%current-target-system)
590 "-DPKG_CONFIG_EXECUTABLE="
591 (assoc-ref %build-inputs "pkg-config")
592 "/bin/" ,(%current-target-system) "-pkg-config"))
595 (modify-phases %standard-phases
596 (add-after 'unpack 'fix-pcre2-reference
598 ;; Use PCRE2 with 8-bit character support, as there is no "libpcre2.pc".
599 ;; See <https://github.com/libgit2/libgit2/issues/5438>.
600 (substitute* "src/CMakeLists.txt"
604 (add-after 'unpack 'fix-hardcoded-paths
606 (substitute* "tests/repo/init.c"
607 (("#!/bin/sh") (string-append "#!" (which "sh"))))
608 (substitute* "tests/clar/fs.h"
609 (("/bin/cp") (which "cp"))
610 (("/bin/rm") (which "rm")))
612 (add-after 'unpack 'make-git-checkout-writable
614 (for-each make-file-writable (find-files "."))
616 ;; Run checks more verbosely, unless we are cross-compiling.
618 (lambda* (#:key (tests? #t) #:allow-other-keys)
620 (invoke "./libgit2_clar" "-v" "-Q")
621 ;; Tests may be disabled if cross-compiling.
622 (format #t "Test suite not run.~%")))))))
624 `(("libssh2" ,libssh2)))
626 `(("pkg-config" ,pkg-config)
629 ;; These libraries are in 'Requires.private' in libgit2.pc.
630 `(("openssl" ,openssl)
633 (home-page "https://libgit2.github.com/")
634 (synopsis "Library providing Git core methods")
636 "Libgit2 is a portable, pure C implementation of the Git core methods
637 provided as a re-entrant linkable library with a solid API, allowing you to
638 write native speed custom Git applications in any language with bindings.")
639 ;; GPLv2 with linking exception
640 (license license:gpl2)))
642 (define-public git-crypt
650 (url "https://github.com/AGWA/git-crypt.git")
652 (file-name (git-file-name name version))
654 (base32 "1ba5s0fvmd9hhnfhfsjrm40v0qpxfnwc8vmm55m0k4dryzkzx66q"))))
655 (build-system gnu-build-system)
658 ("openssl" ,openssl)))
660 `(("docbook-xsl" ,docbook-xsl)
661 ("libxslt" ,libxslt)))
663 `(#:tests? #f ; No tests.
665 (modify-phases %standard-phases
667 (add-after 'unpack 'patch-makefile
668 (lambda* (#:key inputs #:allow-other-keys)
669 (substitute* "Makefile"
670 (("http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl")
671 (string-append (assoc-ref inputs "docbook-xsl")
672 "/xml/xsl/docbook-xsl-"
673 ,(package-version docbook-xsl)
674 "/manpages/docbook.xsl")))
678 (invoke "make" "ENABLE_MAN=yes")))
680 (lambda* (#:key outputs #:allow-other-keys)
681 (let ((out (assoc-ref outputs "out")))
682 (invoke "make" "install"
684 (string-append "PREFIX=" out))))))))
685 (home-page "https://www.agwa.name/projects/git-crypt/")
686 (synopsis "Transparent encryption of files in a git repository")
687 (description "git-crypt enables transparent encryption and decryption of
688 files in a git repository. Files which you choose to protect are encrypted when
689 committed, and decrypted when checked out. git-crypt lets you freely share a
690 repository containing a mix of public and private content. git-crypt gracefully
691 degrades, so developers without the secret key can still clone and commit to a
692 repository with encrypted files. This lets you store your secret material (such
693 as keys or passwords) in the same repository as your code, without requiring you
694 to lock down your entire repository.")
695 (license license:gpl3+)))
697 (define-public git-remote-gcrypt
699 (name "git-remote-gcrypt")
704 (url "https://git.spwhitton.name/git-remote-gcrypt")
706 (file-name (string-append name "-" version "-checkout"))
709 "1vay3204729c7wajgn3nxf0s0hzwpdrw14pl6kd8w2ss25gvw2k1"))))
710 (build-system trivial-build-system)
712 `(#:modules ((guix build utils))
714 (use-modules (guix build utils))
715 (let* ((source (assoc-ref %build-inputs "source"))
716 (output (assoc-ref %outputs "out"))
717 (bindir (string-append output "/bin")))
718 (install-file (string-append source "/git-remote-gcrypt")
721 (home-page "https://spwhitton.name/tech/code/git-remote-gcrypt/")
722 (synopsis "Whole remote repository encryption")
723 (description "git-remote-gcrypt is a Git remote helper to push and pull from
724 repositories encrypted with GnuPG. It works with the standard Git transports,
725 including repository hosting services like GitLab.
727 Remote helper programs are invoked by Git to handle network transport. This
728 helper handles @code{gcrypt:} URLs that access a remote repository encrypted
729 with GPG, using our custom format.
731 Supported locations are local, @code{rsync://} and @code{sftp://}, where the
732 repository is stored as a set of files, or instead any Git URL where gcrypt
733 will store the same representation in a Git repository, bridged over arbitrary
736 The aim is to provide confidential, authenticated Git storage and
737 collaboration using typical untrusted file hosts or services.")
738 (license license:gpl3+)))
743 ;; Update the ‘git-source’ input as well.
748 "https://git.zx2c4.com/cgit/snapshot/cgit-"
752 "0dmjsisigjz5k4gw7gm55qhm3wazzbm4cg7a5dwf0gqg9nacx5rz"))))
753 (build-system gnu-build-system)
755 '(#:tests? #f ; XXX: fail to build the in-source git.
757 #:make-flags '("CC=gcc" "SHELL_PATH=sh")
759 (modify-phases %standard-phases
760 (add-after 'unpack 'unpack-git
761 (lambda* (#:key inputs #:allow-other-keys)
762 ;; Unpack the source of git into the 'git' directory.
763 (invoke "tar" "--strip-components=1" "-C" "git" "-xf"
764 (assoc-ref inputs "git-source"))))
765 (add-after 'unpack 'patch-absolute-file-names
766 (lambda* (#:key inputs #:allow-other-keys)
767 (define (quoted-file-name input path)
768 (string-append "\"" input path "\""))
769 (substitute* "ui-snapshot.c"
771 (quoted-file-name (assoc-ref inputs "gzip") "/bin/gzip"))
773 (quoted-file-name (assoc-ref inputs "bzip2") "/bin/bzip2"))
775 (quoted-file-name (assoc-ref inputs "xz") "/bin/xz")))
777 (substitute* "filters/about-formatting.sh"
778 (("$\\(dirname $0\\)") (string-append (assoc-ref outputs "out")
779 "/lib/cgit/filters"))
780 (("\\| tr") (string-append "| " (which "tr"))))
782 (substitute* "filters/html-converters/txt2html"
783 (("sed") (which "sed")))
785 (substitute* "filters/html-converters/man2html"
786 (("groff") (which "groff")))
788 (substitute* "filters/html-converters/rst2html"
789 (("rst2html\\.py") (which "rst2html.py")))
792 (delete 'configure) ; no configure script
793 (add-after 'build 'build-man
794 (lambda* (#:key make-flags #:allow-other-keys)
795 (apply invoke "make" "doc-man" make-flags)))
797 (lambda* (#:key make-flags outputs #:allow-other-keys)
798 (let ((out (assoc-ref outputs "out")))
800 "make" "install" "install-man"
801 (string-append "prefix=" out)
802 (string-append "CGIT_SCRIPT_PATH=" out "/share/cgit")
804 ;; Move the platform-dependent 'cgit.cgi' into lib to get it
806 (rename-file (string-append out "/share/cgit/cgit.cgi")
807 (string-append out "/lib/cgit/cgit.cgi"))
809 (add-after 'install 'wrap-python-scripts
810 (lambda* (#:key outputs #:allow-other-keys)
813 (wrap-program (string-append (assoc-ref outputs "out")
814 "/lib/cgit/filters/" file)
815 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH")))))
816 '("syntax-highlighting.py"
817 "html-converters/md2html"))
820 ;; For building manpage.
821 `(("asciidoc" ,asciidoc)
826 `(;; Building cgit requires a Git source tree.
830 ;; cgit is tightly bound to git. Use GIT_VER from the Makefile,
831 ;; which may not match the current (package-version git).
832 (uri "mirror://kernel.org/software/scm/git/git-2.25.0.tar.xz")
834 (base32 "1l58v42aazj0x9276gk8r9mwyl9pgp9w99aakz4xfhzv7wd2jq60"))))
838 ("python-docutils" ,python-docutils)
839 ("python-markdown" ,python-markdown)
840 ("python-pygments" ,python-pygments)
842 (home-page "https://git.zx2c4.com/cgit/")
843 (synopsis "Web frontend for git repositories")
845 "CGit is an attempt to create a fast web interface for the Git SCM, using
846 a built-in cache to decrease server I/O pressure.")
847 (license license:gpl2)))
849 (define-public python-git-multimail
851 (name "python-git-multimail")
852 (version "1.5.0.post1")
856 (uri (pypi-uri "git-multimail" version))
859 "1zkrbsa70anwpw86ysfwalrb7nsr064kygfiyikyq1pl9pcl969y"))))
860 (build-system python-build-system)
863 (modify-phases %standard-phases
864 (add-after 'unpack 'patch
865 (lambda* (#:key inputs #:allow-other-keys)
866 (substitute* "git-multimail/git_multimail.py"
867 (("GIT_EXECUTABLE = 'git'")
868 (string-append "GIT_EXECUTABLE = '"
869 (assoc-ref inputs "git") "/bin/git"
871 (("/usr/sbin/sendmail")
872 (string-append (assoc-ref inputs "sendmail")
873 "/usr/sbin/sendmail")))
877 ("sendmail" ,sendmail)))
878 (home-page "https://github.com/git-multimail/git-multimail")
879 (synopsis "Send notification emails for Git pushes")
881 "This hook sends emails describing changes introduced by pushes to a Git
882 repository. For each reference that was changed, it emits one ReferenceChange
883 email summarizing how the reference was changed, followed by one Revision
884 email for each new commit that was introduced by the reference change.
886 This script is designed to be used as a post-receive hook in a Git
888 (license license:gpl2)))
890 (define-public python-ghp-import
892 (name "python-ghp-import")
898 (url "https://github.com/davisp/ghp-import.git")
900 (file-name (git-file-name name version))
902 (base32 "12pmw3zz3i57ljnm0rxdyjqdyhisbvy18mjwkb3bzp5pgzs2f45c"))))
903 (build-system python-build-system)
905 `(#:phases (modify-phases %standard-phases
906 (add-after 'install 'install-documentation
907 (lambda* (#:key outputs #:allow-other-keys)
908 (let* ((out (assoc-ref outputs "out"))
909 (doc (string-append out "/share/doc"))
910 (licenses (string-append out "/share/licenses")))
911 (install-file "README.md" doc)
912 (install-file "LICENSE" licenses)))))))
913 (home-page "https://github.com/davisp/ghp-import")
914 (synopsis "Copy directory to the gh-pages branch")
915 (description "Script that copies a directory to the gh-pages branch (by
916 default) of the repository.")
918 ;; See <https://bugs.gnu.org/27913>.
919 (license (license:non-copyleft
920 "https://raw.githubusercontent.com/davisp/ghp-import/master/LICENSE"
921 "Tumbolia Public License"))))
923 (define-public python2-ghp-import
924 (package-with-python2
925 (strip-python2-variant python-ghp-import)))
927 (define-public python-gitdb
929 (name "python-gitdb")
933 (uri (pypi-uri "gitdb" version))
936 "0l113fphn6msjl3cl3kyf332b6lal7daxdd0nfma0x9ipfb013jr"))))
937 (build-system python-build-system)
939 `(#:phases (modify-phases %standard-phases
940 (add-before 'check 'create-test-repository
942 (mkdir "/tmp/testrepo")
943 ;; Some tests require a git repository, so create one.
944 (with-directory-excursion "/tmp/testrepo"
945 (do ((filecount 1 (1+ filecount)))
947 (call-with-output-file (string-append
948 "file" (number->string filecount))
950 (format port "~a" filecount))))
952 (invoke "git" "init")
953 (invoke "git" "config" "user.name" "Total Git")
954 (invoke "git" "config" "user.email" "git@localhost")
955 (invoke "git" "add" "-A")
956 (invoke "git" "commit" "-q" "-m" "dummy commit")))
958 ;; The repository checkout must be a "bare" clone.
959 (invoke "git" "clone" "--bare" "/tmp/testrepo"
960 "/tmp/testrepo.git")))
963 (setenv "GITDB_TEST_GIT_REPO_BASE" "/tmp/testrepo.git")
964 ;; Skip tests that must be run from the gitdb repository.
965 (setenv "TRAVIS" "1")
966 (invoke "nosetests" "-v"))))))
968 `(("python-smmap" ,python-smmap)))
971 ("python-nose" ,python-nose)))
972 (home-page "https://github.com/gitpython-developers/gitdb")
973 (synopsis "Python implementation of the Git object database")
975 "GitDB allows you to access @dfn{bare} Git repositories for reading and
976 writing. It aims at allowing full access to loose objects as well as packs
977 with performance and scalability in mind. It operates exclusively on streams,
978 allowing to handle large objects with a small memory footprint.")
979 (license license:bsd-3)))
981 (define-public python2-gitdb
982 (package-with-python2 python-gitdb))
984 (define-public python-gitpython
986 (name "python-gitpython")
990 (uri (pypi-uri "GitPython" version))
993 "1jzllsy9lwc9yibccgv7h9naxisazx2n3zmpy21c8n5xhysw69p4"))))
994 (build-system python-build-system)
996 `(#:tests? #f ;XXX: Tests can only be run within the GitPython repository.
997 #:phases (modify-phases %standard-phases
998 (add-after 'unpack 'embed-git-reference
999 (lambda* (#:key inputs #:allow-other-keys)
1000 (substitute* "git/cmd.py"
1001 (("git_exec_name = \"git\"")
1002 (string-append "git_exec_name = \""
1003 (assoc-ref inputs "git")
1009 `(("python-gitdb" ,python-gitdb)))
1011 `(("python-ddt" ,python-ddt)
1012 ("python-nose" ,python-nose)))
1013 (home-page "https://github.com/gitpython-developers/GitPython")
1014 (synopsis "Python library for interacting with Git repositories")
1016 "GitPython is a python library used to interact with Git repositories,
1017 high-level like git-porcelain, or low-level like git-plumbing.
1019 It provides abstractions of Git objects for easy access of repository data,
1020 and additionally allows you to access the Git repository more directly using
1021 either a pure Python implementation, or the faster, but more resource intensive
1022 @command{git} command implementation.")
1023 (license license:bsd-3)))
1025 (define-public python2-gitpython
1026 (package-with-python2 python-gitpython))
1028 (define-public shflags
1035 (url "https://github.com/kward/shflags.git")
1036 (commit (string-append "v" version))))
1037 (file-name (git-file-name name version))
1040 "1ydx0sb6vz9s2dgp5bd64y7fpzh9qvmlfjxrbmzac8saknijrlly"))))
1041 (build-system gnu-build-system)
1043 `(#:tests? #f ; no tests
1045 (modify-phases %standard-phases
1046 (delete 'configure) ; nothing to configure
1047 (delete 'build) ; nothing to build
1049 (lambda* (#:key outputs #:allow-other-keys)
1050 (let* ((out (assoc-ref outputs "out"))
1051 (src (string-append out "/src")))
1052 (install-file "shflags" src)
1054 (home-page "https://github.com/kward/shflags")
1055 (synopsis "Command-line flags library for shell scripts")
1057 "Shell Flags (shFlags) is a library written to greatly simplify the
1058 handling of command-line flags in Bourne based Unix shell scripts (bash, dash,
1059 ksh, sh, zsh). Most shell scripts use getopt for flags processing, but the
1060 different versions of getopt on various OSes make writing portable shell
1061 scripts difficult. shFlags instead provides an API that doesn't change across
1062 shell and OS versions so the script writer can be confident that the script
1064 (license license:lgpl2.1)))
1066 (define-public git-flow
1069 ;; This version has not be officially released yet, so we build it
1070 ;; directly from the git repository.
1075 (url "https://github.com/petervanderdoes/gitflow-avh/")
1077 (file-name (git-file-name name version))
1080 "13q4mnrxr03wz2dkhzy73j384g299m4d545cnhxcaznvdwfany4h"))))
1081 (build-system gnu-build-system)
1082 (inputs `(("shflags" ,shflags)))
1084 '(#:tests? #f ; no tests
1085 #:make-flags (list (string-append "prefix="
1086 (assoc-ref %outputs "out")))
1088 (modify-phases %standard-phases
1089 (add-after 'unpack 'reset-shFlags-link
1090 (lambda* (#:key inputs #:allow-other-keys)
1091 ;; The link points to a file in the shFlags submodule.
1092 ;; Redirect it to point to our system shFlags.
1093 (let ((shflags (assoc-ref inputs "shflags")))
1095 (delete-file "gitflow-shFlags")
1096 (symlink (string-append shflags "/src/shflags")
1097 "gitflow-shFlags")))))
1100 (home-page "http://nvie.com/posts/a-successful-git-branching-model/")
1101 (synopsis "Git extensions for Vincent Driessen's branching model")
1103 "Vincent Driessen's branching model is a git branching and release
1104 management strategy that helps developers keep track of features, hotfixes,
1105 and releases in bigger software projects. The git-flow library of git
1106 subcommands helps automate some parts of the flow to make working with it a
1108 (license license:bsd-2)))
1110 (define-public stgit
1118 (url "https://github.com/ctmarinas/stgit.git")
1119 (commit (string-append "v" version))))
1120 (file-name (git-file-name name version))
1122 (base32 "00pmz93znl418lsjwy4mr0chp8i2w27h1xjysa05f62smsv91yyc"))))
1123 (build-system python-build-system)
1130 (modify-phases %standard-phases
1131 (add-after 'unpack 'hard-code-version
1133 ;; setup.py tries to cleverly extract the version number from the
1134 ;; git history, which the source checkout lacks. Hard-code one.
1135 (substitute* "setup.py"
1137 (format #f "'~a'" ,version)))
1139 (add-before 'check 'patch-tests
1141 (substitute* (list "t/t1900-mail.sh"
1142 "t/t7504-commit-msg-hook.sh")
1150 (string-append "SHELL_PATH=" (which "bash"))
1152 (home-page "http://procode.org/stgit/")
1153 (synopsis "Stacked Git")
1155 "StGit is a command-line application that provides functionality similar
1156 to Quilt (i.e., pushing/popping patches to/from a stack), but using Git
1157 instead of @command{diff} and @command{patch}. StGit stores its patches in a
1158 Git repository as normal Git commits, and provides a number of commands to
1159 manipulate them in various ways.")
1160 (license license:gpl2)))
1165 (version "1.20151229")
1170 (url "https://github.com/RichiH/vcsh.git")
1171 (commit (string-append "v" version))))
1172 (file-name (git-file-name name version))
1174 (base32 "1grpj45nbpv4j60vd2kg4rj53zrm0bc0h9l4pfd3c2mwbvywm6ab"))))
1175 (build-system gnu-build-system)
1177 `(("which" ,which)))
1181 ("perl-test-harness" ,perl-test-harness)
1182 ("perl-shell-command" ,perl-shell-command)
1183 ("perl-test-most" ,perl-test-most)))
1185 '(#:phases (modify-phases %standard-phases
1188 #:make-flags (list (string-append "PREFIX="
1189 (assoc-ref %outputs "out")))
1190 #:test-target "test"))
1191 (home-page "https://github.com/RichiH/vcsh")
1192 (synopsis "Version control system for @code{$HOME}")
1194 "vcsh version-controls configuration files in several Git repositories,
1195 all in one single directory. They all maintain their working trees without
1196 clobbering each other or interfering otherwise. By default, all Git
1197 repositories maintained via vcsh store the actual files in @code{$HOME},
1198 though this can be overridden.")
1199 (license license:gpl2+)))
1201 (define-public git-test-sequence
1202 (let ((commit "48e5a2f5a13a5f30452647237e23362b459b9c76"))
1204 (name "git-test-sequence")
1205 (version (string-append "20140312." (string-take commit 7)))
1209 ;; There are many other scripts in this directory; we
1210 ;; are interested in just one for this package.
1211 (url "https://github.com/dustin/bindir")
1213 (file-name (git-file-name name version))
1216 "1dcq0y16yznbv4k9h8gg90kv1gkn8r8dbvl4m2rpfd7q5nqhn617"))))
1217 (build-system trivial-build-system)
1219 `(#:modules ((guix build utils))
1221 (use-modules (guix build utils))
1222 (let* ((source (assoc-ref %build-inputs "source"))
1223 (output (assoc-ref %outputs "out"))
1224 (bindir (string-append output "/bin"))
1225 (script "git-test-sequence"))
1226 (install-file (string-append source "/" script)
1229 (home-page "http://dustin.sallings.org/2010/03/28/git-test-sequence.html")
1230 (synopsis "Run a command over a sequence of commits")
1232 "git-test-sequence is similar to an automated git bisect except it’s
1233 linear. It will test every change between two points in the DAG. It will
1234 also walk each side of a merge and test those changes individually.")
1235 (license (license:x11-style "file://LICENSE")))))
1237 (define-public gitolite
1245 (url "https://github.com/sitaramc/gitolite.git")
1246 (commit (string-append "v" version))))
1247 (file-name (git-file-name name version))
1249 (base32 "0rmyzr66lxh2ildf3h1nh3hh2ndwk21rjdin50r5vhwbdd7jg8vb"))))
1250 (build-system gnu-build-system)
1252 '(#:tests? #f ; no tests
1253 #:phases (modify-phases %standard-phases
1256 (add-before 'install 'patch-scripts
1257 (lambda* (#:key inputs #:allow-other-keys)
1258 (let ((perl (string-append (assoc-ref inputs "perl")
1260 ;; This seems to take care of every shell script that
1262 (substitute* (find-files "." ".*")
1264 (string-append " " perl " -")))
1266 (substitute* (find-files "src/triggers" ".*")
1268 (string-append " " (which "sed") " ")))
1271 '("src/triggers/post-compile/update-gitweb-access-list"
1272 "src/triggers/post-compile/ssh-authkeys-split"
1273 "src/triggers/upstream")
1275 (string-append " " (which "grep") " ")))
1277 ;; Avoid references to the store in authorized_keys.
1278 ;; This works because gitolite-shell is in the PATH.
1279 (substitute* "src/triggers/post-compile/ssh-authkeys"
1280 (("\\$glshell \\$user")
1281 "gitolite-shell $user"))
1283 (add-before 'install 'patch-source
1284 (lambda* (#:key inputs #:allow-other-keys)
1285 ;; Gitolite uses cat to test the readability of the
1287 (substitute* "src/lib/Gitolite/Setup.pm"
1289 (string-append "\"" (which "cat") " "))
1291 (string-append "\"" (which "ssh-keygen"))))
1293 (substitute* '("src/lib/Gitolite/Hooks/PostUpdate.pm"
1294 "src/lib/Gitolite/Hooks/Update.pm")
1296 (string-append (assoc-ref inputs "perl")
1299 (substitute* "src/lib/Gitolite/Common.pm"
1301 (string-append "\"" (which "ssh-keygen")))
1304 (assoc-ref inputs "inetutils")
1309 (lambda* (#:key outputs #:allow-other-keys)
1310 (let* ((output (assoc-ref outputs "out"))
1311 (sharedir (string-append output "/share/gitolite"))
1312 (bindir (string-append output "/bin")))
1315 (invoke "./install" "-to" sharedir)
1316 ;; Create symlinks for executable scripts in /bin.
1317 (for-each (lambda (script)
1318 (symlink (string-append sharedir "/" script)
1319 (string-append bindir "/" script)))
1320 '("gitolite" "gitolite-shell"))
1322 (add-after 'install 'wrap-scripts
1323 (lambda* (#:key inputs outputs #:allow-other-keys)
1324 (let ((out (assoc-ref outputs "out"))
1325 (coreutils (assoc-ref inputs "coreutils"))
1326 (findutils (assoc-ref inputs "findutils"))
1327 (git (assoc-ref inputs "git")))
1328 (wrap-program (string-append out "/bin/gitolite")
1331 (string-append dir "/bin"))
1332 (list out coreutils findutils git))))
1336 ("coreutils" ,coreutils)
1337 ("findutils" ,findutils)
1338 ("inetutils" ,inetutils)))
1339 ;; git and openssh are propagated because trying to patch the source via
1340 ;; regexp matching is too brittle and prone to false positives.
1343 ("openssh" ,openssh)))
1344 (home-page "https://gitolite.com")
1345 (synopsis "Git access control layer")
1347 "Gitolite is an access control layer on top of Git, providing fine access
1348 control to Git repositories.")
1349 (license license:gpl2)))
1351 (define-public mercurial
1357 (uri (string-append "https://www.mercurial-scm.org/"
1358 "release/mercurial-" version ".tar.gz"))
1361 "1nbjpzjrzgql4hrvslpxwbcgn885ikq6ba1yb4w6p78rw9nzkhgp"))))
1362 (build-system python-build-system)
1365 (modify-phases %standard-phases
1366 (add-after 'unpack 'patch-tests
1368 (substitute* '("tests/test-extdiff.t"
1369 "tests/test-logtoprocess.t"
1370 "tests/test-patchbomb.t"
1371 "tests/test-run-tests.t"
1372 "tests/test-transplant.t")
1377 (lambda* (#:key tests? #:allow-other-keys)
1378 (with-directory-excursion "tests"
1379 ;; The following tests are known to fail.
1380 (for-each delete-file
1381 '(;; XXX: This test calls 'run-tests.py --with-hg=
1382 ;; `which hg`' and fails because there is no hg on
1383 ;; PATH from before (that's why we are building it!)?
1386 ;; FIXME: Why does this fail in the build container, but
1387 ;; not in 'guix environment -C' (even without /bin/sh)?
1388 "test-nointerrupt.t"
1390 ;; TODO: the fqaddr() call fails in the build
1391 ;; container, causing these server tests to fail.
1393 "test-http-branchmap.t"
1394 "test-pull-bundle.t"
1397 "test-subrepo-deep-nested-change.t"
1398 "test-subrepo-recursion.t"))
1400 (invoke "./run-tests.py"
1401 ;; ‘make check’ does not respect ‘-j’.
1402 (string-append "-j" (number->string
1403 (parallel-job-count)))
1404 ;; The default time-outs are too low for many systems.
1405 ;; Raise them generously: Guix enforces its own.
1407 "--slowtimeout" "86400"
1408 ;; The test suite takes a long time and produces little
1409 ;; output by default. Prevent timeouts due to silence.
1412 ;; The following inputs are only needed to run the tests.
1414 `(("python-nose" ,python-nose)
1417 (home-page "https://www.mercurial-scm.org/")
1418 (synopsis "Decentralized version control system")
1420 "Mercurial is a free, distributed source control management tool.
1421 It efficiently handles projects of any size
1422 and offers an easy and intuitive interface.")
1423 (license license:gpl2+)))
1431 (uri (string-append "http://www.webdav.org/neon/neon-"
1435 "1jpvczcx658vimqm7c8my2q41fnmjaf1j03g7bsli6rjxk6xh2yv"))))
1436 (build-system gnu-build-system)
1439 ("pkg-config" ,pkg-config)))
1441 `(("libxml2" ,libxml2)
1442 ("openssl" ,openssl)
1445 `(;; FIXME: Add tests once reverse address lookup is fixed in glibc, see
1446 ;; https://sourceware.org/bugzilla/show_bug.cgi?id=16475
1448 #:configure-flags '("--enable-shared"
1449 ;; requires libgnutils-config, deprecated
1451 ; "--with-ssl=gnutls")))
1452 "--with-ssl=openssl")))
1453 (home-page "http://www.webdav.org/neon/")
1454 (synopsis "HTTP and WebDAV client library")
1456 "Neon is an HTTP and WebDAV client library, with a C interface and the
1459 @item High-level wrappers for common HTTP and WebDAV operations (GET, MOVE,
1461 @item low-level interface to the HTTP request/response engine, allowing the use
1462 of arbitrary HTTP methods, headers, etc.;
1463 @item authentication support including Basic and Digest support, along with
1464 GSSAPI-based Negotiate on Unix, and SSPI-based Negotiate/NTLM on Win32;
1465 @item SSL/TLS support using OpenSSL or GnuTLS, exposing an abstraction layer for
1466 verifying server certificates, handling client certificates, and examining
1467 certificate properties, smartcard-based client certificates are also
1468 supported via a PKCS#11 wrapper interface;
1469 @item abstract interface to parsing XML using libxml2 or expat, and wrappers for
1470 simplifying handling XML HTTP response bodies;
1471 @item WebDAV metadata support, wrappers for PROPFIND and PROPPATCH to simplify
1472 property manipulation.
1474 (license license:gpl2+))) ; for documentation and tests; source under lgpl2.0+
1476 (define-public subversion
1484 (string-append "https://archive.apache.org/dist/subversion/"
1485 "subversion-" version ".tar.bz2")
1486 (string-append "https://www-eu.apache.org/dist/subversion/"
1487 "subversion-" version ".tar.bz2")))
1490 "19zc215mhpnm92mlyl5jbv57r5zqp6cavr3s2g9yglp6j4kfgj0q"))))
1491 (build-system gnu-build-system)
1493 '(#:parallel-tests? #f ; TODO Seems to cause test failures on
1495 #:configure-flags '("--enable-static=no")
1497 (modify-phases %standard-phases
1498 (add-after 'configure 'patch-libtool-wrapper-ls
1499 (lambda* (#:key inputs #:allow-other-keys)
1500 ;; This substitution allows tests svnauthz_tests and svnlook_tests
1501 ;; to pass. These tests execute svnauthz and svnlook through
1502 ;; their libtool wrapper scripts from svn hooks, whose empty
1503 ;; environments cause "ls: command not found" errors. It would be
1504 ;; nice if this fix ultimately made its way into libtool.
1505 (let ((coreutils (assoc-ref inputs "coreutils")))
1506 (substitute* "libtool"
1507 (("\\\\`ls") (string-append "\\`" coreutils "/bin/ls")))
1509 (add-before 'build 'patch-test-sh
1511 (substitute* "subversion/tests/libsvn_repos/repos-test.c"
1512 (("#!/bin/sh") (string-append "#!" (which "sh"))))
1514 (add-before 'check 'set-PARALLEL
1515 (lambda* (#:key parallel-tests? #:allow-other-keys)
1517 (setenv "PARALLEL" (number->string (parallel-job-count)))
1518 (simple-format #t "parallel-tests? are disabled\n"))
1520 (add-after 'install 'install-perl-bindings
1521 (lambda* (#:key outputs #:allow-other-keys)
1522 ;; Follow the instructions from 'subversion/bindings/swig/INSTALL'.
1523 (let ((out (assoc-ref outputs "out")))
1524 (invoke "make" "swig-pl-lib")
1525 ;; FIXME: Test failures.
1526 ;; (invoke "make" "check-swig-pl")
1527 (invoke "make" "install-swig-pl-lib")
1529 ;; Set the right installation prefix.
1530 (with-directory-excursion
1531 "subversion/bindings/swig/perl/native"
1532 (invoke "perl" "Makefile.PL"
1534 (string-append "PREFIX=" out))
1535 (invoke "make" "install"
1536 (string-append "OTHERLDFLAGS="
1540 `(("pkg-config" ,pkg-config)
1541 ;; For the Perl bindings.
1545 ("apr-util" ,apr-util)
1549 ("python" ,python-wrapper)
1551 ("utf8proc" ,utf8proc)
1553 (home-page "https://subversion.apache.org/")
1554 (synopsis "Revision control system")
1556 "@dfn{Subversion} (svn) exists to be recognized and adopted as a
1557 centralized version control system characterized by its
1558 reliability as a safe haven for valuable data; the simplicity of its model and
1559 usage; and its ability to support the needs of a wide variety of users and
1560 projects, from individuals to large-scale enterprise operations.")
1561 (license license:asl2.0)))
1569 (uri (string-append "mirror://gnu/rcs/rcs-"
1573 "1zsx7bb0rgvvvisiy4zlixf56ay8wbd9qqqcp1a1g0m1gl6mlg86"))
1574 (patches (search-patches "rcs-5.9.4-noreturn.patch"))))
1575 (build-system gnu-build-system)
1576 (native-inputs `(("ed" ,ed)))
1578 `(#:phases (modify-phases %standard-phases
1579 (add-before 'check 'disable-t810
1580 ;; See https://savannah.gnu.org/bugs/index.php?52288
1581 ;; Back-porting the fix is non-trivial, so disable for now.
1583 (substitute* "tests/Makefile"
1584 ((" t810 \\\\\n") ""))
1586 (home-page "https://www.gnu.org/software/rcs/")
1587 (synopsis "Per-file local revision control system")
1589 "RCS is the original Revision Control System. It works on a
1590 file-by-file basis, in contrast to subsequent version control systems such as
1591 CVS, Subversion, and Git. This can make it suitable for system
1592 administration files, for example, which are often inherently local to one
1594 (license license:gpl3+)))
1603 "https://ftp.gnu.org/non-gnu/cvs/source/feature/"
1604 version "/cvs-" version ".tar.bz2"))
1605 (patches (search-patches "cvs-CVE-2017-12836.patch"))
1608 "0pjir8cwn0087mxszzbsi1gyfc6373vif96cw4q3m1x6p49kd1bq"))))
1609 (build-system gnu-build-system)
1611 ;; XXX: The test suite looks flawed, and the package is obsolete anyway.
1613 #:configure-flags (list "--with-external-zlib")))
1614 (inputs `(("zlib" ,zlib)
1615 ("nano" ,nano))) ; the default editor
1616 (home-page "http://cvs.nongnu.org")
1617 (synopsis "Historical centralized version control system")
1619 "CVS is a version control system, an important component of Source
1620 Configuration Management (SCM). Using it, you can record the history of
1621 sources files, and documents. It fills a similar role to the free software
1622 RCS, PRCS, and Aegis packages.")
1623 (license license:gpl1+)))
1625 (define-public cvs-fast-export
1627 (name "cvs-fast-export")
1631 (uri (string-append "http://www.catb.org/~esr/cvs-fast-export/"
1632 "cvs-fast-export-" version ".tar.gz"))
1635 "0nn5cf8syb5nbjvkn8w561pk25clv187h4hs9pnc700g9w56chzf"))))
1636 (build-system gnu-build-system)
1639 (modify-phases %standard-phases
1640 (delete 'configure)) ; no configure script
1641 #:parallel-build? #f ; parallel a2x commands fail spectacularly
1643 (list "CC=gcc" (string-append "prefix?=" (assoc-ref %outputs "out")))))
1646 ("python" ,python-wrapper)))
1648 `(("asciidoc" ,asciidoc)
1649 ;; These are needed for the tests.
1652 (home-page "http://www.catb.org/esr/cvs-fast-export/")
1653 (synopsis "Export an RCS or CVS history as a fast-import stream")
1654 (description "This program analyzes a collection of RCS files in a CVS
1655 repository (or outside of one) and, when possible, emits an equivalent history
1656 in the form of a fast-import stream. Not all possible histories can be
1657 rendered this way; the program tries to emit useful warnings when it can't.
1659 The program can also produce a visualization of the resulting commit directed
1660 acyclic graph (DAG) in the input format of @uref{http://www.graphviz.org,
1661 Graphviz}. The package also includes @command{cvssync}, a tool for mirroring
1662 masters from remote CVS hosts.")
1663 (license license:gpl2+)))
1665 (define-public vc-dwim
1671 (uri (string-append "mirror://gnu/vc-dwim/vc-dwim-"
1675 "0mf1dd7wdqxsm4fcfinfd7iadzarmzvg747pbsbi32qpavpk8gdf"))))
1676 (build-system gnu-build-system)
1677 (inputs `(("perl" ,perl)))
1679 `(("emacs" ,emacs-minimal) ; for `ctags'
1680 ("inetutils" ,inetutils))) ; for `hostname', used in the tests
1681 (home-page "https://www.gnu.org/software/vc-dwim/")
1682 (synopsis "Version-control-agnostic ChangeLog diff and commit tool")
1684 "The vc-dwim package contains two tools, \"vc-dwim\" and \"vc-chlog\".
1685 vc-dwim is a tool that simplifies the task of maintaining a ChangeLog and
1686 using version control at the same time, for example by printing a reminder
1687 when a file change has been described in the ChangeLog but the file has not
1688 been added to the VC. vc-chlog scans changed files and generates
1689 standards-compliant ChangeLog entries based on the changes that it detects.")
1690 (license license:gpl3+)))
1692 (define-public diffstat
1700 (string-append "ftp://invisible-island.net/diffstat/"
1701 "diffstat-" version ".tgz")
1702 (string-append "http://invisible-mirror.net/archives/diffstat/"
1703 "diffstat-" version ".tgz")))
1706 "0vyw200s5dv1257pmrh6c6fdkmw3slyz5szpqfx916xr04sdbpby"))))
1707 (build-system gnu-build-system)
1708 (home-page "https://invisible-island.net/diffstat/")
1709 (synopsis "Make histograms from the output of @command{diff}")
1711 "Diffstat reads the output of @command{diff} and displays a histogram of
1712 the insertions, deletions, and modifications per file. It is useful for
1713 reviewing large, complex patch files.")
1714 (license (license:x11-style "file://COPYING"))))
1722 (uri (string-append "mirror://gnu/" name "/CSSC-"
1726 "1vsisqq573xjr2qpn19iwmpqgl3mq03m790akpa4rvj60b4d1gni"))))
1727 (build-system gnu-build-system)
1730 (modify-phases %standard-phases
1731 (add-before 'check 'precheck
1734 (substitute* "tests/common/test-common"
1735 (("/bin/pwd") (which "pwd")))
1737 (substitute* "tests/prt/all-512.sh"
1738 (("/bin/sh") (which "sh")))
1740 ;; XXX: This test has no hope of passing until there is a "nogroup"
1741 ;; entry (or at least some group to which the guix builder does
1742 ;; not belong) in the /etc/group file of the build environment.
1743 ;; Currently we do not have such a group. Disable this test for now.
1744 (substitute* "tests/Makefile"
1745 (("test-delta ") ""))))))))
1746 ;; These are needed for the tests
1747 (native-inputs `(("git" ,git)
1749 (home-page "https://www.gnu.org/software/cssc/")
1750 (synopsis "File-based version control like SCCS")
1751 (description "GNU CSSC provides a replacement for the legacy Unix source
1752 code control system SCCS. This allows old code still under that system to be
1753 accessed and migrated on modern systems.")
1754 (license license:gpl3+)))
1756 ;; This package can unfortunately work only in -TEST mode, since Aegis
1757 ;; requires that it is installed setuid root.
1758 (define-public aegis
1764 (uri (string-append "mirror://sourceforge/aegis/aegis/" version
1765 "/aegis-" version ".tar.gz"))
1768 "18s86ssarfmc4l17gbpzybca29m5wa37cbaimdji8czlcry3mcjl"))
1769 (patches (search-patches "aegis-perl-tempdir1.patch"
1770 "aegis-perl-tempdir2.patch"
1771 "aegis-test-fixup-1.patch"
1772 "aegis-test-fixup-2.patch"
1773 "aegis-constness-error.patch"))))
1774 (build-system gnu-build-system)
1776 `(("e2fsprogs" ,e2fsprogs)
1779 ("libxml2" ,libxml2)
1781 ("gettext" ,gettext-minimal)))
1786 ;; Various tests require the following:
1790 ("subversion" ,subversion)
1794 `(#:configure-flags (list "--with-no-aegis-configured"
1795 "--sharedstatedir=/var/com/aegis")
1796 #:parallel-build? #f ; There are some nasty racy rules in the Makefile.
1798 (modify-phases %standard-phases
1799 (add-before 'configure 'pre-conf
1801 (substitute* (append '("configure"
1802 "etc/check-tar-gz.sh"
1806 "script/aebisect.in"
1807 "script/aeintegratq.in"
1809 "script/test_funcs.in"
1810 "web/eg_oss_templ.sh"
1812 "libaegis/getpw_cache.cc")
1813 (find-files "test" "\\.sh"))
1814 (("/bin/sh") (which "sh")))
1815 (setenv "SH" (which "sh"))
1819 (let ((home (string-append (getcwd) "/my-new-home")))
1820 ;; Some tests need to write to $HOME.
1822 (setenv "HOME" home)
1824 ;; This test assumes that flex has been symlinked to "lex".
1825 (substitute* "test/00/t0011a.sh"
1826 (("type lex") "type flex"))
1828 ;; XXX Disable tests that fail, for unknown reasons, ‘for now’.
1830 (lambda (test) (substitute* "Makefile"
1831 (((string-append "test/" test "\\.ES ")) "")))
1836 ;; The author decided to call the check rule "sure".
1837 (invoke "make" "sure")))))))
1838 (home-page "http://aegis.sourceforge.net")
1839 (synopsis "Project change supervisor")
1840 (description "Aegis is a project change supervisor, and performs some of
1841 the Software Configuration Management needed in a CASE environment. Aegis
1842 provides a framework within which a team of developers may work on many
1843 changes to a program independently, and Aegis coordinates integrating these
1844 changes back into the master source of the program, with as little disruption
1845 as possible. Resolution of contention for source files, a major headache for
1846 any project with more than one developer, is one of Aegis's major functions.")
1847 (license license:gpl3+)))
1849 (define-public reposurgeon
1851 (name "reposurgeon")
1855 (uri (string-append "http://www.catb.org/~esr/" name "/"
1856 name "-" version ".tar.xz"))
1859 "1af0z14wcm4bk5a9ysinbwq2fp3lf5f7i8mvwh7286hr3fnagcaz"))
1860 (patches (search-patches
1861 "reposurgeon-add-missing-docbook-files.patch"))))
1862 (build-system gnu-build-system)
1866 (string-append "target=" (assoc-ref %outputs "out")))
1868 (modify-phases %standard-phases
1869 (add-after 'unpack 'patch-inputs
1870 (lambda* (#:key inputs #:allow-other-keys)
1871 (let ((tzdata (assoc-ref inputs "tzdata")))
1872 (substitute* "reposurgeon"
1873 (("/usr/share/zoneinfo")
1874 (string-append tzdata "/share/zoneinfo")))
1875 (substitute* "test/svn-to-svn"
1876 (("/bin/echo") "echo"))
1878 (delete 'configure) ; no configure script
1879 (add-before 'build 'fix-docbook
1880 (lambda* (#:key inputs #:allow-other-keys)
1881 (substitute* (find-files "." "\\.xml$")
1882 (("docbook/docbookx.dtd")
1883 (string-append (assoc-ref inputs "docbook-xml")
1884 "/xml/dtd/docbook/docbookx.dtd")))
1886 (add-before 'check 'set-up-test-environment
1887 (lambda* (#:key inputs #:allow-other-keys)
1888 (let ((tzdata (assoc-ref inputs "tzdata")))
1889 (setenv "TZDIR" (string-append tzdata "/share/zoneinfo"))
1891 (add-after 'install 'install-emacs-data
1892 (lambda* (#:key outputs #:allow-other-keys)
1893 (install-file "reposurgeon-mode.el"
1894 (string-append (assoc-ref outputs "out")
1895 "/share/emacs/site-lisp"))
1898 `(("python" ,python-wrapper)
1899 ("tzdata" ,tzdata)))
1901 `( ;; For building documentation.
1902 ("asciidoc" ,asciidoc)
1903 ("docbook-xml" ,docbook-xml)
1904 ("docbook-xsl" ,docbook-xsl)
1905 ("libxml2" ,libxml2)
1911 ("mercurial" ,mercurial)
1912 ("subversion" ,subversion)))
1913 (home-page "http://www.catb.org/~esr/reposurgeon/")
1914 (synopsis "Edit version-control repository history")
1915 (description "Reposurgeon enables risky operations that version-control
1916 systems don't want to let you do, such as editing past comments and metadata
1917 and removing commits. It works with any version control system that can
1918 export and import Git fast-import streams, including Git, Mercurial, Fossil,
1919 Bazaar, CVS, RCS, and Src. It can also read Subversion dump files directly
1920 and can thus be used to script production of very high-quality conversions
1921 from Subversion to any supported Distributed Version Control System (DVCS).")
1922 ;; Most files are distributed under bsd-2, except 'repocutter' which is
1924 (license (list license:bsd-2 license:bsd-3))))
1933 "https://github.com/jonas/tig/releases/download/tig-"
1934 version "/tig-" version ".tar.gz"))
1937 "1x5famvvs93ih7sr11x7m33dksb1k7zs1s3c4zkyf0cjmxkpqlzz"))))
1938 (build-system gnu-build-system)
1940 `(("asciidoc" ,asciidoc)
1943 `(("ncurses" ,ncurses)
1944 ("readline" ,readline)))
1947 (modify-phases %standard-phases
1948 (add-after 'install 'install-doc
1950 (invoke "make" "install-doc"))))
1951 #:tests? #f)) ; tests require access to /dev/tty
1952 ;; #:test-target "test"))
1953 (home-page "https://jonas.github.io/tig/")
1954 (synopsis "Ncurses-based text user interface for Git")
1956 "Tig is an ncurses text user interface for Git, primarily intended as
1957 a history browser. It can also stage hunks for commit, or colorize the
1958 output of the @code{git} command.")
1959 (license license:gpl2+)))
1961 (define-public findnewest
1969 (url "https://github.com/0-wiz-0/findnewest.git")
1970 (commit (string-append "findnewest-" version))))
1971 (file-name (git-file-name name version))
1973 (base32 "1x1cbn2b27h5r0ah5xc06fkalfdci2ngrgd4wibxjw0h88h0nvgq"))))
1974 (build-system gnu-build-system)
1975 (native-inputs `(("autoconf" ,autoconf)
1976 ("automake" ,automake)))
1977 (home-page "https://github.com/0-wiz-0/findnewest/releases")
1978 (synopsis "Print the modification time of the latest file")
1980 "Recursively find the newest file in a file tree and print its
1981 modification time.")
1982 (license license:bsd-2)))
1984 (define-public myrepos
1987 (version "1.20180726")
1992 (url "git://myrepos.branchable.com/myrepos")
1994 (file-name (string-append name "-" version "-checkout"))
1996 (base32 "0jphw61plm8cgklja6hs639xhdvxgvjwbr6jpvjwpp7hc5gmhms5"))))
1997 (build-system gnu-build-system)
1999 '(#:test-target "test"
2000 #:make-flags (list (string-append "PREFIX=" %output))
2002 (modify-phases %standard-phases
2004 (add-after 'install 'wrap-webcheckout
2005 (lambda* (#:key inputs outputs #:allow-other-keys)
2006 (let ((out (assoc-ref outputs "out")))
2007 (wrap-program (string-append out "/bin/webcheckout")
2008 `("PERL5LIB" ":" prefix
2009 ,(map (lambda (i) (string-append (assoc-ref inputs i)
2010 "/lib/perl5/site_perl"))
2011 '("perl-encode-locale" "perl-http-date"
2012 "perl-http-message" "perl-html-parser" "perl-libwww"
2013 "perl-uri" "perl-try-tiny"))))
2017 ("perl-encode-locale" ,perl-encode-locale)
2018 ("perl-html-parser" ,perl-html-parser)
2019 ("perl-http-date" ,perl-http-date)
2020 ("perl-http-message" ,perl-http-message)
2021 ("perl-libwww" ,perl-libwww)
2022 ("perl-try-tiny" ,perl-try-tiny)
2023 ("perl-uri" ,perl-uri)))
2024 (home-page "https://myrepos.branchable.com/")
2025 (synopsis "Multiple repository management tool")
2027 "Myrepos provides the @code{mr} command, which maps an operation (e.g.,
2028 fetching updates) over a collection of version control repositories. It
2029 supports a large number of version control systems: Git, Subversion,
2030 Mercurial, Bazaar, Darcs, CVS, Fossil, and Veracity.")
2031 (license license:gpl2+)))
2033 (define-public git-annex-remote-hubic
2035 (name "git-annex-remote-hubic")
2041 (url "https://github.com/Schnouki/git-annex-remote-hubic.git")
2042 (commit (string-append "v" version))))
2043 (file-name (git-file-name name version))
2045 (base32 "16y9sk67hfi17h9n2kkffyabfccksh5rab40hhk69v6cxmbpn2sx"))))
2046 (build-system python-build-system)
2047 (arguments `(#:python ,python-2))
2050 ("python2-six" ,python2-six)))
2052 `(("python2-dateutil" ,python2-dateutil)
2053 ("python2-futures" ,python2-futures)
2054 ("python2-rauth" ,python2-rauth)
2055 ("python2-swiftclient" ,python2-swiftclient)))
2056 (home-page "https://github.com/Schnouki/git-annex-remote-hubic/")
2057 (synopsis "Use hubic as a git-annex remote")
2059 "This package allows you to use your hubic account as a \"special
2060 repository\" with git-annex.")
2061 (license license:gpl3+)))
2063 (define-public git-annex-remote-rclone
2065 (name "git-annex-remote-rclone")
2071 (url "https://github.com/DanielDent/git-annex-remote-rclone.git")
2072 (commit (string-append "v" version))))
2073 (file-name (git-file-name name version))
2076 "0j0hlxji8d974fq7zd4xc02n0jpi31ylhxc7z4zp8iiwad5mkpxp"))))
2077 (build-system trivial-build-system)
2079 `(#:modules ((guix build utils))
2082 (use-modules (guix build utils))
2083 (let ((bash (string-append (assoc-ref %build-inputs "bash")
2085 (rclone (string-append (assoc-ref %build-inputs "rclone")
2087 (copy-file (string-append (assoc-ref %build-inputs "source")
2088 "/git-annex-remote-rclone")
2089 "git-annex-remote-rclone")
2090 (substitute* "git-annex-remote-rclone"
2091 (("/bin/bash") bash)
2092 (("runcmd rclone") (string-append "runcmd " rclone)))
2093 (install-file "git-annex-remote-rclone"
2094 (string-append %output "/bin"))
2098 ("rclone" ,rclone)))
2099 (home-page "https://github.com/DanielDent/git-annex-remote-rclone")
2100 (synopsis "Use rclone-supported cloud storage providers with git-annex")
2101 (description "This wrapper around rclone makes any destination supported
2102 by rclone usable with git-annex.")
2103 (license license:gpl3+)))
2105 (define-public fossil
2112 ;; Older downloads are moved to another URL.
2115 "https://www.fossil-scm.org/index.html/uv/download/"
2116 "fossil-src-" version ".tar.gz")
2118 "https://www.fossil-scm.org/index.html/uv/"
2119 "fossil-src-" version ".tar.gz")))
2122 "0pbinf8d2kj1j7niblhzjd2l2khg6r2pn2xvig6gavz27p3vwcka"))
2123 (modules '((guix build utils)))
2126 (delete-file-recursively "compat") #t))))
2127 (build-system gnu-build-system)
2129 `(("tcl" ,tcl) ;for configuration only
2130 ("which" ,which) ;for tests only
2133 `(("openssl" ,openssl)
2135 ("sqlite" ,sqlite)))
2137 `(#:configure-flags (list "--with-openssl=auto"
2138 "--disable-internal-sqlite")
2139 #:test-target "test"
2140 #:phases (modify-phases %standard-phases
2141 (add-after 'patch-source-shebangs 'patch-sh
2143 (substitute* '("auto.def")
2144 (("/bin/sh") (which "sh")))
2147 (lambda* (#:key outputs (configure-flags '())
2149 ;; The 'configure' script is not an autoconf script and
2150 ;; chokes on unrecognized options.
2153 (string-append "--prefix="
2154 (assoc-ref outputs "out"))
2157 (add-before 'check 'test-setup
2159 (setenv "USER" "guix")
2162 (home-page "https://fossil-scm.org")
2163 (synopsis "Software configuration management system")
2165 "Fossil is a distributed source control management system which supports
2166 access and administration over HTTP CGI or via a built-in HTTP server. It has
2167 a built-in wiki, built-in file browsing, built-in tickets system, etc.")
2168 (license (list license:public-domain ;src/miniz.c, src/shell.c
2171 (define-public stagit
2177 (uri (string-append "https://dl.2f30.org/releases/"
2178 name "-" version ".tar.gz"))
2181 "1m3s9g1z9szbjrhm8sic91xh6f2bfpi56rskdkqd5wc4wdycpyi5"))))
2182 (build-system gnu-build-system)
2184 `(#:tests? #f ; No tests
2185 #:make-flags (list "CC=gcc"
2186 (string-append "PREFIX=" %output))
2188 (modify-phases %standard-phases
2189 (delete 'configure)))) ; No configure script
2191 `(("libgit2" ,libgit2)))
2192 (home-page "https://2f30.org/")
2193 (synopsis "Static git page generator")
2194 (description "Stagit creates static pages for git repositories, the results can
2195 be served with a HTTP file server of your choice.")
2196 (license license:expat)))
2198 (define-public gource
2205 "https://github.com/acaudwell/Gource/releases/download"
2206 "/gource-" version "/gource-" version ".tar.gz"))
2209 "16p7b1x4r0915w883lp374jcdqqja37fnb7m8vnsfnl2n64gi8qr"))))
2210 (build-system gnu-build-system)
2213 (list (string-append "--with-boost-libdir="
2214 (assoc-ref %build-inputs "boost")
2217 `(("pkg-config" ,pkg-config)))
2227 ("sdl-union" ,(sdl-union (list sdl2 sdl2-image)))))
2228 (home-page "https://gource.io/")
2229 (synopsis "3D visualisation tool for source control repositories")
2230 (description "@code{gource} provides a software version control
2231 visualization. The repository is displayed as a tree where the root of the
2232 repository is the centre, directories are branches and files are leaves.
2233 Contributors to the source code appear and disappear as they contribute to
2234 specific files and directories.")
2235 (license license:gpl3+)))
2244 "http://www.catb.org/~esr/src/src-" version ".tar.gz"))
2247 "0n0skhvya8w2az45h2gsafxy8m2mvqas64nrgxifcmrzfv0rf26c"))))
2248 (build-system gnu-build-system)
2251 (list (string-append "prefix=" (assoc-ref %outputs "out")))
2253 (modify-phases %standard-phases
2254 (delete 'configure) ; no 'configure' script
2255 (add-after 'install 'wrap-program
2256 (lambda* (#:key inputs outputs #:allow-other-keys)
2257 (let* ((out (assoc-ref outputs "out"))
2258 (prog (string-append out "/bin/src"))
2259 (rcs (assoc-ref inputs "rcs")))
2261 `("PATH" ":" prefix (,(string-append rcs "/bin"))))
2265 (setenv "HOME" (getenv "TMPDIR"))
2266 (invoke "git" "config" "--global" "user.name" "guix")
2267 (invoke "git" "config" "--global" "user.email" "guix")
2268 (invoke "./srctest"))))))
2274 `(("python" ,python-wrapper)
2276 (synopsis "Simple revision control")
2277 (home-page "http://www.catb.org/~esr/src/")
2279 "SRC (or src) is simple revision control, a version-control system for
2280 single-file projects by solo developers and authors. It modernizes the
2281 venerable RCS, hence the anagrammatic acronym. The design is tuned for use
2282 cases like all those little scripts in your @file{~/bin} directory, or a
2283 directory full of HOWTOs.")
2284 (license license:bsd-2)))
2286 (define-public git-when-merged
2287 ;; Use an unreleased version to get a PY3 compatibility fix.
2288 (let ((commit "ab6af7865a0ba55ba364a6c507e0be6f84f31c6d"))
2290 (name "git-when-merged")
2291 (version (string-append "1.2.0-" (string-take commit 7)))
2295 (url "https://github.com/mhagger/git-when-merged/")
2297 (file-name (git-file-name name version))
2300 "0iyk2psf97bc9h43m89p3xjmm79fsx99i7px29g4lcnmdy5kmz0p"))))
2301 (build-system gnu-build-system)
2303 `(#:tests? #f ; there are no tests
2305 (modify-phases %standard-phases
2309 (lambda* (#:key outputs #:allow-other-keys)
2310 (install-file "bin/git-when-merged"
2311 (string-append (assoc-ref outputs "out")
2314 (add-before 'install 'patch-git
2315 (lambda* (#:key inputs #:allow-other-keys)
2316 (let ((git (string-append (assoc-ref inputs "git")
2318 (substitute* "bin/git-when-merged"
2319 (("'git'") (string-append "'" git "'")))
2321 (add-after 'install 'wrap-script
2322 (lambda* (#:key outputs #:allow-other-keys)
2323 (wrap-program (string-append (assoc-ref outputs "out")
2324 "/bin/git-when-merged")
2325 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
2329 ("python" ,python-wrapper)))
2330 (home-page "https://github.com/mhagger/git-when-merged")
2331 (synopsis "Determine when a commit was merged into a Git branch")
2332 (description "This Git extension defines a subcommand,
2333 @code{when-merged}, whose core operation is to find the merge that brought a
2334 given commit into the specified ref(s). It has various options that control
2335 how information about the merge is displayed.")
2336 (license license:gpl2+))))
2338 (define-public git-imerge
2346 (url "https://github.com/mhagger/git-imerge.git")
2347 (commit (string-append "v" version))))
2348 (file-name (git-file-name name version))
2350 (base32 "0vi1w3f0yk4gqhxj2hzqafqq28rihyhyfnp8x7xzib96j2si14a4"))))
2351 (build-system gnu-build-system)
2353 `(#:tests? #f ; only manual test scripts
2354 #:make-flags (list (string-append "DESTDIR=" %output)
2357 (modify-phases %standard-phases
2359 (add-before 'install 'patch-git
2360 (lambda* (#:key inputs #:allow-other-keys)
2361 (let ((git (string-append (assoc-ref inputs "git")
2363 (substitute* "git-imerge"
2364 (("'git'") (string-append "'" git "'")))
2366 (add-after 'install 'wrap-script
2367 (lambda* (#:key outputs #:allow-other-keys)
2368 (wrap-program (string-append (assoc-ref outputs "out")
2370 `("PYTHONPATH" ":" prefix (,(getenv "PYTHONPATH"))))
2374 ("python" ,python-wrapper)))
2375 (home-page "https://github.com/mhagger/git-imerge")
2376 (synopsis "Incremental merge for Git")
2377 (description "This Git extension defines a subcommand, @code{imerge},
2378 which performs an incremental merge between two branches. Its two primary
2379 design goals are to reduce the pain of resolving merge conflicts by finding
2380 the smallest possible conflicts and to allow a merge to be saved, tested,
2381 interrupted, published, and collaborated on while in progress.")
2382 (license license:gpl2+)))
2384 (define-public git-lfs
2391 (url "https://github.com/git-lfs/git-lfs")
2392 (commit (string-append "v" version))))
2393 (file-name (git-file-name name version))
2396 "1nf40rbdz901vsahg5cm09pznpina6wimmxl0lmh8pn0mi51yzvc"))))
2397 (build-system go-build-system)
2399 '(#:import-path "github.com/git-lfs/git-lfs"))
2400 (home-page "https://git-lfs.github.com/")
2401 (synopsis "Git extension for versioning large files")
2403 "Git Large File Storage (LFS) replaces large files such as audio samples,
2404 videos, datasets, and graphics with text pointers inside Git, while storing the
2405 file contents on a remote server.")
2406 (license license:expat)))