add forgejo

pull/2/head
hashirama 2024-04-06 14:20:19 -04:00
parent 6108b9c483
commit 64a25ad418
No known key found for this signature in database
GPG Key ID: 53E62470A86BC185
1 changed files with 70 additions and 0 deletions

70
ajatt/packages/utils.scm Normal file
View File

@ -0,0 +1,70 @@
(define-module (ajatt packages utils))
(use-modules (gnu)
(guix gexp)
(guix packages)
(guix download)
(guix build utils)
(guix build-system gnu)
(guix build-system copy)
(nonguix build-system binary)
((guix licenses) #:prefix license:))
(use-package-modules version-control gcc bash certs admin linux)
(use-service-modules certbot shepherd configuration networking ssh web)
(define forgejo
(let ((version "1.20.5-0"))
(package
(name "forgejo")
(version version)
(source
(origin
(method url-fetch)
(uri (string-append "https://codeberg.org/forgejo/forgejo/releases/download/v" version "/forgejo-" version "-linux-amd64"))
(file-name "forgejo")
(sha256
(base32 "0jj13qwq67acbqsina3gqi5fr2lsm80jxjmm26i1ixxhf0r0w641"))))
(build-system binary-build-system)
(arguments
`(#:phases (modify-phases %standard-phases
(add-after 'unpack 'chmod-to-allow-patchelf
(lambda _
(chmod "forgejo" #o755))))
#:install-plan `(("forgejo" "bin/"))))
(propagated-inputs (list git git-lfs))
(home-page "https://forgejo.org")
(synopsis "A self-hosted lightweight software forge.")
(description "Forgejo is a self-hosted lightweight software forge.")
(license license:expat))))
(define loophole
(let ((version "1.0.0-beta.15"))
(package
(name "loophole")
(version version)
(source
(origin
(method url-fetch)
(uri "https://github.com/loophole/cli/releases/download/1.0.0-beta.15/loophole-cli_1.0.0-beta.15_linux_64bit.tar.gz")
(file-name "loophole")
(sha256
(base32 "1bk5dqvw6zkjablc6b29y7a59mkh4ivziss0s2z13zvjbll315jd"))))
(build-system binary-build-system)
(arguments
`(#:phases (modify-phases %standard-phases
;; fix: patchelf isn't working, but
;; patchelf --set-interpreter "$(patchelf --print-interpreter "$(realpath "$(which sh)")")"
;; works
(add-after 'unpack 'chmod-to-allow-patchelf
(lambda _
(chmod "loophole" #o755))))
#:install-plan `(("loophole" "bin/"))))
(home-page "https://loophole.cloud/")
(synopsis "Instant hosting, right from your local machine.")
(description "No more hassle with port-forwarding, bypassing firewalls, or setting up dynamic.")
(license license:expat))))
forgejo