diff mbox series

[bug#60673,01/39] gnu: Add ocaml-domain-name.

Message ID 20230109003529.23375-1-raingloom@riseup.net
State New
Headers show
Series [bug#60673,01/39] gnu: Add ocaml-domain-name. | expand

Commit Message

Csepp Jan. 9, 2023, 12:34 a.m. UTC
From: raingloom <raingloom@riseup.net>

gnu/packages/ocaml.scm (ocaml-domain-name): New variable.
---
 gnu/packages/ocaml.scm | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

Comments

Christopher Baines Feb. 7, 2023, 7:57 a.m. UTC | #1
Hey,

While I think the builds look OK for this series, there are quite a few
formatting issues raised by the linter (this can be seen on [1] and [2]).

1: https://qa.guix.gnu.org/issue/60674
2: https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519

Could you run the linter on the packages you've added here, address the
issues it raises and send an updated series?

Thanks,

Chris
Csepp Feb. 8, 2023, 1:37 a.m. UTC | #2
Christopher Baines <mail@cbaines.net> writes:

> [[PGP Signed Part:Undecided]]
> Hey,
>
> While I think the builds look OK for this series, there are quite a few
> formatting issues raised by the linter (this can be seen on [1] and [2]).
>
> 1: https://qa.guix.gnu.org/issue/60674
> 2:
> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>
> Could you run the linter on the packages you've added here, address the
> issues it raises and send an updated series?
>
> Thanks,
>
> Chris
>
> [[End of PGP Signed Part]]

Those are all URL constants, can't really do much about them other than slice
them up with string-append, which I'm not sure really helps with
readability or ease of editing.  They were not an issue while I was
editing the code and gnu/packages/ocaml.scm already has a lot of lines
that whitespace-mode highlights as too long, so I thought it wouldn't
matter much and my time would be better spent elsewhere.
The real fix IMHO would be to convert them into git-fetch origins, which
would also make it possible to use git related package transforms.  This
is on my TODO list.
Or at least the OPAM importer should be changed to do the URL splitting.
Christopher Baines Feb. 8, 2023, 7:32 a.m. UTC | #3
Csepp <raingloom@riseup.net> writes:

> Christopher Baines <mail@cbaines.net> writes:
>
>> [[PGP Signed Part:Undecided]]
>> Hey,
>>
>> While I think the builds look OK for this series, there are quite a few
>> formatting issues raised by the linter (this can be seen on [1] and [2]).
>>
>> 1: https://qa.guix.gnu.org/issue/60674
>> 2:
>> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>>
>> Could you run the linter on the packages you've added here, address the
>> issues it raises and send an updated series?
>>
>> Thanks,
>>
>> Chris
>>
>> [[End of PGP Signed Part]]
>
> Those are all URL constants, can't really do much about them other than slice
> them up with string-append, which I'm not sure really helps with
> readability or ease of editing.  They were not an issue while I was
> editing the code and gnu/packages/ocaml.scm already has a lot of lines
> that whitespace-mode highlights as too long, so I thought it wouldn't
> matter much and my time would be better spent elsewhere.

You're right that there are quite a few other instances of lines that
are too long in that module, but I don't think that's a reason not to
add more. I think splitting the long URL strings with string-append is a
good approach and can help with readability.
Csepp Feb. 15, 2023, 9:59 p.m. UTC | #4
Updated version of the packages needed to build the hello world unikernel.
Lint warnings taken care of, the few that remain are false positives related
to upgrades to versions that are not actually newer.
Csepp Feb. 17, 2023, 1:03 a.m. UTC | #5
Christopher Baines <mail@cbaines.net> writes:

> [[PGP Signed Part:Undecided]]
>
> Csepp <raingloom@riseup.net> writes:
>
>> Christopher Baines <mail@cbaines.net> writes:
>>
>>> [[PGP Signed Part:Undecided]]
>>> Hey,
>>>
>>> While I think the builds look OK for this series, there are quite a few
>>> formatting issues raised by the linter (this can be seen on [1] and [2]).
>>>
>>> 1: https://qa.guix.gnu.org/issue/60674
>>> 2:
>>> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>>>
>>> Could you run the linter on the packages you've added here, address the
>>> issues it raises and send an updated series?
>>>
>>> Thanks,
>>>
>>> Chris
>>>
>>> [[End of PGP Signed Part]]
>>
>> Those are all URL constants, can't really do much about them other than slice
>> them up with string-append, which I'm not sure really helps with
>> readability or ease of editing.  They were not an issue while I was
>> editing the code and gnu/packages/ocaml.scm already has a lot of lines
>> that whitespace-mode highlights as too long, so I thought it wouldn't
>> matter much and my time would be better spent elsewhere.
>
> You're right that there are quite a few other instances of lines that
> are too long in that module, but I don't think that's a reason not to
> add more. I think splitting the long URL strings with string-append is a
> good approach and can help with readability.
>
> [[End of PGP Signed Part]]

Alright, got around to sending the updated patch series.  Hopefully I
got the send-email arguments right.
Julien Lepiller Feb. 17, 2023, 6:41 a.m. UTC | #6
https://qa.guix.gnu.org/issue/60673 has picked it up at least :). We still need to wait for a few builds.

Le 17 février 2023 02:03:46 GMT+01:00, Csepp <raingloom@riseup.net> a écrit :
>
>Christopher Baines <mail@cbaines.net> writes:
>
>> [[PGP Signed Part:Undecided]]
>>
>> Csepp <raingloom@riseup.net> writes:
>>
>>> Christopher Baines <mail@cbaines.net> writes:
>>>
>>>> [[PGP Signed Part:Undecided]]
>>>> Hey,
>>>>
>>>> While I think the builds look OK for this series, there are quite a few
>>>> formatting issues raised by the linter (this can be seen on [1] and [2]).
>>>>
>>>> 1: https://qa.guix.gnu.org/issue/60674
>>>> 2:
>>>> https://data.qa.guix.gnu.org/compare?base_commit=238f965c331990459a69cbc713ca951ad40e6044&target_commit=3b5485b9cdaebda127dc040ad67a287f39e33519
>>>>
>>>> Could you run the linter on the packages you've added here, address the
>>>> issues it raises and send an updated series?
>>>>
>>>> Thanks,
>>>>
>>>> Chris
>>>>
>>>> [[End of PGP Signed Part]]
>>>
>>> Those are all URL constants, can't really do much about them other than slice
>>> them up with string-append, which I'm not sure really helps with
>>> readability or ease of editing.  They were not an issue while I was
>>> editing the code and gnu/packages/ocaml.scm already has a lot of lines
>>> that whitespace-mode highlights as too long, so I thought it wouldn't
>>> matter much and my time would be better spent elsewhere.
>>
>> You're right that there are quite a few other instances of lines that
>> are too long in that module, but I don't think that's a reason not to
>> add more. I think splitting the long URL strings with string-append is a
>> good approach and can help with readability.
>>
>> [[End of PGP Signed Part]]
>
>Alright, got around to sending the updated patch series.  Hopefully I
>got the send-email arguments right.
>
>
>
Christopher Baines Feb. 17, 2023, 3:50 p.m. UTC | #7
Julien Lepiller <julien@lepiller.eu> writes:

> https://qa.guix.gnu.org/issue/60673 has picked it up at least :). We
> still need to wait for a few builds.

Everything looks to have built on x86_64-linux and aarch64-linux, plus
there are no introduced lint warnings now (for the checkers the data
service runs at least), so I've gone ahead and pushed these patches to
master as 48724a66422e02995e62e2f707dcd9087d43bee5.

Thanks,

Chris
diff mbox series

Patch

diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index c3a586f091..41485b3686 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -27,6 +27,7 @@ 
 ;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
 ;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
 ;;; Copyright © 2022 Garek Dyszel <garekdyszel@disroot.org>
+;;; Copyright © 2023 Csepp <raingloom@riseup.net>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -3537,6 +3538,28 @@  (define-public ocaml-ocp-index
     (license (list license:gpl3+
                    license:lgpl2.1+))))
 
+(define-public ocaml-domain-name
+  (package
+    (name "ocaml-domain-name")
+    (version "0.4.0")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url "https://github.com/hannesm/domain-name/")
+                    (commit (string-append "v" version))))
+              (file-name name)
+              (sha256
+               (base32
+                "1a669zz1pc7sqbi1c13jsnp8algcph2b8gr5fjrjhyh3p232770k"))))
+    (build-system dune-build-system)
+    (native-inputs (list ocaml-alcotest))
+    (home-page "https://github.com/hannesm/domain-name")
+    (synopsis "RFC 1035 Internet domain name data structure and parser")
+    (description
+     "Parses and constructs RFC compliant domain names.  The invariants on the
+length of domain names are preserved throughout the module.")
+    (license license:isc)))
+
 (define-public ocaml-ocurl
   (package
     (name "ocaml-ocurl")