aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/version-control.scm
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/version-control.scm')
-rw-r--r--gnu/packages/version-control.scm275
1 files changed, 134 insertions, 141 deletions
diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index a15f274c37..c077f0694d 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -296,7 +296,10 @@ Python 3.3 and later, rather than on Python 2.")
;; By default 'make install' creates hard links for
;; things in 'libexec/git-core', which leads to huge
;; nars; see <https://bugs.gnu.org/21949>.
- "NO_INSTALL_HARDLINKS=indeed")
+ "NO_INSTALL_HARDLINKS=indeed"
+ #$@(if (or (target-hurd64?) (%current-target-system))
+ #~("-Wno-implicit-function-declaration")
+ #~()))
#:phases
#~(modify-phases %standard-phases
#$@(if (%current-target-system)
@@ -305,7 +308,7 @@ Python 3.3 and later, rather than on Python 2.")
(lambda _
(substitute* "config.mak.uname"
(("uname_S := .*" all)
- (if (equal? #$(%current-target-system) "i586-pc-gnu")
+ (if #$(target-hurd?)
"uname_S := GNU\n"
all))))))
;; We do not have a full bash when cross-compiling.
@@ -518,7 +521,8 @@ everything from small to very large projects with speed and efficiency.")
"CVE-2022-30949"
"CVE-2022-36882"
"CVE-2022-36883"
- "CVE-2022-36884"))))
+ "CVE-2022-36884"))
+ (upstream-name . "git")))
(license license:gpl2)
(home-page "https://git-scm.com/")))
@@ -1170,7 +1174,7 @@ write native speed custom Git applications in any language with bindings.")
(define-public libgit2-1.8
(package
(inherit libgit2-1.7)
- (version "1.8.1")
+ (version "1.8.3")
(source (origin
(inherit (package-source libgit2-1.7))
(uri (git-reference
@@ -1179,7 +1183,7 @@ write native speed custom Git applications in any language with bindings.")
(file-name (git-file-name "libgit2" version))
(sha256
(base32
- "1mh55804cvxl2cyl4clinajzgfn3zmlhacnv1pdvdj4w6z2w4si7"))
+ "11jyxy6ckl19ayqpq5s3nlbcd0s1q4sdy8884m4pjrbzgxg6y1ds"))
(patches
(search-patches "libgit2-uninitialized-proxy-settings.patch"))
(snippet
@@ -1369,7 +1373,7 @@ collaboration using typical untrusted file hosts or services.")
(lambda* (#:key inputs #:allow-other-keys)
;; Unpack the source of git into the 'git' directory.
(invoke "tar" "--strip-components=1" "-C" "git" "-xf"
- (assoc-ref inputs "git-source"))))
+ #$(this-package-input "git-source.tar.xz"))))
(add-after 'unpack 'patch-absolute-file-names
(lambda* (#:key inputs outputs #:allow-other-keys)
(define (quoted-file-name input path)
@@ -1424,29 +1428,30 @@ collaboration using typical untrusted file hosts or services.")
;; For building manpage.
(list asciidoc))
(inputs
- `( ;; Building cgit requires a Git source tree.
- ("git-source"
- ,(origin
- (method url-fetch)
- ;; cgit is tightly bound to git. Use GIT_VER from the Makefile,
- ;; which may not match the current (package-version git).
- (uri "mirror://kernel.org/software/scm/git/git-2.46.2.tar.xz")
- (sha256
- (base32 "18rcmvximgyg3v1a9papi9djfamiak0ys5cmgx7ll29nhp3a3s2y"))))
- ("bash-minimal" ,bash-minimal)
- ("openssl" ,openssl)
- ("python" ,python)
- ("python-docutils" ,python-docutils)
- ("python-markdown" ,python-markdown)
- ("python-pygments" ,python-pygments)
- ("zlib" ,zlib)
- ;; bzip2, groff, gzip and xz are inputs (not native inputs)
- ;; since they are actually substituted into cgit source and
- ;; referenced by the built package output.
- ("bzip2" ,bzip2)
- ("groff" ,groff)
- ("gzip" ,gzip)
- ("xz" ,xz)))
+ (list (origin
+ (method url-fetch)
+ ;; Building cgit requires a Git source tree.
+ ;; cgit is tightly bound to git. Use GIT_VER from the Makefile,
+ ;; which may not match the current (package-version git).
+ (uri "mirror://kernel.org/software/scm/git/git-2.46.2.tar.xz")
+ (sha256
+ (base32
+ "18rcmvximgyg3v1a9papi9djfamiak0ys5cmgx7ll29nhp3a3s2y"))
+ (file-name "git-source.tar.xz"))
+ bash-minimal
+ openssl
+ python
+ python-docutils
+ python-markdown
+ python-pygments
+ zlib
+ ;; bzip2, groff, gzip and xz are inputs (not native inputs)
+ ;; since they are actually substituted into cgit source and
+ ;; referenced by the built package output.
+ bzip2
+ groff
+ gzip
+ xz))
(home-page "https://git.zx2c4.com/cgit/")
(synopsis "Web frontend for git repositories")
(description
@@ -1822,7 +1827,7 @@ lot easier.")
(define-public stgit-2
(package
(name "stgit")
- (version "2.4.0")
+ (version "2.4.12")
(source
(origin
(method git-fetch)
@@ -1831,7 +1836,7 @@ lot easier.")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "0cgv7chxqkjaqmzi4691in26j2fm8r0vanw8xzb9cqnz6350wvvj"))
+ (base32 "0kp3gwmxcjvphg1s0san0vyis8dsdaf02xsflc2b7kkg8m0r0mi3"))
(modules '((guix build utils)))
(snippet
'(begin (substitute* (find-files "." "^Cargo\\.toml$")
@@ -1848,10 +1853,10 @@ lot easier.")
("rust-curl" ,rust-curl-0.4)
("rust-encoding_rs" ,rust-encoding-rs-0.8)
("rust-flate2" ,rust-flate2-1)
- ("rust-gix" ,rust-gix-0.54)
+ ("rust-gix" ,rust-gix-0.66)
("rust-indexmap" ,rust-indexmap-2)
("rust-is-terminal" ,rust-is-terminal-0.4)
- ("rust-nom" ,rust-nom-7)
+ ("rust-jiff" ,rust-jiff-0.1)
("rust-serde" ,rust-serde-1)
("rust-serde-json" ,rust-serde-json-1)
("rust-strsim" ,rust-strsim-0.10)
@@ -1859,7 +1864,7 @@ lot easier.")
("rust-tempfile" ,rust-tempfile-3)
("rust-termcolor" ,rust-termcolor-1)
("rust-thiserror" ,rust-thiserror-1)
- ("rust-time" ,rust-time-0.3))
+ ("rust-winnow" ,rust-winnow-0.6))
#:install-source? #f
#:phases
(modify-phases %standard-phases
@@ -2069,23 +2074,26 @@ wrappers, to be used for optional gitolite extensions."
(delete 'configure)
(delete 'build)
(add-before 'install 'patch-scripts
- (lambda* _
+ (lambda* (#:key inputs #:allow-other-keys)
;; This seems to take care of every shell script that
;; invokes Perl.
(substitute* (find-files ".")
((" perl -")
- (string-append " " #$perl "/bin/perl" " -")))
+ (string-append
+ " " (search-input-file inputs "bin/perl") " -")))
(substitute* (find-files "src/triggers" ".*")
((" sed ")
- (string-append " " #$sed "/bin/sed" " ")))
+ (string-append
+ " " (search-input-file inputs "bin/sed") " ")))
(substitute*
'("src/triggers/post-compile/update-gitweb-access-list"
"src/triggers/post-compile/ssh-authkeys-split"
"src/triggers/upstream")
((" grep ")
- (string-append " " #$grep "/bin/grep" " ")))
+ (string-append
+ " " (search-input-file inputs "bin/grep") " ")))
;; Avoid references to the store in authorized_keys.
;; This works because gitolite-shell is in the PATH.
@@ -2093,25 +2101,29 @@ wrappers, to be used for optional gitolite extensions."
(("\\$glshell \\$user")
"gitolite-shell $user"))))
(add-before 'install 'patch-source
- (lambda* _
+ (lambda* (#:key inputs #:allow-other-keys)
;; Gitolite uses cat to test the readability of the
;; pubkey
(substitute* "src/lib/Gitolite/Setup.pm"
(("\"cat ")
- (string-append "\"" #$coreutils "/bin/cat" " "))
+ (string-append
+ "\"" (search-input-file inputs "bin/cat") " "))
(("\"ssh-keygen")
- (string-append "\"" #$openssh "/bin/ssh-keygen")))
+ (string-append
+ "\"" (search-input-file inputs "bin/ssh-keygen"))))
(substitute* '("src/lib/Gitolite/Hooks/PostUpdate.pm"
"src/lib/Gitolite/Hooks/Update.pm")
(("/usr/bin/perl")
- (string-append #$perl "/bin/perl")))
+ (search-input-file inputs "bin/perl")))
(substitute* "src/lib/Gitolite/Common.pm"
(("\"ssh-keygen")
- (string-append "\"" #$openssh "/bin/ssh-keygen"))
+ (string-append
+ "\"" (search-input-file inputs "bin/ssh-keygen")))
(("\"logger\"")
- (string-append "\"" #$inetutils "/bin/logger\"")))
+ (string-append
+ "\"" (search-input-file inputs "bin/logger") "\"")))
(substitute* "src/lib/Gitolite/Cache.pm"
(("/usr/sbin/redis-server") "redis-server"))
@@ -2131,17 +2143,23 @@ wrappers, to be used for optional gitolite extensions."
(string-append bindir "/" script)))
'("gitolite" "gitolite-shell")))))
(add-after 'install 'wrap-scripts
- (lambda* _
+ (lambda* (#:key inputs #:allow-other-keys)
(for-each (lambda (file-name)
(wrap-program (string-append #$output file-name)
`("PATH" ":" prefix
- ,(map (lambda (dir)
+ ,(append
+ (map (lambda (command)
+ (dirname
+ (search-input-file
+ inputs
+ (string-append "bin/" command))))
+ '("chmod" ;coreutils
+ "find"
+ "git"))
+ (map (lambda (dir)
(string-append dir "/bin"))
(list #$output
- #$coreutils
- #$findutils
- #$git
- #$@extra-inputs)))))
+ #$@extra-inputs))))))
'("/bin/gitolite" "/bin/gitolite-shell")))))))
(inputs
(append (list bash-minimal coreutils findutils git inetutils openssh perl)
@@ -2230,7 +2248,7 @@ visualize your public Git repositories on a web interface.")
(define-public pre-commit
(package
(name "pre-commit") ;formerly known as python-pre-commit
- (version "3.3.3")
+ (version "3.7.1")
(source
(origin
(method git-fetch) ; no tests in PyPI release
@@ -2239,73 +2257,55 @@ visualize your public Git repositories on a web interface.")
(commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
- (base32 "1spkg3ld3s6l7wz24lcywlf1z2ywp751bcdlxjfdsln76bi9ylp8"))
+ (base32 "1m2cs21xq2j1x80s7bh47fm2nsbnfxgscxfijaqwdsi2rrf4vlzv"))
(modules '((guix build utils)))
(snippet '(substitute* "setup.cfg"
(("virtualenv>=20.10.0") ;our virtualenv (20.3.1) is fine
"virtualenv>=20.0.8")))))
- (build-system python-build-system)
+ (build-system pyproject-build-system)
(arguments
- `(#:phases
- (modify-phases %standard-phases
- (add-before 'check 'prepare-check-env
- (lambda _
- ;; Change from /homeless-shelter to /tmp for write permission.
- (setenv "HOME" "/tmp")
- ;; Environment variables used in the tests.
- (setenv "GIT_AUTHOR_NAME" "Your Name")
- (setenv "GIT_COMMITTER_NAME" "Your Name")
- (setenv "GIT_AUTHOR_EMAIL" "you@example.com")
- (setenv "GIT_COMMITTER_EMAIL" "you@example.com")
- ;; Some tests still fail with PermissionError. Make the source
- ;; tree writable.
- (for-each make-file-writable (find-files "."))
- ;; Some tests will need a working git repository.
- (invoke "git" "init")
- (invoke "git" "config" "--global" "user.name" "Your Name")
- (invoke "git" "config" "--global" "user.email" "you@example.com")))
- (replace 'check
- (lambda* (#:key inputs outputs tests? #:allow-other-keys)
- (add-installed-pythonpath inputs outputs)
- (when tests?
- ;; The file below contains 30+ tests that fail because they
- ;; depend on tools from multiple languages (cargo, npm, cpan,
- ;; Rscript, etc). Other tests are passing, but it's more
- ;; convenient to skip the file than list 30 tests to skip.
- (invoke "pytest" "--ignore=tests/repository_test.py"
- ;; Ruby and Node tests require node and gem.
- "--ignore=tests/languages/node_test.py"
- "--ignore=tests/languages/ruby_test.py"
- ;; Skip lang-specific (network) tests added in 3.1.1
- "--ignore=tests/languages/conda_test.py"
- "--ignore=tests/languages/coursier_test.py"
- "--ignore=tests/languages/dart_test.py"
- "--ignore=tests/languages/docker_test.py"
- "--ignore=tests/languages/docker_image_test.py"
- "--ignore=tests/languages/dotnet_test.py"
- "--ignore=tests/languages/golang_test.py"
- "--ignore=tests/languages/lua_test.py"
- "--ignore=tests/languages/perl_test.py"
- "--ignore=tests/languages/rust_test.py"
- "--ignore=tests/languages/swift_test.py"
- "-k"
- (string-append
- ;; TODO: these tests fail with AssertionError. It may
- ;; be possible to fix them.
- "not test_install_existing_hooks_no_overwrite"
- " and not test_uninstall_restores_legacy_hooks"
- " and not test_installed_from_venv"
- " and not test_healthy_venv_creator"
- " and not test_r_hook and not test_r_inline"))))))))
+ (list
+ ;; Skip language-specific tests because they depennd on language tools.
+ #:test-flags
+ #~(list "--ignore" "tests/languages"
+ ;; These fail with AssertionError.
+ "-k" (string-append
+ "not test_additional_dependencies_roll_forward"
+ " and not test_control_c_control_c_on_install"
+ " and not test_invalidated_virtualenv"
+ " and not test_local_python_repo"
+ " and not test_install_existing_hooks_no_overwrite"
+ " and not test_uninstall_restores_legacy_hooks"
+ " and not test_installed_from_venv"))
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'check 'prepare-check-env
+ (lambda _
+ ;; Change from /homeless-shelter to /tmp for write permission.
+ (setenv "HOME" "/tmp")
+ ;; Environment variables used in the tests.
+ (setenv "GIT_AUTHOR_NAME" "Your Name")
+ (setenv "GIT_COMMITTER_NAME" "Your Name")
+ (setenv "GIT_AUTHOR_EMAIL" "you@example.com")
+ (setenv "GIT_COMMITTER_EMAIL" "you@example.com")
+ ;; Some tests still fail with PermissionError. Make the source
+ ;; tree writable.
+ ;; (for-each make-file-writable (find-files "."))
+ ;; Some tests will need a working git repository.
+ (invoke "git" "init")
+ (invoke "git" "config" "--global" "user.name" "Your Name")
+ (invoke "git" "config" "--global" "user.email" "you@example.com"))))))
(native-inputs
- `(("git" ,git-minimal/pinned)
- ("python-covdefaults" ,python-covdefaults)
- ("python-coverage" ,python-coverage)
- ("python-distlib" ,python-distlib)
- ("python-pytest" ,python-pytest)
- ("python-pytest-env" ,python-pytest-env)
- ("python-re-assert" ,python-re-assert)
- ("which" ,which)))
+ (list git-minimal
+ python-covdefaults
+ python-coverage
+ python-distlib
+ python-pytest
+ python-pytest-env
+ python-re-assert
+ python-setuptools
+ python-wheel
+ which))
;; Propagate because pre-commit is also used as a module.
(propagated-inputs
(list python-cfgv
@@ -3239,7 +3239,7 @@ email header.")
;; This ensures git is present when called.
(add-after 'unpack 'hardcode-git-bin
(lambda* (#:key inputs #:allow-other-keys)
- (substitute* (find-files "b4" "\\.py$")
+ (substitute* (find-files "src/b4" "\\.py$")
(("\\['git'")
(string-append
"['" (search-input-file inputs "bin/git") "'"))))))))
@@ -3251,7 +3251,7 @@ email header.")
python-dnspython
python-requests))
(native-inputs
- (list python-pytest))
+ (list python-pytest python-setuptools python-wheel))
(home-page "https://git.kernel.org/pub/scm/utils/b4/b4.git")
(synopsis "Tool for working with patches in public-inbox archives")
(description
@@ -3686,6 +3686,7 @@ will reconstruct the object along its delta-base chain and return it.")
(build-system go-build-system)
(arguments
(list
+ #:embed-files #~(list "children" "nodes" "text")
#:import-path "github.com/git-lfs/git-lfs"
#:install-source? #f
#:phases
@@ -3695,13 +3696,6 @@ will reconstruct the object along its delta-base chain and return it.")
(substitute* "src/github.com/git-lfs/git-lfs/lfs/hook.go"
(("/bin/sh")
(search-input-file inputs "bin/sh")))))
- (add-after 'unpack 'fix-embed-x-net
- (lambda _
- (delete-file-recursively "src/golang.org/x/net/publicsuffix/data")
- (copy-recursively
- #$(file-append (this-package-input "go-golang-org-x-net")
- "/src/golang.org/x/net/publicsuffix/data")
- "src/golang.org/x/net/publicsuffix/data")))
;; Only build the man pages if ruby-asciidoctor is available.
#$@(if (this-package-native-input "ruby-asciidoctor")
#~((add-before 'build 'man-gen
@@ -3922,9 +3916,9 @@ of machine readable. This helps improve code quality and helps you spot
defects faster.")
(license license:expat)))
-(define-public go-github-go-git
+(define-public go-github-com-go-git-go-git-v5
(package
- (name "go-github-go-git")
+ (name "go-github-com-go-git-go-git-v5")
(version "5.1.0")
(source (origin
(method git-fetch)
@@ -3937,28 +3931,27 @@ defects faster.")
"1vkcmhh2qq8c38sjbnzf0wvg2rzr19wssaq177bsvrjwj1xz1qbs"))))
(build-system go-build-system)
(arguments
- `(#:tests? #f ;requires network connection
- #:import-path "github.com/go-git/go-git/v5"
- #:phases
- (modify-phases %standard-phases
- (add-before 'build 'setup
- (lambda* (#:key inputs #:allow-other-keys)
- (let* ((git (assoc-ref inputs "git"))
- (git-bin (string-append (assoc-ref inputs "git") "/bin"))
- (git-exe (string-append git-bin "/git")))
- (setenv "GIT_DIST_PATH=" git)
- (setenv "GIT_EXEC_PATH=" git-bin)
- (setenv "HOME" (getcwd))
- (invoke git-exe "config" "--global" "user.email" "gha@example.com")
- (invoke git-exe "config" "--global" "user.name" "GitHub Actions")
- #t)
- #t)))))
+ (list
+ #:tests? #f ;requires network connection
+ #:import-path "github.com/go-git/go-git/v5"
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'build 'setup
+ (lambda* (#:key inputs #:allow-other-keys)
+ (let* ((git #$(this-package-native-input "git"))
+ (git-bin (string-append git "/bin"))
+ (git-exe (string-append git-bin "/git")))
+ (setenv "GIT_DIST_PATH=" git)
+ (setenv "GIT_EXEC_PATH=" git-bin)
+ (setenv "HOME" (getcwd))
+ (invoke git-exe "config" "--global" "user.email" "gha@example.com")
+ (invoke git-exe "config" "--global" "user.name" "GitHub Actions")))))))
(propagated-inputs
(list go-github-com-alcortesm-tgz
go-github-com-emirpasic-gods
go-github-com-go-git-gcfg
- go-github-com-go-git-go-billy
- go-github-com-go-git-go-git-fixtures
+ go-github-com-go-git-go-billy-v5
+ go-github-com-go-git-go-git-fixtures-v4
go-github-com-imdario-mergo
go-github-com-jbenet-go-context
go-github-com-kevinburke-ssh-config