unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
From: bigbookofbug--- via Guix-patches via <guix-patches@gnu.org>
To: 74858@debbugs.gnu.org
Cc: emma thompson <bigbookofbug@proton.me>
Subject: [bug#74858] [PATCH] gnu: add guile-guix-graze
Date: Fri, 13 Dec 2024 20:18:47 +0000	[thread overview]
Message-ID: <20241213201839.14282-1-bigbookofbug@proton.me> (raw)

From: emma thompson <bigbookofbug@proton.me>

---
 gnu/packages/guile-xyz.scm | 63 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 63 insertions(+)

diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm
index bd5878d229..ef98fdbc54 100644
--- a/gnu/packages/guile-xyz.scm
+++ b/gnu/packages/guile-xyz.scm
@@ -2317,6 +2317,69 @@ (define-public guile2.2-ics
     (inputs (list guile-2.2))
     (propagated-inputs (list guile2.2-lib guile2.2-dsv guile2.2-smc))))
 
+(define-public guile-guix-graze
+  (let ((version "0.1"))
+    (package
+      (name "guix-graze")
+      (version version)
+      (source
+       (origin
+	 (method git-fetch)
+	 (uri (git-reference
+	       (url "https://gitlab.com/bigbookofbug/guix-graze")
+	       (commit version)))
+	 (file-name (git-file-name name version))
+	 (sha256
+	  (base32 "0fk8gfdnm41gwmhppjv7zwg5j7fb0n7ww27sdcdf8s9rjs9415fl"))))
+      (build-system gnu-build-system)
+      (arguments
+       (list
+	#:modules
+          `(((guix build guile-build-system)
+	     #:select
+	     (target-guile-effective-version))
+	    ,@%default-gnu-imported-modules)
+	  #:phases
+          (with-imported-modules
+            `((guix build guile-build-system)
+              ,@%default-gnu-imported-modules)
+            #~(modify-phases
+                    %standard-phases
+                    (add-after
+			'install
+			'graze-wrap-binaries
+		      (lambda* (#:key inputs #:allow-other-keys)
+			(let* ((version (target-guile-effective-version))
+			       (site-ccache
+				(string-append "/lib/guile/" version "/site-ccache"))
+			       (site (string-append "/share/guile/site/" version))
+			       (dep-path
+				(lambda (env path)
+				  (list env ":" 'prefix
+					(cons (string-append
+					       nil output
+					       path)
+					      (map (lambda (input)
+						     (string-append
+						      (assoc-ref inputs input)
+						      path))
+						   (list "guile-config"))))))
+			       (bin (string-append (ungexp output) "/bin/")))
+			  (wrap-program
+			      (string-append bin "graze")
+			    (dep-path "GUILE_LOAD_PATH" site)
+			    (dep-path "GUILE_LOAD_COMPILED_PATH" site-ccache)))))))))
+      (native-inputs
+       (list autoconf automake pkg-config guile-3.0))
+      (inputs (list bash-minimal guile-3.0))
+      (propagated-inputs (list guile-config))
+      (synopsis "A guix shell templating and automation system")
+      (description
+       "Graze is a command-line tool used for complex guix shell invocations, where a simple manifest does not suffice. Through the use of a shell.scm file, it allows for a declarative approach to Guix development environments, and a project templating system inspired by Nix's flake templates.")
+      (home-page
+   "https://gitlab.com/bigbookofbug/guix-graze")
+      (license license:gpl3+))))
+
 (define-public guile-imanifest
   (let ((commit "ccd5a2111b008d778106f5595a3a585954d95d0")
         (revision "0"))

base-commit: 0787a180b3ca64d3958438920ca1b58a2a27fba4
-- 
2.46.0






                 reply	other threads:[~2024-12-13 20:20 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20241213201839.14282-1-bigbookofbug@proton.me \
    --to=guix-patches@gnu.org \
    --cc=74858@debbugs.gnu.org \
    --cc=bigbookofbug@proton.me \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).