unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#53317] [PATCH] Add guile-srfi-189.
@ 2022-01-17 13:20 Attila Lendvai
  2022-01-17 13:49 ` [bug#53317] how to test it Attila Lendvai
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Attila Lendvai @ 2022-01-17 13:20 UTC (permalink / raw)
  To: 53317; +Cc: Attila Lendvai

* gnu/packages/guile-xyz.scm (guile-srfi-189): New variable.
---

this is mimicing guile-srfi-180.

please note that there's quite an anomaly among the guile-srfi packages,
including which guile they depend on, and the use of native-inputs vs.
inputs. it may be worth cleaning that up for someone with a better
overview of what's going on here.

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

diff --git a/gnu/packages/guile-xyz.scm b/gnu/packages/guile-xyz.scm
index 74567830e6..6e46a8f376 100644
--- a/gnu/packages/guile-xyz.scm
+++ b/gnu/packages/guile-xyz.scm
@@ -3173,6 +3173,51 @@ (define-public guile-srfi-180
 API.")
       (license license:expat))))
 
+(define-public guile-srfi-189
+  (let ((commit "a0e3786702956c9e510d92746474ac988c2010ec")
+        (revision "0"))
+    (package
+      (name "guile-srfi-189")
+      (version (git-version "0" revision commit))
+      (source
+       (origin
+         (method git-fetch)
+         (uri (git-reference
+               ;; This is a fork of:
+               ;; (url "https://github.com/scheme-requests-for-implementation/srfi-189")
+               ;; Upstream merge requested at:
+               ;; https://github.com/scheme-requests-for-implementation/srfi-189/pull/21
+               ;; TODO switch over to the official repo when the PR gets merged
+               (url "https://github.com/attila-lendvai-patches/srfi-189")
+               (commit commit)))
+         (sha256
+          (base32
+           "0iqv4sjwbp4k87r9l9abzbs5yjcljm69m91kb1ypb03b0rx7napy"))
+         (modules '((guix build utils)))
+         (snippet
+          '(begin
+             (delete-file "test-syntax.scm")
+             (delete-file "test.scm")))
+         (file-name (git-file-name name version))))
+      (build-system guile-build-system)
+      (arguments
+       '(#:not-compiled-file-regexp "srfi/189\\.scm$")) ; it's INCLUDE'd
+      (native-inputs
+       (list guile-3.0))
+      (propagated-inputs
+       (list guile-srfi-145))
+      (home-page "https://srfi.schemers.org/srfi-189/")
+      (synopsis "Scheme SRFI implementation of Maybe and Either")
+      (description
+       "This SRFI defines two disjoint immutable container types known as
+Maybe and Either, both of which can contain objects collectively known
+as their payload.  A Maybe object is either a Just object or the unique
+object Nothing (which has no payload); an Either object is either a Right
+object or a Left object.  Maybe represents the concept of optional values;
+Either represents the concept of values which are either correct (Right)
+or errors (Left).")
+      (license license:expat))))
+
 (define-public emacsy
   (package
     (name "emacsy")
-- 
2.34.0





^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#53317] how to test it
  2022-01-17 13:20 [bug#53317] [PATCH] Add guile-srfi-189 Attila Lendvai
@ 2022-01-17 13:49 ` Attila Lendvai
  2022-01-17 23:13 ` [bug#53317] (no subject) jgart via Guix-patches via
  2022-01-18 21:44 ` bug#53317: [PATCH] Add guile-srfi-189 Ludovic Courtès
  2 siblings, 0 replies; 4+ messages in thread
From: Attila Lendvai @ 2022-01-17 13:49 UTC (permalink / raw)
  To: 53317@debbugs.gnu.org

[-- Attachment #1: Type: text/plain, Size: 234 bytes --]

you can test it using:

```
$ ./pre-inst-env guix shell guile guile-srfi-189 -- guile
GNU Guile 3.0.7

[...]

scheme@(guile-user)> (use-modules (srfi srfi-189))
scheme@(guile-user)> (nothing)
$1 = #<<nothing>>
scheme@(guile-user)>
```

[-- Attachment #2: Type: text/html, Size: 1210 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#53317] (no subject)
  2022-01-17 13:20 [bug#53317] [PATCH] Add guile-srfi-189 Attila Lendvai
  2022-01-17 13:49 ` [bug#53317] how to test it Attila Lendvai
@ 2022-01-17 23:13 ` jgart via Guix-patches via
  2022-01-18 21:44 ` bug#53317: [PATCH] Add guile-srfi-189 Ludovic Courtès
  2 siblings, 0 replies; 4+ messages in thread
From: jgart via Guix-patches via @ 2022-01-17 23:13 UTC (permalink / raw)
  To: 53317

Hi Attila,

I added this package to Guix 'R Us as a pre-release:

https://git.sr.ht/~whereiseveryone/guixrus/commit/983d105cc22b81b2fe009360f0977510afb69cc2

Great stuff! Thanks!

all best,

jgart

gemini://whereiseveryone.srht.site/
https://whereiseveryone.srht.site/




^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#53317: [PATCH] Add guile-srfi-189.
  2022-01-17 13:20 [bug#53317] [PATCH] Add guile-srfi-189 Attila Lendvai
  2022-01-17 13:49 ` [bug#53317] how to test it Attila Lendvai
  2022-01-17 23:13 ` [bug#53317] (no subject) jgart via Guix-patches via
@ 2022-01-18 21:44 ` Ludovic Courtès
  2 siblings, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2022-01-18 21:44 UTC (permalink / raw)
  To: Attila Lendvai; +Cc: 53317-done

Hi,

Attila Lendvai <attila@lendvai.name> skribis:

> * gnu/packages/guile-xyz.scm (guile-srfi-189): New variable.
> ---
>
> this is mimicing guile-srfi-180.
>
> please note that there's quite an anomaly among the guile-srfi packages,
> including which guile they depend on, and the use of native-inputs vs.
> inputs. it may be worth cleaning that up for someone with a better
> overview of what's going on here.

I think it’s fine.

Applied, thanks!

Ludo’.




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-01-18 21:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-01-17 13:20 [bug#53317] [PATCH] Add guile-srfi-189 Attila Lendvai
2022-01-17 13:49 ` [bug#53317] how to test it Attila Lendvai
2022-01-17 23:13 ` [bug#53317] (no subject) jgart via Guix-patches via
2022-01-18 21:44 ` bug#53317: [PATCH] Add guile-srfi-189 Ludovic Courtès

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).