diff mbox series

[bug#56037,03/14] gnu: Add rust-similar-2.

Message ID 371bac1e750c318007a519831f73547c5a85100f.1655465108.git.foo.dogsquared@gmail.com
State New
Headers show
Series [bug#56037,01/14] gnu: Add rust-kstring-2. | expand

Checks

Context Check Description
cbaines/comparison success View comparision
cbaines/git branch success View Git branch
cbaines/applying patch success View Laminar job
cbaines/issue success View issue

Commit Message

Gabriel Arazas June 17, 2022, 11:59 a.m. UTC
* gnu/packages/crates-io.scm (rust-similar-2): New variable.
(rust-similar-1): Inherit and adjust.
---
 gnu/packages/crates-io.scm | 30 ++++++++++++++++++++++++------
 1 file changed, 24 insertions(+), 6 deletions(-)
diff mbox series

Patch

diff --git a/gnu/packages/crates-io.scm b/gnu/packages/crates-io.scm
index 88339619ca..8278bef7a6 100644
--- a/gnu/packages/crates-io.scm
+++ b/gnu/packages/crates-io.scm
@@ -56363,8 +56363,31 @@  (define-public rust-simdutf8-0.1
 extensions.")
     (license (list license:expat license:asl2.0))))
 
+(define-public rust-similar-2
+  (package
+    (name "rust-similar")
+    (version "2.1.0")
+    (source (origin
+              (method url-fetch)
+              (uri (crate-uri "similar" version))
+              (file-name (string-append name "-" version ".tar.gz"))
+              (sha256
+               (base32
+                "1lw33na01r35h09s47jqhjgz3m29wapl20f6ybsla5d1cfgrf91f"))))
+    (build-system cargo-build-system)
+    (arguments
+     `(#:skip-build? #t
+       #:cargo-inputs
+       (("rust-bstr" ,rust-bstr-0.2) ("rust-serde" ,rust-serde-1)
+        ("rust-unicode-segmentation" ,rust-unicode-segmentation-1))))
+    (home-page "https://github.com/mitsuhiko/similar")
+    (synopsis "A diff library for Rust")
+    (description "This package provides a diff library for Rust.")
+    (license license:asl2.0)))
+
 (define-public rust-similar-1
   (package
+    (inherit rust-similar-2)
     (name "rust-similar")
     (version "1.3.0")
     (source
@@ -56379,12 +56402,7 @@  (define-public rust-similar-1
      `(#:skip-build? #t
        #:cargo-inputs
        (("rust-bstr" ,rust-bstr-0.2)
-        ("rust-unicode-segmentation" ,rust-unicode-segmentation-1))))
-    (home-page
-     "https://github.com/mitsuhiko/similar")
-    (synopsis "Diff library for Rust")
-    (description "This package provides a diff library for Rust.")
-    (license license:asl2.0)))
+        ("rust-unicode-segmentation" ,rust-unicode-segmentation-1))))))
 
 (define-public rust-simplelog-0.11
   (package