summaryrefslogtreecommitdiff
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.scm236
1 files changed, 150 insertions, 86 deletions
diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
index ad3029e814..d8d4a77341 100644
--- a/gnu/packages/version-control.scm
+++ b/gnu/packages/version-control.scm
@@ -45,6 +45,7 @@
;;; Copyright © 2021 Foo Chuan Wei <chuanwei.foo@hotmail.com>
;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com>
;;; Copyright © 2022 Maxime Devos <maximedevos@telenet.be>
+;;; Copyright © 2022 Dhruvin Gandhi <contact@dhruvin.dev>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -104,6 +105,7 @@
#:use-module (gnu packages image)
#:use-module (gnu packages linux)
#:use-module (gnu packages mail)
+ #:use-module (gnu packages man)
#:use-module (gnu packages maths)
#:use-module (gnu packages nano)
#:use-module (gnu packages ncurses)
@@ -221,14 +223,14 @@ Python 3.3 and later, rather than on Python 2.")
(define-public git
(package
(name "git")
- (version "2.37.3")
+ (version "2.38.0")
(source (origin
(method url-fetch)
(uri (string-append "mirror://kernel.org/software/scm/git/git-"
version ".tar.xz"))
(sha256
(base32
- "0yp8hdj0w18jhmmdflzz74z418cw95i08pc22yycyn8nyvbl2il1"))))
+ "02ij201lyipv1w2zkcq4ng2bga2xkw58xnkbs1wdw50qdgiasglj"))))
(build-system gnu-build-system)
(native-inputs
`(("native-perl" ,perl)
@@ -248,7 +250,7 @@ Python 3.3 and later, rather than on Python 2.")
version ".tar.xz"))
(sha256
(base32
- "053lj9wy8y2yr5jzpb0af4w50gz3ckhgc15wqx7is4z6k9a76lww"))))
+ "1qyn6rhwblshz0hp0kdc8lk22c1fv8avfr44sia0vzlbd82xj828"))))
;; For subtree documentation.
("asciidoc" ,asciidoc)
("docbook-xsl" ,docbook-xsl)
@@ -1497,89 +1499,85 @@ also walk each side of a merge and test those changes individually.")
(base32 "05xw1pmagvkrbzga5pgl3xk9qyc6b5x73f842454f3w9ijspa8zy"))))
(build-system gnu-build-system)
(arguments
- '(#:tests? #f ; no tests
- #:phases (modify-phases %standard-phases
- (delete 'configure)
- (delete 'build)
- (add-before 'install 'patch-scripts
- (lambda* (#:key inputs #:allow-other-keys)
- (let ((perl (search-input-file inputs "/bin/perl")))
- ;; This seems to take care of every shell script that
- ;; invokes Perl.
- (substitute* (find-files ".")
- ((" perl -")
- (string-append " " perl " -")))
-
- (substitute* (find-files "src/triggers" ".*")
- ((" sed ")
- (string-append " " (which "sed") " ")))
-
- (substitute*
- '("src/triggers/post-compile/update-gitweb-access-list"
- "src/triggers/post-compile/ssh-authkeys-split"
- "src/triggers/upstream")
- ((" grep ")
- (string-append " " (which "grep") " ")))
-
- ;; Avoid references to the store in authorized_keys.
- ;; This works because gitolite-shell is in the PATH.
- (substitute* "src/triggers/post-compile/ssh-authkeys"
- (("\\$glshell \\$user")
- "gitolite-shell $user")))))
- (add-before 'install 'patch-source
- (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 "\"" (which "cat") " "))
- (("\"ssh-keygen")
- (string-append "\"" (which "ssh-keygen"))))
-
- (substitute* '("src/lib/Gitolite/Hooks/PostUpdate.pm"
- "src/lib/Gitolite/Hooks/Update.pm")
- (("/usr/bin/perl")
- (search-input-file inputs "/bin/perl")))
-
- (substitute* "src/lib/Gitolite/Common.pm"
- (("\"ssh-keygen")
- (string-append "\"" (which "ssh-keygen")))
- (("\"logger\"")
- (string-append "\""
- (assoc-ref inputs "inetutils")
- "/bin/logger\"")))
-
- (substitute* "src/lib/Gitolite/Cache.pm"
- (("/usr/sbin/redis-server") "redis-server"))
-
- (substitute* "src/commands/svnserve"
- (("/usr/bin/svnserve") "svnserve"))))
- (replace 'install
- (lambda* (#:key outputs #:allow-other-keys)
- (let* ((output (assoc-ref outputs "out"))
- (sharedir (string-append output "/share/gitolite"))
- (bindir (string-append output "/bin")))
- (mkdir-p sharedir)
- (mkdir-p bindir)
- (invoke "./install" "-to" sharedir)
- ;; Create symlinks for executable scripts in /bin.
- (for-each (lambda (script)
- (symlink (string-append sharedir "/" script)
- (string-append bindir "/" script)))
- '("gitolite" "gitolite-shell")))))
- (add-after 'install 'wrap-scripts
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (let ((out (assoc-ref outputs "out"))
- (coreutils (assoc-ref inputs "coreutils"))
- (findutils (assoc-ref inputs "findutils"))
- (git (assoc-ref inputs "git")))
- (for-each (lambda (file-name)
- (wrap-program (string-append out file-name)
- `("PATH" ":" prefix
- ,(map (lambda (dir)
- (string-append dir "/bin"))
- (list out coreutils findutils git)))))
- '("/bin/gitolite" "/bin/gitolite-shell"))))))))
+ (list #:tests? #f ; no tests
+ #:phases
+ #~(modify-phases %standard-phases
+ (delete 'configure)
+ (delete 'build)
+ (add-before 'install 'patch-scripts
+ (lambda* _
+ ;; This seems to take care of every shell script that
+ ;; invokes Perl.
+ (substitute* (find-files ".")
+ ((" perl -")
+ (string-append " " #$perl "/bin/perl" " -")))
+
+ (substitute* (find-files "src/triggers" ".*")
+ ((" sed ")
+ (string-append " " #$sed "/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" " ")))
+
+ ;; Avoid references to the store in authorized_keys.
+ ;; This works because gitolite-shell is in the PATH.
+ (substitute* "src/triggers/post-compile/ssh-authkeys"
+ (("\\$glshell \\$user")
+ "gitolite-shell $user"))))
+ (add-before 'install 'patch-source
+ (lambda* _
+ ;; Gitolite uses cat to test the readability of the
+ ;; pubkey
+ (substitute* "src/lib/Gitolite/Setup.pm"
+ (("\"cat ")
+ (string-append "\"" #$coreutils "/bin/cat" " "))
+ (("\"ssh-keygen")
+ (string-append "\"" #$openssh "/bin/ssh-keygen")))
+
+ (substitute* '("src/lib/Gitolite/Hooks/PostUpdate.pm"
+ "src/lib/Gitolite/Hooks/Update.pm")
+ (("/usr/bin/perl")
+ (string-append #$perl "/bin/perl")))
+
+ (substitute* "src/lib/Gitolite/Common.pm"
+ (("\"ssh-keygen")
+ (string-append "\"" #$openssh "/bin/ssh-keygen"))
+ (("\"logger\"")
+ (string-append "\"" #$inetutils "/bin/logger\"")))
+
+ (substitute* "src/lib/Gitolite/Cache.pm"
+ (("/usr/sbin/redis-server") "redis-server"))
+
+ (substitute* "src/commands/svnserve"
+ (("/usr/bin/svnserve") "svnserve"))))
+ (replace 'install
+ (lambda* _
+ (let* ((sharedir (string-append #$output "/share/gitolite"))
+ (bindir (string-append #$output "/bin")))
+ (mkdir-p sharedir)
+ (mkdir-p bindir)
+ (invoke "./install" "-to" sharedir)
+ ;; Create symlinks for executable scripts in /bin.
+ (for-each (lambda (script)
+ (symlink (string-append sharedir "/" script)
+ (string-append bindir "/" script)))
+ '("gitolite" "gitolite-shell")))))
+ (add-after 'install 'wrap-scripts
+ (lambda* _
+ (for-each (lambda (file-name)
+ (wrap-program (string-append #$output file-name)
+ `("PATH" ":" prefix
+ ,(map (lambda (dir)
+ (string-append dir "/bin"))
+ (list #$output
+ #$coreutils
+ #$findutils
+ #$git)))))
+ '("/bin/gitolite" "/bin/gitolite-shell")))))))
(inputs
(list bash-minimal coreutils findutils git inetutils openssh perl))
(home-page "https://gitolite.com")
@@ -3460,3 +3458,69 @@ Git project instead of @command{git filter-branch}.")
"Gitlint is a Git commit message linter written in Python: it checks your
commit messages for style.")
(license license:expat)))
+
+(define-public hut
+ (package
+ (name "hut")
+ (version "0.2.0")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://git.sr.ht/~emersion/hut")
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0ybngrwwmkm00dlkdhvkfcvcjhp5xzs8fh90zqr0h12ssqx9pll3"))))
+ (build-system go-build-system)
+ (arguments
+ (list
+ #:import-path "git.sr.ht/~emersion/hut"
+ #:phases
+ #~(modify-phases %standard-phases
+ (replace 'build
+ (lambda* (#:key import-path #:allow-other-keys)
+ (with-directory-excursion (string-append "src/" import-path)
+ ;; The flags are copied from (guix build go-build-system).
+ (setenv "CGO_LDFLAGS" "-s -w")
+ (invoke "make" "all" "GOFLAGS=-v -x"))))
+ (replace 'install
+ (lambda* (#:key import-path #:allow-other-keys)
+ (with-directory-excursion (string-append "src/" import-path)
+ (invoke "make" "install"
+ (string-append "PREFIX=" #$output))))))))
+ (native-inputs
+ (list scdoc))
+ (inputs
+ (list go-git-sr-ht-emersion-go-scfg
+ go-git-sr-ht-emersion-gqlclient
+ go-github-com-juju-ansiterm
+ go-github-com-spf13-cobra
+ go-golang-org-x-oauth2
+ go-golang-org-x-term))
+ (home-page "https://git.sr.ht/~emersion/hut")
+ (synopsis "CLI tool for sr.ht")
+ (description "@command{hut} is a CLI tool for
+@uref{https://sr.ht/~sircmpwn/sourcehut/, sr.ht}. It helps you interact with
+sr.ht's public services:
+@table @asis
+@item builds
+submit and manage build jobs
+@item git
+create, and manage git repositories and artifacts
+@item hg
+list Mercurial repositories
+@item lists
+manage mailing lists and patches
+@item meta
+manage PGP, and SSH keys
+@item pages
+publish and manage hosted websites
+@item paste
+create and manage pastes
+@item todo
+create and manage trackers, tickets
+@item graphql
+interact with GraphQL APIs directly
+@end table")
+ (license license:agpl3)))