[PATCH 0/2] gnu: Add soupault.

  • Open
  • quality assurance status badge
Details
One participant
  • Lobo Torres
Owner
unassigned
Submitted by
Lobo Torres
Severity
normal
L
L
Lobo Torres wrote on 24 Apr 00:10 +0200
(address . guix-patches@gnu.org)(name . Lobo Torres)(address . lobo@quiltro.org)
cover.1713910041.git.lobo@quiltro.org
This patch adds Soupault https://soupault.app, a static site management tool,
alongside the OCaml libraries it depends on that were not packaged, and updates
`ocaml-camomile' to version 2.0.0, as the current packaged version is outdated.

Lobo Torres (2):
gnu: ocaml-camomile: Update to 2.0.0.
gnu: Add soupault.

gnu/packages/ocaml.scm | 342 +++++++++++++++++++++++++++++++++++------
gnu/packages/web.scm | 44 ++++++
2 files changed, 341 insertions(+), 45 deletions(-)


base-commit: 83e6437e92ad056838fe170963d920d446d0e4db
--
2.41.0
L
L
Lobo Torres wrote on 24 Apr 03:54 +0200
[PATCH 1/2] gnu: ocaml-camomile: Update to 2.0.0.
(address . 70545@debbugs.gnu.org)(name . Lobo Torres)(address . lobo@quiltro.org)
78d270643f8c776128f7ec09e1beb31dfb7de43e.1713910041.git.lobo@quiltro.org
* gnu/packages/ocaml.scm (ocaml-camomile): Update to 2.0.0.
* gnu/packages/ocaml.scm (ocaml-charinfo-width): Update to 2.0.0.
* gnu/packages/ocaml.scm (ocaml-stdlib-random): New variable.

Change-Id: I6d01453acc19db5df6a02343f96929d47721c911
---
gnu/packages/ocaml.scm | 109 ++++++++++++++++++++++++-----------------
1 file changed, 64 insertions(+), 45 deletions(-)

Toggle diff (146 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 7fad276b4e..75a42058d6 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -4825,6 +4825,33 @@ (define-public ocaml-stdlib-shims
;; with ocaml-linking exception
(license license:lgpl2.1+)))
+(define-public ocaml-stdlib-random
+ (package
+ (name "ocaml-stdlib-random")
+ (version "1.1.0")
+ (home-page "https://github.com/ocaml/stdlib-random")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append home-page
+ "/releases/download/"
+ version
+ "/stdlib-random-"
+ version
+ ".tbz"))
+ (sha256
+ (base32 "0n95h57z0d9hf1y5a3v7bbci303wl63jn20ymnb8n2v8zs1034wb"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-cppo ocaml-odoc))
+ (synopsis "Versioned random number library")
+ (description
+ "Compatibility library for Random number generation
+
+This library provides access to the various implementation of the Random
+module from the OCaml standard library independently of the compiler
+version.")
+ (license license:lgpl2.1+)))
+
(define-public ocaml-fileutils
(package
(name "ocaml-fileutils")
@@ -4832,8 +4859,8 @@ (define-public ocaml-fileutils
(source (origin
(method git-fetch)
(uri (git-reference
- (url "https://github.com/gildor478/ocaml-fileutils")
- (commit (string-append "v" version))))
+ (url "https://github.com/gildor478/ocaml-fileutils")
+ (commit (string-append "v" version))))
(file-name (git-file-name name version))
(sha256
(base32
@@ -5443,27 +5470,23 @@ (define-public bap
(define-public ocaml-camomile
(package
(name "ocaml-camomile")
- (version "1.0.2")
- (home-page "https://github.com/yoriyuki/Camomile")
- (source (origin
- (method url-fetch)
- (uri (string-append home-page "/releases/download/" version
- "/camomile-" version ".tbz"))
- (sha256
- (base32
- "0chn7ldqb3wyf95yhmsxxq65cif56smgz1mhhc7m0dpwmyq1k97h"))))
+ (version "2.0.0")
+ (home-page "https://github.com/ocaml-community/Camomile")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1br1as5xb8w0jds7yi23546nrf6sag8gkzkv5avkdlf3agwmfj8y"))))
(build-system dune-build-system)
- (arguments
- `(#:tests? #f ; Tests fail, see https://github.com/yoriyuki/Camomile/issues/82
- #:phases
- (modify-phases %standard-phases
- (add-before 'build 'fix-usr-share
- (lambda* (#:key outputs #:allow-other-keys)
- (substitute* '("Camomile/dune" "configure.ml")
- (("/usr/share") (string-append (assoc-ref outputs "out") "/share")))
- #t)))))
+ (propagated-inputs (list ocaml-camlp-streams dune-site))
+ (native-inputs (list ocaml-stdlib-random))
(synopsis "Comprehensive Unicode library")
- (description "Camomile is a Unicode library for OCaml. Camomile provides
+ (description
+ "Camomile is a Unicode library for OCaml. Camomile provides
Unicode character type, UTF-8, UTF-16, UTF-32 strings, conversion to/from about
200 encodings, collation and locale-sensitive case mappings, and more. The
library is currently designed for Unicode Standard 3.2.")
@@ -5472,31 +5495,27 @@ (define-public ocaml-camomile
(define-public ocaml-charinfo-width
;; Add LICENSE file and Dune tests
- (let ((commit "20aaaa6dca8f1e0b1ace55b6f2a8ba5e5910b620"))
- (package
- (name "ocaml-charinfo-width")
- (version (git-version "1.1.0" "1" commit))
- (home-page "https://github.com/kandu/charinfo_width/")
- (source (origin
- (method git-fetch)
- (uri (git-reference
- (url home-page)
- (commit commit)))
- (file-name (git-file-name name version))
- (sha256
- (base32
- "04gil5hxm2jax9paw3i24d8zyzhyl5cphzfyryvy2lcrm3c485q0"))))
- (build-system dune-build-system)
- (propagated-inputs
- (list ocaml-result ocaml-camomile))
- (native-inputs
- (list ocaml-ppx-expect))
- (properties
- `((upstream-name . "charInfo_width")))
- (synopsis "Determine column width for a character")
- (description "This module implements purely in OCaml a character width
+ (package
+ (name "ocaml-charinfo-width")
+ (version "2.0.0")
+ (home-page "https://github.com/kandu/charinfo_width/")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0f4siscbfm03bdgzip3n5m551v6zi8n4vgl69djnxa87mkfim015"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-result ocaml-camomile))
+ (native-inputs (list ocaml-ppx-expect))
+ (properties `((upstream-name . "charInfo_width")))
+ (synopsis "Determine column width for a character")
+ (description "This module implements purely in OCaml a character width
function that follows the prototype of POSIX's wcwidth.")
- (license license:expat))))
+ (license license:expat)))
(define-public ocaml-zed
(package
--
2.41.0
L
L
Lobo Torres wrote on 24 Apr 03:54 +0200
[PATCH 2/2] gnu: Add soupault.
(address . 70545@debbugs.gnu.org)(name . Lobo Torres)(address . lobo@quiltro.org)
364b7672205833223030e6438e15cd6cd0e69f33.1713910041.git.lobo@quiltro.org
* gnu/packages/web.scm (soupault): New variable.

* gnu/packages/ocaml.scm (ocaml-containers): New variable.
* gnu/packages/ocaml.scm (ocaml-iter): New variable.
* gnu/packages/ocaml.scm (ocaml-jingoo): New variable.
* gnu/packages/ocaml.scm (ocaml-lambdasoup): New variable.
* gnu/packages/ocaml.scm (ocaml-lua-ml): New variable.
* gnu/packages/ocaml.scm (ocaml-odate): New variable.
* gnu/packages/ocaml.scm (ocaml-otoml): New variable.
* gnu/packages/ocaml.scm (ocaml-spelll): New variable.
* gnu/packages/ocaml.scm (ocaml-tsort): New variable.

Change-Id: Ifde96b25cea2ce7373a174c7c15dfa584ecd7064
---
gnu/packages/ocaml.scm | 233 +++++++++++++++++++++++++++++++++++++++++
gnu/packages/web.scm | 44 ++++++++
2 files changed, 277 insertions(+)

Toggle diff (350 lines)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 75a42058d6..97ba9c5cff 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -1710,6 +1710,56 @@ (define-public ocaml-junit-alcotest
;; with OCaml linking exception
(license license:gpl3+)))
+(define-public ocaml-jingoo
+ (package
+ (name "ocaml-jingoo")
+ (version "1.5.0")
+ (home-page "https://github.com/tategakibunko/jingoo")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "08qymg1p598q75i7zlma17kwqms83iym46m0wdgfffi0rank0rpd"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-menhir ocaml-ppx-deriving ocaml-re
+ ocaml-uutf ocaml-uucp))
+ (native-inputs (list ocaml-ounit))
+ (synopsis "Template engine almost compatible with Jinja2")
+ (description "Jingoo is an OCaml template engine almost compatible with
+Jinja2 (the Python template engine).")
+ (license license:expat)))
+
+(define-public ocaml-lambdasoup
+ (package
+ (name "ocaml-lambdasoup")
+ (version "1.0.0")
+ (home-page "https://github.com/aantron/lambdasoup")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "04jd0rjjqcrzm0w490v2bg0bsyps9qgaw63q0fybp474kcvj369x"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-camlp-streams ocaml-markup))
+ (native-inputs (list ocaml-bisect-ppx ocaml-ounit2))
+ (synopsis "Functional HTML scraping and rewriting with CSS in OCaml")
+ (description
+ "Lambda Soup is a functional HTML scraping and manipulation
+library for OCaml aimed at being easy to use. It provides a set of elementary
+traversals for getting from node to node, familiar functional combinators such
+as filter, map, and fold, and support for all CSS selectors that still make
+sense when not running in a browser (and a few obvious extensions on top of
+that).")
+ (license license:expat)))
+
(define-public camlzip
(package
(name "camlzip")
@@ -2402,6 +2452,38 @@ (define-public ocaml-toml
(home-page "https://github.com/ocaml-toml/To.ml")
(license license:expat)))
+(define-public ocaml-otoml
+ (package
+ (name "ocaml-otoml")
+ (version "1.0.5")
+ (home-page "https://github.com/dmbaturin/otoml")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0cchvfwzxrckr4zj5psinq47z2y9lhvb5vyc5hjvi8l7l9vnml3v"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-menhir ocaml-uutf))
+ (native-inputs (list ocaml-ounit2 ocaml-odoc))
+ (synopsis
+ "TOML parsing, manipulation, and pretty-printing library (1.0.0-compliant)")
+ (description
+ "OTOML is a library for parsing, manipulating, and
+pretty-printing TOML files.
+
+* Fully 1.0.0-compliant.
+* No extra dependencies: default implementation uses native numbers and
+represents dates as strings.
+* Provides a functor for building alternative implementations: plug your own
+bignum and calendar libraries if required.
+* Informative parse error reporting.
+* Pretty-printer offers flexible indentation options.")
+ (license license:expat)))
+
(define-public ocaml-grain-dypgen
(package
(name "ocaml-grain-dypgen")
@@ -2630,6 +2712,32 @@ (define-public ocaml-calendar
;; With linking exception.
(license license:lgpl2.1+))))
+(define-public ocaml-odate
+ (package
+ (name "ocaml-odate")
+ (version "0.7")
+ (home-page "https://github.com/hhugo/odate")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append home-page
+ "/releases/download/"
+ version
+ "/odate-"
+ version
+ ".tbz"))
+ (sha256
+ (base32 "1bsmix8qbsk04a1l2x4lrh919xq6a3pmanvgkdlc5wwp3p42q6bl"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-menhir))
+ (arguments
+ ;; broken tests, see https://github.com/hhugo/odate/issues/7
+ '(#:tests? #f))
+ (synopsis "Date & duration library for OCaml")
+ (description "Simple date and duration manipulation. Also implements
+duration printer based on string format.")
+ (license license:expat)))
+
(define-public ocaml-cmdliner
(package
(name "ocaml-cmdliner")
@@ -5551,6 +5659,59 @@ (define-public ocaml-zed
capabilities, Zed provides macro recording and cursor management facilities.")
(license license:bsd-3)))
+(define-public ocaml-spelll
+ (package
+ (name "ocaml-spelll")
+ (version "0.4")
+ (home-page "https://github.com/c-cube/spelll")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit (string-append "v" version))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1rx8i98wqn8pp5rzb185i1xl4q40m06242gms1xp9jnq19s1z3ww"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-seq ocaml-stdlib-shims))
+ (native-inputs (list ocaml-qcheck ocaml-mdx ocaml-odoc))
+ (synopsis "Fuzzy string searching, using Levenshtein automaton")
+ (description "Fuzzy string searching, using Levenshtein automaton. Can be
+used for spell-checking.")
+ (license license:bsd-2)))
+
+(define-public ocaml-tsort
+ (package
+ (name "ocaml-tsort")
+ (version "2.1.0")
+ (home-page "https://github.com/dmbaturin/ocaml-tsort")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "07m88nxb9w6wv64h18xyz7js6flpglkk5c8lhs8wgh46r13p89s8"))))
+ (build-system dune-build-system)
+ (inputs (list ocaml-containers))
+ (arguments
+ ;; no tests with dune build system
+ '(#:tests? #f))
+ (synopsis
+ "Easy to use and user-friendly topological sort module for OCaml")
+ (description
+ "@code{ocaml-tsort} is a library for sorting graphs in topological
+order.
+
+* Uses Kahn's algorithm.
+* Easy to use, but not very fast.
+* Provides friendly error reporting (e.g., if there's a cycle, tells you what
+the offending nodes are).")
+ (license license:expat)))
+
(define-public ocaml-lambda-term
(package
(name "ocaml-lambda-term")
@@ -6487,6 +6648,56 @@ (define-public ocaml5.0-base
"15vsiv3q53l1bzrvqgspf3lp2104s9dzw62z3nl75f53jvjvsyf6"))))
(properties '())))))
+(define-public ocaml-iter
+ (package
+ (name "ocaml-iter")
+ (version "1.8")
+ (home-page "https://github.com/c-cube/iter")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append home-page
+ "/releases/download/v"
+ version
+ "/iter-"
+ version
+ ".tbz"))
+ (sha256
+ (base32 "08rhykcizbs21mri4zx1b6vg42a4wybl238cla5bmi79bah9qwzq"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-qcheck ocaml-ounit2 ocaml-mdx ocaml-odoc))
+ (synopsis "Simple iterator abstract datatype")
+ (description
+ "A simple abstraction over @code{iter} functions intended to
+iterate efficiently on collections while performing some transformations.
+Common operations supported include @code{filter}, @code{map}, @code{take},
+@code{drop}, @code{append}, @code{flat_map}, etc.")
+ (license license:bsd-2)))
+
+(define-public ocaml-containers
+ (package
+ (name "ocaml-containers")
+ (version "3.13.1")
+ (home-page "https://github.com/c-cube/ocaml-containers")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (string-append home-page
+ "/releases/download/v"
+ version
+ "/containers-"
+ version
+ ".tbz"))
+ (sha256
+ (base32 "114pcswmscbh5mvniiarbk5jqma3kjs6w9bx2p2lzw1w5kmjd6zb"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-either))
+ (native-inputs (list ocaml-qcheck ocaml-iter ocaml-gen ocaml-yojson ocaml-mdx))
+ (synopsis "Lightweight, modular standard library extension of OCaml")
+ (description "Containers is an extension of OCaml's standard library
+focused on data structures, combinators and iterators.")
+ (license license:bsd-2)))
+
(define-public ocaml-compiler-libs
(package
(name "ocaml-compiler-libs")
@@ -9362,6 +9573,28 @@ (define-public ocaml-bibtex2html
bibliography files in BibTeX format, a bibliography in HTML format.")
(license license:gpl2)))
+(define-public ocaml-lua-ml
+ (package
+ (name "ocaml-lua-ml")
+ (version "0.9.4")
+ (home-page "https://github.com/lindig/lua-ml")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url home-page)
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0rz9v7wss4i8jc87c9rmn7b3mhv1cdnxy1kcln6ibbd574gm7h4h"))))
+ (build-system dune-build-system)
+ (native-inputs (list ocaml-odoc))
+ (synopsis "Embeddable Lua 2.5 interpreter implemented in OCaml")
+ (description
+ "Lua-ML is an implementation of the Lua 2.5 programming
+language written in OCaml and designed for extending OCaml programs.")
+ (license license:bsd-2)))
+
(define-public ocaml-guile
(package
(name "ocaml-guile")
diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index a71a0e07a3..d4149b571f 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -96,6 +96,7 @@ (define-module (gnu packages web)
#:use-module (guix build-system cargo)
#:use-module (guix build-system cmake)
#:use-module (guix build-system copy)
+ #:use-module (guix build-system dune)
#:use-module (guix build-system glib-or-gtk)
#:use-module (guix build-system gnu)
#:use-module (guix build-system go)
@@ -178,6 +179,7 @@ (define-module (gnu packages web)
#:use-module (gnu packages networking)
#:use-module (gnu packages node)
#:use-module (gnu packages nss)
+ #:use-module (gnu packages ocaml)
#:use-module (gnu packages openldap)
#:use-module (gnu packages openstack)
#:use-module (gnu packages package-management)
@@ -8833,6 +8835,48 @@ (define-public kiln
and can be extended with the use of external commands.")
(license license:expat)))
+(define-public soupault
+ (package
+ (name "soupault")
+ (version "4.10.0")
+ (home-page "https://soupault.app/")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/PataphysicalSociety/soupault")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "17jxxlrxpwsmhn9g7zf36pq842vh7l8122f4v1jbm3qh1rdx2ils"))))
+ (build-system dune-build-system)
+ (inputs (list ocaml-base64
+ ocaml-camomile
+ ocaml-containers
+ ocaml-csv
+ ocaml-digestif
+ ocaml-ezjsonm
+ ocaml-fileutils
+ ocaml-fmt
+ ocaml-jingoo
+ ocaml-lambdasoup
+ ocaml-lua-ml
+ ocaml-logs
+ ocaml-markup
+ ocaml-odate
+ ocaml-otoml
+ ocaml-re
+ ocaml-spelll
+ ocaml-tsort
+ ocaml-yaml))
+ (synopsis "Static website management tool")
+ (description
+ "A static website generator/framework that works with HTML
+element trees and can automatically manipulate them. It can be described as a
+robotic webmaster that can edit HTML pages according to your rules, but
+doesn’t get tired of editing them.")
+ (license license:expat)))
+
(define-public siege
(package
(name "siege")
--
2.41.0
?