mirror of
https://gitlab.univ-nantes.fr/glicid-public/guix-glicid.git
synced 2025-04-29 21:58:36 +02:00
42 lines
2.5 KiB
Scheme
42 lines
2.5 KiB
Scheme
(define-module (glicid packages forgejo)
|
|
#:use-module (guix)
|
|
#:use-module (ice-9 match)
|
|
#:use-module ((guix licenses) #:prefix license:)
|
|
#:use-module (guix utils)
|
|
#:use-module (guix download)
|
|
#:use-module (guix packages)
|
|
#:use-module (guix build-system trivial)
|
|
#:use-module (gnu packages bash)
|
|
#:use-module (gnu packages version-control))
|
|
|
|
(define-public forgejo-dirty
|
|
(package
|
|
(name "forgejo")
|
|
(version "1.21.10-0")
|
|
(source (origin
|
|
(method url-fetch)
|
|
(uri (string-append "https://codeberg.org/" name "/" name "/releases/download/v" version "/" name "-" version "-linux-amd64"))
|
|
(file-name (string-append name "-" version "-linux-amd64"))
|
|
(sha256 (base32 "1vkp2aipb5d1q4s77dhdwnj66ih3rvbx1bb3fgkvsknyhb1l8mna"))))
|
|
(build-system trivial-build-system)
|
|
(arguments
|
|
'(#:modules ((guix build utils))
|
|
#:builder (begin
|
|
(use-modules (guix build utils))
|
|
(let* ((source (assoc-ref %build-inputs "source"))
|
|
(out (assoc-ref %outputs "out"))
|
|
(install-dir (string-append out "/bin"))
|
|
(executable (string-append install-dir "/forgejo"))
|
|
(bash (string-append (assoc-ref %build-inputs "bash") "/bin/"))
|
|
(git-dir (string-append (assoc-ref %build-inputs "git") "/bin/")))
|
|
(setenv "PATH" (string-append (getenv "PATH") ":" bash))
|
|
(mkdir-p install-dir)
|
|
(copy-file source executable)
|
|
(chmod executable #o755)
|
|
(wrap-program executable `("PATH" ":" prefix (,git-dir)))))))
|
|
(inputs (list git bash))
|
|
(synopsis "Forgejo binary release")
|
|
(description
|
|
"Forgejo is a self-hosted lightweight software forge. Easy to install and low maintenance, it just does the job.")
|
|
(home-page "https://forgejo.org/")
|
|
(license license:expat)))
|