Subject: [PATCH 13/28] gnu: Add ruby-specinfra.

From: Hartmut Goebel <[email-masked]>
Date: Thu, 8 Feb 2024 10:35:43 +0100

* gnu/packages/ruby.scm (ruby-specinfra): New variable.
---
 gnu/packages/ruby.scm | 29 +++++++++++++++++++++++++++++
 1 file changed, 29 insertions(+)

diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 0086ae42df..417ae9b277 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -1211,6 +1211,35 @@ (define-public ruby-rspec-debug
     (home-page "https://github.com/ko1/rspec-debug")
     (license license:expat)))
 
+(define-public ruby-specinfra
+  (package
+    (name "ruby-specinfra")
+    (version "2.87.2")
+    (source (origin
+              (method url-fetch)
+              (uri (rubygems-uri "specinfra" version))
+              (sha256
+               (base32
+                "08d5a5mqswkcjz3cq2vmaivngfr3k8f3gydbs8mj4ffdbdywz7cn"))))
+    (build-system ruby-build-system)
+    (propagated-inputs (list ruby-net-scp ruby-net-ssh ruby-net-telnet
+                             ruby-sfl))
+    (arguments
+     (list
+      #:test-target "spec"
+      #:phases
+      #~(modify-phases %standard-phases
+          (add-after 'extract-gemspec 'relax-dependencies
+            (lambda _
+              (substitute* "specinfra.gemspec"
+                (("%q<net-telnet>.freeze, \\[.*\\]")
+                 "%q<net-telnet>.freeze, [\">= 0\"]")))))))
+    (synopsis "Common layer for serverspec and itamae")
+    (description "This Gem provides a common layer for serverspec and
+itamae.")
+    (home-page "https://github.com/mizzy/specinfra")
+    (license license:expat)))
+
 ;; Bundler is yet another source of circular dependencies, so we must disable
 ;; its test suite as well.
 (define-public bundler
-- 
2.41.0