gnu: ruby-highline: Update to 2.0.1.
[jackhill/guix/guix.git] / gnu / packages / ruby.scm
CommitLineData
6ef8c59a 1;;; GNU Guix --- Functional package management for GNU
37ab3aba 2;;; Copyright © 2014, 2015 Pjotr Prins <pjotr.guix@thebird.nl>
402b03e6 3;;; Copyright © 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
f586c877 4;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
37ab3aba 5;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org>
6742c6f6 6;;; Copyright © 2015, 2019 Ricardo Wurmus <rekado@elephly.net>
cba53c60 7;;; Copyright © 2015, 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
4a78fd46 8;;; Copyright © 2017 Nils Gillmann <ng0@n0.is>
0899352f 9;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
2e77bbed 10;;; Copyright © 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
81a22171 11;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
6a9d2266 12;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
4db80f8b 13;;; Copyright © 2018 Vasile Dumitrascu <va511e@yahoo.com>
8ef06557 14;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
6ef8c59a
PP
15;;;
16;;; This file is part of GNU Guix.
17;;;
18;;; GNU Guix is free software; you can redistribute it and/or modify it
19;;; under the terms of the GNU General Public License as published by
20;;; the Free Software Foundation; either version 3 of the License, or (at
21;;; your option) any later version.
22;;;
23;;; GNU Guix is distributed in the hope that it will be useful, but
24;;; WITHOUT ANY WARRANTY; without even the implied warranty of
25;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
26;;; GNU General Public License for more details.
27;;;
28;;; You should have received a copy of the GNU General Public License
29;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
30
31(define-module (gnu packages ruby)
32 #:use-module ((guix licenses) #:prefix license:)
33 #:use-module (gnu packages)
1db791d5 34 #:use-module (gnu packages base)
15b16c2c 35 #:use-module (gnu packages check)
6ef8c59a 36 #:use-module (gnu packages compression)
4a9e0585 37 #:use-module (gnu packages databases)
255d1bbe 38 #:use-module (gnu packages dbm)
c41fba01 39 #:use-module (gnu packages rails)
6ef8c59a 40 #:use-module (gnu packages readline)
6ef8c59a 41 #:use-module (gnu packages autotools)
ad79eb55 42 #:use-module (gnu packages java)
6ef8c59a 43 #:use-module (gnu packages libffi)
f3d7bb93 44 #:use-module (gnu packages libidn)
c41fba01
CB
45 #:use-module (gnu packages linux)
46 #:use-module (gnu packages lsof)
34138e42 47 #:use-module (gnu packages maths)
0c8eedc1 48 #:use-module (gnu packages ncurses)
fe5dd5f4 49 #:use-module (gnu packages networking)
ac09beba 50 #:use-module (gnu packages python)
44d10b1f 51 #:use-module (gnu packages python-xyz)
763624f5 52 #:use-module (gnu packages ragel)
cd0322a3 53 #:use-module (gnu packages sqlite)
cc2b77df 54 #:use-module (gnu packages tls)
66e20863 55 #:use-module (gnu packages version-control)
6ef8c59a
PP
56 #:use-module (guix packages)
57 #:use-module (guix download)
bda0c139 58 #:use-module (guix git-download)
6ef8c59a 59 #:use-module (guix utils)
acf735f2 60 #:use-module (guix build-system gnu)
e920bfca 61 #:use-module (gnu packages xml)
c2c4e5b2 62 #:use-module (gnu packages web)
15b16c2c
CB
63 #:use-module (guix build-system ruby)
64 #:use-module ((srfi srfi-1) #:select (alist-delete)))
6ef8c59a
PP
65
66(define-public ruby
67 (package
68 (name "ruby")
35db2ba7 69 (version "2.5.3")
6ef8c59a
PP
70 (source
71 (origin
72 (method url-fetch)
6becfdff
MW
73 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
74 (version-major+minor version)
12d39eb5 75 "/ruby-" version ".tar.xz"))
6ef8c59a
PP
76 (sha256
77 (base32
35db2ba7 78 "0vrhrw7kcz9mg0jkqnihkcxqy5k05v8k1j0y2735z8wfk8sx1j8w"))
65e84e31
BW
79 (modules '((guix build utils)))
80 (snippet `(begin
81 ;; Remove bundled libffi
c033c195 82 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
65e84e31 83 #t))))
6ef8c59a
PP
84 (build-system gnu-build-system)
85 (arguments
86 `(#:test-target "test"
6ef8c59a 87 #:phases
9656b8be 88 (modify-phases %standard-phases
65e84e31 89 (add-before 'configure 'replace-bin-sh-and-remove-libffi
9656b8be
BW
90 (lambda _
91 (substitute* '("Makefile.in"
92 "ext/pty/pty.c"
93 "io.c"
94 "lib/mkmf.rb"
95 "process.c"
96 "test/rubygems/test_gem_ext_configure_builder.rb"
97 "test/rdoc/test_rdoc_parser.rb"
98 "test/ruby/test_rubyoptions.rb"
99 "test/ruby/test_process.rb"
100 "test/ruby/test_system.rb"
101 "tool/rbinstall.rb")
102 (("/bin/sh") (which "sh")))
103 #t)))))
6ef8c59a
PP
104 (inputs
105 `(("readline" ,readline)
6ef8c59a
PP
106 ("openssl" ,openssl)
107 ("libffi" ,libffi)
108 ("gdbm" ,gdbm)
109 ("zlib" ,zlib)))
110 (native-search-paths
111 (list (search-path-specification
112 (variable "GEM_PATH")
3cb3fa67 113 (files (list (string-append "lib/ruby/vendor_ruby"))))))
6becfdff 114 (synopsis "Programming language interpreter")
6ef8c59a
PP
115 (description "Ruby is a dynamic object-oriented programming language with
116a focus on simplicity and productivity.")
bf3be6a5 117 (home-page "https://www.ruby-lang.org")
6ef8c59a
PP
118 (license license:ruby)))
119
93cae02f
CB
120(define-public ruby-2.4
121 (package
122 (inherit ruby)
123 (version "2.4.3")
124 (source
125 (origin
126 (method url-fetch)
127 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
128 (version-major+minor version)
129 "/ruby-" version ".tar.xz"))
130 (sha256
131 (base32
132 "0l9bv67dgsphk42lmiskhrnh47hbyj6rfg2rcjx22xivpx07srr3"))
133 (patches (search-patches "ruby-rubygems-276-for-ruby24.patch"))
134 (modules '((guix build utils)))
135 (snippet `(begin
136 ;; Remove bundled libffi
137 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
138 #t))))))
139
98bb983c 140(define-public ruby-2.3
800a7dd5
BW
141 (package
142 (inherit ruby)
2e77bbed 143 (version "2.3.8")
800a7dd5
BW
144 (source
145 (origin
146 (method url-fetch)
147 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
148 (version-major+minor version)
149 "/ruby-" version ".tar.xz"))
150 (sha256
151 (base32
2e77bbed 152 "1zhxbjff08pvbnxvn58krns6q0p6g4977q6ykfn823gxhifn63wi"))
800a7dd5
BW
153 (modules '((guix build utils)))
154 (snippet `(begin
155 ;; Remove bundled libffi
156 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
157 #t))))))
158
823ed097
CB
159(define-public ruby-highline
160 (package
161 (name "ruby-highline")
6742c6f6 162 (version "2.0.1")
823ed097
CB
163 (source
164 (origin
165 (method url-fetch)
166 (uri (rubygems-uri "highline" version))
167 (sha256
168 (base32
6742c6f6 169 "0gr6pckj2jayxw1gdgh9193j5jag5zrrqqlrnl4jvcwpyd3sn2zc"))))
823ed097
CB
170 (build-system ruby-build-system)
171 (arguments
172 `(#:tests? #f)) ;; TODO: NameError: uninitialized constant SPEC
173 (native-inputs
174 `(("bundler" ,bundler)
175 ("ruby-code-statistics" ,ruby-code-statistics)))
176 (synopsis
177 "HighLine helps you build command-line interfaces")
178 (description
179 "HighLine provides a high-level IO library that provides validation,
180type conversion, and more for command-line interfaces. HighLine also includes
181a menu system for providing multiple options to the user.")
182 (home-page "https://github.com/JEG2/highline")
183 (license (list license:gpl2 license:ruby))))
184
bda0c139
DT
185(define-public ruby-hoe
186 (package
187 (name "ruby-hoe")
05f2f8bc 188 (version "3.16.2")
bda0c139 189 (source (origin
e83c6d00
DT
190 (method url-fetch)
191 (uri (rubygems-uri "hoe" version))
bda0c139
DT
192 (sha256
193 (base32
05f2f8bc 194 "12q6dn2irsfamdbjpqvs0dwl4i1vl7wflxrcg972h9jw0ds38f3a"))))
bda0c139 195 (build-system ruby-build-system)
bda0c139
DT
196 (synopsis "Ruby project management helper")
197 (description
198 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
199maintain, and release projects and includes a dynamic plug-in system allowing
200for easy extensibility. Hoe ships with plug-ins for all the usual project
201tasks including rdoc generation, testing, packaging, deployment, and
202announcement.")
2f3800e5 203 (home-page "https://www.zenspider.com/projects/hoe.html")
bda0c139
DT
204 (license license:expat)))
205
022170dc
PP
206(define-public ruby-rake-compiler
207 (package
208 (name "ruby-rake-compiler")
0cd7b816 209 (version "1.0.4")
022170dc
PP
210 (source (origin
211 (method url-fetch)
e83c6d00 212 (uri (rubygems-uri "rake-compiler" version))
022170dc
PP
213 (sha256
214 (base32
0cd7b816 215 "1xpdi4w8zaklk1i9ps8g3k0icw3v5fcks092l84w28rgrpx82qip"))))
022170dc
PP
216 (build-system ruby-build-system)
217 (arguments
e83c6d00 218 '(#:tests? #f)) ; needs cucumber
022170dc 219 (synopsis "Building and packaging helper for Ruby native extensions")
e881752c 220 (description "Rake-compiler provides a framework for building and
022170dc
PP
221packaging native C and Java extensions in Ruby.")
222 (home-page "https://github.com/rake-compiler/rake-compiler")
223 (license license:expat)))
224
acf735f2
DT
225(define-public ruby-i18n
226 (package
227 (name "ruby-i18n")
cbb50182 228 (version "1.1.0")
acf735f2
DT
229 (source (origin
230 (method url-fetch)
e83c6d00 231 (uri (rubygems-uri "i18n" version))
acf735f2
DT
232 (sha256
233 (base32
cbb50182 234 "0ppvmla21hssvrfm8g1n2fnb4lxn4yhy9qmmba0imanflgldrjmr"))))
acf735f2
DT
235 (build-system ruby-build-system)
236 (arguments
0bfdfd37 237 '(#:tests? #f)) ; no tests
cbb50182 238 (propagated-inputs `(("concurrent-ruby" ,ruby-concurrent)))
acf735f2
DT
239 (synopsis "Internationalization library for Ruby")
240 (description "Ruby i18n is an internationalization and localization
241solution for Ruby programs. It features translation and localization,
242interpolation of values to translations, pluralization, customizable
243transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
244translation data, custom key/scope separator, custom exception handlers, and
245an extensible architecture with a swappable backend.")
7bf837fd 246 (home-page "https://github.com/svenfuchs/i18n")
acf735f2 247 (license license:expat)))
eb0c2dd6 248
62b138ca
CB
249(define-public ruby-iruby
250 (package
251 (name "ruby-iruby")
252 (version "0.3")
253 (source
254 (origin
255 (method url-fetch)
256 (uri (rubygems-uri "iruby" version))
257 (sha256
258 (base32
259 "1wdf2c0x8y6cya0n3y0p3p7b1sxkb2fdavdn2k58rf4rs37s7rzn"))))
260 (build-system ruby-build-system)
261 (arguments
262 ;; TODO: Tests currently fail.
263 ;;
264 ;; Finished in 1.764405s, 1.1335 runs/s, 5.1009 assertions/s.
265 ;;
266 ;; 1) Failure:
267 ;; IntegrationTest#test_interaction [/tmp/guix-build-ruby-iruby-0.3.drv-0/gem/test/integration_test.rb:25]:
268 ;; In [ expected
269 ;;
270 ;; 2 runs, 9 assertions, 1 failures, 0 errors, 0 skips
271 '(#:tests? #f
272 #:phases
273 (modify-phases %standard-phases
274 (add-after 'unpack 'patch-ipython
275 (lambda* (#:key inputs #:allow-other-keys)
276 (substitute* "lib/iruby/command.rb"
277 (("version = `")
278 (string-append
279 "version = `"
280 (assoc-ref inputs "python-ipython")
281 "/bin/"))
282 (("Kernel\\.exec\\('")
283 (string-append
284 "Kernel.exec('"
285 (assoc-ref inputs "python-ipython")
286 "/bin/")))
287 #t)))))
288 (inputs
289 `(("python-ipython" ,python-ipython)))
290 (propagated-inputs
291 `(("ruby-bond" ,ruby-bond)
292 ("ruby-data_uri" ,ruby-data_uri)
293 ("ruby-mimemagic" ,ruby-mimemagic)
294 ("ruby-multi-json" ,ruby-multi-json)
295 ("ruby-cztop" ,ruby-cztop)
296 ;; Optional inputs
297 ("ruby-pry" ,ruby-pry)))
298 (synopsis "Ruby kernel for Jupyter/IPython")
299 (description
300 "This package provides a Ruby kernel for Jupyter/IPython frontends (e.g.
301notebook).")
302 (home-page "https://github.com/SciRuby/iruby")
303 (license license:expat)))
304
eb0c2dd6
DT
305;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
306;; dependencies use RSpec for their test suites! To avoid these circular
307;; dependencies, we disable tests for all of the RSpec-related packages.
308(define ruby-rspec-support
309 (package
310 (name "ruby-rspec-support")
2d9f1c06 311 (version "3.5.0")
eb0c2dd6
DT
312 (source (origin
313 (method url-fetch)
e83c6d00 314 (uri (rubygems-uri "rspec-support" version))
eb0c2dd6
DT
315 (sha256
316 (base32
2d9f1c06 317 "10vf3k3d472y573mag2kzfsfrf6rv355s13kadnpryk8d36yq5r0"))))
eb0c2dd6
DT
318 (build-system ruby-build-system)
319 (arguments
320 '(#:tests? #f)) ; avoid dependency cycles
321 (synopsis "RSpec support library")
322 (description "Support utilities for RSpec gems.")
323 (home-page "https://github.com/rspec/rspec-support")
324 (license license:expat)))
325
326(define-public ruby-rspec-core
327 (package
328 (name "ruby-rspec-core")
c5949118 329 (version "3.5.4")
eb0c2dd6
DT
330 (source (origin
331 (method url-fetch)
e83c6d00 332 (uri (rubygems-uri "rspec-core" version))
eb0c2dd6
DT
333 (sha256
334 (base32
c5949118 335 "1nacs062qbr98fx6czf1vwppn1js956nv2c8vfwj6i65axdfs46i"))))
eb0c2dd6
DT
336 (build-system ruby-build-system)
337 (arguments
338 '(#:tests? #f)) ; avoid dependency cycles
339 (propagated-inputs
340 `(("ruby-rspec-support" ,ruby-rspec-support)))
341 (synopsis "RSpec core library")
342 (description "Rspec-core provides the RSpec test runner and example
343groups.")
344 (home-page "https://github.com/rspec/rspec-core")
345 (license license:expat)))
e6962009 346
64c318f2
BW
347(define-public ruby-rspec-core-2
348 (package (inherit ruby-rspec-core)
349 (version "2.14.8")
350 (source (origin
351 (method url-fetch)
352 (uri (rubygems-uri "rspec-core" version))
353 (sha256
354 (base32
355 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
356 (propagated-inputs `())))
357
20c05ea9 358(define-public ruby-diff-lcs
e6962009
DT
359 (package
360 (name "ruby-diff-lcs")
e2fcef39 361 (version "1.3")
e6962009
DT
362 (source (origin
363 (method url-fetch)
e83c6d00 364 (uri (rubygems-uri "diff-lcs" version))
e6962009
DT
365 (sha256
366 (base32
e2fcef39 367 "18w22bjz424gzafv6nzv98h0aqkwz3d9xhm7cbr1wfbyas8zayza"))))
e6962009
DT
368 (build-system ruby-build-system)
369 (arguments
370 '(#:tests? #f)) ; avoid dependency cycles
371 (synopsis "Compute the difference between two Enumerable sequences")
372 (description "Diff::LCS computes the difference between two Enumerable
373sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
374It includes utilities to create a simple HTML diff output format and a
375standard diff-like tool.")
376 (home-page "https://github.com/halostatue/diff-lcs")
377 (license license:expat)))
378
379(define-public ruby-rspec-expectations
380 (package
381 (name "ruby-rspec-expectations")
2d9f1c06 382 (version "3.5.0")
e6962009
DT
383 (source (origin
384 (method url-fetch)
e83c6d00 385 (uri (rubygems-uri "rspec-expectations" version))
e6962009
DT
386 (sha256
387 (base32
2d9f1c06 388 "0bbqfrb1x8gmwf8x2xhhwvvlhwbbafq4isbvlibxi6jk602f09gs"))))
e6962009
DT
389 (build-system ruby-build-system)
390 (arguments
391 '(#:tests? #f)) ; avoid dependency cycles
392 (propagated-inputs
393 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 394 ("ruby-diff-lcs" ,ruby-diff-lcs)))
e881752c 395 (synopsis "RSpec expectations library")
e6962009
DT
396 (description "Rspec-expectations provides a simple API to express expected
397outcomes of a code example.")
398 (home-page "https://github.com/rspec/rspec-expectations")
399 (license license:expat)))
4f2a0cac 400
fb157f25
BW
401(define-public ruby-rspec-expectations-2
402 (package (inherit ruby-rspec-expectations)
403 (version "2.14.5")
404 (source (origin
405 (method url-fetch)
406 (uri (rubygems-uri "rspec-expectations" version))
407 (sha256
408 (base32
409 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
410 (propagated-inputs
411 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
412
999ffb26
DM
413(define-public ruby-rspec-its
414 (package
415 (name "ruby-rspec-its")
416 (version "1.2.0")
417 (source
418 (origin
3306f02a
CB
419 (method git-fetch)
420 (uri (git-reference
421 (url "https://github.com/rspec/rspec-its.git")
422 (commit (string-append "v" version))))
423 (file-name (git-file-name name version))
999ffb26
DM
424 (sha256
425 (base32
3306f02a
CB
426 "190rz7v4q4wk80fzhr5hknvxx4vb2pywmqr8wc41w2blj9ylzi0f"))
427 (patches
428 (list
429 (origin (method url-fetch)
430 (uri (string-append
431 "https://github.com/rspec/rspec-its/commit/"
432 "bfaab439c7c879f5ef25552f41827891f6308373.patch"))
433 (file-name "ruby-rspec-its-fix-specs-for-ruby-2.4.patch")
434 (sha256
435 (base32
436 "0lnik0kvrpgkakvdb2fmzg22pdlraf6kiidr9sv6rnfyviiqwxgh")))))))
999ffb26
DM
437 (build-system ruby-build-system)
438 (arguments
3306f02a
CB
439 `(#:test-target "spec"
440 #:phases
441 (modify-phases %standard-phases
442 (add-after 'unpack 'dont-install-gems-from-gemfile
443 (lambda _
444 (substitute* "Gemfile"
445 (("rspec rspec-core rspec-expectations rspec-mocks rspec-support")
446 ""))
447 #t))
448 (add-before 'build 'remove-unnecessary-dependency-versions-from-gemfile
449 (lambda _
450 (substitute* "rspec-its.gemspec"
451 (("rake.*") "rake'\n")
452 (("cucumber.*") "cucumber'\n")
453 (("bundler.*") "bundler'\n")
454 (("aruba.*") "aruba'\n"))
455 #t)))))
999ffb26
DM
456 (propagated-inputs
457 `(("ruby-rspec-core" ,ruby-rspec-core)
458 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
3306f02a
CB
459 (native-inputs
460 `(("bundler" ,bundler)
461 ("ruby-cucumber" ,ruby-cucumber)
462 ("ruby-aruba" ,ruby-aruba)))
463 (synopsis "RSpec extension that provides the @code{its} method")
464 (description
465 "RSpec::Its provides the its method as a short-hand to specify the expected
466value of an attribute. For example, one can use @code{its(:size)\\{should
467eq(1)\\}}.")
999ffb26
DM
468 (home-page "https://github.com/rspec/rspec-its")
469 (license license:expat)))
470
4f2a0cac
DT
471(define-public ruby-rspec-mocks
472 (package
473 (name "ruby-rspec-mocks")
2d9f1c06 474 (version "3.5.0")
4f2a0cac
DT
475 (source (origin
476 (method url-fetch)
e83c6d00 477 (uri (rubygems-uri "rspec-mocks" version))
4f2a0cac
DT
478 (sha256
479 (base32
2d9f1c06 480 "0nl3ksivh9wwrjjd47z5dggrwx40v6gpb3a0gzbp1gs06a5dmk24"))))
4f2a0cac
DT
481 (build-system ruby-build-system)
482 (arguments
483 '(#:tests? #f)) ; avoid dependency cycles
484 (propagated-inputs
485 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 486 ("ruby-diff-lcs" ,ruby-diff-lcs)))
4f2a0cac
DT
487 (synopsis "RSpec stubbing and mocking library")
488 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
489support for stubbing and mocking.")
490 (home-page "https://github.com/rspec/rspec-mocks")
491 (license license:expat)))
d4fde1f2 492
6da9adeb
BW
493(define-public ruby-rspec-mocks-2
494 (package (inherit ruby-rspec-mocks)
495 (version "2.14.6")
496 (source (origin
497 (method url-fetch)
498 (uri (rubygems-uri "rspec-mocks" version))
499 (sha256
500 (base32
501 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
502 (propagated-inputs
503 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
504
198bc648
CB
505(define-public ruby-rspec-rerun
506 (package
507 (name "ruby-rspec-rerun")
508 (version "1.1.0")
509 (source
510 (origin
511 (method url-fetch)
512 (uri (rubygems-uri "rspec-rerun" version))
513 (sha256
514 (base32
515 "1gy7znkcaqhpccfnk2nvaqbsvgxy3q57cmjwkl9fi1zabaq5lbkj"))))
516 (build-system ruby-build-system)
517 (arguments
518 '(;; No included tests
519 #:tests? #f))
520 (propagated-inputs `(("ruby-rspec" ,ruby-rspec)))
521 (synopsis "Track failed RSpec tests to re-run them")
522 (description
523 "This package provides an automated way to track, and then re-run failed
524RSpec tests.")
525 (home-page "https://github.com/dblock/rspec-rerun")
526 (license license:expat)))
527
d4fde1f2
DT
528(define-public ruby-rspec
529 (package
530 (name "ruby-rspec")
2d9f1c06 531 (version "3.5.0")
d4fde1f2
DT
532 (source (origin
533 (method url-fetch)
e83c6d00 534 (uri (rubygems-uri "rspec" version))
d4fde1f2
DT
535 (sha256
536 (base32
2d9f1c06 537 "16g3mmih999f0b6vcz2c3qsc7ks5zy4lj1rzjh8hf6wk531nvc6s"))))
d4fde1f2
DT
538 (build-system ruby-build-system)
539 (arguments
540 '(#:tests? #f)) ; avoid dependency cycles
541 (propagated-inputs
542 `(("ruby-rspec-core" ,ruby-rspec-core)
543 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
544 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
545 (synopsis "Behavior-driven development framework for Ruby")
546 (description "RSpec is a behavior-driven development (BDD) framework for
547Ruby. This meta-package includes the RSpec test runner, along with the
548expectations and mocks frameworks.")
549 (home-page "http://rspec.info/")
550 (license license:expat)))
2cbc105b 551
5ac984b3
BW
552(define-public ruby-rspec-2
553 (package (inherit ruby-rspec)
554 (version "2.14.1")
555 (source (origin
556 (method url-fetch)
557 (uri (rubygems-uri "rspec" version))
558 (sha256
559 (base32
560 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
561 (propagated-inputs
562 `(("ruby-rspec-core" ,ruby-rspec-core-2)
563 ("ruby-rspec-mocks" ,ruby-rspec-mocks-2)
564 ("ruby-rspec-expectations" ,ruby-rspec-expectations-2)))))
565
2cbc105b
DT
566;; Bundler is yet another source of circular dependencies, so we must disable
567;; its test suite as well.
568(define-public bundler
569 (package
570 (name "bundler")
29a33257 571 (version "1.15.4")
2cbc105b
DT
572 (source (origin
573 (method url-fetch)
e83c6d00 574 (uri (rubygems-uri "bundler" version))
2cbc105b
DT
575 (sha256
576 (base32
29a33257 577 "0wl4r7wbwdq68xidfv4hhzfb1spb6lmhbspwlzrg4pf1l6ipxlgs"))))
2cbc105b
DT
578 (build-system ruby-build-system)
579 (arguments
580 '(#:tests? #f)) ; avoid dependency cycles
581 (synopsis "Ruby gem bundler")
582 (description "Bundler automatically downloads and installs a list of gems
583specified in a \"Gemfile\", as well as their dependencies.")
2f3800e5 584 (home-page "https://bundler.io/")
2cbc105b 585 (license license:expat)))
98b87b82 586
cf36174f
RW
587(define-public ruby-builder
588 (package
589 (name "ruby-builder")
42b48db2 590 (version "3.2.3")
cf36174f
RW
591 (source (origin
592 (method url-fetch)
593 (uri (rubygems-uri "builder" version))
594 (sha256
595 (base32
42b48db2 596 "0qibi5s67lpdv1wgcj66wcymcr04q6j4mzws6a479n0mlrmh5wr1"))))
cf36174f
RW
597 (build-system ruby-build-system)
598 (arguments
599 `(#:phases
600 (modify-phases %standard-phases
601 (add-after 'unpack 'do-not-use-rvm
602 (lambda _
603 (substitute* "rakelib/tags.rake"
604 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
605 #t)))))
606 (synopsis "Ruby library to create structured data")
607 (description "Builder provides a number of builder objects that make it
608easy to create structured data. Currently the following builder objects are
609supported: XML Markup and XML Events.")
610 (home-page "https://github.com/jimweirich/builder")
611 (license license:expat)))
612
566f71f8
CB
613(define-public ruby-bump
614 (package
615 (name "ruby-bump")
616 (version "0.7.0")
617 (source
618 (origin
619 (method url-fetch)
620 (uri (rubygems-uri "bump" version))
621 (sha256
622 (base32
623 "1xinbr9rzh6cj75x24niwgqcnbhdxc68a8bc41lk8xv6fd906fym"))))
624 (build-system ruby-build-system)
625 (arguments
626 '(;; No included tests
627 #:tests? #f))
628 (synopsis "Tool for working with Rubygems")
629 (description
630 "Bump provides commands to manage Rubygem versioning, updating to the
631next patch version for example.")
632 (home-page "https://github.com/gregorym/bump")
633 (license license:expat)))
634
ad79eb55
RW
635(define-public ruby-rjb
636 (package
637 (name "ruby-rjb")
aeb4e61e 638 (version "1.5.5")
ad79eb55
RW
639 (source (origin
640 (method url-fetch)
641 (uri (rubygems-uri "rjb" version))
642 (sha256
643 (base32
aeb4e61e 644 "1ppj8rbicj3w0nhh7f73mflq19yd7pzdzkh2a91hcvphriy5b0ca"))))
ad79eb55
RW
645 (build-system ruby-build-system)
646 (arguments
647 `(#:tests? #f ; no rakefile
648 #:phases
649 (modify-phases %standard-phases
650 (add-before 'build 'set-java-home
651 (lambda* (#:key inputs #:allow-other-keys)
652 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
653 #t)))))
654 (native-inputs
d2540f80 655 `(("jdk" ,icedtea "jdk")))
ad79eb55
RW
656 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
657 (description "RJB is a bridge program that connects Ruby and Java via the
658Java Native Interface.")
2f3800e5 659 (home-page "https://www.artonx.org/collabo/backyard/?RubyJavaBridge")
ad79eb55
RW
660 (license license:lgpl2.1+)))
661
f9ae2c06
PP
662(define-public ruby-log4r
663 (package
664 (name "ruby-log4r")
665 (version "1.1.10")
666 (source
667 (origin
668 (method url-fetch)
669 (uri (rubygems-uri "log4r" version))
670 (sha256
671 (base32
672 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
673 (build-system ruby-build-system)
674 (arguments
675 '(#:tests? #f)) ; no Rakefile in gem
676 (synopsis "Flexible logging library for Ruby")
677 (description "Comprehensive and flexible logging library written
678in Ruby for use in Ruby programs. It features a hierarchical logging
679system of any number of levels, custom level names, logger
680inheritance, multiple output destinations per log event, execution
681tracing, custom formatting, thread safteyness, XML and YAML
682configuration, and more.")
683 (home-page "http://log4r.rubyforge.org/")
684 (license license:bsd-3)))
685
71a03c29
RW
686(define-public ruby-atoulme-antwrap
687 (package
688 (name "ruby-atoulme-antwrap")
689 (version "0.7.5")
690 (source (origin
691 (method url-fetch)
692 (uri (rubygems-uri "atoulme-Antwrap" version))
693 (sha256
694 (base32
695 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
696 (build-system ruby-build-system)
697 ;; Test data required for most of the tests are not included.
698 (arguments `(#:tests? #f))
699 (native-inputs
700 `(("ruby-hoe" ,ruby-hoe)))
701 (inputs
702 `(("ruby-rjb" ,ruby-rjb)))
703 (synopsis "Ruby wrapper for the Ant build tool")
704 (description "Antwrap is a Ruby module that wraps the Apache Ant build
705tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
706script.")
707 (home-page "http://rubyforge.org/projects/antwrap/")
708 (license license:expat)))
709
fe1ddad5
RW
710(define-public ruby-atoulme-saikuro
711 (package
712 (name "ruby-atoulme-saikuro")
713 (version "1.2.1")
714 (source (origin
715 (method url-fetch)
716 (uri (rubygems-uri "atoulme-Saikuro" version))
717 (sha256
718 (base32
719 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
720 (build-system ruby-build-system)
721 ;; FIXME: There are no unit tests. The tests are demonstrations of the
722 ;; "saikuro" tool.
723 (arguments `(#:tests? #f))
724 (synopsis "Cyclomatic complexity analyzer")
725 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
726given Ruby source code Saikuro will generate a report listing the cyclomatic
727complexity of each method found. In addition, Saikuro counts the number of
728lines per method and can generate a listing of the number of tokens on each
729line of code.")
730 (home-page "http://www.github.com/atoulme/Saikuro")
731 ;; File headers contain the BSD-3 license and the README.rdoc says that
732 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
733 ;; of the Expat license.
734 (license license:bsd-3)))
735
34138e42
BW
736(define-public ruby-asciidoctor
737 (package
738 (name "ruby-asciidoctor")
9933a8e7 739 (version "1.5.7.1")
34138e42
BW
740 (source
741 (origin
742 (method url-fetch)
743 (uri (rubygems-uri "asciidoctor" version))
744 (sha256
745 (base32
9933a8e7 746 "0v52bzc72cvg7zfgq27pa4mgyf29dx9m20fghrw1xmvwgd519n1w"))))
34138e42
BW
747 (build-system ruby-build-system)
748 (arguments
749 `(#:test-target "test:all"
750 #:phases
751 (modify-phases %standard-phases
752 (add-before 'check 'remove-circular-tests
753 (lambda _
754 ;; Remove tests that require circular dependencies to load or pass.
755 (delete-file "test/invoker_test.rb")
756 (delete-file "test/converter_test.rb")
757 (delete-file "test/options_test.rb")
758 #t)))))
759 (native-inputs
760 `(("ruby-minitest" ,ruby-minitest)
761 ("ruby-nokogiri" ,ruby-nokogiri)
762 ("ruby-asciimath" ,ruby-asciimath)
763 ("ruby-coderay" ,ruby-coderay)))
764 (synopsis "Converter from AsciiDoc content to other formats")
765 (description
766 "Asciidoctor is a text processor and publishing toolchain for converting
20860819 767AsciiDoc content to HTML5, DocBook 5 (or 4.5), PDF, and other formats.")
bba082a1 768 (home-page "https://asciidoctor.org")
34138e42
BW
769 (license license:expat)))
770
d5840f77
CB
771(define-public ruby-ast
772 (package
773 (name "ruby-ast")
774 (version "2.4.0")
775 (source
776 (origin
777 (method url-fetch)
778 (uri (rubygems-uri "ast" version))
779 (sha256
780 (base32
781 "184ssy3w93nkajlz2c70ifm79jp3j737294kbc5fjw69v1w0n9x7"))))
782 (build-system ruby-build-system)
783 (arguments
784 '(#:phases
785 (modify-phases %standard-phases
786 (add-after 'unpack 'remove-coveralls-requirement
787 (lambda _
788 (substitute* "test/helper.rb"
789 (("require 'coveralls'") "")
790 (("Coveralls::SimpleCov::Formatter") ""))
791 #t))
792 (add-after 'extract-gemspec 'remove-unnecessary-requirements
793 (lambda _
794 (substitute* "ast.gemspec"
795 ((".*coveralls.*") "\n")
796 (("%q<rest-client>.*") "%q<rest-client>.freeze, [\">= 0\"])\n")
797 (("%q<mime-types>.*") "%q<mime-types>.freeze, [\">= 0\"])\n")
798 (("%q<rake>.*") "%q<rake>.freeze, [\">= 0\"])\n"))
799 #t)))))
800 (native-inputs
801 `(("bundler" ,bundler)
802 ("ruby-simplecov" ,ruby-simplecov)
803 ("ruby-json-pure" ,ruby-json-pure)
804 ("ruby-mime-times" ,ruby-mime-types)
805 ("ruby-yard" ,ruby-yard)
806 ("ruby-kramdown" ,ruby-kramdown)
807 ("ruby-rest-client" ,ruby-rest-client)
808 ("ruby-bacon" ,ruby-bacon)
809 ("ruby-bacon-colored-output" ,ruby-bacon-colored-output)
810 ("ruby-racc" ,ruby-racc)))
811 (synopsis "Library for working with Abstract Syntax Trees")
812 (description
813 "@code{ast} is a Ruby library for working with Abstract Syntax Trees.
814It does this through immutable data structures.")
815 (home-page "https://whitequark.github.io/ast/")
816 (license license:expat)))
817
b88502c9
BW
818(define-public ruby-sporkmonger-rack-mount
819 ;; Testing the addressable gem requires a newer commit than that released, so
820 ;; use an up to date version.
821 (let ((revision "1")
822 (commit "076aa2c47d9a4c081f1e9bcb56a826a9e72bd5c3"))
823 (package
824 (name "ruby-sporkmonger-rack-mount")
825 (version (git-version "0.8.3" revision commit))
826 (source (origin
827 (method git-fetch)
828 (uri (git-reference
829 (url "https://github.com/sporkmonger/rack-mount.git")
830 (commit commit)))
831 (file-name (git-file-name name version))
832 (sha256
833 (base32
834 "1scx273g3xd93424x9lxc4zyvcp2niknbw5mkz6wkivpf7xsyxdq"))))
835 (build-system ruby-build-system)
836 (arguments
837 ;; Tests currently fail so disable them.
838 ;; https://github.com/sporkmonger/rack-mount/pull/1
839 `(#:tests? #f))
840 (propagated-inputs `(("ruby-rack" ,ruby-rack)))
841 (synopsis "Stackable dynamic tree based Rack router")
842 (description
843 "@code{Rack::Mount} supports Rack's @code{X-Cascade} convention to
844continue trying routes if the response returns pass. This allows multiple
845routes to be nested or stacked on top of each other.")
846 (home-page "https://github.com/sporkmonger/rack-mount")
847 (license license:expat))))
848
2f9e0b68
RW
849(define-public ruby-ci-reporter
850 (package
851 (name "ruby-ci-reporter")
852 (version "2.0.0")
853 (source (origin
854 (method url-fetch)
855 (uri (rubygems-uri "ci_reporter" version))
856 (sha256
857 (base32
858 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
859 (build-system ruby-build-system)
860 (arguments
861 `(#:test-target "rspec"))
862 (propagated-inputs
863 `(("ruby-builder" ,ruby-builder)))
864 (native-inputs
865 `(("bundler" ,bundler)
866 ("ruby-rspec" ,ruby-rspec)))
867 (synopsis "Generate XML reports of runs test")
868 (description
869 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
870you to generate XML reports of your test runs. The resulting files can be
871read by a continuous integration system that understands Ant's JUnit report
872format.")
873 (home-page "https://github.com/nicksieger/ci_reporter")
874 (license license:expat)))
875
2ed201c1
CB
876(define-public ruby-contracts
877 (package
878 (name "ruby-contracts")
879 (version "0.16.0")
880 (source
881 (origin
882 (method url-fetch)
883 (uri (rubygems-uri "contracts" version))
884 (sha256
885 (base32
886 "119f5p1n6r5svbx8h09za6a4vrsnj5i1pzr9cqdn9hj3wrxvyl3a"))))
887 (build-system ruby-build-system)
888 (arguments
889 '(#:test-target "spec"
890 #:phases
891 (modify-phases %standard-phases
892 ;; Don't run or require rubocop, the code linting tool, as this is a
893 ;; bit unnecessary.
894 (add-after 'unpack 'dont-run-rubocop
895 (lambda _
896 (substitute* "Rakefile"
897 ((".*rubocop.*") "")
898 ((".*RuboCop.*") ""))
899 #t)))))
900 (native-inputs
901 `(("ruby-rspec" ,ruby-rspec)))
902 (synopsis "Method contracts for Ruby")
903 (description
904 "This library provides contracts for Ruby. A contract describes the
905correct inputs and output for a method, and will raise an error if a incorrect
906value is found.")
907 (home-page "https://github.com/egonSchiele/contracts.ruby")
908 (license license:bsd-2)))
909
6f8bf0eb
CB
910(define-public ruby-crack
911 (package
912 (name "ruby-crack")
913 (version "0.4.3")
914 (source
915 (origin
916 (method url-fetch)
917 (uri (rubygems-uri "crack" version))
918 (sha256
919 (base32
920 "0abb0fvgw00akyik1zxnq7yv391va148151qxdghnzngv66bl62k"))))
921 (build-system ruby-build-system)
922 (arguments
923 `(#:phases
924 (modify-phases %standard-phases
925 (replace 'check
926 (lambda* (#:key tests? #:allow-other-keys)
927 (when tests?
928 (for-each (lambda (file)
929 (display file)(display "\n")
930 (invoke "ruby" "-Ilib" "-Itest" "-rrubygems" file))
931 (find-files "test" ".*rb$")))
932 #t)))))
933 (propagated-inputs
934 `(("ruby-safe-yaml" ,ruby-safe-yaml)))
935 (synopsis "Simple JSON and XML parsing for Ruby")
936 (description
937 "@code{crack} provides really simple JSON and XML parsing, extracted from
938code in Merb and Rails.")
939 (home-page "https://github.com/jnunemaker/crack")
940 (license license:expat)))
941
d7f9f887
CB
942(define-public ruby-crass
943 (package
944 (name "ruby-crass")
945 (version "1.0.4")
946 (source
947 (origin
948 (method url-fetch)
949 (uri (rubygems-uri "crass" version))
950 (sha256
951 (base32
952 "0bpxzy6gjw9ggjynlxschbfsgmx8lv3zw1azkjvnb8b9i895dqfi"))))
953 (build-system ruby-build-system)
954 (synopsis "Pure Ruby CSS parser based on CSS Syntax Level 3")
955 (description
956 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
957 (home-page "https://github.com/rgrove/crass/")
958 (license license:expat)))
959
bef3506e
CB
960(define-public ruby-cliver
961 (package
962 (name "ruby-cliver")
963 (version "0.3.2")
964 (source
965 (origin
966 (method url-fetch)
967 (uri (rubygems-uri "cliver" version))
968 (sha256
969 (base32
970 "096f4rj7virwvqxhkavy0v55rax10r4jqf8cymbvn4n631948xc7"))))
971 (build-system ruby-build-system)
972 (arguments
973 '(#:phases
974 (modify-phases %standard-phases
975 ;; Avoid a incompatibility between rspec@2 and rake. Using rspec@3
976 ;; would be nice, but the tests look to be incompatible:
977 ;;
978 ;; NoMethodError: undefined method `last_comment'
979 (replace 'check
980 (lambda* (#:key tests? #:allow-other-keys)
981 (when tests?
982 (invoke "rspec"))
983 #t)))))
984 (native-inputs
985 `(("bundler" ,bundler)
986 ("ruby-rspec" ,ruby-rspec-2)))
987 (synopsis "Assertions for command-line dependencies in Ruby")
988 (description
989 "@code{cliver} provides a way to detect missing command-line
990dependencies, including versions.")
991 (home-page "https://github.com/yaauie/cliver")
992 (license license:expat)))
993
fe5dd5f4
CB
994(define-public ruby-czmq-ffi-gen
995 (package
996 (name "ruby-czmq-ffi-gen")
997 (version "0.13.0")
998 (source
999 (origin
1000 (method url-fetch)
1001 (uri (rubygems-uri "czmq-ffi-gen" version))
1002 (sha256
1003 (base32
1004 "1yf719dmf4mwks1hqdsy6i5kzfvlsha69sfnhb2fr2cgk2snbys3"))))
1005 (build-system ruby-build-system)
1006 (arguments
1007 '(#:tests? #f ;; Tests are not included in the release on rubygems.org
1008 #:phases
1009 (modify-phases %standard-phases
1010 (add-after 'unpack 'patch-lib_dirs
1011 (lambda* (#:key inputs #:allow-other-keys)
1012 (substitute* "lib/czmq-ffi-gen/czmq/ffi.rb"
1013 (("lib\\_dirs = \\[.*\\]")
1014 (string-append "lib_dirs = ['"
1015 (assoc-ref inputs "czmq") "/lib"
1016 "']")))
1017 (substitute* "lib/czmq-ffi-gen/libzmq.rb"
1018 (("lib\\_dirs = \\[.*\\]")
1019 (string-append "lib_dirs = ['"
1020 (assoc-ref inputs "zeromq") "/lib"
1021 "']"))))))))
1022 (inputs
1023 `(("zeromq" ,zeromq)
1024 ("czmq" ,czmq)))
1025 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
1026 (synopsis "Low-level Ruby bindings for CZMQ (generated using zproject)")
1027 (description
1028 "These Ruby bindings are not intended to be directly used, but rather
1029used by higher level bindings like those provided by CZTop.")
1030 (home-page
1031 "https://github.com/paddor/czmq-ffi-gen")
1032 (license license:isc)))
1033
d0afff26
CB
1034(define-public ruby-cztop
1035 (package
1036 (name "ruby-cztop")
1037 (version "0.12.2")
1038 (source
1039 (origin
1040 (method url-fetch)
1041 (uri (rubygems-uri "cztop" version))
1042 (sha256
1043 (base32
1044 "0yqbpaiw5d7f271d73lyrsh8xpx6n4zi6xqwfgi00dacxrq3s3fa"))))
1045 (build-system ruby-build-system)
1046 (arguments
1047 '(#:test-target "spec"
1048 #:phases
1049 (modify-phases %standard-phases
1050 (add-after 'unpack 'patch-lib_paths
1051 (lambda* (#:key inputs #:allow-other-keys)
1052 (substitute* "lib/cztop/poller/zmq.rb"
1053 (("lib\\_paths = \\[.*\\]")
1054 (string-append "lib_paths = ['"
1055 (assoc-ref inputs "zeromq") "/lib"
1056 "']"))))))))
1057 (native-inputs
1058 `(("bundler" ,bundler)
1059 ("ruby-rspec" ,ruby-rspec)))
1060 (inputs
1061 `(("zeromq" ,zeromq)))
1062 (propagated-inputs
1063 `(("ruby-czmq-ffi-gen" ,ruby-czmq-ffi-gen)))
1064 (synopsis "CZMQ Ruby bindings")
1065 (description
1066 "CZMQ Ruby bindings, based on the generated low-level FFI bindings of
1067CZMQ. The focus of of CZTop is on being easy to use and providing first class
1068support for security mechanisms.")
1069 (home-page "https://github.com/paddor/cztop")
1070 (license license:isc)))
1071
b004fb6a
RW
1072(define-public ruby-saikuro-treemap
1073 (package
1074 (name "ruby-saikuro-treemap")
1075 (version "0.2.0")
1076 (source (origin
1077 (method url-fetch)
1078 (uri (rubygems-uri "saikuro_treemap" version))
1079 (sha256
1080 (base32
1081 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
1082 (build-system ruby-build-system)
1083 ;; Some of the tests fail because the generated JSON has keys in a
1084 ;; different order. This is a problem with the test suite rather than any
1085 ;; of the involved libraries.
1086 (arguments `(#:tests? #f))
1087 (propagated-inputs
1088 `(("ruby-json-pure" ,ruby-json-pure)
1089 ("ruby-atoulme-saikuro" ,ruby-atoulme-saikuro)))
1090 (synopsis "Generate complexity treemap based on saikuro analysis")
1091 (description
1092 "This gem generates a treemap showing the complexity of Ruby code on
1093which it is run. It uses Saikuro under the covers to analyze Ruby code
1094complexity.")
7bf837fd 1095 (home-page "https://github.com/ThoughtWorksStudios/saikuro_treemap")
b004fb6a
RW
1096 (license license:expat)))
1097
cef87ed6
CB
1098(define-public ruby-options
1099 (package
1100 (name "ruby-options")
1101 (version "2.3.2")
1102 (source
1103 (origin
1104 (method url-fetch)
1105 (uri (rubygems-uri "options" version))
1106 (sha256
1107 (base32
1108 "1s650nwnabx66w584m1cyw82icyym6hv5kzfsbp38cinkr5klh9j"))))
1109 (build-system ruby-build-system)
1110 (arguments
1111 '(#:tests? #f ;; TODO: NameError: uninitialized constant Config
1112 #:phases
1113 (modify-phases %standard-phases
1114 (add-before 'check 'set-LIB
1115 (lambda _
1116 ;; This is used in the Rakefile, and setting it avoids an issue
1117 ;; with running the tests.
fe27238c
CB
1118 (setenv "LIB" "options")
1119 #t)))))
cef87ed6
CB
1120 (synopsis "Ruby library to parse options from *args cleanly")
1121 (description
1122 "The @code{options} library helps with parsing keyword options in Ruby
1123functions.")
1124 (home-page "https://github.com/ahoward/options")
1125 (license license:ruby)))
1126
d15dbe83
CB
1127(define-public ruby-erubi
1128 (package
1129 (name "ruby-erubi")
1130 (version "1.8.0")
1131 (source
1132 (origin
1133 (method url-fetch)
1134 (uri (rubygems-uri "erubi" version))
1135 (sha256
1136 (base32
1137 "1kagnf6ziahj0d781s6ryy6fwqwa3ad4xbzzj84p9m4nv4c2jir1"))))
1138 (build-system ruby-build-system)
1139 (synopsis "ERB template engine for Ruby")
1140 (description
1141 "Erubi is a ERB template engine for Ruby. It is a simplified fork of
1142Erubis")
1143 (home-page "https://github.com/jeremyevans/erubi")
1144 (license license:expat)))
1145
d64ebebd
BW
1146(define-public ruby-erubis
1147 (package
1148 (name "ruby-erubis")
1149 (version "2.7.0")
1150 (source
1151 (origin
1152 (method url-fetch)
1153 (uri (rubygems-uri "erubis" version))
1154 (sha256
1155 (base32
1156 "1fj827xqjs91yqsydf0zmfyw9p4l2jz5yikg3mppz6d7fi8kyrb3"))))
1157 (build-system ruby-build-system)
1158 (arguments
1159 '(#:tests? #f)) ; tests do not run properly with Ruby 2.0
1160 (synopsis "Implementation of embedded Ruby (eRuby)")
1161 (description
1162 "Erubis is a fast implementation of embedded Ruby (eRuby) with several
1163features such as multi-language support, auto escaping, auto trimming spaces
1164around @code{<% %>}, a changeable embedded pattern, and Ruby on Rails
1165support.")
1166 (home-page "http://www.kuwata-lab.com/erubis/")
1167 (license license:expat)))
1168
cc53e630
RW
1169(define-public ruby-orderedhash
1170 (package
1171 (name "ruby-orderedhash")
1172 (version "0.0.6")
1173 (source (origin
1174 (method url-fetch)
1175 (uri (rubygems-uri "orderedhash" version))
1176 (sha256
1177 (base32
1178 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
1179 (build-system ruby-build-system)
1180 (arguments
1181 '(#:tests? #f)) ; no test suite
1182 (synopsis "Ruby library providing an order-preserving hash")
1183 (description "Orderedhash is a Ruby library providing a hash
1184implementation that preserves the order of items and features some array-like
1185extensions.")
1186 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
1187 (license license:public-domain)))
1188
28c5d42d
PP
1189(define-public ruby-libxml
1190 (package
1191 (name "ruby-libxml")
acbc5062 1192 (version "3.0.0")
28c5d42d
PP
1193 (source
1194 (origin
1195 (method url-fetch)
1196 (uri (rubygems-uri "libxml-ruby" version))
1197 (sha256
1198 (base32
acbc5062 1199 "0xy8wmjwjcnv36zi042678ncjzpxvy351ccbv7mzkns2n3kxfp54"))))
28c5d42d
PP
1200 (build-system ruby-build-system)
1201 (inputs
1202 `(("zlib" ,zlib)
1203 ("libxml2" ,libxml2)))
1204 (arguments
1205 '(#:tests? #f ; test suite hangs for unknown reason
1206 #:gem-flags
1207 (list "--"
1208 (string-append "--with-xml2-include="
1209 (assoc-ref %build-inputs "libxml2")
1210 "/include/libxml2" ))))
1211 (synopsis "Ruby bindings for GNOME Libxml2")
1212 (description "The Libxml-Ruby project provides Ruby language bindings for
1213the GNOME Libxml2 XML toolkit.")
2f3800e5 1214 (home-page "https://xml4r.github.com/libxml-ruby")
28c5d42d
PP
1215 (license license:expat)))
1216
8b9bde07
RW
1217(define-public ruby-xml-simple
1218 (package
1219 (name "ruby-xml-simple")
1220 (version "1.1.5")
1221 (source (origin
1222 (method url-fetch)
1223 (uri (rubygems-uri "xml-simple" version))
1224 (sha256
1225 (base32
1226 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
1227 (build-system ruby-build-system)
1228 (arguments
1229 '(#:tests? #f)) ; no test suite
1230 (synopsis "Simple Ruby library for XML processing")
1231 (description "This library provides a simple API for XML processing in
1232Ruby.")
1233 (home-page "https://github.com/maik/xml-simple")
1234 (license license:ruby)))
1235
2cb3ab48
RW
1236(define-public ruby-thor
1237 (package
1238 (name "ruby-thor")
2e8cd862 1239 (version "0.19.4")
2cb3ab48
RW
1240 (source (origin
1241 (method url-fetch)
1242 (uri (rubygems-uri "thor" version))
1243 (sha256
1244 (base32
2e8cd862 1245 "01n5dv9kql60m6a00zc0r66jvaxx98qhdny3klyj0p3w34pad2ns"))))
2cb3ab48
RW
1246 (build-system ruby-build-system)
1247 (arguments
1248 '(#:tests? #f)) ; no test suite
1249 (native-inputs
1250 `(("bundler" ,bundler)))
1251 (synopsis "Ruby toolkit for building command-line interfaces")
1252 (description "Thor is a toolkit for building powerful command-line
1253interfaces.")
1254 (home-page "http://whatisthor.com/")
1255 (license license:expat)))
1256
ec79018e
RW
1257(define-public ruby-lumberjack
1258 (package
1259 (name "ruby-lumberjack")
41700efa 1260 (version "1.0.13")
ec79018e
RW
1261 (source (origin
1262 (method url-fetch)
1263 (uri (rubygems-uri "lumberjack" version))
1264 (sha256
1265 (base32
41700efa 1266 "06im7gcg42x77yhz2w5da2ly9xz0n0c36y5ks7xs53v0l9g0vf5n"))))
ec79018e
RW
1267 (build-system ruby-build-system)
1268 (native-inputs
8be62d3f
BW
1269 `(("ruby-rspec" ,ruby-rspec)
1270 ("ruby-timecop" ,ruby-timecop)))
ec79018e
RW
1271 (synopsis "Logging utility library for Ruby")
1272 (description "Lumberjack is a simple logging utility that can be a drop in
1273replacement for Logger or ActiveSupport::BufferedLogger. It provides support
1274for automatically rolling log files even with multiple processes writing the
1275same log file.")
7bf837fd 1276 (home-page "https://github.com/bdurand/lumberjack")
ec79018e
RW
1277 (license license:expat)))
1278
70b4cf38
RW
1279(define-public ruby-nenv
1280 (package
1281 (name "ruby-nenv")
12313cd0 1282 (version "0.3.0")
70b4cf38
RW
1283 (source (origin
1284 (method url-fetch)
1285 (uri (rubygems-uri "nenv" version))
1286 (sha256
1287 (base32
12313cd0 1288 "0r97jzknll9bhd8yyg2bngnnkj8rjhal667n7d32h8h7ny7nvpnr"))))
70b4cf38
RW
1289 (build-system ruby-build-system)
1290 (arguments
1291 `(#:tests? #f)) ; no tests included
1292 (native-inputs
1293 `(("ruby-rspec" ,ruby-rspec)
1294 ("bundler" ,bundler)))
1295 (synopsis "Ruby interface for modifying the environment")
1296 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
1297and inspect the environment.")
1298 (home-page "https://github.com/e2/nenv")
1299 (license license:expat)))
1300
8d9e9f28
RW
1301(define-public ruby-permutation
1302 (package
1303 (name "ruby-permutation")
1304 (version "0.1.8")
1305 (source (origin
1306 (method url-fetch)
1307 (uri (rubygems-uri "permutation" version))
1308 (sha256
1309 (base32
1310 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
1311 (build-system ruby-build-system)
1312 (arguments
1313 `(#:phases
1314 (modify-phases %standard-phases
1315 (add-after 'unpack 'fix-rakefile
1316 (lambda _
1317 (substitute* "Rakefile"
1318 (("require 'rake/gempackagetask'")
1319 "require 'rubygems/package_task'")
1320 (("include Config") ""))
1321 #t))
1322 (replace 'check
1323 (lambda _
9923d5a4 1324 (invoke "ruby" "-Ilib" "test/test.rb"))))))
8d9e9f28
RW
1325 (synopsis "Library to perform operations with sequence permutations")
1326 (description "This package provides a Ruby library to perform different
1327operations with permutations of sequences, such as strings and arrays.")
2f3800e5 1328 (home-page "https://flori.github.io/permutation")
8d9e9f28
RW
1329 (license license:gpl2))) ; GPL 2 only
1330
c5d14d42
RW
1331(define-public ruby-shellany
1332 (package
1333 (name "ruby-shellany")
1334 (version "0.0.1")
1335 (source (origin
1336 (method url-fetch)
1337 (uri (rubygems-uri "shellany" version))
1338 (sha256
1339 (base32
1340 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
1341 (build-system ruby-build-system)
1342 (arguments
1343 `(#:test-target "default"
1344 #:phases
1345 (modify-phases %standard-phases
1346 (add-after 'unpack 'fix-version-test
1347 (lambda _
1348 (substitute* "spec/shellany_spec.rb"
1349 (("^RSpec") "require \"shellany\"\nRSpec"))
1350 #t)))))
1351 (native-inputs
1352 `(("ruby-rspec" ,ruby-rspec)
1353 ("ruby-nenv" ,ruby-nenv)
1354 ("bundler" ,bundler)))
1355 (synopsis "Capture command output")
1356 (description "Shellany is a Ruby library providing functions to capture
1357the output produced by running shell commands.")
1358 (home-page "https://rubygems.org/gems/shellany")
1359 (license license:expat)))
1360
d152162f
RW
1361(define-public ruby-notiffany
1362 (package
1363 (name "ruby-notiffany")
a7ca218c 1364 (version "0.1.1")
d152162f
RW
1365 (source (origin
1366 (method url-fetch)
1367 (uri (rubygems-uri "notiffany" version))
1368 (sha256
1369 (base32
a7ca218c 1370 "0x838fa5il0dd9zbm3lxkpbfxcf5fxv9556mayc2mxsdl5ghv8nx"))))
d152162f
RW
1371 (build-system ruby-build-system)
1372 ;; Tests are not included in the gem.
1373 (arguments `(#:tests? #f))
1374 (propagated-inputs
1375 `(("ruby-shellany" ,ruby-shellany)
1376 ("ruby-nenv" ,ruby-nenv)))
1377 (native-inputs
1378 `(("bundler" ,bundler)))
1379 (synopsis "Wrapper libray for notification libraries")
1380 (description "Notiffany is a Ruby wrapper libray for notification
1381libraries such as Libnotify.")
1382 (home-page "https://github.com/guard/notiffany")
1383 (license license:expat)))
1384
8528365b
RW
1385(define-public ruby-formatador
1386 (package
1387 (name "ruby-formatador")
1388 (version "0.2.5")
1389 (source (origin
1390 (method url-fetch)
1391 (uri (rubygems-uri "formatador" version))
1392 (sha256
1393 (base32
1394 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
1395 (build-system ruby-build-system)
1396 ;; Circular dependency: Tests require ruby-shindo, which requires
1397 ;; ruby-formatador at runtime.
1398 (arguments `(#:tests? #f))
1399 (synopsis "Ruby library to format text on stdout")
1400 (description "Formatador is a Ruby library to format text printed to the
1401standard output stream.")
7bf837fd 1402 (home-page "https://github.com/geemus/formatador")
8528365b
RW
1403 (license license:expat)))
1404
5437c741
CB
1405(define-public ruby-fuubar
1406 (package
1407 (name "ruby-fuubar")
1408 (version "2.3.2")
1409 (source
1410 (origin
1411 ;; Fetch from the git repository, as the gem package doesn't include
1412 ;; the tests.
1413 (method git-fetch)
1414 (uri (git-reference
1415 (url "https://github.com/thekompanee/fuubar.git")
1416 (commit (string-append "releases/v" version))))
1417 (file-name (git-file-name name version))
1418 (sha256
1419 (base32
1420 "0jm1x2xp13csbnadixaikj7mlkp5yk4byx51npm56zi13izp7259"))))
1421 (build-system ruby-build-system)
1422 (arguments
1423 '(;; TODO: Some tests fail, unsure why.
1424 ;; 21 examples, 7 failures
1425 #:tests? #f
1426 #:phases
1427 (modify-phases %standard-phases
1428 (add-before 'build 'delete-certificate
1429 (lambda _
1430 ;; Remove 's.cert_chain' as we do not build with a private key
1431 (substitute* "fuubar.gemspec"
1432 ((".*cert_chain.*") "")
1433 ((".*signing_key.*") ""))
1434 #t))
1435 (replace 'check
1436 (lambda* (#:key tests? #:allow-other-keys)
1437 (when tests?
1438 (invoke "rspec"))
1439 #t)))))
1440 (native-inputs
1441 `(("bundler" ,bundler)))
1442 (propagated-inputs
1443 `(("ruby-rspec-core" ,ruby-rspec-core)
1444 ("ruby-progressbar" ,ruby-progressbar)))
1445 (synopsis "Fuubar is an RSpec formatter that uses a progress bar")
1446 (description
1447 "Fuubar is an RSpec formatter that uses a progress bar instead of a
1448string of letters and dots as feedback. It also stops on the first test
1449failure.")
1450 (home-page "https://github.com/thekompanee/fuubar")
1451 (license license:expat)))
1452
21781436
CB
1453(define-public ruby-hashdiff
1454 (package
1455 (name "ruby-hashdiff")
1456 (version "0.3.8")
1457 (source
1458 (origin
1459 (method url-fetch)
1460 (uri (rubygems-uri "hashdiff" version))
1461 (sha256
1462 (base32
1463 "19ykg5pax8798nh1yv71adkx0zzs7gn2rxjj86v7nsw0jba5lask"))))
1464 (build-system ruby-build-system)
1465 (arguments
1466 '(#:phases
1467 (modify-phases %standard-phases
1468 ;; Run tests directly via rspec to avoid Rake issue:
1469 ;; NoMethodError: undefined method `last_comment'
1470 (replace 'check
1471 (lambda* (#:key tests? #:allow-other-keys)
1472 (when tests?
1473 (invoke "rspec"))
1474 #t)))))
1475 (native-inputs
1476 `(("bundler" ,bundler)
1477 ("ruby-rspec" ,ruby-rspec-2)))
1478 (synopsis "HashDiff computes the smallest difference between two hashes")
1479 (description
1480 "HashDiff is a Ruby library to compute the smallest difference between
1481two hashes.")
1482 (home-page "https://github.com/liufengyun/hashdiff")
1483 (license license:expat)))
1484
7ac4610f
RW
1485(define-public ruby-shindo
1486 (package
1487 (name "ruby-shindo")
1488 (version "0.3.8")
1489 (source (origin
1490 (method url-fetch)
1491 (uri (rubygems-uri "shindo" version))
1492 (sha256
1493 (base32
1494 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
1495 (build-system ruby-build-system)
1496 (arguments
1497 `(#:test-target "shindo_tests"
1498 #:phases
1499 (modify-phases %standard-phases
1500 (add-after 'unpack 'fix-tests
0b060e34
CB
1501 (lambda _
1502 (substitute* "tests/tests_helper.rb"
1503 (("-rubygems") ""))
1504 (substitute* "Rakefile"
1505 (("system \"shindo") "system \"./bin/shindo")
1506 ;; This test doesn't work, so we disable it.
1507 (("fail \"The build_error test should fail") "#")
1508 ((" -rubygems") ""))
1509 #t)))))
7ac4610f
RW
1510 (propagated-inputs
1511 `(("ruby-formatador" ,ruby-formatador)))
1512 (synopsis "Simple depth first Ruby testing")
1513 (description "Shindo is a simple depth first testing library for Ruby.")
1514 (home-page "https://github.com/geemus/shindo")
1515 (license license:expat)))
1516
f13636f2
RW
1517(define-public ruby-rubygems-tasks
1518 (package
1519 (name "ruby-rubygems-tasks")
1520 (version "0.2.4")
1521 (source (origin
1522 (method url-fetch)
1523 (uri (rubygems-uri "rubygems-tasks" version))
1524 (sha256
1525 (base32
1526 "16cp45qlbcglnqdm4f1vj3diywdz4v024saqpgrz6palf0wmgz2j"))))
1527 (build-system ruby-build-system)
1528 ;; Tests need Internet access.
1529 (arguments `(#:tests? #f))
1530 (native-inputs
1531 `(("ruby-rspec" ,ruby-rspec)
1532 ("ruby-yard" ,ruby-yard)))
1533 (synopsis "Rake tasks for managing and releasing Ruby Gems")
1534 (description "Rubygems-task provides Rake tasks for managing and releasing
1535Ruby Gems.")
1536 (home-page "https://github.com/postmodern/rubygems-tasks")
1537 (license license:expat)))
1538
cb6bc5df
CB
1539(define-public ruby-rubyzip
1540 (package
1541 (name "ruby-rubyzip")
1542 (version "1.2.1")
1543 (source
1544 (origin
1545 (method url-fetch)
1546 (uri (rubygems-uri "rubyzip" version))
1547 (sha256
1548 (base32
1549 "06js4gznzgh8ac2ldvmjcmg9v1vg9llm357yckkpylaj6z456zqz"))))
1550 (build-system ruby-build-system)
1551 (arguments
1552 '(#:phases
1553 (modify-phases %standard-phases
1554 (add-before 'check 'patch-tests
1555 (lambda* (#:key inputs #:allow-other-keys)
1556 (substitute* "test/gentestfiles.rb"
1557 (("/usr/bin/zip")
1558 (string-append
1559 (assoc-ref inputs "zip") "/bin/zip")))
1560 (substitute* "test/input_stream_test.rb"
1561 (("/usr/bin/env ruby") (which "ruby")))
1562 #t)))))
1563 (native-inputs
1564 `(("bundler" ,bundler)
1565 ("ruby-simplecov" ,ruby-simplecov)
1566 ("zip" ,zip)
1567 ("unzip" ,unzip)))
1568 (synopsis "Ruby module is for reading and writing zip files")
1569 (description
1570 "The rubyzip module provides ways to read from and create zip files.")
1571 (home-page "http://github.com/rubyzip/rubyzip")
1572 (license license:bsd-2)))
1573
58b59742
RW
1574(define-public ruby-simplecov-html
1575 (package
1576 (name "ruby-simplecov-html")
53fd476f 1577 (version "0.10.2")
58b59742
RW
1578 (source (origin
1579 (method url-fetch)
1580 (uri (rubygems-uri "simplecov-html" version))
1581 (sha256
1582 (base32
53fd476f 1583 "1lihraa4rgxk8wbfl77fy9sf0ypk31iivly8vl3w04srd7i0clzn"))))
58b59742 1584 (build-system ruby-build-system)
8b749cf3 1585 (arguments `(#:tests? #f)) ; there are no tests
58b59742
RW
1586 (native-inputs
1587 `(("bundler" ,bundler)))
1588 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
1589 (description "This package provides the default HTML formatter for
1590the SimpleCov code coverage tool for Ruby version 1.9 and above.")
1591 (home-page "https://github.com/colszowka/simplecov-html")
1592 (license license:expat)))
1593
a84fa2ad
RW
1594(define-public ruby-simplecov
1595 (package
1596 (name "ruby-simplecov")
1b107245 1597 (version "0.12.0")
a84fa2ad
RW
1598 (source (origin
1599 (method url-fetch)
1600 (uri (rubygems-uri "simplecov" version))
1601 (sha256
1602 (base32
1b107245 1603 "0ffhyrfnq2zm2mc1742a4hqy475g3qa1zf6yfldwg1ldh5sn3qbx"))))
a84fa2ad
RW
1604 (build-system ruby-build-system)
1605 ;; Simplecov depends on rubocop for code style checking at build time.
1606 ;; Rubocop needs simplecov at build time.
1607 (arguments `(#:tests? #f))
1608 (propagated-inputs
1609 `(("ruby-json" ,ruby-json)
1610 ("ruby-docile" ,ruby-docile)
1611 ("ruby-simplecov-html" ,ruby-simplecov-html)))
1612 (native-inputs
1613 `(("bundler" ,bundler)))
1614 (synopsis "Code coverage framework for Ruby")
1615 (description "SimpleCov is a code coverage framework for Ruby with a
1616powerful configuration library and automatic merging of coverage across test
1617suites.")
7bf837fd 1618 (home-page "https://github.com/colszowka/simplecov")
a84fa2ad
RW
1619 (license license:expat)))
1620
98b87b82
DT
1621(define-public ruby-useragent
1622 (package
1623 (name "ruby-useragent")
3b0e45c8 1624 (version "0.16.8")
98b87b82
DT
1625 (source (origin
1626 (method url-fetch)
e83c6d00 1627 (uri (rubygems-uri "useragent" version))
98b87b82
DT
1628 (sha256
1629 (base32
3b0e45c8 1630 "1139cjqyv1hk1qcw89k81ajjkqyakqgbcyvmfrsmjqi8yn9kgqhq"))))
98b87b82
DT
1631 (build-system ruby-build-system)
1632 (arguments
e83c6d00 1633 '(#:tests? #f)) ; no test suite
98b87b82
DT
1634 (synopsis "HTTP user agent parser for Ruby")
1635 (description "UserAgent is a Ruby library that parses and compares HTTP
1636User Agents.")
1637 (home-page "https://github.com/gshutler/useragent")
1638 (license license:expat)))
96086cc5 1639
f7e9b2f3
CB
1640(define-public ruby-backports
1641 (package
1642 (name "ruby-backports")
1643 (version "3.11.4")
1644 (source
1645 (origin
1646 (method url-fetch)
1647 (uri (rubygems-uri "backports" version))
1648 (sha256
1649 (base32
1650 "1hshjxww2h7s0dk57njrygq4zpp0nlqrjfya7zwm27iq3rhc3y8g"))))
1651 (build-system ruby-build-system)
1652 (arguments
1653 '(;; TODO: This should be default, but there is one test failure
1654 #:test-target "all_spec"))
1655 (native-inputs
1656 `(("ruby-mspec" ,ruby-mspec)
1657 ("ruby-activesupport" ,ruby-activesupport)))
1658 (synopsis "Backports of the features in newer Ruby versions")
1659 (description
1660 "Backports enables more compatibility across Ruby versions by providing
1661backports of some features.")
1662 (home-page "https://github.com/marcandre/backports")
1663 (license license:expat)))
1664
96086cc5
DT
1665(define-public ruby-bacon
1666 (package
1667 (name "ruby-bacon")
e83c6d00 1668 (version "1.2.0")
96086cc5
DT
1669 (source (origin
1670 (method url-fetch)
e83c6d00 1671 (uri (rubygems-uri "bacon" version))
96086cc5
DT
1672 (sha256
1673 (base32
e83c6d00 1674 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
96086cc5 1675 (build-system ruby-build-system)
96086cc5
DT
1676 (synopsis "Small RSpec clone")
1677 (description "Bacon is a small RSpec clone providing all essential
1678features.")
1679 (home-page "https://github.com/chneukirchen/bacon")
1680 (license license:expat)))
de59d316 1681
a8d2bf3c
CB
1682(define-public ruby-bacon-bits
1683 (package
1684 (name "ruby-bacon-bits")
1685 (version "0.1.0")
1686 (source
1687 (origin
1688 (method url-fetch)
1689 (uri (rubygems-uri "bacon-bits" version))
1690 (sha256
1691 (base32
1692 "1ghpj8ja94lhi8rgi872hqk4fd2amz2k7g9znd64z5dj7v6l0dmx"))))
1693 (build-system ruby-build-system)
1694 (arguments
1695 ;; No tests
1696 '(#:tests? #f))
1697 (propagated-inputs `(("ruby-bacon" ,ruby-bacon)))
1698 (synopsis "Extensions to Bacon, for disabling tests, before and after
1699blocks and more")
1700 (description
1701 "This extends the bacon testing framework with useful extensions to
1702disable tests, have before and after blocks that run once and more.")
1703 (home-page "https://github.com/cldwalker/bacon-bits")
1704 (license license:expat)))
1705
65f65889
CB
1706(define-public ruby-bacon-colored-output
1707 (package
1708 (name "ruby-bacon-colored-output")
1709 (version "1.1.1")
1710 (source
1711 (origin
1712 (method url-fetch)
1713 (uri (rubygems-uri "bacon-colored_output" version))
1714 (sha256
1715 (base32
1716 "1znyh3vkfdlmf19p3k4zip88ibym41dn5g4p4n5hmks2iznb7qpx"))))
1717 (build-system ruby-build-system)
1718 (arguments
1719 '(;; No included tests
1720 #:tests? #f))
1721 (propagated-inputs
1722 `(("ruby-bacon" ,ruby-bacon)))
1723 (synopsis "Colored output for Bacon test framework")
1724 (description
1725 "This package adds color through ANSI escape codes to Bacon test
1726output.")
1727 (home-page "https://github.com/whitequark/bacon-colored_output")
1728 (license license:expat)))
1729
e259bdf0
DT
1730(define-public ruby-connection-pool
1731 (package
1732 (name "ruby-connection-pool")
58021db4 1733 (version "2.2.2")
e259bdf0
DT
1734 (source (origin
1735 (method url-fetch)
e83c6d00 1736 (uri (rubygems-uri "connection_pool" version))
e259bdf0
DT
1737 (sha256
1738 (base32
58021db4 1739 "0lflx29mlznf1hn0nihkgllzbj8xp5qasn8j7h838465pi399k68"))))
e259bdf0
DT
1740 (build-system ruby-build-system)
1741 (native-inputs
1742 `(("bundler" ,bundler)))
1743 (synopsis "Generic connection pool for Ruby")
1744 (description "Connection_pool provides a generic connection pooling
1745interface for Ruby programs.")
1746 (home-page "https://github.com/mperham/connection_pool")
1747 (license license:expat)))
4c0aeb44
DT
1748
1749(define-public ruby-net-http-persistent
1750 (package
1751 (name "ruby-net-http-persistent")
185ea446 1752 (version "3.0.0")
4c0aeb44
DT
1753 (source (origin
1754 (method url-fetch)
e83c6d00 1755 (uri (rubygems-uri "net-http-persistent" version))
4c0aeb44
DT
1756 (sha256
1757 (base32
185ea446 1758 "156rv95bgxfz6qw5y1r7c7bswr77918hygl8dyl14qzbqc5vyp18"))))
4c0aeb44 1759 (build-system ruby-build-system)
4c0aeb44
DT
1760 (native-inputs
1761 `(("ruby-connection-pool" ,ruby-connection-pool)
1762 ("ruby-hoe" ,ruby-hoe)))
1763 (synopsis "Persistent HTTP connection manager")
1764 (description "Net::HTTP::Persistent manages persistent HTTP connections
1765using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
1766 (home-page "https://github.com/drbrain/net-http-persistent")
1767 (license license:expat)))
afbbdf77 1768
f88bacaf
RW
1769(define-public ruby-power-assert
1770 (package
1771 (name "ruby-power-assert")
3918146b 1772 (version "0.2.7")
f88bacaf
RW
1773 (source (origin
1774 (method url-fetch)
1775 (uri (rubygems-uri "power_assert" version))
1776 (sha256
1777 (base32
3918146b 1778 "0ka6w71lcan4wgf111xi3pcn9ma9lhakv31jg8w007nwzi0xfjbi"))))
f88bacaf
RW
1779 (build-system ruby-build-system)
1780 (native-inputs
1781 `(("bundler" ,bundler)))
1782 (synopsis "Assert library with descriptive assertion messages")
1783 (description "Power-assert is an assertion library providing descriptive
1784assertion messages for tests.")
1785 (home-page "https://github.com/k-tsj/power_assert")
1786 (license (list license:bsd-2 license:ruby))))
1787
e42e3bfa
CB
1788(define-public ruby-powerpack
1789 (package
1790 (name "ruby-powerpack")
1791 (version "0.1.2")
1792 (source
1793 (origin
1794 (method url-fetch)
1795 (uri (rubygems-uri "powerpack" version))
1796 (sha256
1797 (base32
1798 "1r51d67wd467rpdfl6x43y84vwm8f5ql9l9m85ak1s2sp3nc5hyv"))))
1799 (build-system ruby-build-system)
1800 (arguments
1801 '(#:test-target "spec"))
1802 (native-inputs
1803 `(("bundler" ,bundler)
1804 ("ruby-rspec" ,ruby-rspec)
1805 ("ruby-yard" ,ruby-yard)))
1806 (synopsis "Useful extensions to core Ruby classes")
1807 (description
1808 "This package provides a few useful extensions to core Ruby classes,
1809including @code{Array}, @code{Enumerable}, @code{Hash}, @code{Numeric}, and
1810@code{String}.")
1811 (home-page "https://github.com/bbatsov/powerpack")
1812 (license license:expat)))
1813
347eb21e
RW
1814(define-public ruby-locale
1815 (package
1816 (name "ruby-locale")
1817 (version "2.1.2")
1818 (source (origin
1819 (method url-fetch)
1820 (uri (rubygems-uri "locale" version))
1821 (sha256
1822 (base32
1823 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
1824 (build-system ruby-build-system)
1825 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
1826 ;; which needs ruby-gettext, which needs ruby-locale. To break the
1827 ;; dependency cycle we disable tests.
1828 (arguments `(#:tests? #f))
1829 (native-inputs
1830 `(("bundler" ,bundler)
1831 ("ruby-yard" ,ruby-yard)))
1832 (synopsis "Ruby library providing basic localization APIs")
1833 (description
1834 "Ruby-Locale is the pure ruby library which provides basic APIs for
1835localization.")
1836 (home-page "https://github.com/ruby-gettext/locale")
1837 (license (list license:lgpl3+ license:ruby))))
1838
e2333ea3
RW
1839(define-public ruby-text
1840 (package
1841 (name "ruby-text")
1842 (version "1.3.1")
1843 (source (origin
1844 (method url-fetch)
1845 (uri (rubygems-uri "text" version))
1846 (sha256
1847 (base32
1848 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
1849 (build-system ruby-build-system)
1850 (synopsis "Collection of text algorithms for Ruby")
1851 (description
1852 "This package provides a collection of text algorithms: Levenshtein,
1853Soundex, Metaphone, Double Metaphone, Porter Stemming.")
7bf837fd 1854 (home-page "https://github.com/threedaymonk/text")
e2333ea3
RW
1855 (license license:expat)))
1856
c1f52261
RW
1857(define-public ruby-gettext
1858 (package
1859 (name "ruby-gettext")
1860 (version "3.1.7")
1861 (source (origin
1862 (method url-fetch)
1863 (uri (rubygems-uri "gettext" version))
1864 (sha256
1865 (base32
1866 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
1867 (build-system ruby-build-system)
1868 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
1869 ;; which needs ruby-gettext. To break the dependency cycle we disable
1870 ;; tests.
1871 (arguments `(#:tests? #f))
1872 (propagated-inputs
1873 `(("ruby-locale" ,ruby-locale)
1874 ("ruby-text" ,ruby-text)))
1875 (native-inputs
1876 `(("bundler" ,bundler)
1877 ("ruby-yard" ,ruby-yard)))
1878 (synopsis "GNU gettext-like program for Ruby")
1879 (description
1880 "Gettext is a GNU gettext-like program for Ruby. The catalog
1881file (po-file) used is the same as that used by GNU gettext, allowing you to
1882use GNU gettext tools for maintenance.")
2f3800e5 1883 (home-page "https://ruby-gettext.github.com/")
c1f52261
RW
1884 (license (list license:lgpl3+ license:ruby))))
1885
cc5aeb8c
RW
1886(define-public ruby-packnga
1887 (package
1888 (name "ruby-packnga")
1d60c436 1889 (version "1.0.4")
cc5aeb8c
RW
1890 (source (origin
1891 (method url-fetch)
1892 (uri (rubygems-uri "packnga" version))
1893 (sha256
1894 (base32
1d60c436 1895 "1vv2j0i43s4xid2km5hgrrxqlqpwgq8nlm8kaxfg2531c1vwfsd4"))))
cc5aeb8c
RW
1896 (build-system ruby-build-system)
1897 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
1898 ;; To break the dependency cycle we disable tests.
1899 (arguments `(#:tests? #f))
1900 (propagated-inputs
1901 `(("ruby-gettext" ,ruby-gettext)
1902 ("ruby-yard" ,ruby-yard)))
1903 (native-inputs
1904 `(("bundler" ,bundler)))
1905 (synopsis "Utility library to package internationalized libraries")
1906 (description
1907 "Packnga is a library to translate to many languages using YARD.")
1908 (home-page "http://ranguba.org/packnga/")
1909 (license license:lgpl2.0+)))
1910
3383f5bd
RW
1911(define-public ruby-test-unit
1912 (package
1913 (name "ruby-test-unit")
d74d96e4 1914 (version "3.2.5")
3383f5bd
RW
1915 (source (origin
1916 (method url-fetch)
1917 (uri (rubygems-uri "test-unit" version))
1918 (sha256
1919 (base32
d74d96e4 1920 "05bx36fw01iqz0xqhvjfrwjgnj1zx3b2vn6w1fzp19rchd7zqc52"))))
3383f5bd
RW
1921 (build-system ruby-build-system)
1922 (propagated-inputs
1923 `(("ruby-power-assert" ,ruby-power-assert)))
1924 (native-inputs
1925 `(("bundler" ,bundler)
1926 ("ruby-packnga" ,ruby-packnga)
1927 ("ruby-yard" ,ruby-yard)))
1928 (synopsis "Unit testing framework for Ruby")
1929 (description "@code{Test::Unit} is unit testing framework for Ruby, based
1930on xUnit principles. These were originally designed by Kent Beck, creator of
1931extreme programming software development methodology, for Smalltalk's SUnit.
1932It allows writing tests, checking results and automated testing in Ruby.")
2f3800e5 1933 (home-page "https://test-unit.github.io/")
3383f5bd
RW
1934 (license (list license:psfl license:ruby))))
1935
b9511aa9
CB
1936(define-public ruby-maruku
1937 (package
1938 (name "ruby-maruku")
1939 (version "0.7.3")
1940 (source
1941 (origin
1942 (method url-fetch)
1943 (uri (rubygems-uri "maruku" version))
1944 (sha256
1945 (base32
1946 "1r7bxpgnx2hp3g12bjrmdrpv663dfqxsdp0af69kjhxmaxpia56x"))))
1947 (build-system ruby-build-system)
1948 (arguments
1949 '(;; TODO: 3 tests seem to fail due to HTML encoding issues
1950 #:tests? #f
1951 #:phases
1952 (modify-phases %standard-phases
1953 (replace 'check
1954 (lambda* (#:key tests? #:allow-other-keys)
1955 (when tests?
1956 (invoke "rspec"))
1957 #t)))))
1958 (native-inputs
1959 `(("ruby-rspec" ,ruby-rspec)
1960 ("ruby-simplecov" ,ruby-simplecov)
1961 ("ruby-nokogiri-diff" ,ruby-nokogiri-diff)))
1962 (synopsis "Markdown interpreter in Ruby")
1963 (description
1964 "Maruku is a Markdown interpreter in Ruby. It can export Markdown to
1965HTML, and PDF through LaTeX.")
1966 (home-page "https://github.com/bhollis/maruku")
1967 (license license:expat)))
1968
25d6d49b
RW
1969(define-public ruby-metaclass
1970 (package
1971 (name "ruby-metaclass")
1972 (version "0.0.4")
1973 (source (origin
1974 (method url-fetch)
1975 (uri (rubygems-uri "metaclass" version))
1976 (sha256
1977 (base32
1978 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
1979 (build-system ruby-build-system)
1980 (arguments
1981 `(#:phases
1982 (modify-phases %standard-phases
1983 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 1984 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 1985 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
1986 (substitute* "Rakefile"
1987 (("t\\.libs << \"test\"" line)
1988 (string-append line "; t.libs << \""
3cb3fa67 1989 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
1990 "/gems/test-unit-"
1991 ,(package-version ruby-test-unit)
1992 "/lib\""))))
1993 #t)))))
25d6d49b
RW
1994 (native-inputs
1995 `(("bundler" ,bundler)
1996 ("ruby-test-unit" ,ruby-test-unit)))
1997 (synopsis "Ruby library adding metaclass method to all objects")
1998 (description
1999 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
2000objects.")
7bf837fd 2001 (home-page "https://github.com/floehopper/metaclass")
25d6d49b
RW
2002 (license license:expat)))
2003
1d1d20b0
CB
2004(define-public ruby-mspec
2005 (package
2006 (name "ruby-mspec")
2007 (version "1.9.1")
2008 (source
2009 (origin
2010 (method url-fetch)
2011 (uri (rubygems-uri "mspec" version))
2012 (sha256
2013 (base32
2014 "0wmyh2n40m4srwdx9z6h6g6p46k02pzyhcsja3hqcw5h5b0hfmhd"))))
2015 (build-system ruby-build-system)
2016 (arguments
2017 '(;; TODO: 3 test failures
2018 ;; ./spec/mocks/mock_spec.rb:82
2019 ;; ./spec/utils/name_map_spec.rb:151
2020 ;; ./spec/utils/name_map_spec.rb:155
2021 #:tests? #f
2022 #:phases
2023 (modify-phases %standard-phases
2024 (add-after 'extract-gemspec 'change-dependency-constraints
2025 (lambda _
2026 (substitute* "mspec.gemspec"
2027 (("rake.*") "rake>)\n")
2028 (("rspec.*") "rspec>)\n"))
2029 #t))
2030 (replace 'check
2031 (lambda* (#:key tests? #:allow-other-keys)
2032 (when tests?
2033 (invoke "rspec" "spec"))
2034 #t)))))
2035 (native-inputs
2036 `(("bundler" ,bundler)
2037 ("ruby-rake" ,ruby-rake)
2038 ("ruby-rspec" ,ruby-rspec)))
2039 (synopsis "MSpec is a specialized framework for RubySpec")
2040 (description
2041 "MSpec is a specialized framework that is syntax-compatible with RSpec 2
2042for basic features. MSpec contains additional features that assist in writing
2043specs for Ruby implementations in ruby/spec.")
2044 (home-page "http://rubyspec.org")
2045 (license license:expat)))
2046
b8aecc31
CB
2047(define-public ruby-mysql2
2048 (package
2049 (name "ruby-mysql2")
2050 (version "0.5.2")
2051 (source
2052 (origin
2053 (method git-fetch)
2054 (uri (git-reference
2055 (url "https://github.com/brianmario/mysql2.git")
2056 (commit version)))
2057 (file-name (git-file-name name version))
2058 (sha256
2059 (base32
2060 "11lvfgc2rmvkm52jp0nbi6pvhk06klznghr7llldfw8basl9n5wv"))))
2061 (build-system ruby-build-system)
2062 (arguments
2063 '(;; TODO: Tests require a running MySQL/MariaDB service
2064 #:tests? #f
2065 #:phases
2066 (modify-phases %standard-phases
2067 (replace 'replace-git-ls-files
2068 (lambda _
2069 (substitute* "mysql2.gemspec"
2070 (("git ls-files .*`") "find . -type f |sort`"))
2071 #t))
2072 (add-before 'install 'set-MAKEFLAGS
2073 (lambda* (#:key outputs #:allow-other-keys)
2074 (setenv "MAKEFLAGS"
2075 (string-append
2076 "V=1 "
2077 "prefix=" (assoc-ref outputs "out")))
2078 #t))
2079 ;; Move the 'check phase to after 'install, as then you can test
2080 ;; using the installed mysql2 gem in the store.
2081 (delete 'check)
2082 (add-after 'install 'check
2083 (lambda* (#:key outputs tests? #:allow-other-keys)
2084 (setenv "GEM_PATH"
2085 (string-append
2086 (getenv "GEM_PATH")
2087 ":"
2088 (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))
2089 (when tests?
2090 (invoke "rspec"))
2091 #t)))))
2092 (inputs
2093 `(("mariadb" ,mariadb)
2094 ("zlib" ,zlib)))
2095 (native-inputs
2096 `(("ruby-rspec" ,ruby-rspec)
2097 ("ruby-rake-compiler" ,ruby-rake-compiler)))
2098 (synopsis "MySQL library for Ruby, binding to libmysql")
2099 (description
2100 "This package provides a simple, fast MySQL library for Ruby, binding to
2101libmysql.")
2102 (home-page "https://github.com/brianmario/mysql2")
2103 (license license:expat)))
2104
21f7b7bd
RW
2105(define-public ruby-blankslate
2106 (package
2107 (name "ruby-blankslate")
2108 (version "3.1.3")
2109 (source (origin
2110 (method url-fetch)
2111 (uri (rubygems-uri "blankslate" version))
2112 (sha256
2113 (base32
2114 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
2115 (build-system ruby-build-system)
2116 (arguments
2117 `(#:phases
2118 (modify-phases %standard-phases
2119 (replace 'check
9923d5a4 2120 (lambda _ (invoke "rspec" "spec/"))))))
21f7b7bd
RW
2121 (native-inputs
2122 `(("bundler" ,bundler)
2123 ("ruby-rspec" ,ruby-rspec)))
2124 (synopsis "Abstract base class with no predefined methods")
2125 (description
2126 "BlankSlate provides an abstract base class with no predefined
2127methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
2128as a base class when writing classes that depend upon
2129@code{method_missing} (e.g. dynamic proxies).")
7bf837fd 2130 (home-page "https://github.com/masover/blankslate")
21f7b7bd
RW
2131 (license license:expat)))
2132
afdb437c
CB
2133(define-public ruby-bond
2134 (package
2135 (name "ruby-bond")
2136 (version "0.5.1")
2137 (source
2138 (origin
2139 (method url-fetch)
2140 (uri (rubygems-uri "bond" version))
2141 (sha256
2142 (base32
2143 "1r19ifc4skyl2gxnifrxa5jvbbay9fb2in79ppgv02b6n4bhsw90"))))
2144 (build-system ruby-build-system)
2145 (native-inputs
2146 `(("ruby-bacon" ,ruby-bacon)
2147 ("ruby-bacon-bits" ,ruby-bacon-bits)
2148 ("ruby-mocha-on-bacon" ,ruby-mocha-on-bacon)))
2149 (synopsis "Bond can provide custom autocompletion for arguments, methods
2150and more")
2151 (description
2152 "Bond can autocomplete argument(s) to methods, uniquely completing per
2153module, per method and per argument. Bond provides a configuration system and
2154a DSL for creating custom completions and completion rules. Bond can also
2155load completions that ship with gems. Bond is able to offer more than irb's
2156completion since it uses the full line of input when completing as opposed to
2157irb's last-word approach.")
2158 (home-page "http://tagaholic.me/bond/")
2159 (license license:expat)))
2160
f3d7bb93
CB
2161(define-public ruby-idn-ruby
2162 (package
2163 (name "ruby-idn-ruby")
2164 (version "0.1.0")
2165 (source
2166 (origin
2167 (method url-fetch)
2168 (uri (rubygems-uri "idn-ruby" version))
2169 (sha256
2170 (base32
2171 "07vblcyk3g72sbq12xz7xj28snpxnh3sbcnxy8bglqbfqqhvmawr"))))
2172 (build-system ruby-build-system)
2173 (arguments
2174 '(#:phases
2175 (modify-phases %standard-phases
2176 (delete 'check)
2177 (add-after 'install 'check
2178 (lambda* (#:key tests? outputs #:allow-other-keys)
2179 (when tests?
2180 (let* ((gem-file (cadr (find-files "." "\\.gem")))
2181 (name-and-version (basename gem-file ".gem")))
2182 (apply invoke
2183 "ruby" "--verbose"
2184 (string-append "-I"
2185 (assoc-ref outputs "out")
2186 "/lib/ruby/vendor_ruby/gems/"
2187 name-and-version
2188 "/lib")
2189 (find-files "./test" ".*\\.rb"))))
2190 #t)))))
2191 (inputs
2192 `(("libidn" ,libidn)))
2193 (synopsis "Ruby Bindings for the GNU LibIDN library")
2194 (description
2195 "Ruby Bindings for the GNU LibIDN library, an implementation of the
2196Stringprep, Punycode and IDNA specifications. These are used to encode and
2197decode internationalized domain + names according to the IDNA2003
2198specifications.
2199
2200Included are the most important parts of the Stringprep, Punycode and IDNA
2201APIs like performing Stringprep processings, encoding to and decoding from
2202Punycode strings and converting entire domain names to and from the ACE
2203encoded form.")
2204 (home-page "https://github.com/deepfryed/idn-ruby")
2205 (license license:asl2.0)))
2206
4016ba3f
RW
2207(define-public ruby-instantiator
2208 (package
2209 (name "ruby-instantiator")
688c9076 2210 (version "0.0.7")
4016ba3f
RW
2211 (source (origin
2212 (method url-fetch)
2213 (uri (rubygems-uri "instantiator" version))
2214 (sha256
2215 (base32
688c9076 2216 "0w07w3gkyqr7m0vz5h13vm8b411660qywjm2xxxgdjv4wb3fazbr"))))
4016ba3f
RW
2217 (build-system ruby-build-system)
2218 (arguments
2219 `(#:phases
2220 (modify-phases %standard-phases
2221 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 2222 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 2223 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
2224 (substitute* "Rakefile"
2225 (("t\\.libs << \"test\"" line)
2226 (string-append line "; t.libs << \""
3cb3fa67 2227 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
2228 "/gems/test-unit-"
2229 ,(package-version ruby-test-unit)
2230 "/lib\""))))
2231 #t)))))
4016ba3f
RW
2232 (propagated-inputs
2233 `(("ruby-blankslate" ,ruby-blankslate)))
2234 (native-inputs
2235 `(("bundler" ,bundler)
2236 ("ruby-test-unit" ,ruby-test-unit)))
2237 (synopsis "Instantiate an arbitrary Ruby class")
2238 (description
2239 "Instantiator lets you instantiate an arbitrary Ruby class without
2240knowing anything about the constructor.")
2241 (home-page "https://github.com/floehopper/instantiator")
2242 (license license:expat)))
2243
97aee8d3
RW
2244(define-public ruby-introspection
2245 (package
2246 (name "ruby-introspection")
98ff58a5 2247 (version "0.0.4")
97aee8d3
RW
2248 (source (origin
2249 (method url-fetch)
2250 (uri (rubygems-uri "introspection" version))
2251 (sha256
2252 (base32
98ff58a5 2253 "1y2nbijkc0zlfmn9ss6588ilarq2kbn2i7w7pwwsli66dj84zgca"))))
97aee8d3
RW
2254 (build-system ruby-build-system)
2255 (arguments
2256 `(#:phases
2257 (modify-phases %standard-phases
2258 (add-after 'unpack 'add-test-unit-to-search-path
2259 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 2260 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
2261 (substitute* "Rakefile"
2262 (("t\\.libs << \"test\"" line)
2263 (string-append line "; t.libs << \""
3cb3fa67 2264 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
2265 "/gems/test-unit-"
2266 ,(package-version ruby-test-unit)
2267 "/lib\""))))
97aee8d3
RW
2268 #t)))))
2269 (propagated-inputs
2270 `(("ruby-instantiator" ,ruby-instantiator)
2271 ("ruby-metaclass" ,ruby-metaclass)))
2272 (native-inputs
2273 `(("bundler" ,bundler)
2274 ("ruby-blankslate" ,ruby-blankslate)
2275 ("ruby-test-unit" ,ruby-test-unit)))
2276 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
2277 (description
2278 "Introspection provides tools to inspect the hierarchy of method
2279definitions on a Ruby object.")
2280 (home-page "https://github.com/floehopper/introspection")
2281 (license license:expat)))
2282
d93062fd
RW
2283(define-public ruby-redcarpet
2284 (package
2285 (name "ruby-redcarpet")
5ca48923 2286 (version "3.4.0")
d93062fd
RW
2287 (source (origin
2288 (method url-fetch)
2289 (uri (rubygems-uri "redcarpet" version))
2290 (sha256
2291 (base32
5ca48923 2292 "0h9qz2hik4s9knpmbwrzb3jcp3vc5vygp9ya8lcpl7f1l9khmcd7"))))
d93062fd
RW
2293 (build-system ruby-build-system)
2294 (arguments
2295 `(#:phases
2296 (modify-phases %standard-phases
2297 ;; The gem archive does not include the conformance tests.
2298 (add-after 'unpack 'disable-conformance-tests
2299 (lambda _
2300 (substitute* "Rakefile"
2301 (("task :test => %w\\[test:unit test:conformance\\]")
2302 "task :test => %w[test:unit]"))
2303 #t)))))
2304 (native-inputs
2305 `(("bundler" ,bundler)
2306 ("ruby-test-unit" ,ruby-test-unit)
2307 ("ruby-rake-compiler" ,ruby-rake-compiler)))
2308 (synopsis "Extensible Markdown to (X)HTML converter")
2309 (description
2310 "Redcarpet is an extensible Ruby library for Markdown processing and
2311conversion to (X)HTML.")
7bf837fd 2312 (home-page "https://github.com/vmg/redcarpet")
d93062fd
RW
2313 (license license:expat)))
2314
4f2a52ae
RW
2315(define-public ruby-mocha
2316 (package
2317 (name "ruby-mocha")
2318 (version "1.1.0")
2319 (source (origin
2320 (method url-fetch)
2321 (uri (rubygems-uri "mocha" version))
2322 (sha256
2323 (base32
2324 "107nmnngbv8lq2g7hbjpn5kplb4v2c8gs9lxrg6vs8gdbddkilzi"))))
2325 (build-system ruby-build-system)
2326 (arguments
2327 `(#:phases
2328 (modify-phases %standard-phases
2329 (add-after 'unpack 'add-test-unit-to-search-path
2330 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 2331 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
2332 (substitute* "Rakefile"
2333 (("t\\.libs << 'test'" line)
2334 (string-append line "; t.libs << \""
3cb3fa67 2335 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
2336 "/gems/test-unit-"
2337 ,(package-version ruby-test-unit)
2338 "/lib\""))))
4f2a52ae
RW
2339 #t))
2340 (add-before 'check 'use-latest-redcarpet
2341 (lambda _
2342 (substitute* "mocha.gemspec"
71596c3c
BW
2343 (("<redcarpet>.freeze, \\[\"~> 1\"\\]")
2344 "<redcarpet>.freeze, [\">= 3\"]"))
4f2a52ae
RW
2345 #t))
2346 (add-before 'check 'hardcode-version
2347 (lambda _
2348 ;; Mocha is undefined at build time
2349 (substitute* "Rakefile"
2350 (("#\\{Mocha::VERSION\\}") ,version))
2351 #t))
2352 (add-before 'check 'remove-failing-test
2353 ;; FIXME: This test fails for reasons unrelated to Guix packaging.
2354 (lambda _
2355 (delete-file "test/acceptance/stubbing_nil_test.rb")
2356 #t)))))
2357 (propagated-inputs
2358 `(("ruby-metaclass" ,ruby-metaclass)))
2359 (native-inputs
2360 `(("bundler" ,bundler)
2361 ("ruby-yard" ,ruby-yard)
2362 ("ruby-introspection" ,ruby-introspection)
2363 ("ruby-test-unit" ,ruby-test-unit)
2364 ("ruby-redcarpet" ,ruby-redcarpet)))
2365 (synopsis "Mocking and stubbing library for Ruby")
2366 (description
2367 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
2368allows mocking and stubbing of methods on real (non-mock) classes.")
2369 (home-page "http://gofreerange.com/mocha/docs")
2370 (license license:expat)))
2371
cf646acf
CB
2372(define-public ruby-mocha-on-bacon
2373 (package
2374 (name "ruby-mocha-on-bacon")
2375 (version "0.2.3")
2376 (source
2377 (origin
2378 (method url-fetch)
2379 (uri (rubygems-uri "mocha-on-bacon" version))
2380 (sha256
2381 (base32
2382 "1h49b33rq889hn8x3wp9byczl91va16jh1w4d2wyy4yj23icdrcp"))))
2383 (build-system ruby-build-system)
2384 (arguments
2385 ;; rubygems.org release missing tests
2386 '(#:tests? #f))
2387 (propagated-inputs `(("ruby-mocha" ,ruby-mocha)))
2388 (synopsis "Mocha adapter for Bacon")
2389 (description
2390 "This package provides a Mocha adapter for Bacon, allowing you to use the
2391Mocha stubbing and mocking library with Bacon, a small RSpec clone.")
2392 (home-page
2393 "https://github.com/alloy/mocha-on-bacon")
2394 (license license:expat)))
2395
2c84ba7e
RW
2396(define-public ruby-net-ssh
2397 (package
2398 (name "ruby-net-ssh")
5803f872 2399 (version "4.2.0")
2c84ba7e
RW
2400 (source (origin
2401 (method url-fetch)
2402 (uri (rubygems-uri "net-ssh" version))
2403 (sha256
2404 (base32
5803f872 2405 "07c4v97zl1daabmri9zlbzs6yvkl56z1q14bw74d53jdj0c17nhx"))))
2c84ba7e
RW
2406 (build-system ruby-build-system)
2407 (native-inputs
a7938625
MB
2408 `(("bundler" ,bundler)
2409 ("ruby-mocha" ,ruby-mocha)
2c84ba7e
RW
2410 ("ruby-test-unit" ,ruby-test-unit)))
2411 (synopsis "Ruby implementation of the SSH2 client protocol")
2412 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
2413client protocol. It allows you to write programs that invoke and interact
2414with processes on remote servers, via SSH2.")
2415 (home-page "https://github.com/net-ssh/net-ssh")
2416 (license license:expat)))
2417
d38755cb
DM
2418(define-public ruby-net-scp
2419 (package
2420 (name "ruby-net-scp")
2421 ;; The 1.2.1 release would be incompatible with ruby-net-ssh >= 4.
2422 (version "1.2.2.rc2")
2423 (source
2424 (origin
2425 (method url-fetch)
2426 (uri (string-append "https://github.com/net-ssh/net-scp/archive/v"
2427 version ".tar.gz"))
2428 (sha256
2429 (base32
2430 "0xyf17mhgvyz54xjj9ria4wnq3x62bhmkfgzqv8jwiip2bplv1nk"))))
2431 (build-system ruby-build-system)
2432 (native-inputs
2433 `(("bundler" ,bundler)
2434 ("ruby-test-unit" ,ruby-test-unit)
2435 ("ruby-mocha" ,ruby-mocha)))
2436 (propagated-inputs
2437 `(("ruby-net-ssh" ,ruby-net-ssh)))
2438 (synopsis "Pure-Ruby SCP client library")
2439 (description "@code{Net::SCP} is a pure-Ruby implementation of the SCP
2440client protocol.")
2441 (home-page "https://github.com/net-ssh/net-scp")
2442 (license license:expat)))
2443
2206e948
DT
2444(define-public ruby-minitest
2445 (package
2446 (name "ruby-minitest")
88a105c1 2447 (version "5.11.3")
2206e948 2448 (source (origin
e83c6d00
DT
2449 (method url-fetch)
2450 (uri (rubygems-uri "minitest" version))
2206e948
DT
2451 (sha256
2452 (base32
88a105c1 2453 "0icglrhghgwdlnzzp4jf76b0mbc71s80njn5afyfjn4wqji8mqbq"))))
2206e948 2454 (build-system ruby-build-system)
2206e948
DT
2455 (native-inputs
2456 `(("ruby-hoe" ,ruby-hoe)))
2457 (synopsis "Small test suite library for Ruby")
2458 (description "Minitest provides a complete suite of Ruby testing
2459facilities supporting TDD, BDD, mocking, and benchmarking.")
2460 (home-page "https://github.com/seattlerb/minitest")
2461 (license license:expat)))
2462
1db6e09f
RW
2463;; This is the last release of Minitest 4, which is used by some packages.
2464(define-public ruby-minitest-4
2465 (package (inherit ruby-minitest)
2466 (version "4.7.5")
2467 (source (origin
2468 (method url-fetch)
2469 (uri (rubygems-uri "minitest" version))
2470 (sha256
2471 (base32
2472 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
2473 (arguments
2474 `(#:phases
2475 (modify-phases %standard-phases
2476 (add-after 'unpack 'remove-unsupported-method
2477 (lambda _
2478 (substitute* "Rakefile"
2479 (("self\\.rubyforge_name = .*") ""))
9a7017eb
BW
2480 #t))
2481 (add-after 'build 'exclude-failing-tests
2482 (lambda _
2483 ;; Some tests are failing on Ruby 2.4 due to the deprecation of
2484 ;; Fixnum.
2485 (delete-file "test/minitest/test_minitest_spec.rb")
2486 #t)))))))
1db6e09f 2487
35130835
DT
2488(define-public ruby-minitest-sprint
2489 (package
2490 (name "ruby-minitest-sprint")
2491 (version "1.1.0")
2492 (source (origin
e83c6d00
DT
2493 (method url-fetch)
2494 (uri (rubygems-uri "minitest-sprint" version))
35130835
DT
2495 (sha256
2496 (base32
e83c6d00 2497 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
35130835 2498 (build-system ruby-build-system)
35130835
DT
2499 (native-inputs
2500 `(("ruby-hoe" ,ruby-hoe)
2501 ("ruby-minitest" ,ruby-minitest)))
2502 (synopsis "Fast test suite runner for minitest")
2503 (description "Minitest-sprint is a test runner for minitest that makes it
2504easier to re-run individual failing tests.")
2505 (home-page "https://github.com/seattlerb/minitest-sprint")
2506 (license license:expat)))
2507
0808e361
DT
2508(define-public ruby-minitest-bacon
2509 (package
2510 (name "ruby-minitest-bacon")
6f9652b0 2511 (version "1.0.3")
0808e361 2512 (source (origin
e83c6d00
DT
2513 (method url-fetch)
2514 (uri (rubygems-uri "minitest-bacon" version))
0808e361
DT
2515 (sha256
2516 (base32
6f9652b0 2517 "0zhdwcl6bgha61qiyfvr7zs7ywaxc33wmj9xhxl8jdmpdvifvfaj"))))
0808e361 2518 (build-system ruby-build-system)
0808e361
DT
2519 (native-inputs
2520 `(("ruby-hoe" ,ruby-hoe)))
2521 (inputs
2522 `(("ruby-minitest" ,ruby-minitest)))
2523 (synopsis "Bacon compatibility library for minitest")
2524 (description "Minitest-bacon extends minitest with bacon-like
2525functionality, making it easier to migrate test suites from bacon to minitest.")
2526 (home-page "https://github.com/seattlerb/minitest-bacon")
2527 (license license:expat)))
2528
39dc0eb5
BW
2529(define-public ruby-minitest-focus
2530 (package
2531 (name "ruby-minitest-focus")
2532 (version "1.1.2")
2533 (source
2534 (origin
2535 (method url-fetch)
2536 (uri (rubygems-uri "minitest-focus" version))
2537 (sha256
2538 (base32
2539 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
2540 (build-system ruby-build-system)
2541 (propagated-inputs
2542 `(("ruby-minitest" ,ruby-minitest)))
2543 (native-inputs
2544 `(("ruby-hoe" ,ruby-hoe)))
2545 (synopsis "Allows a few specific tests to be focused on")
2546 (description
2547 "@code{minitest-focus} gives the ability focus on a few tests with ease
2548without having to use command-line arguments. It introduces a @code{focus}
2549class method for use in testing classes, specifying that the next defined test
2550is to be run.")
2551 (home-page "https://github.com/seattlerb/minitest-focus")
2552 (license license:expat)))
2553
99fc5cd5
BW
2554(define-public ruby-minitest-pretty-diff
2555 ;; Use git reference because gem is out of date and does not contain testing
2556 ;; script. There are no releases on GitHub.
2557 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
2558 (package
2559 (name "ruby-minitest-pretty-diff")
2560 (version (string-append "0.1-1." (string-take commit 8)))
2561 (source (origin
2562 (method git-fetch)
2563 (uri (git-reference
2564 (url "https://github.com/adammck/minitest-pretty_diff.git")
2565 (commit commit)))
2566 (file-name (string-append name "-" version "-checkout"))
2567 (sha256
2568 (base32
2569 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
2570 (build-system ruby-build-system)
2571 (arguments
2572 `(#:phases
2573 (modify-phases %standard-phases
2574 (replace 'check
2575 (lambda _
9923d5a4 2576 (invoke "script/test"))))))
99fc5cd5
BW
2577 (native-inputs
2578 `(("bundler" ,bundler)
2579 ("ruby-turn" ,ruby-turn)))
2580 (synopsis "Pretty-print hashes and arrays in MiniTest")
2581 (description
2582 "@code{minitest-pretty_diff} monkey-patches
2583@code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
2584diffing them. This makes it easier to spot differences between nested
2585structures when tests fail.")
2586 (home-page "https://github.com/adammck/minitest-pretty_diff")
2587 (license license:expat))))
2588
685d0d2f
BW
2589(define-public ruby-minitest-moar
2590 (package
2591 (name "ruby-minitest-moar")
2592 (version "0.0.4")
2593 (source
2594 (origin
2595 (method url-fetch)
2596 (uri (rubygems-uri "minitest-moar" version))
2597 (sha256
2598 (base32
2599 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
2600 (build-system ruby-build-system)
2601 (arguments
2602 `(#:phases
2603 (modify-phases %standard-phases
2604 (add-before 'check 'clean-dependencies
2605 (lambda _
2606 ;; Remove all gems defined in the Gemfile because these are not
2607 ;; truly needed.
2608 (substitute* "Gemfile"
2609 (("gem .*") ""))
2610 ;; Remove byebug as not needed to run tests.
2611 (substitute* "test/test_helper.rb"
2612 (("require 'byebug'") ""))
2613 #t)))))
2614 (native-inputs
2615 `(("bundler" ,bundler)
2616 ("ruby-minitest" ,ruby-minitest)))
2617 (synopsis "Extra features and changes to MiniTest")
2618 (description "@code{MiniTest Moar} add some additional features and
2619changes some default behaviours in MiniTest. For instance, Moar replaces the
2620MiniTest @code{Object#stub} with a global @code{stub} method.")
2621 (home-page "https://github.com/dockyard/minitest-moar")
2622 (license license:expat)))
2623
e07ef1d6
BW
2624(define-public ruby-minitest-bonus-assertions
2625 (package
2626 (name "ruby-minitest-bonus-assertions")
c9e261b7 2627 (version "3.0")
e07ef1d6
BW
2628 (source
2629 (origin
2630 (method url-fetch)
2631 (uri (rubygems-uri "minitest-bonus-assertions" version))
2632 (sha256
2633 (base32
c9e261b7 2634 "1hbq9jk904xkz868yha1bqcm6azm7kmjsll2k4pn2nrcib508h2a"))))
e07ef1d6
BW
2635 (build-system ruby-build-system)
2636 (arguments
2637 `(#:phases
2638 (modify-phases %standard-phases
2639 (add-before 'check 'clean-dependencies
2640 (lambda _
2641 ;; Remove unneeded require statement that would entail another
2642 ;; dependency.
2643 (substitute* "test/minitest_config.rb"
2644 (("require 'minitest/bisect'") ""))
2645 #t)))))
2646 (native-inputs
2647 `(("ruby-hoe" ,ruby-hoe)
2648 ("ruby-minitest-pretty-diff" ,ruby-minitest-pretty-diff)
2649 ("ruby-minitest-focus" ,ruby-minitest-focus)
2650 ("ruby-minitest-moar" ,ruby-minitest-moar)))
2651 (synopsis "Bonus assertions for @code{Minitest}")
2652 (description
2653 "Minitest bonus assertions provides extra MiniTest assertions. For
2654instance, it provides @code{assert_true}, @code{assert_false} and
2655@code{assert_set_equal}.")
2656 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
2657 (license license:expat)))
2658
e2c9a9cc
CB
2659(define-public ruby-minitest-reporters
2660 (package
2661 (name "ruby-minitest-reporters")
2662 (version "1.3.6")
2663 (source
2664 (origin
2665 (method url-fetch)
2666 (uri (rubygems-uri "minitest-reporters" version))
2667 (sha256
2668 (base32
2669 "1a3das80rwgys5rj48i5ly144nvszyqyi748bk9bss74jblcf5ay"))))
2670 (build-system ruby-build-system)
2671 (arguments
2672 '(#:phases
2673 (modify-phases %standard-phases
2674 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
2675 ;; including it as an input can lead to circular dependencies.
2676 (add-after 'unpack 'remove-rubocop-from-Rakefile
2677 (lambda _
2678 (substitute* "Rakefile"
2679 (("require 'rubocop/rake\\_task'") "")
2680 (("RuboCop::RakeTask\\.new\\(:rubocop\\)") "[].each"))
2681 #t))
2682 (add-after 'extract-gemspec 'remove-rubocop-from-gemspec
2683 (lambda _
2684 (substitute* "minitest-reporters.gemspec"
2685 ((".*%q<rubocop>.*") "\n"))
2686 #t)))))
2687 (propagated-inputs
2688 `(("ruby-ansi" ,ruby-ansi)
2689 ("ruby-builder" ,ruby-builder)
2690 ("ruby-minitest" ,ruby-minitest)
2691 ("ruby-progressbar" ,ruby-progressbar)))
2692 (native-inputs
2693 `(("bundler" ,bundler)
2694 ("ruby-maruku" ,ruby-maruku)))
2695 (synopsis "Enhanced reporting for Minitest tests")
2696 (description
2697 "@code{minitest/reporters} provides a custom Minitest runner to improve
2698how the test state is reported. A number of different reporters are
2699available, including a spec reporter, progress bar reporter, a HTML
2700reporter.")
2701 (home-page "https://github.com/kern/minitest-reporters")
2702 (license license:expat)))
2703
e582fa93
BW
2704(define-public ruby-minitest-rg
2705 (package
2706 (name "ruby-minitest-rg")
2707 (version "5.2.0")
2708 (source
2709 (origin
2710 (method url-fetch)
2711 (uri (rubygems-uri "minitest-rg" version))
2712 (sha256
2713 (base32
2714 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
2715 (build-system ruby-build-system)
2716 (arguments
2717 ;; Some tests fail even outside Guix, so disable tests.
2718 ;; https://github.com/blowmage/minitest-rg/issues/12
2719 ;; https://github.com/blowmage/minitest-rg/pull/13
2720 `(#:tests? #f))
2721 (propagated-inputs
2722 `(("ruby-minitest" ,ruby-minitest)))
2723 (synopsis "Coloured output for Minitest")
2724 (description
2725 "@code{minitest-rg} changes the colour of the output from Minitest.")
2726 (home-page "http://blowmage.com/minitest-rg")
2727 (license license:expat)))
2728
2a96dbe6
BW
2729(define-public ruby-minitest-hooks
2730 (package
2731 (name "ruby-minitest-hooks")
eaaf8b12 2732 (version "1.4.2")
2a96dbe6
BW
2733 (source
2734 (origin
2735 (method url-fetch)
2736 (uri (rubygems-uri "minitest-hooks" version))
2737 (sha256
2738 (base32
eaaf8b12 2739 "0lnpvzijbjrvxjc43d155jnbk2mkfshrz22an711wh004scavlzc"))))
2a96dbe6
BW
2740 (build-system ruby-build-system)
2741 (arguments
2742 '(#:test-target "spec"))
2743 (native-inputs
2744 `(("ruby-sequel" ,ruby-sequel)
2745 ("ruby-sqlite3" ,ruby-sqlite3)))
2746 (synopsis "Hooks for the minitest framework")
2747 (description
2748 "Minitest-hooks adds @code{around}, @code{before_all}, @code{after_all},
2749@code{around_all} hooks for Minitest. This allows, for instance, running each
2750suite of specs inside a database transaction, running each spec inside its own
2751savepoint inside that transaction. This can significantly speed up testing
2752for specs that share expensive database setup code.")
7bf837fd 2753 (home-page "https://github.com/jeremyevans/minitest-hooks")
2a96dbe6
BW
2754 (license license:expat)))
2755
afbbdf77
DT
2756(define-public ruby-daemons
2757 (package
2758 (name "ruby-daemons")
f03153db 2759 (version "1.2.5")
afbbdf77
DT
2760 (source (origin
2761 (method url-fetch)
e83c6d00 2762 (uri (rubygems-uri "daemons" version))
afbbdf77
DT
2763 (sha256
2764 (base32
f03153db 2765 "15smbsg0gxb7nf0nrlnplc68y0cdy13dm6fviavpmw7c630sring"))))
afbbdf77
DT
2766 (build-system ruby-build-system)
2767 (arguments
2768 `(#:tests? #f)) ; no test suite
2769 (synopsis "Daemonize Ruby programs")
2770 (description "Daemons provides a way to wrap existing Ruby scripts to be
2771run as a daemon and to be controlled by simple start/stop/restart commands.")
2772 (home-page "https://github.com/thuehlinger/daemons")
2773 (license license:expat)))
b03eb6ac
CB
2774
2775(define-public ruby-data_uri
2776 (package
2777 (name "ruby-data_uri")
2778 (version "0.1.0")
2779 (source
2780 (origin
2781 (method url-fetch)
2782 (uri (rubygems-uri "data_uri" version))
2783 (sha256
2784 (base32
2785 "0fzkxgdxrlbfl4537y3n9mjxbm28kir639gcw3x47ffchwsgdcky"))))
2786 (build-system ruby-build-system)
2787 (synopsis "URI class for parsing data URIs")
2788 (description
2789 "Data @acronym{URI, universal resource idenfitier}s allow resources to be
2790embedded inside a URI. The URI::Data class provides support for parsing these
2791URIs using the normal URI.parse method.")
2792 (home-page "https://github.com/dball/data_uri")
2793 (license license:expat)))
66e20863
DT
2794
2795(define-public ruby-git
2796 (package
2797 (name "ruby-git")
ceaff59e 2798 (version "1.3.0")
66e20863
DT
2799 (source (origin
2800 (method url-fetch)
e83c6d00 2801 (uri (rubygems-uri "git" version))
66e20863
DT
2802 (sha256
2803 (base32
ceaff59e 2804 "1waikaggw7a1d24nw0sh8fd419gbf7awh000qhsf411valycj6q3"))))
66e20863
DT
2805 (build-system ruby-build-system)
2806 (arguments
e83c6d00
DT
2807 `(#:tests? #f ; no tests
2808 #:phases (modify-phases %standard-phases
2809 (add-after 'install 'patch-git-binary
2810 (lambda* (#:key inputs outputs #:allow-other-keys)
66e20863
DT
2811 ;; Make the default git binary an absolute path to the
2812 ;; store.
e83c6d00
DT
2813 (let ((git (string-append (assoc-ref inputs "git")
2814 "/bin/git"))
3cb3fa67
CB
2815 (config (string-append
2816 (assoc-ref outputs "out")
2817 "/lib/ruby/vendor_ruby/gems/git-"
2818 ,version "/lib/git/config.rb")))
e83c6d00 2819 (substitute* (list config)
66e20863
DT
2820 (("'git'")
2821 (string-append "'" git "'")))
e83c6d00 2822 #t))))))
66e20863
DT
2823 (inputs
2824 `(("git" ,git)))
2825 (synopsis "Ruby wrappers for Git")
2826 (description "Ruby/Git is a Ruby library that can be used to create, read
2827and manipulate Git repositories by wrapping system calls to the git binary.")
2828 (home-page "https://github.com/schacon/ruby-git")
2829 (license license:expat)))
71d3e2c2
DT
2830
2831(define-public ruby-slop
2832 (package
2833 (name "ruby-slop")
d14e5eaa 2834 (version "4.5.0")
71d3e2c2
DT
2835 (source (origin
2836 (method url-fetch)
e83c6d00 2837 (uri (rubygems-uri "slop" version))
71d3e2c2
DT
2838 (sha256
2839 (base32
d14e5eaa 2840 "0bfm8535g0rkn9cbjndkckf0f7a3wj0rg4rqhrpsgxnbfdf2lm0p"))))
71d3e2c2
DT
2841 (build-system ruby-build-system)
2842 (native-inputs
2843 `(("ruby-minitest" ,ruby-minitest)))
2844 (synopsis "Ruby command line option parser")
2845 (description "Slop provides a Ruby domain specific language for gathering
2846options and parsing command line flags.")
2847 (home-page "https://github.com/leejarvis/slop")
2848 (license license:expat)))
e778a549 2849
5337f8b9
DT
2850(define-public ruby-slop-3
2851 (package (inherit ruby-slop)
2852 (version "3.6.0")
2853 (source (origin
2854 (method url-fetch)
2855 (uri (rubygems-uri "slop" version))
2856 (sha256
2857 (base32
2858 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
2859
e778a549
DT
2860(define-public ruby-multipart-post
2861 (package
2862 (name "ruby-multipart-post")
2863 (version "2.0.0")
2864 (source (origin
2865 (method url-fetch)
e83c6d00 2866 (uri (rubygems-uri "multipart-post" version))
e778a549
DT
2867 (sha256
2868 (base32
e83c6d00 2869 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
e778a549
DT
2870 (build-system ruby-build-system)
2871 (native-inputs
2872 `(("bundler" ,bundler)))
2873 (synopsis "Multipart POST library for Ruby")
2874 (description "Multipart-Post Adds multipart POST capability to Ruby's
2875net/http library.")
2876 (home-page "https://github.com/nicksieger/multipart-post")
2877 (license license:expat)))
f8da3af0 2878
9a97e7ce
CB
2879(define-public ruby-multi-json
2880 (package
2881 (name "ruby-multi-json")
1b6f5475 2882 (version "1.13.1")
9a97e7ce
CB
2883 (source
2884 (origin
2885 (method url-fetch)
1b6f5475
BW
2886 ;; Tests are not distributed at rubygems.org so download from GitHub
2887 ;; instead.
2888 (uri (string-append "https://github.com/intridea/multi_json/archive/v"
2889 version ".tar.gz"))
2890 (file-name (string-append name "-" version ".tar.gz"))
9a97e7ce
CB
2891 (sha256
2892 (base32
1b6f5475 2893 "1s64xqvrnrxmb59v6b2kchnisawg5ai9ky1w60dy6z6ws9la1xv4"))))
9a97e7ce
CB
2894 (build-system ruby-build-system)
2895 (arguments
1b6f5475
BW
2896 `(#:phases
2897 (modify-phases %standard-phases
2898 (add-after 'unpack 'remove-signing-key-reference
2899 (lambda _
2900 (substitute* "multi_json.gemspec"
2901 ((".*spec.signing_key.*") ""))
2902 #t)))))
2903 (native-inputs
2904 `(("bundler" ,bundler)
2905 ("ruby-rspec" ,ruby-rspec)
2906 ("ruby-yard" ,ruby-yard)
2907 ("ruby-json-pure" ,ruby-json-pure)
2908 ("ruby-oj" ,ruby-oj)
2909 ("ruby-yajl-ruby" ,ruby-yajl-ruby)))
9a97e7ce
CB
2910 (synopsis "Common interface to multiple JSON libraries for Ruby")
2911 (description
2912 "This package provides a common interface to multiple JSON libraries,
2913including Oj, Yajl, the JSON gem (with C-extensions), the pure-Ruby JSON gem,
2914NSJSONSerialization, gson.rb, JrJackson, and OkJson.")
1b6f5475 2915 (home-page "https://github.com/intridea/multi_json")
9a97e7ce
CB
2916 (license license:expat)))
2917
5edef88b
BW
2918(define-public ruby-multi-test
2919 (package
2920 (name "ruby-multi-test")
2921 (version "0.1.2")
2922 (source
2923 (origin
2924 (method url-fetch)
2925 (uri (rubygems-uri "multi_test" version))
2926 (sha256
2927 (base32
2928 "1sx356q81plr67hg16jfwz9hcqvnk03bd9n75pmdw8pfxjfy1yxd"))))
2929 (build-system ruby-build-system)
2930 (arguments
2931 '(;; Tests require different sets of specific gem versions to be available,
2932 ;; and there is no gemfile that specifies the newest versions of
2933 ;; dependencies to be tested.
2934 #:tests? #f))
2935 (synopsis
2936 "Interface to testing libraries loaded into a running Ruby process")
2937 (description
2938 "@code{multi_test} provides a uniform interface onto whatever testing
2939libraries that have been loaded into a running Ruby process to help control
2940rogue test/unit/autorun requires.")
2941 (home-page "https://github.com/cucumber/multi_test")
9a97e7ce
CB
2942 (license license:expat)))
2943
f8da3af0
DT
2944(define-public ruby-arel
2945 (package
2946 (name "ruby-arel")
aecd533d 2947 (version "9.0.0")
f8da3af0
DT
2948 (source (origin
2949 (method url-fetch)
2950 (uri (rubygems-uri "arel" version))
2951 (sha256
2952 (base32
aecd533d 2953 "1jk7wlmkr61f6g36w9s2sn46nmdg6wn2jfssrhbhirv5x9n95nk0"))))
f8da3af0
DT
2954 (build-system ruby-build-system)
2955 (arguments '(#:tests? #f)) ; no tests
2956 (home-page "https://github.com/rails/arel")
2957 (synopsis "SQL AST manager for Ruby")
6f23e2fb
TGR
2958 (description "Arel is an SQL @dfn{Abstract Syntax Tree} (AST) manager for
2959Ruby. It simplifies the generation of complex SQL queries and adapts to
2960various relational database implementations.")
f8da3af0 2961 (license license:expat)))
616eaead 2962
554bf4f6
CB
2963(define-public ruby-marcel
2964 (package
2965 (name "ruby-marcel")
2966 (version "0.3.3")
2967 (source
2968 (origin
2969 (method url-fetch)
2970 (uri (rubygems-uri "marcel" version))
2971 (sha256
2972 (base32
2973 "1nxbjmcyg8vlw6zwagf17l9y2mwkagmmkg95xybpn4bmf3rfnksx"))))
2974 (build-system ruby-build-system)
2975 (arguments
2976 '(;; No included tests
2977 #:tests? #f))
2978 (propagated-inputs
2979 `(("ruby-mimemagic" ,ruby-mimemagic)))
2980 (synopsis "MIME type detection using magic numbers, filenames and extensions")
2981 (description
2982 "@code{marcel} provides @acronym{MIME, Multipurpose Internet Mail
2983Extensions} type detection using magic numbers, filenames, and extensions")
2984 (home-page "https://github.com/basecamp/marcel")
2985 (license license:expat)))
2986
616eaead 2987(define-public ruby-minitar
bfaf8efd
BW
2988 ;; We package from the GitHub source to fix the security issue reported at
2989 ;; https://github.com/halostatue/minitar/issues/16.
2990 (let ((commit "e25205ecbb6277ae8a3df1e6a306d7ed4458b6e4"))
2991 (package
2992 (name "ruby-minitar")
2993 (version (string-append "0.5.4-1." (string-take commit 8)))
2994 (source
2995 (origin
2996 (method git-fetch)
2997 (uri (git-reference
2998 (url "https://github.com/halostatue/minitar.git")
2999 (commit commit)))
3000 (file-name (string-append name "-" version "-checkout"))
3001 (sha256
3002 (base32
3003 "1iywfx07jgjqcmixzkxk9zdwfmij1fyg1z2jlwzj15cj7s99qlfv"))))
3004 (build-system ruby-build-system)
3005 (arguments
3006 '(#:tests? #f)) ; missing a gemspec
3007 (synopsis "Ruby library and utility for handling tar archives")
3008 (description
3009 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
616eaead 3010that provides the ability to deal with POSIX tar archive files.")
bfaf8efd
BW
3011 (home-page "http://www.github.com/atoulme/minitar")
3012 (license (list license:gpl2+ license:ruby)))))
bea1c0e2
DT
3013
3014(define-public ruby-mini-portile
3015 (package
3016 (name "ruby-mini-portile")
3017 (version "0.6.2")
3018 (source
3019 (origin
3020 (method url-fetch)
3021 (uri (rubygems-uri "mini_portile" version))
3022 (sha256
3023 (base32
3024 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
3025 (build-system ruby-build-system)
3026 (arguments
3027 '(#:tests? #f)) ; tests require network access
3028 (synopsis "Ports system for Ruby developers")
3029 (description "Mini-portile is a port/recipe system for Ruby developers.
3030It provides a standard way to compile against specific versions of libraries
3031to reproduce user environments.")
7bf837fd 3032 (home-page "https://github.com/flavorjones/mini_portile")
bea1c0e2 3033 (license license:expat)))
e920bfca 3034
d000fc92
BW
3035(define-public ruby-mini-portile-2
3036 (package (inherit ruby-mini-portile)
26f4a377 3037 (version "2.2.0")
d000fc92
BW
3038 (source (origin
3039 (method url-fetch)
3040 (uri (rubygems-uri "mini_portile2" version))
3041 (sha256
3042 (base32
26f4a377 3043 "0g5bpgy08q0nc0anisg3yvwc1gc3inl854fcrg48wvg7glqd6dpm"))))))
d000fc92 3044
e920bfca
DT
3045(define-public ruby-nokogiri
3046 (package
3047 (name "ruby-nokogiri")
efb94fda 3048 (version "1.8.0")
e920bfca
DT
3049 (source (origin
3050 (method url-fetch)
3051 (uri (rubygems-uri "nokogiri" version))
3052 (sha256
3053 (base32
efb94fda 3054 "1nffsyx1xjg6v5n9rrbi8y1arrcx2i5f21cp6clgh9iwiqkr7rnn"))))
e920bfca
DT
3055 (build-system ruby-build-system)
3056 (arguments
3057 ;; Tests fail because Nokogiri can only test with an installed extension,
3058 ;; and also because many test framework dependencies are missing.
7b01f250 3059 `(#:tests? #f
e920bfca
DT
3060 #:gem-flags (list "--" "--use-system-libraries"
3061 (string-append "--with-xml2-include="
3062 (assoc-ref %build-inputs "libxml2")
5e7f1b0b
BW
3063 "/include/libxml2" ))
3064 #:phases
3065 (modify-phases %standard-phases
7b01f250
BW
3066 (add-before 'build 'patch-extconf
3067 ;; 'pkg-config' is not included in the GEM_PATH during
3068 ;; installation, so we add it directly to the load path.
3069 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3070 (let* ((pkg-config (assoc-ref inputs "ruby-pkg-config")))
7b01f250
BW
3071 (substitute* "ext/nokogiri/extconf.rb"
3072 (("gem 'pkg-config'.*")
3073 (string-append "$:.unshift '"
3cb3fa67 3074 pkg-config "/lib/ruby/vendor_ruby"
7b01f250
BW
3075 "/gems/pkg-config-"
3076 ,(package-version ruby-pkg-config)
3077 "/lib'\n"))))
5e7f1b0b 3078 #t)))))
e920bfca 3079 (native-inputs
7b01f250 3080 `(("ruby-hoe" ,ruby-hoe)))
e920bfca
DT
3081 (inputs
3082 `(("zlib" ,zlib)
3083 ("libxml2" ,libxml2)
3084 ("libxslt" ,libxslt)))
3085 (propagated-inputs
7b01f250
BW
3086 `(("ruby-mini-portile" ,ruby-mini-portile-2)
3087 ("ruby-pkg-config" ,ruby-pkg-config)))
e920bfca
DT
3088 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
3089 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
3090both CSS3 selector and XPath 1.0 support.")
3091 (home-page "http://www.nokogiri.org/")
3092 (license license:expat)))
30b0b725
DT
3093
3094(define-public ruby-method-source
3095 (package
3096 (name "ruby-method-source")
c8355037 3097 (version "0.9.0")
30b0b725
DT
3098 (source
3099 (origin
3100 (method url-fetch)
3101 (uri (rubygems-uri "method_source" version))
3102 (sha256
3103 (base32
c8355037 3104 "0xqj21j3vfq4ldia6i2akhn2qd84m0iqcnsl49kfpq3xk6x0dzgn"))))
30b0b725 3105 (build-system ruby-build-system)
c8355037
BW
3106 (arguments
3107 `(#:test-target "spec"))
30b0b725 3108 (native-inputs
c8355037 3109 `(("ruby-rspec" ,ruby-rspec)
30b0b725
DT
3110 ("git" ,git)))
3111 (synopsis "Retrieve the source code for Ruby methods")
3112 (description "Method_source retrieves the source code for Ruby methods.
3113Additionally, it can extract source code from Proc and Lambda objects or just
3114extract comments.")
3115 (home-page "https://github.com/banister/method_source")
3116 (license license:expat)))
2e3fdea4
DT
3117
3118(define-public ruby-coderay
3119 (package
3120 (name "ruby-coderay")
5cf0997a 3121 (version "1.1.2")
2e3fdea4
DT
3122 (source
3123 (origin
3124 (method url-fetch)
3125 (uri (rubygems-uri "coderay" version))
3126 (sha256
3127 (base32
5cf0997a 3128 "15vav4bhcc2x3jmi3izb11l4d9f3xv8hp2fszb7iqmpsccv1pz4y"))))
2e3fdea4
DT
3129 (build-system ruby-build-system)
3130 (arguments
3131 '(#:tests? #f)) ; missing test files
3132 (synopsis "Ruby syntax highlighting library")
3133 (description "Coderay is a Ruby library that provides syntax highlighting
3134for select languages.")
3135 (home-page "http://coderay.rubychan.de")
3136 (license license:expat)))
96e76083 3137
54993457
CB
3138(define-public ruby-parser
3139 (package
3140 (name "ruby-parser")
3141 (version "2.6.0.0")
3142 (source
3143 (origin
3144 (method url-fetch)
3145 (uri (rubygems-uri "parser" version))
3146 (sha256
3147 (base32
3148 "1hhz2k5417vr2k1llwqgjdnmyrhlpqicy0y2arr6r1gp04fg9wlm"))))
3149 (build-system ruby-build-system)
3150 (native-inputs
3151 `(("bundler" ,bundler)
3152 ("ruby-cliver" ,ruby-cliver)
3153 ("ruby-simplecov" ,ruby-simplecov)
3154 ("ruby-racc" ,ruby-racc)))
3155 (inputs
3156 `(("ragel" ,ragel)))
3157 (propagated-inputs
3158 `(("ruby-ast" ,ruby-ast)))
3159 (synopsis "Ruby parser written in pure Ruby")
3160 (description
3161 "This package provides a Ruby parser written in pure Ruby.")
3162 (home-page "https://github.com/whitequark/parser")
3163 (license license:expat)))
3164
16f423cb
CB
3165(define-public ruby-prawn-manual-builder
3166 (package
3167 (name "ruby-prawn-manual-builder")
3168 (version "0.3.0")
3169 (source
3170 (origin
3171 (method url-fetch)
3172 (uri (rubygems-uri "prawn-manual_builder" version))
3173 (sha256
3174 (base32
3175 "0wbjnkqp55p5wmz85ldypcray223glckd209hmdxhnzk8s5pb3za"))))
3176 (build-system ruby-build-system)
3177 (arguments
3178 '(;; No included tests
3179 #:tests? #f
3180 #:phases
3181 (modify-phases %standard-phases
3182 (add-after 'extract-gemspec 'patch-gemspec
3183 (lambda _
3184 (substitute* ".gemspec"
3185 ;; Loosen the requirement for pdf-inspector
3186 (("~> 1\\.0\\.7") ">= 0")))))))
3187 (propagated-inputs
3188 `(("ruby-coderay" ,ruby-coderay)))
3189 (synopsis "Tool for writing manuals for Prawn and Prawn accessories")
3190 (description
3191 "This package provides a tool for writing manuals for Prawn and Prawn
3192accessories")
3193 (home-page "https://github.com/prawnpdf/prawn-manual_builder")
3194 (license (list
3195 ;; GPLv2 or GPLv3 or custom license described in LICENSE file
3196 license:gpl2
3197 license:gpl3))))
3198
268643b9
CB
3199(define-public ruby-progress_bar
3200 (package
3201 (name "ruby-progress_bar")
3202 (version "1.1.0")
3203 (source
3204 (origin
3205 (method url-fetch)
3206 (uri (rubygems-uri "progress_bar" version))
3207 (sha256
3208 (base32
3209 "1qc40mr6p1z9a3vlpnsg1zfgk1qswviql2a31y63wpv3vr6b5f48"))))
3210 (build-system ruby-build-system)
3211 (arguments
3212 '(#:test-target "spec"))
3213 (propagated-inputs
3214 `(("ruby-highline" ,ruby-highline)
3215 ("ruby-options" ,ruby-options)))
3216 (native-inputs
3217 `(("bundler" ,bundler)
3218 ("ruby-rspec" ,ruby-rspec)
3219 ("ruby-timecop" ,ruby-timecop)))
3220 (synopsis
3221 "Ruby library for displaying progress bars")
3222 (description
3223 "ProgressBar is a simple library for displaying progress bars. The
3224maximum value is configurable, and additional information can be displayed
3225like the percentage completion, estimated time remaining, elapsed time and
3226rate.")
3227 (home-page "https://github.com/paul/progress_bar")
3228 (license license:wtfpl2)))
3229
158a9253
CB
3230(define-public ruby-progressbar
3231 (package
3232 (name "ruby-progressbar")
3233 (version "1.10.0")
3234 (source
3235 (origin
3236 (method url-fetch)
3237 (uri (rubygems-uri "ruby-progressbar" version))
3238 (sha256
3239 (base32
3240 "1cv2ym3rl09svw8940ny67bav7b2db4ms39i4raaqzkf59jmhglk"))))
3241 (build-system ruby-build-system)
3242 (arguments
3243 '(;; TODO: There looks to be a circular dependency with ruby-fuubar.
3244 #:tests? #f))
3245 (synopsis "Text progress bar library for Ruby")
3246 (description
3247 "Ruby/ProgressBar is an flexible text progress bar library for Ruby.
3248The output can be customized with a formatting system.")
3249 (home-page "https://github.com/jfelchner/ruby-progressbar")
3250 (license license:expat)))
3251
96e76083
DT
3252(define-public ruby-pry
3253 (package
3254 (name "ruby-pry")
1bf02b20 3255 (version "0.11.3")
96e76083
DT
3256 (source
3257 (origin
3258 (method url-fetch)
3259 (uri (rubygems-uri "pry" version))
3260 (sha256
3261 (base32
1bf02b20 3262 "1mh312k3y94sj0pi160wpia0ps8f4kmzvm505i6bvwynfdh7v30g"))))
96e76083
DT
3263 (build-system ruby-build-system)
3264 (arguments
3265 '(#:tests? #f)) ; no tests
3266 (propagated-inputs
3267 `(("ruby-coderay" ,ruby-coderay)
1960d4fd 3268 ("ruby-method-source" ,ruby-method-source)))
96e76083
DT
3269 (synopsis "Ruby REPL")
3270 (description "Pry is an IRB alternative and runtime developer console for
3271Ruby. It features syntax highlighting, a plugin architecture, runtime
3272invocation, and source and documentation browsing.")
2f3800e5 3273 (home-page "https://pryrepl.org")
96e76083 3274 (license license:expat)))
1415792a 3275
051deeb7
RW
3276(define-public ruby-guard
3277 (package
3278 (name "ruby-guard")
3279 (version "2.13.0")
3280 (source (origin
3281 (method url-fetch)
3282 ;; The gem does not include a Rakefile, nor does it contain a
3283 ;; gemspec file, nor does it come with the tests. This is why
3284 ;; we fetch the tarball from Github.
3285 (uri (string-append "https://github.com/guard/guard/archive/v"
3286 version ".tar.gz"))
3287 (file-name (string-append name "-" version ".tar.gz"))
3288 (sha256
3289 (base32
3290 "1hwj0yi17k6f5axrm0k2bb7fq71dlp0zfywmd7pij9iimbppcca0"))))
3291 (build-system ruby-build-system)
3292 (arguments
3293 `(#:tests? #f ; tests require cucumber
3294 #:phases
3295 (modify-phases %standard-phases
3296 (add-after 'unpack 'remove-git-ls-files
3297 (lambda* (#:key outputs #:allow-other-keys)
3298 (substitute* "guard.gemspec"
3299 (("git ls-files -z") "find . -type f -print0"))
3300 #t))
3301 (replace 'build
3302 (lambda _
9923d5a4 3303 (invoke "gem" "build" "guard.gemspec"))))))
051deeb7
RW
3304 (propagated-inputs
3305 `(("ruby-formatador" ,ruby-formatador)
3306 ("ruby-listen" ,ruby-listen)
3307 ("ruby-lumberjack" ,ruby-lumberjack)
3308 ("ruby-nenv" ,ruby-nenv)
3309 ("ruby-notiffany" ,ruby-notiffany)
3310 ("ruby-pry" ,ruby-pry)
3311 ("ruby-shellany" ,ruby-shellany)
3312 ("ruby-thor" ,ruby-thor)))
3313 (native-inputs
3314 `(("bundler" ,bundler)
3315 ("ruby-rspec" ,ruby-rspec)))
3316 (synopsis "Tool to handle events on file system modifications")
3317 (description
3318 "Guard is a command line tool to easily handle events on file system
3319modifications. Guard automates various tasks by running custom rules whenever
3320file or directories are modified.")
3321 (home-page "http://guardgem.org/")
3322 (license license:expat)))
3323
1415792a
DT
3324(define-public ruby-thread-safe
3325 (package
3326 (name "ruby-thread-safe")
313dd5dd 3327 (version "0.3.6")
1415792a
DT
3328 (source
3329 (origin
3330 (method url-fetch)
3331 (uri (rubygems-uri "thread_safe" version))
3332 (sha256
3333 (base32
313dd5dd 3334 "0nmhcgq6cgz44srylra07bmaw99f5271l0dpsvl5f75m44l0gmwy"))))
1415792a
DT
3335 (build-system ruby-build-system)
3336 (arguments
3337 '(#:tests? #f)) ; needs simplecov, among others
3338 (synopsis "Thread-safe utilities for Ruby")
3339 (description "The thread_safe library provides thread-safe collections and
3340utilities for Ruby.")
3341 (home-page "https://github.com/ruby-concurrency/thread_safe")
3342 (license license:asl2.0)))
08a1b701
DT
3343
3344(define-public ruby-tzinfo
3345 (package
3346 (name "ruby-tzinfo")
4237af85 3347 (version "1.2.4")
08a1b701
DT
3348 (source
3349 (origin
3350 (method url-fetch)
3351 (uri (rubygems-uri "tzinfo" version))
3352 (sha256
3353 (base32
4237af85 3354 "09dpbrih054mn42flbbcdpzk2727mzfvjrgqb12zdafhx7p9rrzp"))))
08a1b701
DT
3355 (build-system ruby-build-system)
3356 (propagated-inputs
3357 `(("ruby-thread-safe" ,ruby-thread-safe)))
3358 (synopsis "Time zone library for Ruby")
3359 (description "TZInfo is a Ruby library that provides daylight savings
3360aware transformations between times in different time zones.")
2f3800e5 3361 (home-page "https://tzinfo.github.io")
1e12924a
BW
3362 (license license:expat)))
3363
3364(define-public ruby-tzinfo-data
3365 (package
3366 (name "ruby-tzinfo-data")
92513191 3367 (version "1.2017.3")
1e12924a
BW
3368 (source
3369 (origin
3370 (method url-fetch)
3371 ;; Download from GitHub because the rubygems version does not contain
3372 ;; Rakefile or tests.
3373 (uri (string-append
3374 "https://github.com/tzinfo/tzinfo-data/archive/v"
3375 version
3376 ".tar.gz"))
3377 (file-name (string-append name "-" version ".tar.gz"))
3378 (sha256
3379 (base32
92513191 3380 "01wff7syqzikbxalbg3isgxasmvzicr85bzadzkb6bf20bip4v54"))
1e12924a
BW
3381 ;; Remove the known test failure.
3382 ;; https://github.com/tzinfo/tzinfo-data/issues/10
3383 ;; https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1587128
3384 (patches (search-patches
3385 "ruby-tzinfo-data-ignore-broken-test.patch"))))
3386 (build-system ruby-build-system)
3387 (propagated-inputs
3388 `(("ruby-tzinfo" ,ruby-tzinfo)))
3389 (synopsis "Data from the IANA Time Zone database")
3390 (description
3391 "This library provides @code{TZInfo::Data}, which contains data from the
3392IANA Time Zone database packaged as Ruby modules for use with @code{TZInfo}.")
2f3800e5 3393 (home-page "https://tzinfo.github.io")
08a1b701 3394 (license license:expat)))
c99e2247 3395
48e6851f
RW
3396(define-public ruby-rb-inotify
3397 (package
3398 (name "ruby-rb-inotify")
32bbfea8 3399 (version "0.9.10")
48e6851f
RW
3400 (source
3401 (origin
3402 (method url-fetch)
3403 (uri (rubygems-uri "rb-inotify" version))
3404 (sha256
3405 (base32
32bbfea8 3406 "0yfsgw5n7pkpyky6a9wkf1g9jafxb0ja7gz0qw0y14fd2jnzfh71"))))
48e6851f
RW
3407 (build-system ruby-build-system)
3408 (arguments
3409 '(#:tests? #f ; there are no tests
3410 #:phases
3411 (modify-phases %standard-phases
3412 ;; Building the gemspec with rake is not working here since it is
3413 ;; generated with Jeweler. It is also unnecessary because the
3414 ;; existing gemspec does not use any development tools to generate a
3415 ;; list of files.
3416 (replace 'build
3417 (lambda _
9923d5a4 3418 (invoke "gem" "build" "rb-inotify.gemspec"))))))
48e6851f
RW
3419 (propagated-inputs
3420 `(("ruby-ffi" ,ruby-ffi)))
3421 (native-inputs
3422 `(("ruby-yard" ,ruby-yard)))
3423 (synopsis "Ruby wrapper for Linux's inotify")
3424 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
3425kernel subsystem for monitoring changes to files and directories.")
3426 (home-page "https://github.com/nex3/rb-inotify")
3427 (license license:expat)))
3428
a75bdfce
RW
3429(define-public ruby-pry-editline
3430 (package
3431 (name "ruby-pry-editline")
3432 (version "1.1.2")
3433 (source (origin
3434 (method url-fetch)
3435 (uri (rubygems-uri "pry-editline" version))
3436 (sha256
3437 (base32
3438 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
3439 (build-system ruby-build-system)
3440 (arguments `(#:tests? #f)) ; no tests included
3441 (native-inputs
3442 `(("bundler" ,bundler)))
3443 (synopsis "Open the current REPL line in an editor")
3444 (description
3445 "This gem provides a plugin for the Ruby REPL to enable opening the
3446current line in an external editor.")
3447 (home-page "https://github.com/tpope/pry-editline")
3448 (license license:expat)))
3449
d3b20a02
RW
3450(define-public ruby-sdoc
3451 (package
3452 (name "ruby-sdoc")
fdf3a68d 3453 (version "0.4.2")
d3b20a02
RW
3454 (source (origin
3455 (method url-fetch)
3456 (uri (rubygems-uri "sdoc" version))
3457 (sha256
3458 (base32
fdf3a68d 3459 "0qhvy10vnmrqcgh8494m13kd5ag9c3sczzhfasv8j0294ylk679n"))))
d3b20a02
RW
3460 (build-system ruby-build-system)
3461 (arguments
3462 `(#:phases
3463 (modify-phases %standard-phases
fc29d5e6 3464 (add-before 'check 'set-rubylib-and-patch-gemfile
d3b20a02 3465 (lambda _
fdf3a68d 3466 (setenv "RUBYLIB" "lib")
fc29d5e6
BW
3467 (substitute* "sdoc.gemspec"
3468 (("s.add_runtime_dependency.*") "\n")
3469 (("s.add_dependency.*") "\n"))
3470 (substitute* "Gemfile"
3471 (("gem \"rake\".*")
3472 "gem 'rake'\ngem 'rdoc'\ngem 'json'\n"))
d3b20a02
RW
3473 #t)))))
3474 (propagated-inputs
3475 `(("ruby-json" ,ruby-json)))
3476 (native-inputs
3477 `(("bundler" ,bundler)
fdf3a68d
BW
3478 ("ruby-minitest" ,ruby-minitest)
3479 ("ruby-hoe" ,ruby-hoe)))
d3b20a02
RW
3480 (synopsis "Generate searchable RDoc documentation")
3481 (description
3482 "SDoc is an RDoc documentation generator to build searchable HTML
3483documentation for Ruby code.")
7bf837fd 3484 (home-page "https://github.com/voloko/sdoc")
d3b20a02
RW
3485 (license license:expat)))
3486
70b002aa
RW
3487(define-public ruby-tins
3488 (package
3489 (name "ruby-tins")
fbefd6ff 3490 (version "1.15.0")
70b002aa
RW
3491 (source (origin
3492 (method url-fetch)
3493 (uri (rubygems-uri "tins" version))
3494 (sha256
3495 (base32
fbefd6ff 3496 "09whix5a7ics6787zrkwjmp16kqyh6560p9f317syks785805f7s"))))
70b002aa
RW
3497 (build-system ruby-build-system)
3498 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
3499 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
3500 ;; the gemspec.
3501 (arguments
3502 `(#:tests? #f ; there are no tests
3503 #:phases
3504 (modify-phases %standard-phases
3505 (replace 'build
3506 (lambda _
3507 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
3508 ;; causes an error.
3509 (substitute* "tins.gemspec"
3510 (("\"lib/spruz\", ") ""))
9923d5a4 3511 (invoke "gem" "build" "tins.gemspec"))))))
70b002aa
RW
3512 (synopsis "Assorted tools for Ruby")
3513 (description "Tins is a Ruby library providing assorted tools.")
3514 (home-page "https://github.com/flori/tins")
3515 (license license:expat)))
3516
bc8277e4
RW
3517(define-public ruby-gem-hadar
3518 (package
3519 (name "ruby-gem-hadar")
3fd577e3 3520 (version "1.9.1")
bc8277e4
RW
3521 (source (origin
3522 (method url-fetch)
3523 (uri (rubygems-uri "gem_hadar" version))
3524 (sha256
3525 (base32
3fd577e3 3526 "1zxvd9l95rbks7x3cxn396w0sn7nha5542bf97v8akkn4vm7nby9"))))
bc8277e4
RW
3527 (build-system ruby-build-system)
3528 ;; This gem needs itself at development time. We disable rebuilding of the
3529 ;; gemspec to avoid this loop.
3530 (arguments
3531 `(#:tests? #f ; there are no tests
3532 #:phases
3533 (modify-phases %standard-phases
3534 (replace 'build
3535 (lambda _
9923d5a4 3536 (invoke "gem" "build" "gem_hadar.gemspec"))))))
bc8277e4
RW
3537 (propagated-inputs
3538 `(("git" ,git)
3539 ("ruby-tins" ,ruby-tins)
3fd577e3 3540 ("ruby-yard" ,ruby-yard)))
bc8277e4
RW
3541 (synopsis "Library for the development of Ruby gems")
3542 (description
3543 "This library contains some useful functionality to support the
3544development of Ruby gems.")
3545 (home-page "https://github.com/flori/gem_hadar")
3546 (license license:expat)))
3547
d8cafe29
RW
3548(define-public ruby-minitest-tu-shim
3549 (package
3550 (name "ruby-minitest-tu-shim")
3551 (version "1.3.3")
3552 (source (origin
3553 (method url-fetch)
3554 (uri (rubygems-uri "minitest_tu_shim" version))
3555 (sha256
3556 (base32
3557 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
3558 (build-system ruby-build-system)
3559 (arguments
3560 `(#:phases
3561 (modify-phases %standard-phases
3562 (add-after 'unpack 'fix-test-include-path
3563 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3564 (let* ((minitest (assoc-ref inputs "ruby-minitest-4")))
761e7042
BW
3565 (substitute* "Rakefile"
3566 (("Hoe\\.add_include_dirs .*")
3567 (string-append "Hoe.add_include_dirs \""
3cb3fa67 3568 minitest "/lib/ruby/vendor_ruby"
761e7042
BW
3569 "/gems/minitest-"
3570 ,(package-version ruby-minitest-4)
3571 "/lib" "\""))))
3572 #t))
d8cafe29
RW
3573 (add-before 'check 'fix-test-assumptions
3574 (lambda _
3575 ;; The test output includes the file name, so a couple of tests
3576 ;; fail. Changing the regular expressions slightly fixes this
3577 ;; problem.
3578 (substitute* "test/test_mini_test.rb"
3579 (("output.sub!\\(.*, 'FILE:LINE'\\)")
3580 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
3581 (("gsub\\(/.*, 'FILE:LINE'\\)")
3582 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
3583 #t)))))
3584 (propagated-inputs
3585 `(("ruby-minitest-4" ,ruby-minitest-4)))
3586 (native-inputs
3587 `(("ruby-hoe" ,ruby-hoe)))
3588 (synopsis "Adapter library between minitest and test/unit")
3589 (description
3590 "This library bridges the gap between the small and fast minitest and
3591Ruby's large and slower test/unit.")
3592 (home-page "https://rubygems.org/gems/minitest_tu_shim")
3593 (license license:expat)))
3594
fd83a212
RW
3595(define-public ruby-term-ansicolor
3596 (package
3597 (name "ruby-term-ansicolor")
f3a6311a 3598 (version "1.6.0")
fd83a212
RW
3599 (source (origin
3600 (method url-fetch)
3601 (uri (rubygems-uri "term-ansicolor" version))
3602 (sha256
3603 (base32
f3a6311a 3604 "1b1wq9ljh7v3qyxkk8vik2fqx2qzwh5lval5f92llmldkw7r7k7b"))))
fd83a212
RW
3605 (build-system ruby-build-system)
3606 ;; Rebuilding the gemspec seems to require git, even though this is not a
3607 ;; git repository, so we just build the gem from the existing gemspec.
3608 (arguments
3609 `(#:phases
3610 (modify-phases %standard-phases
39ecb977
CB
3611 (add-after 'unpack 'fix-test
3612 (lambda -
3613 (substitute* "tests/hsl_triple_test.rb"
3614 (("0\\\\\\.0%")
3615 "0\\.?0?%"))))
fd83a212
RW
3616 (replace 'build
3617 (lambda _
9923d5a4 3618 (invoke "gem" "build" "term-ansicolor.gemspec"))))))
fd83a212
RW
3619 (propagated-inputs
3620 `(("ruby-tins" ,ruby-tins)))
3621 (native-inputs
3622 `(("ruby-gem-hadar" ,ruby-gem-hadar)
3623 ("ruby-minitest-tu-shim" ,ruby-minitest-tu-shim)))
3624 (synopsis "Ruby library to control the attributes of terminal output")
3625 (description
3626 "This Ruby library uses ANSI escape sequences to control the attributes
3627of terminal output.")
2f3800e5 3628 (home-page "https://flori.github.io/term-ansicolor/")
fd83a212
RW
3629 ;; There is no mention of the "or later" clause.
3630 (license license:gpl2)))
3631
6e376ca4
RW
3632(define-public ruby-pstree
3633 (package
3634 (name "ruby-pstree")
3635 (version "0.1.0")
3636 (source (origin
3637 (method url-fetch)
3638 (uri (rubygems-uri "pstree" version))
3639 (sha256
3640 (base32
3641 "1mig1sv5qx1cdyhjaipy8jlh9j8pnja04vprrzihyfr54x0215p1"))))
3642 (build-system ruby-build-system)
3643 (native-inputs
3644 `(("ruby-gem-hadar" ,ruby-gem-hadar)
3645 ("bundler" ,bundler)))
3646 (synopsis "Create a process tree data structure")
3647 (description
3648 "This library uses the output of the @code{ps} command to create a
3649process tree data structure for the current host.")
2f3800e5 3650 (home-page "https://github.com/flori/pstree")
6e376ca4
RW
3651 ;; There is no mention of the "or later" clause.
3652 (license license:gpl2)))
3653
53239b5f
RW
3654(define-public ruby-utils
3655 (package
3656 (name "ruby-utils")
cd698b6e 3657 (version "0.9.0")
53239b5f
RW
3658 (source (origin
3659 (method url-fetch)
3660 (uri (rubygems-uri "utils" version))
3661 (sha256
3662 (base32
cd698b6e 3663 "196zhgcygrnx09bb9mh22qas03rl9avzx8qs0wnxznpin4pffwcl"))))
53239b5f
RW
3664 (build-system ruby-build-system)
3665 (propagated-inputs
3666 `(("ruby-tins" ,ruby-tins)
3667 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
3668 ("ruby-pstree" ,ruby-pstree)
3669 ("ruby-pry-editline" ,ruby-pry-editline)))
3670 (native-inputs
3671 `(("ruby-gem-hadar" ,ruby-gem-hadar)
3672 ("bundler" ,bundler)))
3673 (synopsis "Command line tools for working with Ruby")
3674 (description
3675 "This package provides assorted command line tools that may be useful
3676when working with Ruby code.")
3677 (home-page "https://github.com/flori/utils")
3678 ;; There is no mention of the "or later" clause.
3679 (license license:gpl2)))
3680
433f10b5
CB
3681(define-public ruby-jaro-winkler
3682 (package
3683 (name "ruby-jaro-winkler")
3684 (version "1.5.2")
3685 (source
3686 (origin
3687 (method url-fetch)
3688 (uri (rubygems-uri "jaro_winkler" version))
3689 (sha256
3690 (base32
3691 "1zz27z88qznix4r65gd9h56gl177snlfpgv10b0s69vi8qpl909l"))))
3692 (build-system ruby-build-system)
3693 (arguments
3694 '(;; No included tests
3695 #:tests? #f))
3696 (synopsis "Ruby implementation of Jaro-Winkler distance algorithm")
3697 (description
3698 "@code{jaro_winkler} is an implementation of Jaro-Winkler distance
3699algorithm. It is written as a C extension and will fallback to a pure Ruby
3700implementation on platforms where this is unsupported.")
3701 (home-page "https://github.com/tonytonyjan/jaro_winkler")
3702 (license license:expat)))
3703
c99e2247
DT
3704(define-public ruby-json
3705 (package
3706 (name "ruby-json")
a281acce 3707 (version "2.1.0")
c99e2247
DT
3708 (source
3709 (origin
3710 (method url-fetch)
3711 (uri (rubygems-uri "json" version))
3712 (sha256
3713 (base32
a281acce 3714 "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp"))))
c99e2247
DT
3715 (build-system ruby-build-system)
3716 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
3717 (synopsis "JSON library for Ruby")
3718 (description "This Ruby library provides a JSON implementation written as
3719a native C extension.")
3720 (home-page "http://json-jruby.rubyforge.org/")
3721 (license (list license:ruby license:gpl2)))) ; GPL2 only
5ff89a1b 3722
763624f5
RW
3723(define-public ruby-json-pure
3724 (package
3725 (name "ruby-json-pure")
ac01cb07 3726 (version "2.1.0")
763624f5
RW
3727 (source (origin
3728 (method url-fetch)
3729 (uri (rubygems-uri "json_pure" version))
3730 (sha256
3731 (base32
ac01cb07 3732 "12yf9fmhr4c2jm3xl20vf1qyz5i63vc8a6ngz9j0f86nqwhmi2as"))))
763624f5
RW
3733 (build-system ruby-build-system)
3734 (arguments
ac01cb07 3735 `(#:phases
763624f5 3736 (modify-phases %standard-phases
ac01cb07 3737 (add-after 'unpack 'fix-rakefile
763624f5 3738 (lambda _
ac01cb07
BW
3739 (substitute* "Rakefile"
3740 ;; Since this is not a git repository, do not call 'git'.
3741 (("`git ls-files`") "`find . -type f |sort`")
3742 ;; Loosen dependency constraint.
3743 (("'test-unit', '~> 2.0'") "'test-unit', '>= 2.0'"))
3744 #t))
3745 (add-after 'replace-git-ls-files 'regenerate-gemspec
3746 (lambda _
3747 ;; Regenerate gemspec so loosened dependency constraints are
3748 ;; propagated.
17cfb7ae
CB
3749 (invoke "rake" "gemspec")))
3750 (add-after 'regenerate-gemspec 'fix-json-java.gemspec
3751 (lambda _
3752 ;; This gemspec doesn't look to be generated by the above
3753 ;; command, so patch it separately.
3754 (substitute* "json-java.gemspec"
3755 (("%q<test-unit>\\.freeze, \\[\"~> 2\\.0\"\\]")
3756 "%q<test-unit>.freeze, [\">= 2.0\"]"))
3757 #t)))))
763624f5 3758 (native-inputs
ac01cb07 3759 `(("bundler" ,bundler)
0c9f73cd
TGR
3760 ("ragel" ,ragel)
3761 ("ruby-simplecov" ,ruby-simplecov)
3762 ("ruby-test-unit" ,ruby-test-unit)))
763624f5
RW
3763 (synopsis "JSON implementation in pure Ruby")
3764 (description
3765 "This package provides a JSON implementation written in pure Ruby.")
2f3800e5 3766 (home-page "https://flori.github.com/json")
763624f5
RW
3767 (license license:ruby)))
3768
16b324cd
RW
3769;; Even though this package only provides bindings for a Mac OSX API it is
3770;; required by "ruby-listen" at runtime.
3771(define-public ruby-rb-fsevent
3772 (package
3773 (name "ruby-rb-fsevent")
b0ef15ed 3774 (version "0.10.3")
16b324cd
RW
3775 (source (origin
3776 (method url-fetch)
3777 (uri (rubygems-uri "rb-fsevent" version))
3778 (sha256
3779 (base32
b0ef15ed 3780 "1lm1k7wpz69jx7jrc92w3ggczkjyjbfziq5mg62vjnxmzs383xx8"))))
16b324cd
RW
3781 (build-system ruby-build-system)
3782 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
3783 ;; "listen", which needs "rb-fsevent" at runtime.
3784 (arguments `(#:tests? #f))
3785 (synopsis "FSEvents API with signals catching")
3786 (description
3787 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
3788 (home-page "https://rubygems.org/gems/rb-fsevent")
3789 (license license:expat)))
3790
b86be2ad
RW
3791(define-public ruby-listen
3792 (package
3793 (name "ruby-listen")
c3b36fa1 3794 (version "3.1.5")
b86be2ad
RW
3795 (source
3796 (origin
3797 (method url-fetch)
3798 (uri (rubygems-uri "listen" version))
3799 (sha256
3800 (base32
c3b36fa1 3801 "01v5mrnfqm6sgm8xn2v5swxsn1wlmq7rzh2i48d4jzjsc7qvb6mx"))))
b86be2ad
RW
3802 (build-system ruby-build-system)
3803 (arguments '(#:tests? #f)) ; no tests
3804 (propagated-inputs
cf1a01f4
RW
3805 `(("ruby-rb-inotify" ,ruby-rb-inotify)
3806 ("ruby-rb-fsevent" ,ruby-rb-fsevent)))
b86be2ad
RW
3807 (synopsis "Listen to file modifications")
3808 (description "The Listen gem listens to file modifications and notifies
3809you about the changes.")
3810 (home-page "https://github.com/guard/listen")
3811 (license license:expat)))
3812
88ed727f
JL
3813(define-public ruby-listen-3.0
3814 (package
3815 (inherit ruby-listen)
3816 (version "3.0.8")
3817 (source (origin
3818 (method url-fetch)
3819 (uri (rubygems-uri "listen" version))
3820 (sha256
3821 (base32
3822 "1l0y7hbyfiwpvk172r28hsdqsifq1ls39hsfmzi1vy4ll0smd14i"))))))
3823
8d3c5ff6
CB
3824(define-public ruby-loofah
3825 (package
3826 (name "ruby-loofah")
3827 (version "2.2.3")
3828 (source
3829 (origin
3830 (method url-fetch)
3831 (uri (rubygems-uri "loofah" version))
3832 (sha256
3833 (base32
3834 "1ccsid33xjajd0im2xv941aywi58z7ihwkvaf1w2bv89vn5bhsjg"))))
3835 (build-system ruby-build-system)
3836 (arguments
3837 '(#:phases
3838 (modify-phases %standard-phases
3839 (add-after 'unpack 'remove-unnecessary-dependencies
3840 (lambda _
3841 ;; concourse is a development tool which is unused, so remove it
3842 ;; so it's not required.
3843 (substitute* "Gemfile"
3844 ((".*\"concourse\".*") "\n"))
3845 (substitute* "Rakefile"
3846 (("require 'concourse'") "")
3847 (("Concourse\\.new.*") "\n"))
3848 #t)))))
3849 (native-inputs
3850 `(("ruby-hoe" ,ruby-hoe)
3851 ("ruby-rr" ,ruby-rr)))
3852 (propagated-inputs
3853 `(("ruby-nokogiri" ,ruby-nokogiri)
3854 ("ruby-crass" ,ruby-crass)))
3855 (synopsis "Ruby library for manipulating and transforming HTML/XML")
3856 (description
3857 "Loofah is a general library for manipulating and transforming HTML/XML
3858documents and fragments. It's built on top of Nokogiri and libxml2.")
3859 (home-page "https://github.com/flavorjones/loofah")
3860 (license license:expat)))
3861
5ff89a1b
DT
3862(define-public ruby-activesupport
3863 (package
3864 (name "ruby-activesupport")
fb394a29 3865 (version "5.2.2")
5ff89a1b
DT
3866 (source
3867 (origin
3868 (method url-fetch)
3869 (uri (rubygems-uri "activesupport" version))
3870 (sha256
3871 (base32
fb394a29 3872 "1iya7vxqwxysr74s7b4z1x19gmnx5advimzip3cbmsd5bd43wfgz"))))
5ff89a1b
DT
3873 (build-system ruby-build-system)
3874 (arguments
2af45e50
BW
3875 `(#:phases
3876 (modify-phases %standard-phases
3877 (replace 'check
3878 (lambda _
9923d5a4
TGR
3879 ;; There are no tests, instead attempt to load the library.
3880 (invoke "ruby" "-Ilib" "-r" "active_support"))))))
5ff89a1b 3881 (propagated-inputs
2af45e50
BW
3882 `(("ruby-concurrent" ,ruby-concurrent)
3883 ("ruby-i18n" ,ruby-i18n)
5ff89a1b 3884 ("ruby-minitest" ,ruby-minitest)
606ee9a1
BW
3885 ("ruby-tzinfo" ,ruby-tzinfo)
3886 ("ruby-tzinfo-data" ,ruby-tzinfo-data)))
5ff89a1b
DT
3887 (synopsis "Ruby on Rails utility library")
3888 (description "ActiveSupport is a toolkit of support libraries and Ruby
3889core extensions extracted from the Rails framework. It includes support for
3890multibyte strings, internationalization, time zones, and testing.")
3891 (home-page "http://www.rubyonrails.org")
3892 (license license:expat)))
f847ad7b 3893
3996f0aa
RW
3894(define-public ruby-crass
3895 (package
3896 (name "ruby-crass")
a0e0f9d7 3897 (version "1.0.4")
3996f0aa
RW
3898 (source (origin
3899 (method url-fetch)
3900 (uri (rubygems-uri "crass" version))
3901 (sha256
3902 (base32
a0e0f9d7 3903 "0bpxzy6gjw9ggjynlxschbfsgmx8lv3zw1azkjvnb8b9i895dqfi"))))
3996f0aa
RW
3904 (build-system ruby-build-system)
3905 (native-inputs
3906 `(("bundler" ,bundler)
3907 ("ruby-minitest" ,ruby-minitest)))
3908 (synopsis "Pure Ruby CSS parser")
3909 (description
3910 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
3911 (home-page "https://github.com/rgrove/crass/")
3912 (license license:expat)))
3913
c2c4e5b2 3914(define-public ruby-nokogumbo
f1ae7c62
BW
3915 (let ((commit "fb51ff299a1c34346837580b6d1d9a60fadf5dbd"))
3916 (package
3917 (name "ruby-nokogumbo")
3918 (version (string-append "1.4.7-1." (string-take commit 8)))
3919 (source (origin
3920 ;; We use the git reference, because there's no Rakefile in the
3921 ;; published gem and the tarball on Github is outdated.
3922 (method git-fetch)
3923 (uri (git-reference
3924 (url "https://github.com/rubys/nokogumbo.git")
3925 (commit "d56f954d20a")))
3926 (file-name (string-append name "-" version "-checkout"))
3927 (sha256
3928 (base32
3929 "0bnppjy96xiadrsrc9dp8y6wvdwnkfa930n7acrp0mqm4qywl2wl"))))
3930 (build-system ruby-build-system)
3931 (arguments
3932 `(#:modules ((guix build ruby-build-system)
3933 (guix build utils)
3934 (ice-9 rdelim))
3935 #:phases
3936 (modify-phases %standard-phases
5c31e981 3937 (add-after 'unpack 'build-gemspec
f1ae7c62
BW
3938 (lambda _
3939 (substitute* "Rakefile"
3940 ;; Build Makefile even without a copy of gumbo-parser sources
3941 (("'gumbo-parser/src',") "")
3942 ;; We don't bundle gumbo-parser sources
3943 (("'gumbo-parser/src/\\*',") "")
3944 (("'gumbo-parser/visualc/include/\\*',") "")
3945 ;; The definition of SOURCES will be cut in gemspec, and
3946 ;; "FileList" will be undefined.
3947 (("SOURCES \\+ FileList\\[")
3948 "['ext/nokogumboc/extconf.rb', 'ext/nokogumboc/nokogumbo.c', "))
3949
3950 ;; Copy the Rakefile and cut out the gemspec.
3951 (copy-file "Rakefile" ".gemspec")
3952 (with-atomic-file-replacement ".gemspec"
3953 (lambda (in out)
3954 (let loop ((line (read-line in 'concat))
3955 (skipping? #t))
3956 (if (eof-object? line)
3957 #t
3958 (let ((skip-next? (if skipping?
3959 (not (string-prefix? "SPEC =" line))
3960 (string-prefix? "end" line))))
3961 (when (or (not skipping?)
3962 (and skipping? (not skip-next?)))
3963 (format #t "~a" line)
3964 (display line out))
3965 (loop (read-line in 'concat) skip-next?))))))
3966 #t)))))
3967 (inputs
3968 `(("gumbo-parser" ,gumbo-parser)))
3969 (propagated-inputs
3970 `(("ruby-nokogiri" ,ruby-nokogiri)))
3971 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
3972 (description
3973 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
c2c4e5b2 3974access the result as a Nokogiri parsed document.")
f1ae7c62
BW
3975 (home-page "https://github.com/rubys/nokogumbo/")
3976 (license license:asl2.0))))
c2c4e5b2 3977
d56ff88b
RW
3978(define-public ruby-sanitize
3979 (package
3980 (name "ruby-sanitize")
f812145e 3981 (version "4.6.3")
d56ff88b
RW
3982 (source (origin
3983 (method url-fetch)
3984 ;; The gem does not include the Rakefile, so we download the
3985 ;; release tarball from Github.
3986 (uri (string-append "https://github.com/rgrove/"
3987 "sanitize/archive/v" version ".tar.gz"))
3988 (file-name (string-append name "-" version ".tar.gz"))
3989 (sha256
3990 (base32
f812145e 3991 "1fmqppwif3cm8h79006jfzkdnlxxzlry9kzk03psk0d5xpg55ycc"))))
d56ff88b
RW
3992 (build-system ruby-build-system)
3993 (propagated-inputs
3994 `(("ruby-crass" ,ruby-crass)
3995 ("ruby-nokogiri" ,ruby-nokogiri)
3996 ("ruby-nokogumbo" ,ruby-nokogumbo)))
3997 (native-inputs
3998 `(("bundler" ,bundler)
3999 ("ruby-minitest" ,ruby-minitest)
4000 ("ruby-redcarpet" ,ruby-redcarpet)
4001 ("ruby-yard" ,ruby-yard)))
4002 (synopsis "Whitelist-based HTML and CSS sanitizer")
4003 (description
4004 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
4005acceptable elements, attributes, and CSS properties, Sanitize will remove all
4006unacceptable HTML and/or CSS from a string.")
4007 (home-page "https://github.com/rgrove/sanitize/")
4008 (license license:expat)))
4009
ed4b6b18
BW
4010(define-public ruby-oj
4011 (package
4012 (name "ruby-oj")
4013 (version "3.6.7")
4014 (source
4015 (origin
4016 (method url-fetch)
4017 ;; Version on rubygems.org does not contain Rakefile, so download from
4018 ;; GitHub instead.
4019 (uri (string-append "https://github.com/ohler55/oj/archive/v"
4020 version ".tar.gz"))
4021 (file-name (string-append name "-" version ".tar.gz"))
4022 (sha256
4023 (base32
4024 "1x28ga72jxlnmsd8g8c0fw81vlh54r0qgagw2lxsd3x3la091g2h"))))
4025 (build-system ruby-build-system)
4026 (arguments
4027 '(#:test-target "test_all"
4028 #:phases
4029 (modify-phases %standard-phases
4030 (add-before 'check 'disable-bundler
4031 (lambda _
4032 (substitute* "Rakefile"
4033 (("Bundler\\.with_clean_env") "1.times")
4034 (("bundle exec ") "")))))))
4035 (native-inputs
4036 `(("bundler" ,bundler)
4037 ("ruby-rspec" ,ruby-rspec)
4038 ("ruby-rake-compiler" ,ruby-rake-compiler)))
4039 (synopsis "JSON parser for Ruby optimized for speed")
4040 (description
4041 "Oj is a JSON parser and generator for Ruby, where the encoding and
4042decoding of JSON is implemented as a C extension to Ruby.")
4043 (home-page "http://www.ohler.com/oj")
4044 (license (list license:expat ; Ruby code
4045 license:bsd-3)))) ; extension code
4046
f847ad7b
DT
4047(define-public ruby-ox
4048 (package
4049 (name "ruby-ox")
263c0dbf 4050 (version "2.6.0")
f847ad7b
DT
4051 (source
4052 (origin
4053 (method url-fetch)
4054 (uri (rubygems-uri "ox" version))
4055 (sha256
4056 (base32
263c0dbf 4057 "0fmk62b1h2i79dfzjj8wmf8qid1rv5nhwfc17l489ywnga91xl83"))))
f847ad7b
DT
4058 (build-system ruby-build-system)
4059 (arguments
4060 '(#:tests? #f)) ; no tests
4061 (synopsis "Optimized XML library for Ruby")
4062 (description
4063 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
4064written as a native C extension. It was designed to be an alternative to
4065Nokogiri and other Ruby XML parsers for generic XML parsing and as an
4066alternative to Marshal for Object serialization. ")
4067 (home-page "http://www.ohler.com/ox")
4068 (license license:expat)))
4a9e0585 4069
0c4e7625
RW
4070(define-public ruby-redcloth
4071 (package
4072 (name "ruby-redcloth")
2a91494e 4073 (version "4.3.2")
0c4e7625
RW
4074 (source (origin
4075 (method url-fetch)
4076 (uri (rubygems-uri "RedCloth" version))
4077 (sha256
4078 (base32
2a91494e 4079 "0m9dv7ya9q93r8x1pg2gi15rxlbck8m178j1fz7r5v6wr1avrrqy"))))
0c4e7625
RW
4080 (build-system ruby-build-system)
4081 (arguments
4082 `(#:tests? #f ; no tests
4083 #:phases
4084 (modify-phases %standard-phases
4085 ;; Redcloth has complicated rake tasks to build various versions for
4086 ;; multiple targets using RVM. We don't want this so we just use the
4087 ;; existing gemspec.
4088 (replace 'build
4089 (lambda _
9923d5a4 4090 (invoke "gem" "build" "redcloth.gemspec"))))))
0c4e7625
RW
4091 (native-inputs
4092 `(("bundler" ,bundler)
4093 ("ruby-diff-lcs" ,ruby-diff-lcs)
4094 ("ruby-rspec-2" ,ruby-rspec-2)))
4095 (synopsis "Textile markup language parser for Ruby")
4096 (description
4097 "RedCloth is a Ruby parser for the Textile markup language.")
4098 (home-page "http://redcloth.org")
4099 (license license:expat)))
4100
4a9e0585
DT
4101(define-public ruby-pg
4102 (package
4103 (name "ruby-pg")
4db80f8b 4104 (version "1.1.3")
4a9e0585
DT
4105 (source
4106 (origin
4107 (method url-fetch)
4108 (uri (rubygems-uri "pg" version))
4109 (sha256
4110 (base32
4db80f8b 4111 "1pnjw3rspdfjssxyf42jnbsdlgri8ylysimp0s28wxb93k6ff2qb"))))
4a9e0585
DT
4112 (build-system ruby-build-system)
4113 (arguments
4114 '(#:test-target "spec"))
4115 (native-inputs
4116 `(("ruby-rake-compiler" ,ruby-rake-compiler)
4117 ("ruby-hoe" ,ruby-hoe)
4118 ("ruby-rspec" ,ruby-rspec)))
4119 (inputs
abd78128 4120 `(("postgresql" ,postgresql-9.6)))
4a9e0585
DT
4121 (synopsis "Ruby interface to PostgreSQL")
4122 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
4db80f8b 4123with PostgreSQL 9.0 and later.")
4a9e0585
DT
4124 (home-page "https://bitbucket.org/ged/ruby-pg")
4125 (license license:ruby)))
468e5657
DT
4126
4127(define-public ruby-byebug
4128 (package
4129 (name "ruby-byebug")
d5489a61 4130 (version "9.0.6")
468e5657
DT
4131 (source
4132 (origin
4133 (method url-fetch)
4134 (uri (rubygems-uri "byebug" version))
4135 (sha256
4136 (base32
d5489a61 4137 "1kbfcn65rgdhi72n8x9l393b89rvi5z542459k7d1ggchpb0idb0"))))
468e5657
DT
4138 (build-system ruby-build-system)
4139 (arguments
4140 '(#:tests? #f)) ; no tests
4141 (synopsis "Debugger for Ruby 2")
4142 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
4143TracePoint C API for execution control and the Debug Inspector C API for call
4144stack navigation. The core component provides support that front-ends can
4145build on. It provides breakpoint handling and bindings for stack frames among
4146other things and it comes with a command line interface.")
7bf837fd 4147 (home-page "https://github.com/deivid-rodriguez/byebug")
468e5657 4148 (license license:bsd-2)))
64b6ccc3 4149
5799bc2b
RW
4150(define-public ruby-netrc
4151 (package
4152 (name "ruby-netrc")
4153 (version "0.11.0")
4154 (source (origin
4155 (method url-fetch)
4156 (uri (rubygems-uri "netrc" version))
4157 (sha256
4158 (base32
4159 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
4160 (build-system ruby-build-system)
4161 (arguments
4162 `(#:phases
4163 (modify-phases %standard-phases
4164 (replace 'check
4165 ;; There is no Rakefile and minitest can only run one file at once,
4166 ;; so we have to iterate over all test files.
4167 (lambda _
9923d5a4
TGR
4168 (map (lambda (file)
4169 (invoke "ruby" "-Itest" file))
4170 (find-files "./test" "test_.*\\.rb")))))))
5799bc2b
RW
4171 (native-inputs
4172 `(("ruby-minitest" ,ruby-minitest)))
4173 (synopsis "Library to read and update netrc files")
4174 (description
4175 "This library can read and update netrc files, preserving formatting
4176including comments and whitespace.")
4177 (home-page "https://github.com/geemus/netrc")
4178 (license license:expat)))
4179
3a6989ce
RW
4180(define-public ruby-unf-ext
4181 (package
4182 (name "ruby-unf-ext")
4183 (version "0.0.7.1")
4184 (source (origin
4185 (method url-fetch)
4186 (uri (rubygems-uri "unf_ext" version))
4187 (sha256
4188 (base32
4189 "0ly2ms6c3irmbr1575ldyh52bz2v0lzzr2gagf0p526k12ld2n5b"))))
4190 (build-system ruby-build-system)
b809cc9a
RW
4191 (arguments
4192 `(#:phases
4193 (modify-phases %standard-phases
4194 (add-after 'build 'build-ext
9923d5a4 4195 (lambda _ (invoke "rake" "compile:unf_ext"))))))
3a6989ce
RW
4196 (native-inputs
4197 `(("bundler" ,bundler)
4198 ("ruby-rake-compiler" ,ruby-rake-compiler)
4199 ("ruby-test-unit" ,ruby-test-unit)))
4200 (synopsis "Unicode normalization form support library")
4201 (description
4202 "This package provides unicode normalization form support for Ruby.")
4203 (home-page "https://github.com/knu/ruby-unf_ext")
4204 (license license:expat)))
4205
2632a067 4206(define-public ruby-tdiff
5071f17b
BW
4207 ;; Use a newer than released snapshot so that rspec-2 is not required.
4208 (let ((commit "b662a6048f08abc45c1a834e5f34dd1c662935e2"))
4209 (package
4210 (name "ruby-tdiff")
4211 (version (string-append "0.3.3-1." (string-take commit 8)))
4212 (source (origin
4213 (method git-fetch)
4214 (uri (git-reference
4215 (url "https://github.com/postmodern/tdiff.git")
4216 (commit commit)))
4217 (file-name (string-append name "-" version "-checkout"))
4218 (sha256
4219 (base32
4220 "0n3gq8rx49f7ln6zqlshqfg2mgqyy30rsdjlnki5mv307ykc7ad4"))))
4221 (build-system ruby-build-system)
4222 (native-inputs
4223 `(("ruby-rspec" ,ruby-rspec)
4224 ("ruby-yard" ,ruby-yard)
4225 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
4226 (synopsis "Calculate the differences between two tree-like structures")
4227 (description
4228 "This library provides functions to calculate the differences between two
2632a067 4229tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
5071f17b
BW
4230 (home-page "https://github.com/postmodern/tdiff")
4231 (license license:expat))))
2632a067 4232
f60f5002 4233(define-public ruby-nokogiri-diff
5b0c223a
BW
4234 ;; Use a newer than released snapshot so that rspec-2 is not required.
4235 (let ((commit "a38491e4d8709b7406f2cae11a50226d927d06f5"))
4236 (package
4237 (name "ruby-nokogiri-diff")
4238 (version (string-append "0.2.0-1." (string-take commit 8)))
4239 (source (origin
4240 (method git-fetch)
4241 (uri (git-reference
4242 (url "https://github.com/postmodern/nokogiri-diff.git")
4243 (commit commit)))
4244 (file-name (string-append name "-" version "-checkout"))
4245 (sha256
4246 (base32
4247 "1ah2sfjh9n1p0ln2wkqzfl448ml7j4zfy6dhp1qgzq2m41php6rf"))))
4248 (build-system ruby-build-system)
4249 (propagated-inputs
4250 `(("ruby-tdiff" ,ruby-tdiff)
4251 ("ruby-nokogiri" ,ruby-nokogiri)))
4252 (native-inputs
4253 `(("ruby-rspec" ,ruby-rspec)
4254 ("ruby-yard" ,ruby-yard)
4255 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
4256 (synopsis "Calculate the differences between two XML/HTML documents")
4257 (description
4258 "@code{Nokogiri::Diff} adds the ability to calculate the
f60f5002 4259differences (added or removed nodes) between two XML/HTML documents.")
5b0c223a
BW
4260 (home-page "https://github.com/postmodern/nokogiri-diff")
4261 (license license:expat))))
f60f5002 4262
6dc21310
CB
4263(define-public ruby-racc
4264 (package
4265 (name "ruby-racc")
4266 (version "1.4.14")
4267 (source
4268 (origin
4269 (method url-fetch)
4270 (uri (rubygems-uri "racc" version))
4271 (sha256
4272 (base32
4273 "00yhs2ag7yy5v83mqvkbnhk9bvsh6mx3808k53n61ddzx446v1zl"))))
4274 (build-system ruby-build-system)
4275 (native-inputs
4276 `(("ruby-hoe" ,ruby-hoe)
4277 ("ruby-rake-compiler" ,ruby-rake-compiler)))
4278 (synopsis "LALR(1) parser generator for Ruby")
4279 (description
4280 "Racc is a LALR(1) parser generator. It is written in Ruby itself, and
4281generates Ruby program.")
4282 (home-page "http://i.loveruby.net/en/projects/racc/")
4283 (license (list
4284 ;; Generally licensed under the LGPL2.1, and some files also
4285 ;; available under the same license as Ruby.
4286 license:lgpl2.1
4287 license:ruby))))
4288
64b6ccc3
DT
4289(define-public ruby-rack
4290 (package
4291 (name "ruby-rack")
288d2480 4292 (version "2.0.6")
64b6ccc3
DT
4293 (source
4294 (origin
4295 (method url-fetch)
1db791d5
BW
4296 ;; Download from GitHub so that the patch can be applied.
4297 (uri (string-append
4298 "https://github.com/rack/rack/archive/"
4299 version
4300 ".tar.gz"))
4301 (file-name (string-append name "-" version ".tar.gz"))
64b6ccc3
DT
4302 (sha256
4303 (base32
288d2480 4304 "0pb3g5ymvbf07xaxcn51dpqv3djlxavckp3qkxsjdxiqznb0d9p1"))
1db791d5
BW
4305 ;; Ignore test which fails inside the build environment but works
4306 ;; outside.
4307 (patches (search-patches "ruby-rack-ignore-failing-test.patch"))))
64b6ccc3
DT
4308 (build-system ruby-build-system)
4309 (arguments
4310 '(#:phases
4311 (modify-phases %standard-phases
4312 (add-before 'check 'fix-tests
4313 (lambda _
4314 ;; A few of the tests use the length of a file on disk for
4315 ;; Content-Length and Content-Range headers. However, this file
4316 ;; has a shebang in it which an earlier phase patches, growing
4317 ;; the file size from 193 to 239 bytes when the store prefix is
4318 ;; "/gnu/store".
4319 (let ((size-diff (- (string-length (which "ruby"))
4320 (string-length "/usr/bin/env ruby"))))
4321 (substitute* '("test/spec_file.rb")
4322 (("193")
4323 (number->string (+ 193 size-diff)))
4324 (("bytes(.)22-33" all delimiter)
4325 (string-append "bytes"
4326 delimiter
4327 (number->string (+ 22 size-diff))
4328 "-"
4329 (number->string (+ 33 size-diff))))))
4330 #t)))))
4331 (native-inputs
1db791d5
BW
4332 `(("ruby-minitest" ,ruby-minitest)
4333 ("ruby-minitest-sprint" ,ruby-minitest-sprint)
4334 ("which" ,which)))
4335 (propagated-inputs
4336 `(("ruby-concurrent" ,ruby-concurrent)))
64b6ccc3
DT
4337 (synopsis "Unified web application interface for Ruby")
4338 (description "Rack provides a minimal, modular and adaptable interface for
4339developing web applications in Ruby. By wrapping HTTP requests and responses,
4340it unifies the API for web servers, web frameworks, and software in between
4341into a single method call.")
2f3800e5 4342 (home-page "https://rack.github.io/")
64b6ccc3 4343 (license license:expat)))
62e4cc5a 4344
20a0f804
BW
4345(define-public ruby-rack-test
4346 (package
4347 (name "ruby-rack-test")
4348 (version "0.8.3")
4349 (source
4350 (origin
4351 (method url-fetch)
4352 (uri (rubygems-uri "rack-test" version))
4353 (sha256
4354 (base32
4355 "14ij39zywvr1i9f6jsixfg4zxi2q1m1n1nydvf47f0b6sfc9mv1g"))))
4356 (build-system ruby-build-system)
4357 (arguments
4358 ;; Disable tests because of circular dependencies: requires sinatra,
4359 ;; which requires rack-protection, which requires rack-test. Instead
4360 ;; simply require the library.
4361 `(#:phases
4362 (modify-phases %standard-phases
4363 (replace 'check
4364 (lambda _
4365 (invoke "ruby" "-Ilib" "-r" "rack/test"))))))
4366 (propagated-inputs
4367 `(("ruby-rack" ,ruby-rack)))
4368 (synopsis "Testing API for Rack applications")
4369 (description
4370 "Rack::Test is a small, simple testing API for Rack applications. It can
4371be used on its own or as a reusable starting point for Web frameworks and
4372testing libraries to build on.")
4373 (home-page "https://github.com/rack-test/rack-test")
4374 (license license:expat)))
4375
a0a7e690
BW
4376(define-public ruby-rack-protection
4377 (package
4378 (name "ruby-rack-protection")
603822b0 4379 (version "2.0.3")
a0a7e690
BW
4380 (source
4381 (origin
4382 (method url-fetch)
4383 (uri (rubygems-uri "rack-protection" version))
4384 (sha256
4385 (base32
603822b0 4386 "1z5598qipilmnf45428jnxi63ykrgvnyywa5ckpr52zv2vpd8jdp"))))
a0a7e690
BW
4387 (build-system ruby-build-system)
4388 (arguments
fafeeaa2 4389 '(;; Tests missing from the gem.
a0a7e690
BW
4390 #:tests? #f))
4391 (propagated-inputs
4392 `(("ruby-rack" ,ruby-rack)))
4393 (native-inputs
4394 `(("bundler" ,bundler)
4395 ("ruby-rspec" ,ruby-rspec-2)
4396 ("ruby-rack-test" ,ruby-rack-test)))
4397 (synopsis "Rack middleware that protects against typical web attacks")
4398 (description "Rack middleware that can be used to protect against typical
4399web attacks. It can protect all Rack apps, including Rails. For instance, it
4400protects against cross site request forgery, cross site scripting,
4401clickjacking, directory traversal, session hijacking and IP spoofing.")
4402 (home-page "https://github.com/sinatra/sinatra/tree/master/rack-protection")
4403 (license license:expat)))
4404
6edabcb2
CB
4405(define-public ruby-rainbow
4406 (package
4407 (name "ruby-rainbow")
4408 (version "3.0.0")
4409 (source
4410 (origin
4411 (method url-fetch)
4412 (uri (rubygems-uri "rainbow" version))
4413 (sha256
4414 (base32
4415 "0bb2fpjspydr6x0s8pn1pqkzmxszvkfapv0p4627mywl7ky4zkhk"))))
4416 (build-system ruby-build-system)
4417 (arguments
4418 '(#:phases
4419 (modify-phases %standard-phases
4420 ;; Run rspec directly, to avoid requiring Rubocop which is used from
4421 ;; the Rakefile.
4422 (replace 'check
4423 (lambda* (#:key tests? #:allow-other-keys)
4424 (when tests?
4425 (invoke "rspec"))
4426 #t)))))
4427 (native-inputs
4428 `(("bundler" ,bundler)
4429 ("ruby-rspec" ,ruby-rspec)))
4430 (synopsis "Colorize printed text on ANSI terminals")
4431 (description
4432 "@code{rainbow} provides a string presenter object to colorize strings by
4433wrapping them in ANSI escape codes.")
4434 (home-page "https://github.com/sickill/rainbow")
79193b20
CB
4435 (license license:expat)))
4436
6188d643
CB
4437(define-public ruby-rr
4438 (package
4439 (name "ruby-rr")
4440 (version "1.2.1")
4441 (source
4442 (origin
4443 (method url-fetch)
4444 (uri (rubygems-uri "rr" version))
4445 (sha256
4446 (base32
4447 "1n9g78ba4c2zzmz8cdb97c38h1xm0clircag00vbcxwqs4dq0ymp"))))
4448 (build-system ruby-build-system)
4449 (arguments
4450 '(#:tests? #f)) ; test files not included
4451 (native-inputs
4452 `(("bundler" ,bundler)
4453 ("ruby-rspec" ,ruby-rspec)))
4454 (synopsis "Ruby test double framework")
4455 (description
4456 "RR is a test double framework that features a rich selection of double
4457techniques and a terse syntax.")
4458 (home-page "https://rr.github.io/rr/")
4459 (license license:expat)))
4460
79193b20
CB
4461(define-public ruby-rest-client
4462 (package
4463 (name "ruby-rest-client")
4464 (version "2.0.2")
4465 (source
4466 (origin
4467 (method url-fetch)
4468 (uri (rubygems-uri "rest-client" version))
4469 (sha256
4470 (base32
4471 "1hzcs2r7b5bjkf2x2z3n8z6082maz0j8vqjiciwgg3hzb63f958j"))))
4472 (build-system ruby-build-system)
4473 (arguments
4474 '(#:phases
4475 (modify-phases %standard-phases
4476 (add-before 'check 'remove-unnecessary-development-dependencies
4477 (lambda _
4478 (substitute* "rest-client.gemspec"
4479 ;; Remove rubocop as it's unused. Rubocop also indirectly
4480 ;; depends on this package through ruby-parser and ruby-ast so
4481 ;; this avoids a dependency loop.
4482 ((".*rubocop.*") "\n")
4483 ;; Remove pry as it's unused, it's a debugging tool
4484 ((".*pry.*") "\n")
4485 ;; Remove an unnecessarily strict rdoc dependency
4486 ((".*rdoc.*") "\n"))
4487 #t))
4488 (add-before 'check 'delete-network-dependent-tests
4489 (lambda _
4490 (delete-file "spec/integration/request_spec.rb")
4491 (delete-file "spec/integration/httpbin_spec.rb")
4492 #t)))))
4493 (propagated-inputs
4494 `(("ruby-http-cookie" ,ruby-http-cookie)
4495 ("ruby-mime-types" ,ruby-mime-types)
4496 ("ruby-netrc" ,ruby-netrc)))
4497 (native-inputs
4498 `(("bundler" ,bundler)
4499 ("ruby-webmock", ruby-webmock-2)
4500 ("ruby-rspec", ruby-rspec)))
4501 (synopsis "Simple HTTP and REST client for Ruby")
4502 (description
4503 "@code{rest-client} provides a simple HTTP and REST client for Ruby,
4504inspired by the Sinatra microframework style of specifying actions:
4505@code{get}, @code{put}, @code{post}, @code{delete}.")
4506 (home-page "https://github.com/rest-client/rest-client")
6edabcb2
CB
4507 (license license:expat)))
4508
5d8fe6de
CB
4509(define-public ruby-rubocop
4510 (package
4511 (name "ruby-rubocop")
4512 (version "0.64.0")
4513 (source
4514 (origin
4515 (method url-fetch)
4516 (uri (rubygems-uri "rubocop" version))
4517 (sha256
4518 (base32
4519 "07shi6kncwhkvlh9ci9rgccrjsq4448hbic3yrakh2w65ppynvbj"))))
4520 (build-system ruby-build-system)
4521 (arguments
4522 '(;; No included tests
4523 #:tests? #f))
4524 (propagated-inputs
4525 `(("ruby-parser" ,ruby-parser)
4526 ("ruby-powerpack" ,ruby-powerpack)
4527 ("ruby-rainbow" ,ruby-rainbow)
4528 ("ruby-progressbar" ,ruby-progressbar)
4529 ("ruby-parallel" ,ruby-parallel)
4530 ("ruby-jaro-winkler" ,ruby-jaro-winkler)
4531 ("ruby-unicode-display-width" ,ruby-unicode-display-width)))
4532 (synopsis "Ruby code style checking tool")
4533 (description
4534 "@code{rubocop} is a Ruby code style checking tool. It aims to enforce
4535the community-driven Ruby Style Guide.")
4536 (home-page "https://github.com/rubocop-hq/rubocop")
4537 (license license:expat)))
4538
6ef85256
BW
4539(define-public ruby-contest
4540 (package
4541 (name "ruby-contest")
4542 (version "0.1.3")
4543 (source
4544 (origin
4545 (method url-fetch)
4546 (uri (rubygems-uri "contest" version))
4547 (sha256
4548 (base32
4549 "1p9f2292b7b0fbrcjswvj9v01z7ig5ig52328wyqcabgb553qsdf"))))
4550 (build-system ruby-build-system)
4551 (synopsis "Write declarative tests using nested contexts")
4552 (description
4553 "Contest allows writing declarative @code{Test::Unit} tests using nested
4554contexts without performance penalties.")
4555 (home-page "https://github.com/citrusbyte/contest")
4556 (license license:expat)))
4557
c4550f75
BW
4558(define-public ruby-creole
4559 (package
4560 (name "ruby-creole")
4561 (version "0.5.0")
4562 (source
4563 (origin
4564 (method url-fetch)
4565 (uri (rubygems-uri "creole" version))
4566 (sha256
4567 (base32
4568 "00rcscz16idp6dx0dk5yi5i0fz593i3r6anbn5bg2q07v3i025wm"))))
4569 (build-system ruby-build-system)
4570 (native-inputs
4571 `(("ruby-bacon" ,ruby-bacon)))
4572 (synopsis "Creole markup language converter")
4573 (description
4574 "Creole is a lightweight markup language and this library for converting
4575creole to @code{HTML}.")
4576 (home-page "https://github.com/minad/creole")
4577 (license license:ruby)))
4578
6aaa815e
PP
4579(define-public ruby-docile
4580 (package
4581 (name "ruby-docile")
4582 (version "1.1.5")
4583 (source
4584 (origin
4585 (method url-fetch)
4586 (uri (rubygems-uri "docile" version))
4587 (sha256
4588 (base32
4589 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
4590 (build-system ruby-build-system)
4591 (arguments
4592 '(#:tests? #f)) ; needs github-markup, among others
4593 (synopsis "Ruby EDSL helper library")
4594 (description "Docile is a Ruby library that provides an interface for
4595creating embedded domain specific languages (EDSLs) that manipulate existing
4596Ruby classes.")
4597 (home-page "https://ms-ati.github.io/docile/")
4598 (license license:expat)))
4599
44514637 4600(define-public ruby-gherkin
62e4cc5a 4601 (package
44514637 4602 (name "ruby-gherkin")
aada5f6f 4603 (version "5.1.0")
62e4cc5a
PP
4604 (source
4605 (origin
4606 (method url-fetch)
44514637 4607 (uri (rubygems-uri "gherkin" version))
62e4cc5a
PP
4608 (sha256
4609 (base32
aada5f6f 4610 "1cgcdchwwdm10rsk44frjwqd4ihprhxjbm799nscqy2q1raqfj5s"))))
62e4cc5a
PP
4611 (build-system ruby-build-system)
4612 (native-inputs
4613 `(("bundler" ,bundler)))
4614 (arguments
4615 '(#:tests? #f)) ; needs simplecov, among others
4616 (synopsis "Gherkin parser for Ruby")
44514637 4617 (description "Gherkin is a parser and compiler for the Gherkin language.
aada5f6f
CB
4618It is intended be used by all Cucumber implementations to parse
4619@file{.feature} files.")
4620 (home-page "https://github.com/cucumber-attic/gherkin")
62e4cc5a 4621 (license license:expat)))
cd89fecb 4622
15b16c2c
CB
4623(define-public ruby-aruba
4624 (package
4625 (name "ruby-aruba")
4626 (version "0.14.8")
4627 (source
4628 (origin
4629 (method url-fetch)
4630 (uri (rubygems-uri "aruba" version))
4631 (sha256
4632 (base32
4633 "0zdd81l1lp0x78sxa6kkfqclpj5il3xl70nz05wqv2sfzzhqydxh"))))
4634 (build-system ruby-build-system)
4635 (arguments
4636 '(#:test-target "spec"
4637 #:phases
4638 (modify-phases %standard-phases
4639 (add-after 'unpack 'patch
4640 (lambda _
4641 (substitute* "spec/aruba/api_spec.rb"
4642 ;; This resolves some errors in the specs
4643 ;;
4644 ;; undefined method `parse' for Time:Class
4645 (("require 'spec_helper'")
4646 "require 'spec_helper'\nrequire 'time'"))
4647 ;; Avoid shebang issues in this spec file
4648 (substitute* "spec/aruba/matchers/command_spec.rb"
4649 (("/usr/bin/env bash")
4650 (which "bash")))
4651 #t))
4652 (add-before 'check 'remove-unnecessary-dependencies
4653 (lambda _
4654 (substitute* "Gemfile"
4655 ((".*byebug.*") "\n")
4656 ((".*pry.*") "\n")
4657 ((".*yaml.*") "\n")
4658 ((".*bcat.*") "\n")
4659 ((".*kramdown.*") "\n")
4660 ((".*rubocop.*") "\n")
4661 ((".*cucumber-pro.*") "\n")
4662 ((".*cucumber.*") "\n")
4663 ((".*license_finder.*") "\n")
4664 ((".*rake.*") "gem 'rake'\n")
4665 ((".*simplecov.*") "\n")
4666 ((".*relish.*") "\n"))
4667 (substitute* "spec/spec_helper.rb"
4668 ((".*simplecov.*") "")
4669 (("^SimpleCov.*") ""))
4670 (substitute* "aruba.gemspec"
4671 (("spec\\.add\\_runtime\\_dependency 'cucumber'.*")
4672 "spec.add_runtime_dependency 'cucumber'"))
4673 #t))
4674 (add-before 'check 'set-home
4675 (lambda _ (setenv "HOME" "/tmp") #t)))))
4676 (native-inputs
4677 `(("bundler" ,bundler)
4678 ("ruby-rspec" ,ruby-rspec)
4679 ("ruby-fuubar" ,ruby-fuubar)))
4680 (propagated-inputs
4681 `(("ruby-childprocess" ,ruby-childprocess)
4682 ("ruby-contracts" ,ruby-contracts)
4683 ("ruby-cucumber" ,ruby-cucumber)
4684 ("ruby-ffi" ,ruby-ffi)
4685 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
4686 ("ruby-thor" ,ruby-thor)
4687 ("ruby-yard" ,ruby-yard)))
4688 (synopsis "Test command-line applications with Cucumber, RSpec or Minitest")
4689 (description
4690 "Aruba is an extension for Cucumber, RSpec and Minitest for testing
4691command-line applications. It supports applications written in any
4692language.")
4693 (home-page "https://github.com/cucumber/aruba")
4694 (license license:expat)))
4695
4696;; A version of ruby-aruba without tests run so that circular dependencies can
4697;; be avoided.
4698(define ruby-aruba-without-tests
4699 (package
4700 (inherit ruby-aruba)
4701 (arguments '(#:tests? #f))
4702 (propagated-inputs
4703 `(("ruby-cucumber" ,ruby-cucumber-without-tests)
4704 ,@(alist-delete "ruby-cucumber"
4705 (package-propagated-inputs ruby-aruba))))
4706 (native-inputs '())))
4707
4708(define-public ruby-cucumber
4709 (package
4710 (name "ruby-cucumber")
4711 (version "3.1.2")
4712 (source
4713 (origin
4714 (method git-fetch)
4715 (uri (git-reference
4716 (url "https://github.com/cucumber/cucumber-ruby.git")
4717 (commit (string-append "v" version))))
4718 (file-name (git-file-name name version))
4719 (sha256
4720 (base32
4721 "0764wp2cjg60qa3l69q1dxda5g06a01n5w92szqbf89d2hgl47n3"))))
4722 (build-system ruby-build-system)
4723 (arguments
4724 '(#:test-target "spec"
4725 #:phases
4726 (modify-phases %standard-phases
4727 ;; Don't run or require rubocop, the code linting tool, as this is a
4728 ;; bit unnecessary.
4729 (add-after 'unpack 'dont-run-rubocop
4730 (lambda _
4731 (substitute* "Rakefile"
4732 ((".*rubocop/rake\\_task.*") "")
4733 ((".*RuboCop.*") ""))
4734 #t)))))
4735 (propagated-inputs
4736 `(("ruby-builder" ,ruby-builder)
4737 ("ruby-cucumber-core" ,ruby-cucumber-core)
4738 ("ruby-cucumber-wire" ,ruby-cucumber-wire)
4739 ("ruby-cucumber-expressions" ,ruby-cucumber-expressions)
4740 ("ruby-diff-lcs" ,ruby-diff-lcs)
4741 ("ruby-gherkin" ,ruby-gherkin)
4742 ("ruby-multi-json" ,ruby-multi-json)
4743 ("ruby-multi-test" ,ruby-multi-test)))
4744 (native-inputs
4745 `(("bundler" ,bundler)
4746 ;; Use a untested version of aruba, to avoid a circular dependency, as
4747 ;; ruby-aruba depends on ruby-cucumber.
4748 ("ruby-aruba", ruby-aruba-without-tests)
4749 ("ruby-rspec" ,ruby-rspec)
4750 ("ruby-pry" ,ruby-pry)
4751 ("ruby-nokogiri" ,ruby-nokogiri)))
4752 (synopsis "Describe automated tests in plain language")
4753 (description
4754 "Cucumber is a tool for running automated tests written in plain
4755language. It's designed to support a Behaviour Driven Development (BDD)
4756software development workflow.")
4757 (home-page "https://cucumber.io/")
4758 (license license:expat)))
4759
4760(define ruby-cucumber-without-tests
4761 (package (inherit ruby-cucumber)
4762 (arguments
4763 '(#:tests? #f))
4764 (native-inputs
4765 '())))
4766
cd89fecb
PP
4767(define-public ruby-cucumber-core
4768 (package
4769 (name "ruby-cucumber-core")
5cd047e8
CB
4770 ;; Stick to major version 3, until version 4 of Cucumber is released.
4771 (version "3.2.1")
cd89fecb
PP
4772 (source
4773 (origin
4774 (method url-fetch)
4775 (uri (rubygems-uri "cucumber-core" version))
4776 (sha256
4777 (base32
5cd047e8 4778 "1iavlh8hqj9lwljbpkw06259gdicbr1bdb6pbj5yy3n8szgr8k3c"))))
cd89fecb
PP
4779 (build-system ruby-build-system)
4780 (propagated-inputs
5cd047e8
CB
4781 `(("ruby-backports" ,ruby-backports)
4782 ("ruby-gherkin" ,ruby-gherkin)
4783 ("ruby-cucumber-tag-expressions" ,ruby-cucumber-tag-expressions)))
cd89fecb
PP
4784 (native-inputs
4785 `(("bundler" ,bundler)))
4786 (arguments
4787 '(#:tests? #f)) ; needs simplecov, among others
4788 (synopsis "Core library for the Cucumber BDD app")
4789 (description "Cucumber is a tool for running automated tests
4790written in plain language. Because they're written in plain language,
4791they can be read by anyone on your team. Because they can be read by
4792anyone, you can use them to help improve communication, collaboration
4793and trust on your team.")
4794 (home-page "https://cucumber.io/")
4795 (license license:expat)))
212d563d 4796
fb1a8954
CB
4797(define-public ruby-cucumber-expressions
4798 (package
4799 (name "ruby-cucumber-expressions")
4800 (version "6.0.1")
4801 (source
4802 (origin
4803 (method url-fetch)
4804 (uri (rubygems-uri "cucumber-expressions" version))
4805 (sha256
4806 (base32
4807 "0zwmv6hznyz9vk81f5dhwcr9jhxx2vmbk8yyazayvllvhy0fkpdw"))))
4808 (build-system ruby-build-system)
4809 (arguments
4810 '(#:test-target "spec"))
4811 (native-inputs
4812 `(("bundler" ,bundler)
4813 ("ruby-rspec" ,ruby-rspec)
4814 ("ruby-simplecov" ,ruby-simplecov)))
4815 (synopsis "Simpler alternative to Regular Expressions")
4816 (description "Cucumber Expressions offer similar functionality to Regular
4817Expressions, with a syntax that is easier to read and write. Cucumber
4818Expressions are extensible with parameter types.")
4819 (home-page "https://github.com/cucumber/cucumber-expressions-ruby")
4820 (license license:expat)))
4821
ce872770
CB
4822(define-public ruby-cucumber-wire
4823 (package
4824 (name "ruby-cucumber-wire")
4825 ;; Package version 0.0.1 initially, as this is what's needed by Cucumber
4826 ;; 3, and Cucumber 4 hasn't been released yet.
4827 (version "0.0.1")
4828 (source
4829 (origin
4830 (method url-fetch)
4831 (uri (rubygems-uri "cucumber-wire" version))
4832 (sha256
4833 (base32
4834 "09ymvqb0sbw2if1nxg8rcj33sf0va88ancq5nmp8g01dfwzwma2f"))))
4835 (build-system ruby-build-system)
4836 (arguments
4837 '(;; TODO: Currently, the tests can't be run as cucumber is required,
4838 ;; which would lead to a circular dependency.
4839 #:tests? #f
4840 #:test-target "default"
4841 #:phases
4842 (modify-phases %standard-phases
4843 (add-before 'check 'set-CUCUMBER_USE_RELEASED_GEMS
4844 (lambda _
4845 (setenv "CUCUMBER_USE_RELEASED_GEMS" "true")
4846 #t)))))
4847 (native-inputs
4848 `(("bundler" ,bundler)
4849 ("ruby-rspec" ,ruby-rspec)))
4850 (synopsis "Cucumber wire protocol plugin")
4851 (description
4852 "Cucumber's wire protocol allows step definitions to be implemented and
4853invoked on any platform.")
4854 (home-page "https://github.com/cucumber/cucumber-ruby-wire")
4855 (license license:expat)))
4856
0ce8f344
CB
4857(define-public ruby-cucumber-tag-expressions
4858 (package
4859 (name "ruby-cucumber-tag-expressions")
4860 (version "1.1.1")
4861 (source
4862 (origin
4863 (method url-fetch)
4864 (uri (rubygems-uri "cucumber-tag_expressions" version))
4865 (sha256
4866 (base32
4867 "0cvmbljybws0qzjs1l67fvr9gqr005l8jk1ni5gcsis9pfmqh3vc"))))
4868 (build-system ruby-build-system)
4869 (arguments
4870 '(#:phases
4871 (modify-phases %standard-phases
4872 (replace 'check
4873 (lambda _
4874 (invoke "rspec")
4875 #t)))))
4876 (native-inputs
4877 `(("ruby-rspec" ,ruby-rspec)))
4878 (synopsis "Cucumber tag expressions for Ruby")
4879 (description
4880 "Cucumber tag expression parser for Ruby. A tag expression is an infix
4881boolean expression used by Cucumber.")
4882 (home-page "https://github.com/cucumber/tag-expressions-ruby")
4883 (license license:expat)))
4884
212d563d
PP
4885(define-public ruby-bio-logger
4886 (package
4887 (name "ruby-bio-logger")
4888 (version "1.0.1")
4889 (source
4890 (origin
4891 (method url-fetch)
4892 (uri (rubygems-uri "bio-logger" version))
4893 (sha256
4894 (base32
4895 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
4896 (build-system ruby-build-system)
4897 (arguments
4898 `(#:tests? #f)) ; rake errors, missing shoulda
4899 (propagated-inputs
4900 `(("ruby-log4r" ,ruby-log4r)))
4901 (synopsis "Log4r wrapper for Ruby")
4902 (description "Bio-logger is a wrapper around Log4r adding extra logging
4903features such as filtering and fine grained logging.")
4904 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
4905 (license license:expat)))
07f61cb2 4906
2db0f9c8
BW
4907(define-public ruby-yajl-ruby
4908 (package
4909 (name "ruby-yajl-ruby")
4910 (version "1.4.1")
4911 (source
4912 (origin
4913 (method url-fetch)
4914 (uri (rubygems-uri "yajl-ruby" version))
4915 (sha256
4916 (base32
4917 "16v0w5749qjp13xhjgr2gcsvjv6mf35br7iqwycix1n2h7kfcckf"))))
4918 (build-system ruby-build-system)
4919 (arguments
4920 '(#:test-target "spec"
4921 #:phases
4922 (modify-phases %standard-phases
4923 (add-before 'check 'patch-test-to-update-load-path
4924 (lambda _
4925 (substitute* "spec/parsing/large_number_spec.rb"
4926 (("require \"yajl\"")
4927 "$LOAD_PATH << 'lib'; require 'yajl'"))
4928 #t)))))
4929 (native-inputs
4930 `(("ruby-rake-compiler" ,ruby-rake-compiler)
4931 ("ruby-rspec" ,ruby-rspec)))
4932 (synopsis "Streaming JSON parsing and encoding library for Ruby")
4933 (description
4934 "Ruby C bindings to the Yajl JSON stream-based parser library. The API
4935is compatible with the JSON gem, so yajl-ruby can act as a drop in
4936replacement.
4937
4938A modified copy of yajl is used, and included in the package.")
4939 (home-page "https://github.com/brianmario/yajl-ruby")
4940 (license (list license:expat ; Ruby code, yajl_ext.c and yajl_ext.h
4941 license:bsd-3)))) ; Included, modified copy of yajl
4942
07f61cb2 4943(define-public ruby-yard
6499893e
BW
4944 (package
4945 (name "ruby-yard")
50135ff8 4946 (version "0.9.16")
6499893e
BW
4947 (source
4948 (origin
4949 (method url-fetch)
4950 ;; Tests do not pass if we build from the distributed gem.
4951 (uri (string-append "https://github.com/lsegal/yard/archive/v"
3a3e3099 4952 version ".tar.gz"))
6499893e
BW
4953 (file-name (string-append name "-" version ".tar.gz"))
4954 (sha256
4955 (base32
50135ff8 4956 "0sqpbayy9sb406jh0zqg6qha1xds863qz9531dh6vp58hc00clfq"))))
6499893e
BW
4957 (build-system ruby-build-system)
4958 (arguments
4959 `(#:phases
4960 (modify-phases %standard-phases
4961 (replace 'check
4962 (lambda _
4963 ;; $HOME needs to be set to somewhere writeable for tests to run
4964 (setenv "HOME" "/tmp")
4965 ;; Run tests without using 'rake' to avoid dependencies.
9923d5a4 4966 (invoke "rspec"))))))
6499893e
BW
4967 (native-inputs
4968 `(("ruby-rspec" ,ruby-rspec)
4969 ("ruby-rack" ,ruby-rack)))
4970 (synopsis "Documentation generation tool for Ruby")
4971 (description
4972 "YARD is a documentation generation tool for the Ruby programming
07f61cb2
BW
4973language. It enables the user to generate consistent, usable documentation
4974that can be exported to a number of formats very easily, and also supports
4975extending for custom Ruby constructs such as custom class level definitions.")
2f3800e5 4976 (home-page "https://yardoc.org")
6499893e 4977 (license license:expat)))
2cbcd23a 4978
ad686ef3
RW
4979(define-public ruby-clap
4980 (package
4981 (name "ruby-clap")
4982 (version "1.0.0")
4983 (source (origin
4984 (method url-fetch)
4985 (uri (rubygems-uri "clap" version))
4986 (sha256
4987 (base32
4988 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
4989 (build-system ruby-build-system)
4990 ;; Clap needs cutest for running tests, but cutest needs clap.
4991 (arguments `(#:tests? #f))
4992 (synopsis "Command line argument parsing for simple applications")
4993 (description
4994 "Clap provides command line argument parsing features. It covers the
4995simple case of executing code based on the flags or parameters passed.")
4996 (home-page "https://github.com/djanowski/cutest")
0c80451e
RW
4997 (license license:expat)))
4998
4999(define-public ruby-cutest
5000 (package
5001 (name "ruby-cutest")
5002 (version "1.2.2")
5003 (source (origin
5004 (method url-fetch)
5005 (uri (rubygems-uri "cutest" version))
5006 (sha256
5007 (base32
5008 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
5009 (build-system ruby-build-system)
5010 (propagated-inputs
5011 `(("ruby-clap" ,ruby-clap)))
5012 (synopsis "Run tests in separate processes")
5013 (description
5014 "Cutest runs tests in separate processes to avoid shared state.")
5015 (home-page "https://github.com/djanowski/cutest")
ad686ef3
RW
5016 (license license:expat)))
5017
ac09beba
RW
5018(define-public ruby-pygmentize
5019 (package
5020 (name "ruby-pygmentize")
5021 (version "0.0.3")
5022 (source (origin
5023 (method url-fetch)
5024 (uri (rubygems-uri "pygmentize" version))
5025 (sha256
5026 (base32
5027 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
5028 (build-system ruby-build-system)
5029 (arguments
5030 `(#:phases
5031 (modify-phases %standard-phases
5032 (add-after 'unpack 'fix-pygmentize-path
5033 (lambda _
5034 (substitute* "lib/pygmentize.rb"
5035 (("\"/usr/bin/env python.*")
5036 (string-append "\"" (which "pygmentize") "\"\n")))
5037 #t))
5038 (add-after 'build 'do-not-use-vendor-directory
5039 (lambda _
5040 ;; Remove bundled pygments sources
5041 ;; FIXME: ruby-build-system does not support snippets.
5042 (delete-file-recursively "vendor")
5043 (substitute* "pygmentize.gemspec"
5044 (("\"vendor/\\*\\*/\\*\",") ""))
5045 #t)))))
5046 (inputs
5047 `(("pygments" ,python-pygments)))
5048 (native-inputs
5049 `(("ruby-cutest" ,ruby-cutest)
5050 ("ruby-nokogiri" ,ruby-nokogiri)))
5051 (synopsis "Thin Ruby wrapper around pygmentize")
5052 (description
5053 "Pygmentize provides a simple way to call pygmentize from within a Ruby
5054application.")
5055 (home-page "https://github.com/djanowski/pygmentize")
5056 (license license:expat)))
5057
2cbcd23a
DT
5058(define-public ruby-eventmachine
5059 (package
5060 (name "ruby-eventmachine")
c207fa5e 5061 (version "1.2.7")
2cbcd23a
DT
5062 (source
5063 (origin
5064 (method url-fetch)
5065 (uri (rubygems-uri "eventmachine" version))
5066 (sha256
5067 (base32
c207fa5e 5068 "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"))))
2cbcd23a
DT
5069 (build-system ruby-build-system)
5070 (arguments
c5d269fb 5071 '(#:tests? #f)) ; test suite tries to connect to google.com
2cbcd23a
DT
5072 (native-inputs
5073 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
5074 (synopsis "Single-threaded network event framework for Ruby")
5075 (description
5076 "EventMachine implements a single-threaded engine for arbitrary network
5077communications. EventMachine wraps all interactions with sockets, allowing
5078programs to concentrate on the implementation of network protocols. It can be
5079used to create both network servers and clients.")
24a26227
TGR
5080 ;; The ‘official’ rubyeventmachine.com domain is now registrar-squatted.
5081 (home-page "https://github.com/eventmachine/eventmachine")
2cbcd23a 5082 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
7d3a1a2d 5083
e218b0c8
BW
5084(define-public ruby-ruby-engine
5085 (package
5086 (name "ruby-ruby-engine")
5087 (version "1.0.1")
5088 (source
5089 (origin
5090 (method url-fetch)
5091 (uri (rubygems-uri "ruby_engine" version))
5092 (sha256
5093 (base32
5094 "1d0sd4q50zkcqhr395wj1wpn2ql52r0fpwhzjfvi1bljml7k546v"))))
5095 (build-system ruby-build-system)
5096 (arguments
5097 `(#:phases
5098 (modify-phases %standard-phases
5099 (add-before 'check 'clean-up
5100 (lambda _
5101 (delete-file "Gemfile.lock")
5102 (substitute* "ruby_engine.gemspec"
5103 ;; Remove unnecessary imports that would entail further
5104 ;; dependencies.
5105 ((".*<rdoc.*") "")
5106 ((".*<rubygems-tasks.*") "")
5107 ;; Remove extraneous .gem file
5108 (("\\\"pkg/ruby_engine-1.0.0.gem\\\",") "")
5109 ;; Soften rake dependency
5110 (("%q<rake>.freeze, \\[\\\"~> 10.0\\\"\\]")
5111 "%q<rake>.freeze, [\">= 10.0\"]")
5112 ;; Soften the rspec dependency
5113 (("%q<rspec>.freeze, \\[\\\"~> 2.4\\\"\\]")
5114 "%q<rspec>.freeze, [\">= 2.4\"]"))
5115 (substitute* "Rakefile"
5116 (("require 'rubygems/tasks'") "")
5117 (("Gem::Tasks.new") ""))
5118 ;; Remove extraneous .gem file that otherwise gets installed.
5119 (delete-file "pkg/ruby_engine-1.0.0.gem")
5120 #t)))))
5121 (native-inputs
5122 `(("bundler" ,bundler)
5123 ("ruby-rake" ,ruby-rake)
5124 ("ruby-rspec" ,ruby-rspec)))
5125 (synopsis "Simplifies checking for Ruby implementation")
5126 (description
5127 "@code{ruby_engine} provides an RubyEngine class that can be used to
5128check which implementation of Ruby is in use. It can provide the interpreter
5129name and provides query methods such as @{RubyEngine.mri?}.")
5130 (home-page "https://github.com/janlelis/ruby_engine")
5131 (license license:expat)))
5132
8092e333
BW
5133(define-public ruby-turn
5134 (package
5135 (name "ruby-turn")
5136 (version "0.9.7")
5137 (source
5138 (origin
5139 (method url-fetch)
5140 (uri (rubygems-uri "turn" version))
5141 (sha256
5142 (base32
5143 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
5144 (build-system ruby-build-system)
5145 (arguments
5146 `(#:phases
5147 (modify-phases %standard-phases
5148 ;; Tests fail because turn changes its environment so can no longer
5149 ;; find test/unit. Instead simply test if the executable runs
5150 ;; without issue.
5151 (replace 'check
5152 (lambda _
9923d5a4 5153 (invoke "ruby" "-Ilib" "bin/turn" "-h"))))))
8092e333
BW
5154 (propagated-inputs
5155 `(("ruby-ansi" ,ruby-ansi)
5156 ("ruby-minitest" ,ruby-minitest-4)))
5157 (synopsis "Alternate set of alternative runners for MiniTest")
5158 (description
5159 "TURN provides a set of alternative runners for MiniTest which are both
5160colorful and informative. TURN displays each test on a separate line with
5161failures being displayed immediately instead of at the end of the tests. Note
5162that TURN is no longer being maintained.")
5163 (home-page "http://rubygems.org/gems/turn")
5164 (license license:expat)))
5165
8279b1d3
CB
5166(define-public ruby-mimemagic
5167 (package
5168 (name "ruby-mimemagic")
5169 (version "0.3.2")
5170 (source
5171 (origin
5172 (method url-fetch)
5173 (uri (rubygems-uri "mimemagic" version))
5174 (sha256
5175 (base32
5176 "00ibc1mhvdfyfyl103xwb45621nwyqxf124cni5hyfhag0fn1c3q"))))
5177 (build-system ruby-build-system)
5178 (arguments
5179 '(#:phases
5180 (modify-phases %standard-phases
5181 ;; This phase breaks the tests, as it patches some of the test data.
5182 (delete 'patch-source-shebangs))))
5183 (native-inputs
5184 `(("ruby-bacon" ,ruby-bacon)))
5185 (synopsis "Ruby library for MIME detection by extension or content")
5186 (description
5187 "@acronym{MIME, Multipurpose Internet Mail Extensions} detection by
5188extension or content, using the freedesktop.org.xml shared-mime-info
5189database.")
5190 (home-page "https://github.com/minad/mimemagic")
5191 (license license:expat)))
5192
32d1c06f
BW
5193(define-public ruby-mime-types-data
5194 (package
5195 (name "ruby-mime-types-data")
f49511db 5196 (version "3.2016.0521")
32d1c06f
BW
5197 (source
5198 (origin
5199 (method url-fetch)
5200 (uri (rubygems-uri "mime-types-data" version))
5201 (sha256
5202 (base32
f49511db 5203 "04my3746hwa4yvbx1ranhfaqkgf6vavi1kyijjnw8w3dy37vqhkm"))))
32d1c06f
BW
5204 (build-system ruby-build-system)
5205 (native-inputs
5206 `(("ruby-hoe" ,ruby-hoe)))
5207 (synopsis "Registry for information about MIME media type definitions")
5208 (description
5209 "@code{mime-types-data} provides a registry for information about
5210Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
5211be used with the Ruby mime-types library or other software to determine
5212defined filename extensions for MIME types, or to use filename extensions to
5213look up the likely MIME type definitions.")
5214 (home-page "https://github.com/mime-types/mime-types-data/")
5215 (license license:expat)))
5216
d39b606c
BW
5217(define-public ruby-mime-types
5218 (package
5219 (name "ruby-mime-types")
803bcc81 5220 (version "3.1")
d39b606c
BW
5221 (source
5222 (origin
5223 (method url-fetch)
5224 (uri (rubygems-uri "mime-types" version))
5225 (sha256
5226 (base32
803bcc81 5227 "0087z9kbnlqhci7fxh9f6il63hj1k02icq2rs0c6cppmqchr753m"))))
d39b606c
BW
5228 (build-system ruby-build-system)
5229 (propagated-inputs
5230 `(("ruby-mime-types-data" ,ruby-mime-types-data)))
5231 (native-inputs
5232 `(("ruby-hoe" ,ruby-hoe)
5233 ("ruby-fivemat" ,ruby-fivemat)
5234 ("ruby-minitest-focus" ,ruby-minitest-focus)
5235 ("ruby-minitest-rg" ,ruby-minitest-rg)
803bcc81
BW
5236 ("ruby-minitest-bonus-assertions" ,ruby-minitest-bonus-assertions)
5237 ("ruby-minitest-hooks" ,ruby-minitest-hooks)))
d39b606c
BW
5238 (synopsis "Library and registry for MIME content type definitions")
5239 (description "The mime-types library provides a library and registry for
5240information about Multipurpose Internet Mail Extensions (MIME) content type
5241definitions. It can be used to determine defined filename extensions for MIME
5242types, or to use filename extensions to look up the likely MIME type
5243definitions.")
5244 (home-page "https://github.com/mime-types/ruby-mime-types")
5245 (license license:expat)))
5246
eb5e0bd9
BW
5247(define-public ruby-fivemat
5248 (package
5249 (name "ruby-fivemat")
7e2a4a6b 5250 (version "1.3.6")
eb5e0bd9
BW
5251 (source
5252 (origin
5253 (method url-fetch)
5254 (uri (rubygems-uri "fivemat" version))
5255 (sha256
5256 (base32
7e2a4a6b 5257 "006n7b09vviv5bs5hv2ccmjxw9iw3brcsm3xh3dhzfncsknz4jp7"))))
eb5e0bd9
BW
5258 (build-system ruby-build-system)
5259 (arguments
5260 `(#:tests? #f)) ; no tests
5261 (synopsis "Each test file given its own line of dots")
5262 (description
5263 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
5264its own line of dots during testing. It aims to provide test output that is
5265neither too verbose nor too minimal.")
5266 (home-page "https://github.com/tpope/fivemat")
5267 (license license:expat)))
5268
4fea500b
BW
5269(define-public ruby-sqlite3
5270 (package
5271 (name "ruby-sqlite3")
cba53c60 5272 (version "1.3.13")
4fea500b
BW
5273 (source
5274 (origin
5275 (method url-fetch)
5276 (uri (rubygems-uri "sqlite3" version))
5277 (sha256
5278 (base32
cba53c60 5279 "01ifzp8nwzqppda419c9wcvr8n82ysmisrs0hph9pdmv1lpa4f5i"))))
4fea500b
BW
5280 (build-system ruby-build-system)
5281 (arguments
5282 `(#:phases
5283 (modify-phases %standard-phases
54a93355
MB
5284 (add-before 'check 'adjust-failing-test
5285 (lambda _
5286 ;; XXX: This test fails with SQLite versions >= 3.21.
5287 ;; See <https://github.com/sparklemotion/sqlite3-ruby/issues/226>.
5288 (substitute* "test/test_integration_resultset.rb"
5289 (("\"integer\", \"text\"") "\"INTEGER\", \"text\""))
5290 #t))
4fea500b
BW
5291 (add-before 'check 'add-gemtest-file
5292 ;; This file exists in the repository but is not distributed.
9923d5a4 5293 (lambda _ (invoke "touch" ".gemtest"))))))
4fea500b
BW
5294 (inputs
5295 `(("sqlite" ,sqlite)))
5296 (native-inputs
5297 `(("ruby-hoe" ,ruby-hoe)
5298 ("ruby-rake-compiler" ,ruby-rake-compiler)
5299 ("ruby-mini-portile" ,ruby-mini-portile)))
5300 (synopsis "Interface with SQLite3 databases")
5301 (description
5302 "This module allows Ruby programs to interface with the SQLite3 database
5303engine.")
5304 (home-page
5305 "https://github.com/sparklemotion/sqlite3-ruby")
5306 (license license:bsd-3)))
5307
4dfa39cc
BW
5308(define-public ruby-shoulda-context
5309 (package
5310 (name "ruby-shoulda-context")
e7d1d472 5311 (version "1.2.2")
4dfa39cc
BW
5312 (source
5313 (origin
5314 (method url-fetch)
5315 (uri (rubygems-uri "shoulda-context" version))
5316 (sha256
5317 (base32
e7d1d472 5318 "1l0ncsxycb4s8n47dml97kdnixw4mizljbkwqc3rh05r70csq9bc"))))
4dfa39cc
BW
5319 (build-system ruby-build-system)
5320 (arguments
5321 `(#:phases
5322 (modify-phases %standard-phases
5323 (replace 'check
5324 (lambda _
5325 ;; Do not run tests to avoid circular dependence with rails.
5326 ;; Instead just import the library to test.
9923d5a4 5327 (invoke "ruby" "-Ilib" "-r" "shoulda-context"))))))
4dfa39cc
BW
5328 (synopsis "Test::Unit context framework extracted from Shoulda")
5329 (description
5330 "@code{shoulda-context} is the context framework extracted from Shoulda.
5331Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
5332context, setup, and should blocks combine to produce natural test method
5333names.")
5334 (home-page "https://github.com/thoughtbot/shoulda-context")
5335 (license license:expat)))
5336
e4fea008
BW
5337(define-public ruby-shoulda-matchers
5338 (package
5339 (name "ruby-shoulda-matchers")
d1c1f368 5340 (version "3.1.2")
e4fea008
BW
5341 (source
5342 (origin
5343 (method url-fetch)
5344 (uri (rubygems-uri "shoulda-matchers" version))
5345 (sha256
5346 (base32
d1c1f368 5347 "1zvv94pqk5b5my3w1shdz7h34xf2ldhg5k4qfdpbwi2iy0j9zw2a"))))
e4fea008
BW
5348 (build-system ruby-build-system)
5349 (arguments
5350 `(#:phases
5351 (modify-phases %standard-phases
e4fea008
BW
5352 (replace 'check
5353 (lambda _
5354 ;; Do not run tests to avoid circular dependence with rails. Instead
5355 ;; just import the library to test.
9923d5a4 5356 (invoke "ruby" "-Ilib" "-r" "shoulda-matchers"))))))
e4fea008
BW
5357 (propagated-inputs
5358 `(("ruby-activesupport" ,ruby-activesupport)))
5359 (synopsis "Collection of testing matchers extracted from Shoulda")
5360 (description
5361 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
5362test common Rails functionality. These tests would otherwise be much longer,
5363more complex, and error-prone.")
5364 (home-page "https://github.com/thoughtbot/shoulda-matchers")
5365 (license license:expat)))
5366
3885c58b
BW
5367(define-public ruby-shoulda-matchers-2
5368 (package
5369 (inherit ruby-shoulda-matchers)
5370 (version "2.8.0")
5371 (source (origin
5372 (method url-fetch)
5373 (uri (rubygems-uri "shoulda-matchers" version))
5374 (sha256
5375 (base32
5376 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
5377
6f390716
BW
5378(define-public ruby-shoulda
5379 (package
5380 (name "ruby-shoulda")
5381 (version "3.5.0")
5382 (source
5383 (origin
5384 (method url-fetch)
5385 (uri (rubygems-uri "shoulda" version))
5386 (sha256
5387 (base32
5388 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
5389 (build-system ruby-build-system)
5390 (arguments
5391 `(#:phases
5392 (modify-phases %standard-phases
5393 (replace 'check
5394 ;; Don't run tests to avoid circular dependence with rails. Instead
5395 ;; just import the library to test.
9923d5a4 5396 (lambda _ (invoke "ruby" "-Ilib" "-r" "shoulda"))))))
6f390716
BW
5397 (propagated-inputs
5398 `(("ruby-shoulda-context" ,ruby-shoulda-context)
5399 ("ruby-shoulda-matchers" ,ruby-shoulda-matchers-2)))
5400 (synopsis "Context framework and matchers for testing")
5401 (description
5402 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
5403@code{shoulda-matchers} providing tools for writing tests.")
5404 (home-page "https://github.com/thoughtbot/shoulda")
5405 (license license:expat)))
5406
3b44bcdf
BW
5407(define-public ruby-unf
5408 (package
5409 (name "ruby-unf")
5410 (version "0.1.4")
5411 (source
5412 (origin
5413 (method url-fetch)
5414 (uri (rubygems-uri "unf" version))
5415 (sha256
5416 (base32
5417 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
5418 (build-system ruby-build-system)
5419 (arguments
5420 `(#:phases
5421 (modify-phases %standard-phases
5422 (add-before 'check 'add-dependency-to-bundler
5423 (lambda _
5424 ;; test-unit is required but not provided by the bundler
5425 ;; environment. This is fixed in the upstream repository but fix
5426 ;; has not been released.
5427 (substitute* "Gemfile"
5428 (("^gemspec") "gem 'test-unit'\ngemspec"))
5429 #t)))))
5430 (propagated-inputs
5431 `(("ruby-unf-ext" ,ruby-unf-ext)))
5432 (native-inputs
5433 `(("ruby-shoulda" ,ruby-shoulda)
5434 ("bundler" ,bundler)
5435 ("ruby-test-unit" ,ruby-test-unit)))
5436 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
5437 (description
5438 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
5439support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
5440@code{java.text.Normalizer} on JRuby.")
5441 (home-page "https://github.com/knu/ruby-unf")
5442 (license license:bsd-2)))
5443
8c7ae384
CB
5444(define-public ruby-webmock-2
5445 (package
5446 (name "ruby-webmock")
5447 (version "2.3.2")
5448 (source
5449 (origin
5450 (method url-fetch)
5451 (uri (rubygems-uri "webmock" version))
5452 (sha256
5453 (base32
5454 "04hkcqsmbfnp8g237pisnc834vpgildklicbjbyikqg0bg1rwcy5"))))
5455 (build-system ruby-build-system)
5456 (native-inputs
5457 `(("bundler" ,bundler)
5458 ("ruby-rspec" ,ruby-rspec)))
5459 (propagated-inputs
5460 `(("ruby-addressable" ,ruby-addressable)
5461 ("ruby-crack" ,ruby-crack)
5462 ("ruby-hashdiff" ,ruby-hashdiff)))
5463 (synopsis "Allows stubbing and setting expectations on HTTP requests")
5464 (description
5465 "WebMock allows stubbing HTTP requests and setting expectations on HTTP
5466requests. This is useful when testing software.")
5467 (home-page "https://github.com/bblimke/webmock")
5468 (license license:expat)))
5469
d8c189ed
CB
5470(define-public ruby-unicode-display-width
5471 (package
5472 (name "ruby-unicode-display-width")
5473 (version "1.4.1")
5474 (source
5475 (origin
5476 (method url-fetch)
5477 (uri (rubygems-uri "unicode-display_width" version))
5478 (sha256
5479 (base32
5480 "0bq528fibi8s0jmxz0xzlgzggdq0x4fx46wfqz49478pv8gb2diq"))))
5481 (build-system ruby-build-system)
5482 (arguments
5483 '(;; Test data not included.
5484 #:tests? #f))
5485 (synopsis "Determine the monospace display width of Ruby strings")
5486 (description
5487 "@code{Unicode::DisplayWidth} is a Ruby library which can determine the
5488display width of strings in Ruby.")
5489 (home-page "https://github.com/janlelis/unicode-display_width")
5490 (license license:expat)))
5491
6120589f
CB
5492;; There is another gem called 'ruby-version' so we use an underscore in this
5493;; name
5494(define-public ruby_version
5495 (package
5496 (name "ruby_version")
5497 (version "1.0.1")
5498 (source
5499 (origin
5500 (method url-fetch)
5501 (uri (rubygems-uri "ruby_version" version))
5502 (sha256
5503 (base32
5504 "0854i1bjy56176anr05l5m0vc81nl53c7fyfg7sljj62m1d64dgj"))))
5505 (build-system ruby-build-system)
5506 (arguments
5507 '(#:phases
5508 (modify-phases %standard-phases
5509 (add-before 'check 'fix-dependencies
5510 (lambda _
5511 ;; Remove the Gemfile.lock, as we want to use Guix packages at
5512 ;; whatever versions.
5513 (delete-file "Gemfile.lock")
5514 ;; Remove the incldued gem file as it's unnecessary.
5515 (delete-file "pkg/ruby_version-1.0.0.gem")
5516 (substitute* "ruby_version.gemspec"
5517 ;; Don't require rdoc and rubygems-tasks as they're unnecessary
5518 ((".*rdoc.*") "\n")
5519 ((".*rubygems-tasks.*") "\n")
5520 ;; Accept any version of rake and rspec
5521 (("%q<rake.*") "%q<rake>)\n")
5522 (("%q<rspec.*") "%q<rspec>)\n"))
5523 ;; Remove the use of rubygems-tasks from the Rakefile, as it's
5524 ;; unnecessary.
5525 (substitute* "Rakefile"
5526 (("^require 'rubygems/tasks'") "")
5527 (("Gem::Tasks.new") ""))
5528 #t)))))
5529 (native-inputs
5530 `(("bundler" ,bundler)
5531 ("ruby-rspec" ,ruby-rspec)))
5532 (synopsis "Ruby library to help check the Ruby version")
5533 (description
5534 "@code{ruby_version} provides a @code{RubyVersion} module to simplify
5535checking for the right Ruby version in software.")
5536 (home-page "https://github.com/janlelis/ruby_version")
5537 (license license:expat)))
5538
a229acff
CB
5539(define-public ruby-websocket-driver
5540 (package
5541 (name "ruby-websocket-driver")
5542 (version "0.7.0")
5543 (source
5544 (origin
5545 (method url-fetch)
5546 (uri (rubygems-uri "websocket-driver" version))
5547 (sha256
5548 (base32
5549 "1551k3fs3kkb3ghqfj3n5lps0ikb9pyrdnzmvgfdxy8574n4g1dn"))))
5550 (build-system ruby-build-system)
5551 (arguments
5552 '(;; No included tests
5553 #:tests? #f))
5554 (propagated-inputs
5555 `(("ruby-websocket-extensions" ,ruby-websocket-extensions)))
5556 (synopsis "WebSocket protocol handler with pluggable I/O")
5557 (description
5558 "@code{websocket-driver} provides a complete implementation of the
5559WebSocket protocols that can be hooked up to any TCP library")
5560 (home-page "https://github.com/faye/websocket-driver-ruby")
5561 (license license:expat)))
5562
52b015a9
CB
5563(define-public ruby-websocket-extensions
5564 (package
5565 (name "ruby-websocket-extensions")
5566 (version "0.1.3")
5567 (source
5568 (origin
5569 (method url-fetch)
5570 (uri (rubygems-uri "websocket-extensions" version))
5571 (sha256
5572 (base32
5573 "034sdr7fd34yag5l6y156rkbhiqgmy395m231dwhlpcswhs6d270"))))
5574 (build-system ruby-build-system)
5575 (arguments
5576 '(;; No included tests
5577 #:tests? #f))
5578 (synopsis "Generic extension manager for WebSocket connections")
5579 (description
5580 "@code{websocket-extensions} provides a container for registering
5581extension plugins.")
5582 (home-page "https://github.com/faye/websocket-extensions-ruby")
5583 (license license:expat)))
5584
5799aadd
BW
5585(define-public ruby-domain-name
5586 (package
5587 (name "ruby-domain-name")
222999c9 5588 (version "0.5.20180417")
5799aadd
BW
5589 (source
5590 (origin
5591 (method url-fetch)
5592 (uri (rubygems-uri "domain_name" version))
5593 (sha256
5594 (base32
222999c9 5595 "0abdlwb64ns7ssmiqhdwgl27ly40x2l27l8hs8hn0z4kb3zd2x3v"))))
5799aadd
BW
5596 (build-system ruby-build-system)
5597 (arguments
5598 `(#:phases
5599 (modify-phases %standard-phases
5600 (add-before 'check 'fix-versions
5601 (lambda _
5602 ;; Fix NameError that appears to already be fixed upstream.
5603 (substitute* "Rakefile"
5604 (("DomainName::VERSION")
5605 "Bundler::GemHelper.gemspec.version"))
5606 ;; Loosen unnecessarily strict test-unit version specification.
5607 (substitute* "domain_name.gemspec"
71596c3c 5608 (("<test-unit>.freeze, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
5799aadd
BW
5609 #t)))))
5610 (propagated-inputs
5611 `(("ruby-unf" ,ruby-unf)))
5612 (native-inputs
5613 `(("ruby-shoulda" ,ruby-shoulda)
5614 ("bundler" ,bundler)
5615 ("ruby-test-unit" ,ruby-test-unit)))
5616 (synopsis "Domain name manipulation library")
5617 (description
5618 "@code{domain_name} is a Domain name manipulation library. It parses a
5619domain name ready for extracting the registered domain and TLD (Top Level
5620Domain). It can also be used for cookie domain validation based on the Public
5621Suffix List.")
5622 (home-page "https://github.com/knu/ruby-domain_name")
5623 (license license:bsd-2)))
5624
d114ceeb
BW
5625(define-public ruby-http-cookie
5626 (package
5627 (name "ruby-http-cookie")
2a2eb07d 5628 (version "1.0.3")
d114ceeb
BW
5629 (source
5630 (origin
5631 (method url-fetch)
5632 (uri (rubygems-uri "http-cookie" version))
5633 (sha256
5634 (base32
2a2eb07d 5635 "004cgs4xg5n6byjs7qld0xhsjq3n6ydfh897myr2mibvh6fjc49g"))))
d114ceeb
BW
5636 (build-system ruby-build-system)
5637 (arguments
5638 `(#:phases
5639 (modify-phases %standard-phases
5640 (add-before 'check 'add-dependency-to-bundler
5641 (lambda _
5642 ;; Fix NameError
5643 (substitute* "Rakefile"
5644 (("HTTP::Cookie::VERSION")
5645 "Bundler::GemHelper.gemspec.version"))
5646 #t)))))
5647 (propagated-inputs
5648 `(("ruby-domain-name" ,ruby-domain-name)))
5649 (native-inputs
5650 `(("rubysimplecov" ,ruby-simplecov)
5651 ("bundler" ,bundler)
5652 ("ruby-sqlite3" ,ruby-sqlite3)
5653 ("ruby-test-unit" ,ruby-test-unit)))
5654 (synopsis "Handle HTTP Cookies based on RFC 6265")
5655 (description
5656 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
5657RFC 6265. It has been designed with security, standards compliance and
5658compatibility in mind, to behave just the same as today's major web browsers.
5659It has built-in support for the legacy @code{cookies.txt} and
5660@code{cookies.sqlite} formats of Mozilla Firefox.")
5661 (home-page "https://github.com/sparklemotion/http-cookie")
5662 (license license:expat)))
5663
1c8e6fd3
CB
5664(define-public ruby-httpclient
5665 (package
5666 (name "ruby-httpclient")
5667 (version "2.8.3")
5668 (source
5669 (origin
5670 (method url-fetch)
5671 (uri (rubygems-uri "httpclient" version))
5672 (sha256
5673 (base32
5674 "19mxmvghp7ki3klsxwrlwr431li7hm1lczhhj8z4qihl2acy8l99"))))
5675 (build-system ruby-build-system)
5676 (arguments
5677 '(;; TODO: Some tests currently fail
5678 ;; ------
5679 ;; 211 tests, 729 assertions, 13 failures, 4 errors, 0 pendings,
5680 ;; 2 omissions, 0 notifications
5681 ;; 91.866% passed
5682 ;; ------
5683 ;; 6.49 tests/s, 22.41 assertions/s
5684 #:tests? #f
5685 #:phases
5686 (modify-phases %standard-phases
5687 (replace 'check
5688 (lambda* (#:key tests? #:allow-other-keys)
5689 (if tests?
9923d5a4
TGR
5690 (invoke "ruby"
5691 "-Ilib"
5692 "test/runner.rb")
0076f5a9 5693 #t))))))
1c8e6fd3
CB
5694 (native-inputs
5695 `(("ruby-rack" ,ruby-rack)))
5696 (synopsis
5697 "Make HTTP requests with support for HTTPS, Cookies, authentication and more")
5698 (description
5699 "The @code{httpclient} ruby library provides functionality related to
5700HTTP. Compared to the @code{net/http} library, @{httpclient} also provides
5701Cookie, multithreading and authentication (digest, NTLM) support.
5702
5703Also provided is a @command{httpclient} command, which can perform HTTP
5704requests either using arguments or with an interactive prompt.")
5705 (home-page "https://github.com/nahi/httpclient")
5706 (license license:ruby)))
5707
7d3a1a2d
BW
5708(define-public ruby-ansi
5709 (package
5710 (name "ruby-ansi")
5711 (version "1.5.0")
5712 (source
5713 (origin
5714 (method url-fetch)
5715 ;; Fetch from GitHub as the gem does not contain testing code.
5716 (uri (string-append "https://github.com/rubyworks/ansi/archive/"
5717 version ".tar.gz"))
5718 (file-name (string-append name "-" version ".tar.gz"))
5719 (sha256
5720 (base32
5721 "1zdip30hivyipi8hndhb457bhiz033awd00bgrsk5axjrwp6zhly"))))
5722 (build-system ruby-build-system)
5723 (arguments
5724 `(#:phases
5725 (modify-phases %standard-phases
5726 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
5727 ;; cycle ansi, qed, ansi. Instead simply test that the library can
5728 ;; be require'd.
5729 (replace 'check
5730 (lambda _
9923d5a4 5731 (invoke "ruby" "-Ilib" "-r" "ansi")))
0899352f
MB
5732 (add-before 'validate-runpath 'replace-broken-symlink
5733 (lambda* (#:key outputs #:allow-other-keys)
5734 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
5735 (file (string-append
5736 out "/lib/ruby/vendor_ruby/gems/ansi-"
5737 ,version "/lib/ansi.yml")))
0899352f
MB
5738 ;; XXX: This symlink is broken since ruby 2.4.
5739 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
5740 (delete-file file)
5741 (symlink "../.index" file)
5742 #t))))))
7d3a1a2d
BW
5743 (synopsis "ANSI escape code related libraries")
5744 (description
5745 "This package is a collection of ANSI escape code related libraries
5746enabling ANSI colorization and stylization of console output. Included in the
5747library are the @code{Code} module, which defines ANSI codes as constants and
5748methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
5749@code{ProgressBar}, and a @code{String} subclass. The library also includes a
5750@code{Terminal} module which provides information about the current output
5751device.")
2f3800e5 5752 (home-page "https://rubyworks.github.io/ansi")
7d3a1a2d 5753 (license license:bsd-2)))
7c033c46
BW
5754
5755(define-public ruby-systemu
5756 (package
5757 (name "ruby-systemu")
5758 (version "2.6.5")
5759 (source
5760 (origin
5761 (method url-fetch)
5762 (uri (rubygems-uri "systemu" version))
5763 (sha256
5764 (base32
5765 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
5766 (build-system ruby-build-system)
5767 (arguments
5768 `(#:phases
5769 (modify-phases %standard-phases
5770 (add-before 'check 'set-version
5771 (lambda _
5772 (setenv "VERSION" ,version)
5773 #t)))))
5774 (synopsis "Capture of stdout/stderr and handling of child processes")
5775 (description
5776 "Systemu can be used on any platform to return status, stdout, and stderr
5777of any command. Unlike other methods like @code{open3} and @code{popen4}
5778there is no danger of full pipes or threading issues hanging your process or
5779subprocess.")
5780 (home-page "https://github.com/ahoward/systemu")
5781 (license license:ruby)))
3d84a99e
BW
5782
5783(define-public ruby-bio-commandeer
5784 (package
5785 (name "ruby-bio-commandeer")
37b08547 5786 (version "0.4.0")
3d84a99e
BW
5787 (source
5788 (origin
5789 (method url-fetch)
5790 (uri (rubygems-uri "bio-commandeer" version))
5791 (sha256
5792 (base32
37b08547 5793 "0khpfw1yl5l3d2m8nxpkk32ybc4c3pa5hic3agd160jdfjjjnlni"))))
3d84a99e
BW
5794 (build-system ruby-build-system)
5795 (arguments
5796 `(#:phases
5797 (modify-phases %standard-phases
5798 (replace 'check
5799 ;; Run test without calling 'rake' so that jeweler is
5800 ;; not required as an input.
5801 (lambda _
9923d5a4 5802 (invoke "rspec" "spec/bio-commandeer_spec.rb"))))))
3d84a99e
BW
5803 (propagated-inputs
5804 `(("ruby-bio-logger" ,ruby-bio-logger)
5805 ("ruby-systemu" ,ruby-systemu)))
5806 (native-inputs
5807 `(("bundler" ,bundler)
5808 ("ruby-rspec" ,ruby-rspec)))
5809 (synopsis "Simplified running of shell commands from within Ruby")
5810 (description
5811 "Bio-commandeer provides an opinionated method of running shell commands
5812from within Ruby. The advantage of bio-commandeer over other methods of
5813running external commands is that when something goes wrong, messages printed
5814to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
5815detail to ease debugging.")
7bf837fd 5816 (home-page "https://github.com/wwood/bioruby-commandeer")
3d84a99e 5817 (license license:expat)))
7c8131c7
BW
5818
5819(define-public ruby-rubytest
5820 (package
5821 (name "ruby-rubytest")
5822 (version "0.8.1")
5823 (source
5824 (origin
5825 (method url-fetch)
5826 (uri (rubygems-uri "rubytest" version))
5827 (sha256
5828 (base32
5829 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
5830 (build-system ruby-build-system)
5831 (arguments
5832 ;; Disable regular testing to break the cycle rubytest, qed, brass,
5833 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
5834 ;; simply test that the library can be require'd.
5835 `(#:phases
5836 (modify-phases %standard-phases
5837 (replace 'check
5838 (lambda _
9923d5a4 5839 (invoke "ruby" "-Ilib" "-r" "rubytest"))))))
7c8131c7
BW
5840 (propagated-inputs
5841 `(("ruby-ansi" ,ruby-ansi)))
5842 (synopsis "Universal test harness for Ruby")
5843 (description
5844 "Rubytest is a testing meta-framework for Ruby. It can handle any
5845compliant test framework and can run tests from multiple frameworks in a
5846single pass.")
2f3800e5 5847 (home-page "https://rubyworks.github.io/rubytest")
7c8131c7 5848 (license license:bsd-2)))
90fcedf2
BW
5849
5850(define-public ruby-brass
5851 (package
5852 (name "ruby-brass")
5853 (version "1.2.1")
5854 (source
5855 (origin
5856 (method url-fetch)
5857 (uri (rubygems-uri "brass" version))
5858 (sha256
5859 (base32
5860 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
5861 (build-system ruby-build-system)
5862 (arguments
5863 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
5864 ;; Instead simply test that the library can be require'd.
5865 `(#:phases
5866 (modify-phases %standard-phases
5867 (replace 'check
5868 (lambda _
9923d5a4 5869 (invoke "ruby" "-Ilib" "-r" "brass"))))))
90fcedf2
BW
5870 (synopsis "Basic foundational assertions framework")
5871 (description
5872 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
5873foundational assertions framework for other assertion and test frameworks to
5874make use of.")
2f3800e5 5875 (home-page "https://rubyworks.github.io/brass")
90fcedf2 5876 (license license:bsd-2)))
120fc74b
BW
5877
5878(define-public ruby-qed
5879 (package
5880 (name "ruby-qed")
5881 (version "2.9.2")
5882 (source
5883 (origin
5884 (method url-fetch)
5885 (uri (rubygems-uri "qed" version))
5886 (sha256
5887 (base32
5888 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
5889 (build-system ruby-build-system)
5890 (arguments
5891 ;; Disable testing to break the cycle qed, ansi, qed, among others.
5892 ;; Instead simply test that the executable runs using --copyright.
5893 `(#:phases
5894 (modify-phases %standard-phases
5895 (replace 'check
5896 (lambda _
9923d5a4 5897 (invoke "ruby" "-Ilib" "bin/qed" "--copyright"))))))
120fc74b
BW
5898 (propagated-inputs
5899 `(("ruby-ansi" ,ruby-ansi)
5900 ("ruby-brass" ,ruby-brass)))
5901 (synopsis "Test framework utilizing literate programming techniques")
5902 (description
5903 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
5904@dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
5905Development} (BDD) utilizing Literate Programming techniques. QED sits
5906somewhere between lower-level testing tools like @code{Test::Unit} and
5907requirement specifications systems like Cucumber.")
2f3800e5 5908 (home-page "https://rubyworks.github.io/qed")
120fc74b 5909 (license license:bsd-2)))
9273ee8f
BW
5910
5911(define-public ruby-ae
5912 (package
5913 (name "ruby-ae")
5914 (version "1.8.2")
5915 (source
5916 (origin
5917 (method url-fetch)
5918 ;; Fetch from github so tests are included.
5919 (uri (string-append
5920 "https://github.com/rubyworks/ae/archive/"
5921 version ".tar.gz"))
5922 (file-name (string-append name "-" version ".tar.gz"))
5923 (sha256
5924 (base32
5925 "147jmkx54x7asy2d8m4dyrhhf4hdx4galpnhwzai030y3cdsfrrl"))))
5926 (build-system ruby-build-system)
5927 (arguments
5928 `(#:phases
5929 (modify-phases %standard-phases
5930 (replace 'check
9923d5a4 5931 (lambda _ (invoke "qed")))
de6f6efd
MB
5932 (add-before 'validate-runpath 'replace-broken-symlink
5933 (lambda* (#:key outputs #:allow-other-keys)
5934 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
5935 (file (string-append
5936 out "/lib/ruby/vendor_ruby/gems/ae-"
5937 ,version "/lib/ae.yml")))
de6f6efd
MB
5938 ;; XXX: This symlink is broken since ruby 2.4.
5939 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
5940 (delete-file file)
5941 (symlink "../.index" file)
5942 #t))))))
9273ee8f
BW
5943 (propagated-inputs
5944 `(("ruby-ansi" ,ruby-ansi)))
5945 (native-inputs
5946 `(("ruby-qed" ,ruby-qed)))
5947 (synopsis "Assertions library")
5948 (description
5949 "Assertive Expressive (AE) is an assertions library specifically designed
5950for reuse by other test frameworks.")
2f3800e5 5951 (home-page "https://rubyworks.github.io/ae")
9273ee8f 5952 (license license:bsd-2)))
78bb471f
BW
5953
5954(define-public ruby-lemon
5955 (package
5956 (name "ruby-lemon")
5957 (version "0.9.1")
5958 (source
5959 (origin
5960 (method url-fetch)
5961 (uri (rubygems-uri "lemon" version))
5962 (sha256
5963 (base32
5964 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
5965 (build-system ruby-build-system)
5966 (arguments
5967 `(#:phases
5968 (modify-phases %standard-phases
9923d5a4 5969 (replace 'check (lambda _ (invoke "qed"))))))
78bb471f
BW
5970 (propagated-inputs
5971 `(("ruby-ae" ,ruby-ae)
5972 ("ruby-ansi" ,ruby-ansi)
5973 ("ruby-rubytest" ,ruby-rubytest)))
5974 (native-inputs
5975 `(("ruby-qed" ,ruby-qed)))
5976 (synopsis "Test framework correlating code structure and test unit")
5977 (description
5978 "Lemon is a unit testing framework that enforces highly formal
5979case-to-class and unit-to-method test construction. This enforcement can help
5980focus concern on individual units of behavior.")
2f3800e5 5981 (home-page "https://rubyworks.github.io/lemon")
78bb471f 5982 (license license:bsd-2)))
0832804e
BW
5983
5984(define-public ruby-rubytest-cli
5985 (package
5986 (name "ruby-rubytest-cli")
5987 (version "0.2.0")
5988 (source
5989 (origin
5990 (method url-fetch)
5991 (uri (rubygems-uri "rubytest-cli" version))
5992 (sha256
5993 (base32
5994 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
5995 (build-system ruby-build-system)
5996 (arguments
5997 `(#:tests? #f)) ; no tests
5998 (propagated-inputs
5999 `(("ruby-ansi" ,ruby-ansi)
6000 ("ruby-rubytest" ,ruby-rubytest)))
6001 (synopsis "Command-line interface for rubytest")
6002 (description
6003 "Rubytest CLI is a command-line interface for running tests for
6004Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
2f3800e5 6005 (home-page "https://rubyworks.github.io/rubytest-cli")
0832804e 6006 (license license:bsd-2)))
72ccbfe3
BW
6007
6008(define-public ruby-hashery
6009 (package
6010 (name "ruby-hashery")
cba96208 6011 (version "2.1.2")
72ccbfe3
BW
6012 (source
6013 (origin
6014 (method url-fetch)
6015 (uri (rubygems-uri "hashery" version))
6016 (sha256
6017 (base32
cba96208 6018 "0qj8815bf7q6q7llm5rzdz279gzmpqmqqicxnzv066a020iwqffj"))))
72ccbfe3
BW
6019 (build-system ruby-build-system)
6020 (arguments
6021 `(#:phases
6022 (modify-phases %standard-phases
6023 (replace 'check
6024 (lambda _
9923d5a4
TGR
6025 (invoke "qed")
6026 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
72ccbfe3
BW
6027 (native-inputs
6028 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
6029 ("ruby-qed" ,ruby-qed)
6030 ("ruby-lemon" ,ruby-lemon)))
6031 (synopsis "Hash-like classes with extra features")
6032 (description
6033 "The Hashery is a tight collection of @code{Hash}-like classes.
6034Included are the auto-sorting @code{Dictionary} class, the efficient
6035@code{LRUHash}, the flexible @code{OpenHash} and the convenient
6036@code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
6037defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
6038standard @code{Hash} making it possible to subclass and augment to fit any
6039specific use case.")
2f3800e5 6040 (home-page "https://rubyworks.github.io/hashery")
72ccbfe3 6041 (license license:bsd-2)))
1f1d71e0
BW
6042
6043(define-public ruby-rc4
6044 (package
6045 (name "ruby-rc4")
6046 (version "0.1.5")
6047 (source
6048 (origin
6049 (method url-fetch)
6050 (uri (rubygems-uri "ruby-rc4" version))
6051 (sha256
6052 (base32
6053 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
6054 (build-system ruby-build-system)
6055 (arguments
6056 `(#:phases
6057 (modify-phases %standard-phases
6058 (replace 'check
6059 (lambda _
9923d5a4 6060 (invoke "rspec" "spec/rc4_spec.rb"))))))
1f1d71e0
BW
6061 (native-inputs
6062 `(("ruby-rspec" ,ruby-rspec-2)))
6063 (synopsis "Implementation of the RC4 algorithm")
6064 (description
6065 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
6066 (home-page "https://github.com/caiges/Ruby-RC4")
6067 (license license:expat)))
f3e085a8
BW
6068
6069(define-public ruby-afm
6070 (package
6071 (name "ruby-afm")
6072 (version "0.2.2")
6073 (source
6074 (origin
6075 (method url-fetch)
6076 (uri (rubygems-uri "afm" version))
6077 (sha256
6078 (base32
6079 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
6080 (build-system ruby-build-system)
6081 (native-inputs
6082 `(("bundler" ,bundler)))
6083 (synopsis "Read Adobe Font Metrics (afm) files")
6084 (description
6085 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
6086files and use the data therein.")
7bf837fd 6087 (home-page "https://github.com/halfbyte/afm")
f3e085a8 6088 (license license:expat)))
acb6be42
BW
6089
6090(define-public ruby-ascii85
6091 (package
6092 (name "ruby-ascii85")
5854082a 6093 (version "1.0.3")
acb6be42
BW
6094 (source
6095 (origin
6096 (method url-fetch)
6097 (uri (rubygems-uri "Ascii85" version))
6098 (sha256
6099 (base32
5854082a 6100 "0658m37jjjn6drzqg1gk4p6c205mgp7g1jh2d00n4ngghgmz5qvs"))))
acb6be42
BW
6101 (build-system ruby-build-system)
6102 (native-inputs
6103 `(("bundler" ,bundler)))
6104 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
6105 (description
6106 "This library provides methods to encode and decode Ascii85
6107binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
6108@dfn{Portable Document Format} (PDF) file formats.")
6109 (home-page "https://github.com/datawraith/ascii85gem")
6110 (license license:expat)))
edf8caae
BW
6111
6112(define-public ruby-ttfunk
6113 (package
6114 (name "ruby-ttfunk")
afb7a3e8 6115 (version "1.5.1")
edf8caae
BW
6116 (source
6117 (origin
6118 (method url-fetch)
6119 ;; fetch from github as the gem does not contain testing code
6120 (uri (string-append
6121 "https://github.com/prawnpdf/ttfunk/archive/"
6122 version ".tar.gz"))
6123 (file-name (string-append name "-" version ".tar.gz"))
6124 (sha256
6125 (base32
afb7a3e8 6126 "1ymcn12n5iws401yz03zsj8rr653fdqq13czsrciq09phgh9jzc5"))))
edf8caae
BW
6127 (build-system ruby-build-system)
6128 (arguments
6129 `(#:test-target "spec"
6130 #:phases
6131 (modify-phases %standard-phases
afb7a3e8
JL
6132 (add-before 'build 'remove-ssh
6133 (lambda _
6134 ;; remove dependency on an ssh key pair that doesn't exist
6135 (substitute* "ttfunk.gemspec"
6136 (("spec.signing_key.*") ""))
6137 #t))
edf8caae
BW
6138 (add-before 'check 'remove-rubocop
6139 (lambda _
6140 ;; remove rubocop as a dependency as not needed for testing
6141 (substitute* "ttfunk.gemspec"
6142 (("spec.add_development_dependency\\('rubocop'.*") ""))
6143 (substitute* "Rakefile"
6144 (("require 'rubocop/rake_task'") "")
afb7a3e8 6145 (("RuboCop::RakeTask.new") ""))
edf8caae
BW
6146 #t)))))
6147 (native-inputs
6148 `(("ruby-rspec" ,ruby-rspec)
afb7a3e8 6149 ("ruby-yard" ,ruby-yard)
edf8caae
BW
6150 ("bundler" ,bundler)))
6151 (synopsis "Font metrics parser for the Prawn PDF generator")
6152 (description
6153 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
6154part of the Prawn PDF generator.")
6155 (home-page "https://github.com/prawnpdf/ttfunk")
6156 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
6157 ;; for details."
6158 (license (list license:gpl2 license:gpl3 license:ruby))))
cbdd428c 6159
9270298f
BW
6160(define-public ruby-puma
6161 (package
6162 (name "ruby-puma")
63755fcd 6163 (version "3.9.1")
9270298f
BW
6164 (source
6165 (origin
6166 (method url-fetch)
6167 ;; Fetch from GitHub because distributed gem does not contain tests.
6168 (uri (string-append "https://github.com/puma/puma/archive/v"
6169 version ".tar.gz"))
6170 (file-name (string-append name "-" version ".tar.gz"))
6171 (sha256
6172 (base32
63755fcd 6173 "03pifga841h17brh4vgia8i2ybh3cmsyg0dbybzdf6dq51wzcxdx"))))
9270298f
BW
6174 (build-system ruby-build-system)
6175 (arguments
63755fcd
BW
6176 `(#:tests? #f ; Tests require an out-dated version of minitest.
6177 #:phases
9270298f
BW
6178 (modify-phases %standard-phases
6179 (add-before 'build 'fix-gemspec
6180 (lambda _
6181 (substitute* "puma.gemspec"
6182 (("git ls-files") "find * |sort"))
6183 #t)))))
9270298f
BW
6184 (synopsis "Simple, concurrent HTTP server for Ruby/Rack")
6185 (description
6186 "Puma is a simple, fast, threaded, and highly concurrent HTTP 1.1 server
6187for Ruby/Rack applications. Puma is intended for use in both development and
6188production environments. In order to get the best throughput, it is highly
6189recommended that you use a Ruby implementation with real threads like Rubinius
6190or JRuby.")
6191 (home-page "http://puma.io")
6192 (license license:expat)))
6193
b0813490
BW
6194(define-public ruby-hoe-git
6195 (package
6196 (name "ruby-hoe-git")
6197 (version "1.6.0")
6198 (source
6199 (origin
6200 (method url-fetch)
6201 (uri (rubygems-uri "hoe-git" version))
6202 (sha256
6203 (base32
6204 "10jmmbjm0lkglwxbn4rpqghgg1ipjxrswm117n50adhmy8yij650"))))
6205 (build-system ruby-build-system)
6206 (propagated-inputs
6207 `(("ruby-hoe" ,ruby-hoe)
6208 ("git" ,git)))
6209 (synopsis "Hoe plugins for tighter Git integration")
6210 (description
6211 "This package provides a set of Hoe plugins for tighter Git integration.
6212It provides tasks to automate release tagging and pushing and changelog
6213generation.")
7bf837fd 6214 (home-page "https://github.com/jbarnette/hoe-git")
b0813490
BW
6215 (license license:expat)))
6216
cbdd428c
BW
6217(define-public ruby-sequel
6218 (package
6219 (name "ruby-sequel")
65a7f09c 6220 (version "4.49.0")
cbdd428c
BW
6221 (source
6222 (origin
6223 (method url-fetch)
6224 (uri (rubygems-uri "sequel" version))
6225 (sha256
6226 (base32
65a7f09c 6227 "010p4a60npppvgbyw7pq5xia8aydpgxdlhh3qjm2615kwjsw3fl8"))))
cbdd428c
BW
6228 (build-system ruby-build-system)
6229 (arguments
6230 '(#:tests? #f)) ; Avoid dependency loop with ruby-minitest-hooks.
6231 (synopsis "Database toolkit for Ruby")
6232 (description "Sequel provides thread safety, connection pooling and a
6233concise DSL for constructing SQL queries and table schemas. It includes a
6234comprehensive ORM layer for mapping records to Ruby objects and handling
6235associated records.")
6236 (home-page "http://sequel.jeremyevans.net")
6237 (license license:expat)))
3cc78097
BW
6238
6239(define-public ruby-timecop
6240 (package
6241 (name "ruby-timecop")
3d4a5eb5 6242 (version "0.9.1")
3cc78097
BW
6243 (source
6244 (origin
6245 (method url-fetch)
6246 (uri (rubygems-uri "timecop" version))
6247 (sha256
6248 (base32
3d4a5eb5 6249 "0d7mm786180v4kzvn1f77rhfppsg5n0sq2bdx63x9nv114zm8jrp"))))
3cc78097
BW
6250 (build-system ruby-build-system)
6251 (arguments
6252 `(#:phases
6253 (modify-phases %standard-phases
6254 (add-before 'check 'set-check-rubylib
6255 (lambda _
6256 ;; Set RUBYLIB so timecop tests finds its own lib.
6257 (setenv "RUBYLIB" "lib")
6258 #t)))))
6259 (native-inputs
6260 `(("bundler" ,bundler)
6261 ("ruby-minitest-rg" ,ruby-minitest-rg)
6262 ("ruby-mocha" ,ruby-mocha)
6263 ("ruby-activesupport" ,ruby-activesupport)))
66e07664 6264 (synopsis "Test mocks for time-dependent functions")
3cc78097
BW
6265 (description
6266 "Timecop provides \"time travel\" and \"time freezing\" capabilities,
6267making it easier to test time-dependent code. It provides a unified method to
6268mock @code{Time.now}, @code{Date.today}, and @code{DateTime.now} in a single
6269call.")
6270 (home-page "https://github.com/travisjeffery/timecop")
6271 (license license:expat)))
6272
dae620b8
BW
6273(define-public ruby-concurrent
6274 (package
6275 (name "ruby-concurrent")
21aecec1 6276 (version "1.0.5")
dae620b8
BW
6277 (source
6278 (origin
6279 (method url-fetch)
6280 ;; Download from GitHub because the rubygems version does not contain
6281 ;; Rakefile.
6282 (uri (string-append
6283 "https://github.com/ruby-concurrency/concurrent-ruby/archive/v"
6284 version
6285 ".tar.gz"))
6286 (file-name (string-append name "-" version ".tar.gz"))
6287 (sha256
6288 (base32
21aecec1 6289 "0qhv0qzsby4iijgwa4s9r88zj8123pmyz1dwaqzdk57xgqll9pny"))
dae620b8
BW
6290 ;; Exclude failing test reported at
6291 ;; https://github.com/ruby-concurrency/concurrent-ruby/issues/534
402b03e6
LC
6292 (patches (search-patches "ruby-concurrent-ignore-broken-test.patch"
6293 "ruby-concurrent-test-arm.patch"))))
dae620b8
BW
6294 (build-system ruby-build-system)
6295 (arguments
6296 `(#:test-target "spec"
6297 #:phases
6298 (modify-phases %standard-phases
520e89eb 6299 (add-before 'replace-git-ls-files 'remove-extra-gemspecs
dae620b8
BW
6300 (lambda _
6301 ;; Delete extra gemspec files so 'first-gemspec' chooses the
6302 ;; correct one.
6303 (delete-file "concurrent-ruby-edge.gemspec")
6304 (delete-file "concurrent-ruby-ext.gemspec")
6305 #t))
520e89eb
BW
6306 (add-before 'build 'replace-git-ls-files2
6307 (lambda _
6308 (substitute* "support/file_map.rb"
6309 (("git ls-files") "find * |sort"))
6310 #t))
dae620b8
BW
6311 (add-before 'check 'rake-compile
6312 ;; Fix the test error described at
6313 ;; https://github.com/ruby-concurrency/concurrent-ruby/pull/408
9923d5a4 6314 (lambda _ (invoke "rake" "compile")))
9019b37f
BW
6315 (add-before 'check 'remove-timecop-dependency
6316 ;; Remove timecop-dependent tests as having timecop as a depedency
6317 ;; causes circular depedencies.
6318 (lambda _
6319 (delete-file "spec/concurrent/executor/timer_set_spec.rb")
6320 (delete-file "spec/concurrent/scheduled_task_spec.rb")
6321 #t)))))
dae620b8
BW
6322 (native-inputs
6323 `(("ruby-rake-compiler" ,ruby-rake-compiler)
9019b37f 6324 ("ruby-rspec" ,ruby-rspec)))
dae620b8
BW
6325 (synopsis "Concurrency tools for Ruby")
6326 (description
6327 "This library provides modern concurrency tools including agents,
6328futures, promises, thread pools, actors, supervisors, and more. It is
6329inspired by Erlang, Clojure, Go, JavaScript, actors and classic concurrency
6330patterns.")
6331 (home-page "http://www.concurrent-ruby.com")
6332 (license license:expat)))
2de61e34
BW
6333
6334(define-public ruby-pkg-config
6335 (package
6336 (name "ruby-pkg-config")
884a80dd 6337 (version "1.2.5")
2de61e34
BW
6338 (source
6339 (origin
6340 (method url-fetch)
6341 (uri (rubygems-uri "pkg-config" version))
6342 (sha256
6343 (base32
884a80dd 6344 "056mzqdh4yjznsg36fi0xiq76f24vxlhzh2n4az919l3x5k318ar"))))
2de61e34
BW
6345 (build-system ruby-build-system)
6346 (arguments
6347 ;; Tests require extra files not included in the gem.
6348 `(#:tests? #f))
6349 (synopsis "Detect libraries for compiling Ruby native extensions")
6350 (description
6351 "@code{pkg-config} can be used in your extconf.rb to properly detect need
6352libraries for compiling Ruby native extensions.")
6353 (home-page "https://github.com/ruby-gnome2/pkg-config")
6354 (license license:lgpl2.0+)))
6689c636
MFM
6355
6356(define-public ruby-net-http-digest-auth
6357 (package
6358 (name "ruby-net-http-digest-auth")
ba074a85 6359 (version "1.4.1")
6689c636
MFM
6360 (source
6361 (origin
6362 (method url-fetch)
6363 (uri (rubygems-uri "net-http-digest_auth" version))
6364 (sha256
6365 (base32
ba074a85 6366 "1nq859b0gh2vjhvl1qh1zrk09pc7p54r9i6nnn6sb06iv07db2jb"))))
6689c636
MFM
6367 (build-system ruby-build-system)
6368 (native-inputs
6369 `(("ruby-hoe" ,ruby-hoe)))
6370 (synopsis "RFC 2617 HTTP digest authentication library")
6371 (description
6372 "This library implements HTTP's digest authentication scheme based on
6373RFC 2617. This enables the use of the digest authentication scheme instead
6374of the more insecure basic authentication scheme.")
7bf837fd 6375 (home-page "https://github.com/drbrain/net-http-digest_auth")
6689c636 6376 (license license:expat)))
06116573 6377
6378(define-public ruby-mail
6379 (package
6380 (name "ruby-mail")
04de0cb5 6381 (version "2.6.6")
06116573 6382 (source
6383 (origin
6384 (method url-fetch)
6385 (uri (rubygems-uri "mail" version))
6386 (sha256
6387 (base32
04de0cb5 6388 "0d7lhj2dw52ycls6xigkfz6zvfhc6qggply9iycjmcyj9760yvz9"))))
06116573 6389 (build-system ruby-build-system)
6390 (propagated-inputs
6391 `(("ruby-mime-types" ,ruby-mime-types)))
6392 (arguments
6393 ;; Tests require extra gems not included in the Gemfile.
6394 ;; XXX: Try enabling this for the next version with mini_mime.
6395 `(#:tests? #f))
6396 (synopsis "Mail library for Ruby")
6397 (description
6398 "Mail is an internet library for Ruby that is designed to handle email
6399generation, parsing and sending. The purpose of this library is to provide
6400a single point of access to handle all email functions, including sending
6401and receiving emails. All network type actions are done through proxy
6402methods to @code{Net::SMTP}, @code{Net::POP3} etc.
6403
6404Mail has been designed with a very simple object oriented system that
6405really opens up the email messages you are parsing, if you know what you
6406are doing, you can fiddle with every last bit of your email directly.")
6407 (home-page "https://github.com/mikel/mail")
6408 (license license:expat)))
9b4c8e1b 6409
4d372cb9
CB
6410(define-public ruby-mathn
6411 (package
6412 (name "ruby-mathn")
6413 (version "0.1.0")
6414 (source
6415 (origin
6416 (method url-fetch)
6417 (uri (rubygems-uri "mathn" version))
6418 (sha256
6419 (base32
6420 "1wn812llln9jzgybz2d7536q39z3gi99i6fi0j1dapcpzvhgrr0p"))))
6421 (build-system ruby-build-system)
6422 (native-inputs
6423 `(("bundler" ,bundler)
6424 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6425 (synopsis "Extends math operations for increased precision")
6426 (description
6427 "This gem makes mathematical operations more precise in Ruby and
6428integrates other mathematical standard libraries. Prior to Ruby 2.5,
6429@code{mathn} was part of the Ruby standard library.")
6430 (home-page "https://github.com/ruby/mathn")
6431 (license license:bsd-2)))
6432
9b4c8e1b
BW
6433(define-public ruby-code-statistics
6434 (package
6435 (name "ruby-code-statistics")
6436 (version "0.2.13")
6437 (source
6438 (origin
6439 (method url-fetch)
6440 (uri (rubygems-uri "code_statistics" version))
6441 (sha256
6442 (base32
6443 "07rdpsbwbmh4vp8nxyh308cj7am2pbrfhv9v5xr2d5gq8hnnsm93"))))
6444 (build-system ruby-build-system)
6445 (arguments
6446 `(#:tests? #f)) ; Not all test code is included in gem.
6447 (synopsis "Port of the rails 'rake stats' method")
6448 (description
6449 "This gem is a port of the rails 'rake stats' method so it can be made
6450more robust and work for non rails projects.")
6451 (home-page "http://github.com/danmayer/code_statistics")
6452 (license license:expat)))
f90c25c1
CL
6453
6454(define-public ruby-rubypants
6455 (package
6456 (name "ruby-rubypants")
6457 (version "0.6.0")
6458 (source (origin
6459 (method url-fetch)
6460 (uri (rubygems-uri "rubypants" version))
6461 (sha256
6462 (base32
6463 "0xpqkslan2wkyal2h9qhplkr5d4sdn7q6csigrhnljjpp8j4qfsh"))))
6464 (build-system ruby-build-system)
6465 (arguments
6466 '(#:tests? #f)) ; need Codecov
6467 (synopsis "Port of the smart-quotes library SmartyPants")
6468 (description
6469 "RubyPants is a Ruby port of the smart-quotes library SmartyPants. The
6470original SmartyPants is a web publishing plug-in for Movable Type, Blosxom,
6471and BBEdit that easily translates plain ASCII punctuation characters into
6472smart typographic punctuation HTML entities.")
6473 (home-page "https://github.com/jmcnevin/rubypants")
6474 (license license:bsd-2)))
beb34835
CL
6475
6476(define-public ruby-org-ruby
6477 (package
6478 (name "ruby-org-ruby")
6479 (version "0.9.12")
6480 (source (origin
6481 (method url-fetch)
6482 (uri (rubygems-uri "org-ruby" version))
6483 (sha256
6484 (base32
6485 "0x69s7aysfiwlcpd9hkvksfyld34d8kxr62adb59vjvh8hxfrjwk"))))
6486 (build-system ruby-build-system)
6487 (arguments
6488 '(#:tests? #f)) ; no rakefile
6489 (propagated-inputs
6490 `(("ruby-rubypants" ,ruby-rubypants)))
6491 (synopsis "Org-mode parser written in Ruby")
6492 (description
6493 "Org-ruby is an org-mode parser written in Ruby. The most significant
6494thing this library does today is convert org-mode files to HTML or Textile or
6495Markdown.")
6496 (home-page "https://github.com/wallyqs/org-ruby")
6497 (license license:expat)))
670ee20a
BW
6498
6499(define-public ruby-rake
6500 (package
6501 (name "ruby-rake")
d6fb32b8 6502 (version "12.3.1")
670ee20a
BW
6503 (source
6504 (origin
6505 (method url-fetch)
6506 (uri (rubygems-uri "rake" version))
6507 (sha256
6508 (base32
d6fb32b8 6509 "1idi53jay34ba9j68c3mfr9wwkg3cd9qh0fn9cg42hv72c6q8dyg"))))
670ee20a
BW
6510 (build-system ruby-build-system)
6511 (native-inputs
6512 `(("bundler" ,bundler)))
6513 (synopsis "Rake is a Make-like program implemented in Ruby")
6514 (description
6515 "Rake is a Make-like program where tasks and dependencies are specified
6516in standard Ruby syntax.")
6517 (home-page "https://github.com/ruby/rake")
6518 (license license:expat)))
45498f51 6519
1f10e28d 6520(define-public ruby-childprocess-0.6
45498f51
DM
6521 (package
6522 (name "ruby-childprocess")
1f10e28d 6523 (version "0.6.3")
45498f51
DM
6524 (source
6525 (origin
6526 (method url-fetch)
6527 (uri (rubygems-uri "childprocess" version))
6528 (sha256
6529 (base32
1f10e28d 6530 "1p3f43scdzx9zxmy2kw5zsc3az6v46nq4brwcxmnscjy4w4racbv"))))
45498f51
DM
6531 (build-system ruby-build-system)
6532 (arguments
6533 `(#:tests? #f))
6534 (native-inputs
6535 `(("bundler" ,bundler)
6536 ("ruby-rspec" ,ruby-rspec)))
6537 (propagated-inputs
6538 `(("ruby-ffi" ,ruby-ffi)))
6539 (synopsis "Control external programs running in the background, in Ruby")
6540 (description "@code{childprocess} provides a gem to control external
6541programs running in the background, in Ruby.")
6542 (home-page "http://github.com/enkessler/childprocess")
6543 (license license:expat)))
1f10e28d
DM
6544
6545(define-public ruby-childprocess
6546 (package
6547 (inherit ruby-childprocess-0.6)
6548 (name "ruby-childprocess")
6549 (version "0.9.0")
6550 (source
6551 (origin
6552 (method url-fetch)
6553 (uri (rubygems-uri "childprocess" version))
6554 (sha256
6555 (base32
6556 "0a61922kmvcxyj5l70fycapr87gz1dzzlkfpq85rfqk5vdh3d28p"))))))
0d16905b
JL
6557
6558(define-public ruby-public-suffix
6559 (package
6560 (name "ruby-public-suffix")
6561 (version "3.0.3")
6562 (source (origin
6563 (method url-fetch)
6564 (uri (rubygems-uri "public_suffix" version))
6565 (sha256
6566 (base32
6567 "08q64b5br692dd3v0a9wq9q5dvycc6kmiqmjbdxkxbfizggsvx6l"))))
6568 (build-system ruby-build-system)
6569 (arguments
1f4fc125
CB
6570 '(#:phases
6571 (modify-phases %standard-phases
6572 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
6573 ;; including it as an input can lead to circular dependencies.
6574 (add-after 'unpack 'remove-rubocop-from-Rakefile
6575 (lambda _
6576 (substitute* "Rakefile"
6577 (("require \"rubocop/rake\\_task\"") "")
6578 (("RuboCop::RakeTask\\.new") ""))
6579 #t)))))
6580 (native-inputs
6581 `(("bundler" ,bundler)
6582 ("ruby-yard" ,ruby-yard)
6583 ("ruby-mocha" ,ruby-mocha)
6584 ("ruby-minitest-reporters" ,ruby-minitest-reporters)))
0d16905b
JL
6585 (home-page "https://simonecarletti.com/code/publicsuffix-ruby/")
6586 (synopsis "Domain name parser")
6587 (description "The gem @code{public_suffix} is a domain name parser,
6588written in Ruby, and based on the @dfn{Public Suffix List}. A public suffix
6589is one under which Internet users can (or historically could) directly
6590register names. Some examples of public suffixes are @code{.com},
6591@code{.co.uk} and @code{pvt.k12.ma.us}. The Public Suffix List is a list of
6592all known public suffixes.")
6593 (license license:expat)))
6f2c4efb
JL
6594
6595(define-public ruby-addressable
6596 (package
6597 (name "ruby-addressable")
0a794b30 6598 (version "2.6.0")
6f2c4efb
JL
6599 (source (origin
6600 (method url-fetch)
6601 (uri (rubygems-uri "addressable" version))
6602 (sha256
6603 (base32
0a794b30 6604 "0bcm2hchn897xjhqj9zzsxf3n9xhddymj4lsclz508f4vw3av46l"))))
6f2c4efb 6605 (build-system ruby-build-system)
0a794b30
CB
6606 (arguments
6607 '(#:test-target "spec"
6608 #:phases
6609 (modify-phases %standard-phases
6610 (add-after 'unpack 'remove-unnecessary-dependencies-from-Gemfile
6611 (lambda _
6612 (substitute* "Gemfile"
6613 (("git: 'https://github.com/sporkmonger/rack-mount.git',") "")
6614 ((".*launchy.*") "")
6615 ((".*rake.*") "gem 'rake'\n")
6616 ((".*redcarpet.*") ""))
6617 #t))
6618 (add-before 'check 'delete-network-dependent-test
6619 (lambda _
6620 (delete-file "spec/addressable/net_http_compat_spec.rb")
6621 #t)))))
6622 (native-inputs
6623 `(("ruby-rspec" ,ruby-rspec)
6624 ("bundler" ,bundler)
6625 ("ruby-idn-ruby" ,ruby-idn-ruby)
6626 ("ruby-sporkmonger-rack-mount" ,ruby-sporkmonger-rack-mount)
6627 ("ruby-rspec-its", ruby-rspec-its)
6628 ("ruby-yard" ,ruby-yard)
6629 ("ruby-simplecov" ,ruby-simplecov)))
6f2c4efb
JL
6630 (propagated-inputs
6631 `(("ruby-public-suffix" ,ruby-public-suffix)))
6f2c4efb
JL
6632 (home-page "https://github.com/sporkmonger/addressable")
6633 (synopsis "Alternative URI implementation")
6634 (description "Addressable is a replacement for the URI implementation that
6635is part of Ruby's standard library. It more closely conforms to RFC 3986,
6636RFC 3987, and RFC 6570 (level 4), providing support for IRIs and URI templates.")
6637 (license license:asl2.0)))
9c7f15c0
JL
6638
6639(define-public ruby-colorator
6640 (package
6641 (name "ruby-colorator")
6642 (version "1.1.0")
6643 (source (origin
6644 (method url-fetch)
6645 (uri (rubygems-uri "colorator" version))
6646 (sha256
6647 (base32
6648 "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"))))
6649 (build-system ruby-build-system)
6650 (arguments
6651 ;; No test target
6652 `(#:tests? #f))
6653 (home-page "http://octopress.org/colorator/")
6654 (synopsis "Terminal color library")
6655 (description "Colorator is a Ruby gem that helps you colorize your text
6656for the terminal.")
6657 (license license:expat)))
78b9c291
JL
6658
6659(define-public ruby-command-line-reporter
6660 (package
6661 (name "ruby-command-line-reporter")
6662 (version "4.0.0")
6663 (source (origin
6664 (method url-fetch)
6665 (uri (rubygems-uri "command_line_reporter" version))
6666 (sha256
6667 (base32
6668 "1qma35xrb772whxwy1rs9bicb9d6lvz0s2dd2dnn4fr6zcbcxc0a"))))
6669 (build-system ruby-build-system)
6670 (arguments
6671 ;; No Rakefile
6672 `(#:tests? #f
6673 #:phases
6674 (modify-phases %standard-phases
6675 (add-before 'build 'fix-dependencies
6676 (lambda _
6677 (substitute* ".gemspec"
6678 ;; colored is unmaintained
6679 (("colored") "colorator")
6680 ;; colorator version
6681 (("= 1.2") "= 1.1"))
6682 #t)))))
6683 (propagated-inputs `(("ruby-colorator" ,ruby-colorator)))
6684 (home-page "https://github.com/wbailey/command_line_reporter")
6685 (synopsis "Report production while executing Ruby scripts")
6686 (description "This gem provides a DSL that makes it easy to write reports
6687of various types in ruby. It eliminates the need to litter your source with
6688puts statements, instead providing a more readable, expressive interface to
6689your application.")
6690 (license license:asl2.0)))
f22c0387
JL
6691
6692(define-public ruby-command-line-reporter-3
6693 (package
6694 (inherit ruby-command-line-reporter)
6695 (version "3.3.6")
6696 (source (origin
6697 (method url-fetch)
6698 (uri (rubygems-uri "command_line_reporter" version))
6699 (sha256
6700 (base32
6701 "1h39zqqxp3k4qk49ajpx0jps1vmvxgkh43mqkb6znk583bl0fv71"))))))
6bba8ecf
JL
6702
6703(define-public ruby-rdoc
6704 (package
6705 (name "ruby-rdoc")
6706 (version "6.0.4")
6707 (source
6708 (origin
6709 (method url-fetch)
6710 (uri (rubygems-uri "rdoc" version))
6711 (sha256
6712 (base32
6713 "0anv42cqcdc6g4n386mrva7mgav5i0c2ry3yzvzzc6z6hymkmcr7"))))
6714 (build-system ruby-build-system)
6715 (native-inputs
6716 `(("bundler" ,bundler)))
6717 (home-page "https://ruby.github.io/rdoc/")
6718 (synopsis "HTML and command-line documentation utility")
6719 (description "RDoc produces HTML and command-line documentation for Ruby
6720projects. RDoc includes the +rdoc+ and +ri+ tools for generating and displaying
6721documentation from the command-line.")
6722 (license license:gpl2+)))
18077ffc
JL
6723
6724(define-public ruby-sass-listen
6725 (package
6726 (name "ruby-sass-listen")
6727 (version "4.0.0")
6728 (source (origin
6729 (method url-fetch)
6730 (uri (rubygems-uri "sass-listen" version))
6731 (sha256
6732 (base32
6733 "0xw3q46cmahkgyldid5hwyiwacp590zj2vmswlll68ryvmvcp7df"))))
6734 (build-system ruby-build-system)
6735 (arguments
6736 ;; No test target
6737 `(#:tests? #f))
6738 (propagated-inputs
6739 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
6740 ("ruby-rb-inotify" ,ruby-rb-inotify)))
6741 (home-page "https://github.com/sass/listen")
6742 (synopsis "File modification notification library")
6743 (description "The Listen gem listens to file modifications and notifies you
6744about the changes.")
6745 (license license:expat)))
0c8eedc1
JL
6746
6747(define-public ruby-terminfo
6748 (package
6749 (name "ruby-terminfo")
6750 (version "0.1.1")
6751 (source
6752 (origin
6753 (method url-fetch)
6754 (uri (rubygems-uri "ruby-terminfo" version))
6755 (sha256
6756 (base32
6757 "0rl4ic5pzvrpgd42z0c1s2n3j39c9znksblxxvmhkzrc0ckyg2cm"))))
6758 (build-system ruby-build-system)
6759 (arguments
6760 `(#:test-target "test"
6761 ;; Rakefile requires old packages and would need modification to
6762 ;; work with current software.
6763 #:tests? #f))
6764 (inputs
6765 `(("ncurses" ,ncurses)))
6766 (native-inputs
6767 `(("ruby-rubygems-tasks" ,ruby-rubygems-tasks)
6768 ("ruby-rdoc" ,ruby-rdoc)))
6769 (home-page "http://www.a-k-r.org/ruby-terminfo/")
6770 (synopsis "Terminfo binding for Ruby")
6771 (description "Ruby-terminfo provides terminfo binding for Ruby.")
6772 (license license:bsd-3)))
ddc3a667
JL
6773
6774(define-public ruby-diffy
6775 (package
6776 (name "ruby-diffy")
6777 (version "3.2.1")
6778 (source
6779 (origin
6780 (method url-fetch)
6781 (uri (rubygems-uri "diffy" version))
6782 (sha256
6783 (base32
6784 "119imrkn01agwhx5raxhknsi331y5i4yda7r0ws0an6905ximzjg"))))
6785 (build-system ruby-build-system)
6786 (arguments
6787 ;; No tests
6788 `(#:tests? #f))
6789 (native-inputs
6790 `(("ruby-rspec" ,ruby-rspec)))
6791 (home-page "https://github.com/samg/diffy")
6792 (synopsis "Convenient diffing in ruby")
6793 (description "Diffy provides a convenient way to generate a diff from two
6794strings or files.")
6795 (license license:expat)))
6456beef
JL
6796
6797(define-public ruby-sass-spec
6798 (package
6799 (name "ruby-sass-spec")
6800 (version "3.5.4")
6801 (source (origin
6802 (method url-fetch)
6803 (uri (string-append "https://github.com/sass/sass-spec/archive/v"
6804 version ".tar.gz"))
6805 (file-name (string-append name "-" version ".tar.gz"))
6806 (sha256
6807 (base32
6808 "0nx8lp7c9qa58w489crgqa3c489xsyarn1a8h4np9mwwfqm1h3rr"))))
6809 (build-system ruby-build-system)
6810 (propagated-inputs
6811 `(("ruby-command-line-reporter-3" ,ruby-command-line-reporter-3)
6812 ("ruby-diffy" ,ruby-diffy)
6813 ("ruby-terminfo" ,ruby-terminfo)))
6814 (arguments
2c7cb711
CB
6815 `(;; This package contains tests for a sass implementation, and the to
6816 ;; avoid any circular dependencies, the tests are not run here
6817 #:tests? #f
6818 #:phases
6819 (modify-phases %standard-phases
6820 (add-after 'unpack 'patch-test
6821 (lambda _
6822 (delete-file "spec/values/colors/alpha_hex-3.5/error")
6823 (substitute* "spec/values/colors/alpha_hex-3.5/expected_output.css"
6824 (("string") "color")))))))
6456beef
JL
6825 (home-page "https://github.com/sass/sass-spec")
6826 (synopsis "Test suite for Sass")
6827 (description "Sass Spec is a test suite for Sass. Test cases are all in
6828the @file{spec} directory.")
6829 (license license:expat)))
f00f4492
JL
6830
6831(define-public ruby-sass
6832 (package
6833 (name "ruby-sass")
11ff2adc 6834 (version "3.6.0")
f00f4492
JL
6835 (source (origin
6836 (method url-fetch)
6837 (uri (rubygems-uri "sass" version))
6838 (sha256
6839 (base32
11ff2adc 6840 "18c6prbw9wl8bqhb2435pd9s0lzarl3g7xf8pmyla28zblvwxmyh"))))
f00f4492
JL
6841 (build-system ruby-build-system)
6842 (propagated-inputs
6843 `(("ruby-sass-listen" ,ruby-sass-listen)))
6844 (native-inputs
11ff2adc
CB
6845 `(("ruby-sass-spec" ,ruby-sass-spec)
6846 ("ruby-mathn" ,ruby-mathn)))
f00f4492
JL
6847 (home-page "http://sass-lang.com/")
6848 (synopsis "CSS extension language")
6849 (description "Sass is a CSS extension language. It extends CSS with
6850features that don't exist yet like variables, nesting, mixins and inheritance.")
6851 (license license:expat)))
5e242cb4
JL
6852
6853(define-public ruby-jekyll-sass-converter
6854 (package
6855 (name "ruby-jekyll-sass-converter")
6856 (version "1.5.2")
6857 (source (origin
6858 (method url-fetch)
6859 (uri (rubygems-uri "jekyll-sass-converter" version))
6860 (sha256
6861 (base32
6862 "008ikh5fk0n6ri54mylcl8jn0mq8p2nfyfqif2q3pp0lwilkcxsk"))))
6863 (build-system ruby-build-system)
6864 (propagated-inputs
6865 `(("ruby-sass" ,ruby-sass)))
6866 (arguments
6867 ;; No rakefile
6868 `(#:tests? #f))
6869 (home-page "https://github.com/jekyll/jekyll-sass-converter")
6870 (synopsis "Sass converter for Jekyll")
6871 (description "This gem provide built-in support for the Sass converter
6872in Jekyll.")
6873 (license license:expat)))
ceac6f6f
JL
6874
6875(define-public ruby-jekyll-watch
6876 (package
6877 (name "ruby-jekyll-watch")
6878 (version "2.0.0")
6879 (source (origin
6880 (method url-fetch)
6881 (uri (rubygems-uri "jekyll-watch" version))
6882 (sha256
6883 (base32
6884 "0m7scvj3ki8bmyx5v8pzibpg6my10nycnc28lip98dskf8iakprp"))))
6885 (build-system ruby-build-system)
6886 (propagated-inputs
6887 `(("ruby-listen-3.0" ,ruby-listen-3.0)))
6888 (arguments
6889 ;; No rakefile
6890 `(#:tests? #f))
6891 (home-page "https://github.com/jekyll/jekyll-watch")
6892 (synopsis "Jekyll auto-rebuild support")
6893 (description "This gems add the @code{--watch} switch to the jekyll CLI
6894interface. It allows Jekyll to rebuild your site when a file changes.")
6895 (license license:expat)))
3224a5a8
JL
6896
6897(define-public ruby-parallel
6898 (package
6899 (name "ruby-parallel")
c41fba01
CB
6900 (version "1.13.0")
6901 (source
6902 (origin
6903 (method git-fetch)
6904 (uri (git-reference
6905 (url "https://github.com/grosser/parallel.git")
6906 (commit (string-append "v" version))))
6907 (file-name (git-file-name name version))
6908 (sha256
6909 (base32
6910 "1isqzbqxz2ndad4i5z3lb9ldrhaijfncj8bmffv04sq44sv87ikv"))))
3224a5a8 6911 (build-system ruby-build-system)
c41fba01
CB
6912 (arguments
6913 `(;; TODO 3 test failures
6914 ;; rspec ./spec/parallel_spec.rb:190 # Parallel.in_processes does not
6915 ;; open unnecessary pipes
6916 ;; rspec './spec/parallel_spec.rb[1:9:7]' # Parallel.each works with
6917 ;; SQLite in processes
6918 ;; rspec './spec/parallel_spec.rb[1:9:16]' # Parallel.each works with
6919 ;; SQLite in threads
6920 #:tests? #f
6921 #:test-target "rspec-rerun:spec"
6922 #:phases
6923 (modify-phases %standard-phases
6924 (add-after 'unpack 'patch-Gemfile
6925 (lambda _
6926 (substitute* "Gemfile"
6927 (("gem 'rspec-legacy_formatters'") "")
6928 (("gem 'activerecord.*$") "gem 'activerecord'\n"))))
6929 (add-before 'check 'delete-Gemfile.lock
6930 (lambda _
6931 ;; Bundler isn't being used for fetching dependendencies, so
6932 ;; delete the Gemfile.lock
6933 (delete-file "Gemfile.lock")
6934 #t))
6935 (add-before 'build 'patch-gemspec
6936 (lambda _
6937 (substitute* "parallel.gemspec"
6938 (("git ls-files") "find"))
6939 #t)))))
6940 (native-inputs
6941 `(("ruby-rspec" ,ruby-rspec)
6942 ("ruby-rspec-rerun" ,ruby-rspec-rerun)
6943 ("bundler" ,bundler)
6944 ("ruby-activerecord" ,ruby-activerecord)
6945 ("ruby-progressbar" ,ruby-progressbar)
6946 ("ruby-bump" ,ruby-bump)
6947 ("procps" ,procps)
6948 ("lsof" ,lsof)
6949 ("ruby-mysql2" ,ruby-mysql2)
6950 ("ruby-sqlite3" ,ruby-sqlite3)
6951 ("ruby-i18n" ,ruby-i18n)))
3224a5a8
JL
6952 (home-page "https://github.com/grosser/parallel")
6953 (synopsis "Parallel processing in Ruby")
6954 (description "Parallel allows you to run any code in parallel Processes
6955(to use all CPUs) or Threads(to speedup blocking operations). It is best
6956suited for map-reduce or e.g. parallel downloads/uploads.")
6957 (license license:expat)))
83d9f672
JL
6958
6959(define-public ruby-cane
6960 (package
6961 (name "ruby-cane")
6962 (version "3.0.0")
6963 (source (origin
6964 (method url-fetch)
6965 (uri (rubygems-uri "cane" version))
6966 (sha256
6967 (base32
6968 "0yf5za3l7lhrqa3g56sah73wh33lbxy5y3cb7ij0a2bp1b4kwhih"))))
6969 (build-system ruby-build-system)
6970 (arguments `(#:tests? #f)); No rakefile
6971 (home-page "https://github.com/square/cane")
6972 (propagated-inputs
6973 `(("ruby-parallel" ,ruby-parallel)))
6974 (synopsis "Code quality threshold checking")
6975 (description "Cane fails your build if code quality thresholds are not met.")
6976 (license license:asl2.0)))
00d71efc
JL
6977
6978(define-public ruby-morecane
6979 (package
6980 (name "ruby-morecane")
6981 (version "0.2.0")
6982 (source (origin
6983 (method url-fetch)
6984 (uri (rubygems-uri "morecane" version))
6985 (sha256
6986 (base32
6987 "0w70vb8z5bdhvr21h660aa43m5948pv0bd27z7ngai2iwdvqd771"))))
6988 (build-system ruby-build-system)
6989 (home-page "https://github.com/yob/morecane")
6990 (arguments `(#:tests? #f)); No rakefile
6991 (propagated-inputs
6992 `(("ruby-parallel" ,ruby-parallel)))
6993 (synopsis "Extra checks for cane")
6994 (description "The cane gem provides a great framework for running quality
6995checks over your ruby project as part of continuous integration build. It
6996comes with a few checks out of the box, but also provides an API for loading
6997custom checks. This gem provides a set of additional checks.")
6998 (license license:expat)))
abbe629c
JL
6999
7000(define-public ruby-pdf-reader
7001 (package
7002 (name "ruby-pdf-reader")
7003 (version "2.1.0")
7004 (source (origin
7005 (method url-fetch)
7006 (uri (rubygems-uri "pdf-reader" version))
7007 (sha256
7008 (base32
7009 "1b3ig4wpcgdbqa7yw0ahwbmikkkywn2a22bfmrknl5ls7g066x45"))))
7010 (build-system ruby-build-system)
7011 (arguments `(#:test-target "spec"))
7012 (native-inputs
7013 `(("bundler" ,bundler)
7014 ("ruby-rspec" ,ruby-rspec)
7015 ("ruby-cane" ,ruby-cane)
7016 ("ruby-morecane" ,ruby-morecane)))
7017 (propagated-inputs
7018 `(("ruby-afm" ,ruby-afm)
7019 ("ruby-ascii85" ,ruby-ascii85)
7020 ("ruby-hashery" ,ruby-hashery)
7021 ("ruby-rc4" ,ruby-rc4)
7022 ("ruby-ttfunk" ,ruby-ttfunk)))
7023 (home-page "https://github.com/yob/pdf-reader")
7024 (synopsis "PDF parser in Ruby")
7025 (description "The PDF::Reader library implements a PDF parser conforming as
7026much as possible to the PDF specification from Adobe. It provides programmatic
7027access to the contents of a PDF file with a high degree of flexibility.")
7028 (license license:gpl3+)))
461fb859
JL
7029
7030(define-public ruby-pdf-inspector
7031 (package
7032 (name "ruby-pdf-inspector")
7033 (version "1.3.0")
7034 (source (origin
7035 (method url-fetch)
7036 (uri (rubygems-uri "pdf-inspector" version))
7037 (sha256
7038 (base32
7039 "1g853az4xzgqxr5xiwhb76g4sqmjg4s79mm35mp676zjsrwpa47w"))))
7040 (build-system ruby-build-system)
7041 (propagated-inputs
7042 `(("ruby-pdf-reader" ,ruby-pdf-reader)))
7043 (arguments `(#:tests? #f)); No rakefile
7044 (home-page "https://github.com/prawnpdf/pdf-inspector")
7045 (synopsis "Analysis classes for inspecting PDF output")
7046 (description "This library provides a number of PDF::Reader based tools for
7047use in testing PDF output. Presently, the primary purpose of this tool is to
7048support the tests found in Prawn, a pure Ruby PDF generation library.")
7049 (license license:gpl3+)))
770e3b53
JL
7050
7051(define-public ruby-pdf-core
7052 (package
7053 (name "ruby-pdf-core")
7054 (version "0.8.1")
7055 (source (origin
7056 (method url-fetch)
7057 (uri (rubygems-uri "pdf-core" version))
7058 (sha256
7059 (base32
7060 "15d6m99bc8bbzlkcg13qfpjjzphfg5x905pjbfygvpcxsm8gnsvg"))))
7061 (build-system ruby-build-system)
7062 (arguments
7063 ; No test target
7064 `(#:tests? #f))
7065 (home-page "https://github.com/prawnpdf/pdf-core")
7066 (synopsis "Low level PDF features for Prawn")
7067 (description "This is an experimental gem that extracts low-level PDF
7068functionality from Prawn.")
7069 (license license:gpl3+)))
37fbced7 7070
7ad8dd08
JL
7071(define-public ruby-prawn
7072 (package
7073 (name "ruby-prawn")
7074 (version "2.2.2")
7075 (source (origin
7076 (method url-fetch)
7077 (uri (rubygems-uri "prawn" version))
7078 (sha256
7079 (base32
7080 "1qdjf1v6sfl44g3rqxlg8k4jrzkwaxgvh2l4xws97a8f3xv4na4m"))))
7081 (build-system ruby-build-system)
7082 (arguments
7083 ; No tests
7084 `(#:tests? #f
7085 #:phases
7086 (modify-phases %standard-phases
7087 (add-before 'build 'fix-dependencies
7088 (lambda _
7089 (substitute* "prawn.gemspec"
7090 (("~> 0.7.0") "~> 0.7"))
7091 #t)))))
7092 (propagated-inputs
7093 `(("ruby-pdf-core" ,ruby-pdf-core)
7094 ("ruby-ttfunk" ,ruby-ttfunk)))
7095 (native-inputs
7096 `(("bundler" ,bundler)
7097 ("ruby-pdf-inspector" ,ruby-pdf-inspector)
7098 ("ruby-rspec" ,ruby-rspec)
7099 ("ruby-simplecov" ,ruby-simplecov)
7100 ("ruby-yard" ,ruby-yard)))
7101 (home-page "http://prawnpdf.org/api-docs/2.0/")
7102 (synopsis "PDF generation for Ruby")
7103 (description "Prawn is a pure Ruby PDF generation library.")
7104 (license license:gpl3+)))
197ca8ec
JL
7105
7106(define-public ruby-prawn-table
7107 (package
7108 (name "ruby-prawn-table")
7109 (version "0.2.2")
7110 (source (origin
7111 (method url-fetch)
7112 (uri (rubygems-uri "prawn-table" version))
7113 (sha256
7114 (base32
7115 "1nxd6qmxqwl850icp18wjh5k0s3amxcajdrkjyzpfgq0kvilcv9k"))))
7116 (build-system ruby-build-system)
197ca8ec 7117 (propagated-inputs
0927b039
CB
7118 `(("ruby-prawn" ,ruby-prawn)
7119 ("ruby-pdf-inspector" ,ruby-pdf-inspector)))
7120 (native-inputs
7121 `(("bundler" ,bundler)
7122 ("ruby-yard" ,ruby-yard)
7123 ("ruby-mocha" ,ruby-mocha)
7124 ("ruby-coderay" ,ruby-coderay)
7125 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
7126 ("ruby-simplecov" ,ruby-simplecov)
7127 ("ruby-rspec-2" ,ruby-rspec-2)))
7128 (arguments
7129 '(;; TODO: 1 test fails
7130 ;; Failure/Error: pdf.page_count.should == 1
7131 ;; expected: 1
7132 ;; got: 2 (using ==)
7133 ;; # ./spec/table_spec.rb:1308
7134 ;;
7135 ;; 225 examples, 1 failure
7136 #:tests? #f
7137 #:phases
7138 (modify-phases %standard-phases
7139 (add-before 'check 'patch-gemspec
7140 (lambda _
7141 (substitute* "prawn-table.gemspec"
7142 ;; Loosen the requirement for pdf-inspector
7143 (("~> 1\\.1\\.0") ">= 0")
7144 ;; Loosen the requirement for pdf-reader
7145 (("~> 1\\.2") ">= 0"))))
7146 (replace 'check
7147 (lambda* (#:key tests? #:allow-other-keys)
7148 (when tests?
7149 (invoke "rspec"))
7150 #t)))))
197ca8ec
JL
7151 (home-page "https://github.com/prawnpdf/prawn-table")
7152 (synopsis "Tables support for Prawn")
7153 (description "This gem provides tables support for Prawn.")
7154 (license license:gpl3+)))
03127069
JL
7155
7156(define-public ruby-kramdown
7157 (package
7158 (name "ruby-kramdown")
7159 (version "1.17.0")
7160 (source (origin
7161 (method url-fetch)
7162 (uri (rubygems-uri "kramdown" version))
7163 (sha256
7164 (base32
7165 "1n1c4jmrh5ig8iv1rw81s4mw4xsp4v97hvf8zkigv4hn5h542qjq"))))
7166 (build-system ruby-build-system)
7167 (arguments `(#:tests? #f)); FIXME: some test failures
7168 (native-inputs
7169 `(("ruby-prawn" ,ruby-prawn)
7170 ("ruby-prawn-table" ,ruby-prawn-table)))
7171 (home-page "https://kramdown.gettalong.org/")
7172 (synopsis "Markdown parsing and converting library")
7173 (description "Kramdown is a library for parsing and converting a superset
7174of Markdown. It is completely written in Ruby, supports standard Markdown
7175(with some minor modifications) and various extensions that have been made
7176popular by the PHP @code{Markdown Extra} package and @code{Maruku}.")
7177 (license license:expat)))
fa0063bc
JL
7178
7179(define-public ruby-http-parser.rb
7180 (package
7181 (name "ruby-http-parser.rb")
7182 (version "0.6.0")
7183 (source
7184 (origin
7185 (method url-fetch)
7186 (uri (rubygems-uri "http_parser.rb" version))
7187 (sha256
7188 (base32
7189 "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"))))
7190 (build-system ruby-build-system)
7191 (arguments
7192 ;; No tests
7193 `(#:tests? #f))
7194 (native-inputs
7195 `(("ruby-rake-compiler" ,ruby-rake-compiler)
7196 ("ruby-rspec" ,ruby-rspec)))
7197 (home-page "https://github.com/tmm1/http_parser.rb")
7198 (synopsis "HTTP parser un Ruby")
7199 (description "This gem is a simple callback-based HTTP request/response
7200parser for writing http servers, clients and proxies.")
7201 (license license:expat)))
5e2f74bd
JL
7202
7203(define-public ruby-em-websocket
7204 (package
7205 (name "ruby-em-websocket")
7206 (version "0.5.1")
7207 (source
7208 (origin
7209 (method url-fetch)
7210 (uri (rubygems-uri "em-websocket" version))
7211 (sha256
7212 (base32
7213 "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"))))
7214 (build-system ruby-build-system)
7215 (arguments
7216 ;; No tests
7217 `(#:tests? #f))
7218 (propagated-inputs
7219 `(("ruby-eventmachine" ,ruby-eventmachine)
7220 ("ruby-http-parser.rb" ,ruby-http-parser.rb)))
7221 (native-inputs
7222 `(("bundler" ,bundler)
7223 ("ruby-rspec" ,ruby-rspec)))
7224 (home-page "https://github.com/igrigorik/em-websocket")
7225 (synopsis "EventMachine based WebSocket server")
7226 (description "Em-websocket is an EventMachine based WebSocket server
7227implementation.")
7228 (license license:expat)))
4ce0414b
JL
7229
7230(define-public ruby-rouge
7231 (package
7232 (name "ruby-rouge")
7233 (version "3.2.1")
7234 (source (origin
7235 (method url-fetch)
7236 (uri (rubygems-uri "rouge" version))
7237 (sha256
7238 (base32
7239 "0h79gn2wmn1wix2d27lgiaimccyj8gvizrllyym500pir408x62f"))))
7240 (build-system ruby-build-system)
7241 (arguments `(#:tests? #f)); No rakefile
7242 (home-page "http://rouge.jneen.net/")
7243 (synopsis "Code highlighter")
7244 (description "Rouge is a code highlighter written in Ruby. It supports more
7245than 100 languages and outputs HTML or ANSI 256-color text. Its HTML output
7246is compatible with stylesheets designed for pygments.")
7247 (license (list
7248 ;; rouge is licensed under expat
7249 license:expat
7250 ;; pygments is licensed under bsd-2
7251 license:bsd-2))))
2c5028bd
JL
7252
7253(define-public ruby-rouge-2
7254 (package
7255 (inherit ruby-rouge)
7256 (version "2.2.1")
7257 (source (origin
7258 (method url-fetch)
7259 (uri (rubygems-uri "rouge" version))
7260 (sha256
7261 (base32
7262 "02kpahk5nkc33yxnn75649kzxaz073wvazr2zyg491nndykgnvcs"))))))
2e072e37
JL
7263
7264(define-public ruby-hashie
7265 (package
7266 (name "ruby-hashie")
7267 (version "3.6.0")
7268 (source (origin
7269 (method url-fetch)
7270 (uri (rubygems-uri "hashie" version))
7271 (sha256
7272 (base32
7273 "13bdzfp25c8k51ayzxqkbzag3wj5gc1jd8h7d985nsq6pn57g5xh"))))
7274 (build-system ruby-build-system)
7275 (native-inputs
7276 `(("bundler" ,bundler)))
7277 (arguments `(#:tests? #f)); FIXME: Could not locate Gemfile or .bundle/ directory
7278 (home-page "https://github.com/intridea/hashie")
7279 (synopsis "Extensions to Ruby Hashes")
7280 (description "Hashie is a collection of classes and mixins that make Ruby
7281hashes more powerful.")
7282 (license license:expat)))
73bfc125
JL
7283
7284(define-public ruby-heredoc-unindent
7285 (package
7286 (name "ruby-heredoc-unindent")
7287 (version "1.2.0")
7288 (source (origin
7289 (method url-fetch)
7290 (uri (rubygems-uri "heredoc_unindent" version))
7291 (sha256
7292 (base32
7293 "14ijr2fsjwhrkjkcaz81d5xnfa4vvgvcflrff83avqw9klm011yw"))))
7294 (build-system ruby-build-system)
7295 (native-inputs
7296 `(("ruby-hoe" ,ruby-hoe)))
7297 (home-page "https://github.com/adrianomitre/heredoc_unindent")
7298 (synopsis "Heredoc indentation cleaner")
7299 (description "This gem removes common margin from indented strings, such
7300as the ones produced by indented heredocs. In other words, it strips out
4f66ae28 7301leading whitespace chars at the beginning of each line, but only as much as
73bfc125
JL
7302the line with the smallest margin.
7303
7304It is acknowledged that many strings defined by heredocs are just code and
7305fact is that most parsers are insensitive to indentation. If, however, the
7306strings are to be used otherwise, be it for printing or testing, the extra
7307indentation will probably be an issue and hence this gem.")
7308 (license license:expat)))
f8ae2ee5
JL
7309
7310(define-public ruby-safe-yaml
7311 (package
7312 (name "ruby-safe-yaml")
7313 (version "1.0.4")
28cf8dab
CB
7314 (source
7315 (origin
7316 ;; TODO Fetch from the git repository so a patch can be applied
7317 (method git-fetch)
7318 (uri (git-reference
7319 (url "https://github.com/dtao/safe_yaml.git")
7320 (commit version)))
7321 (file-name (git-file-name name version))
7322 (sha256
7323 (base32
7324 "1wnln8xdy8g6kwdj4amm8773xwffqxpf2sxslk6jjh2wxsy1lrig"))
7325 (patches
7326 (search-patches "ruby-safe-yaml-add-require-time.patch"))))
f8ae2ee5
JL
7327 (build-system ruby-build-system)
7328 (native-inputs
7329 `(("ruby-rspec" ,ruby-rspec)
7330 ("ruby-hashie" ,ruby-hashie)
7331 ("ruby-heredoc-unindent" ,ruby-heredoc-unindent)))
28cf8dab
CB
7332 (arguments
7333 '(#:test-target "spec"
7334 #:phases
7335 (modify-phases %standard-phases
7336 (add-before 'check 'set-TZ
7337 (lambda _
7338 ;; This test is dependent on the timezone
7339 ;; spec/transform/to_date_spec.rb:35
7340 ;; # SafeYAML::Transform::ToDate converts times to the local
7341 ;; timezone
7342 (setenv "TZ" "UTC-11")
7343 #t)))))
f8ae2ee5
JL
7344 (home-page "https://github.com/dtao/safe_yaml")
7345 (synopsis "YAML parser")
7346 (description "The SafeYAML gem provides an alternative implementation of
7347YAML.load suitable for accepting user input in Ruby applications.")
7348 (license license:expat)))
f1ec4d76
JL
7349
7350(define-public ruby-mercenary
7351 (package
7352 (name "ruby-mercenary")
7353 (version "0.3.6")
7354 (source (origin
7355 (method url-fetch)
7356 (uri (rubygems-uri "mercenary" version))
7357 (sha256
7358 (base32
7359 "10la0xw82dh5mqab8bl0dk21zld63cqxb1g16fk8cb39ylc4n21a"))))
7360 (build-system ruby-build-system)
7361 (arguments `(#:test-target "spec"))
7362 (native-inputs
7363 `(("bundler" ,bundler)))
7364 (home-page "https://github.com/jekyll/mercenary")
7365 (synopsis "Command-line apps library in Ruby")
7366 (description "Mercenary is a lightweight and flexible library for writing
7367command-line apps in Ruby.")
7368 (license license:expat)))
a13d451e
JL
7369
7370(define-public ruby-liquid
7371 (package
7372 (name "ruby-liquid")
7373 (version "4.0.0")
7374 (source (origin
7375 (method url-fetch)
7376 (uri (rubygems-uri "liquid" version))
7377 (sha256
7378 (base32
7379 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))
7380 (build-system ruby-build-system)
7381 (arguments `(#:tests? #f)); No rakefile
7382 (home-page "https://shopify.github.io/liquid/")
7383 (synopsis "Template language")
7384 (description "Liquid is a template language written in Ruby. It is used
7385to load dynamic content on storefronts.")
7386 (license license:expat)))
49395112
JL
7387
7388(define-public ruby-forwardable-extended
7389 (package
7390 (name "ruby-forwardable-extended")
7391 (version "2.6.0")
7392 (source (origin
7393 (method url-fetch)
7394 (uri (rubygems-uri "forwardable-extended" version))
7395 (sha256
7396 (base32
7397 "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"))))
7398 (build-system ruby-build-system)
7399 (arguments `(#:tests? #f)); Cyclic dependency on luna-rspec-formatters
7400 (home-page "https://github.com/envygeeks/forwardable-extended")
7401 (synopsis "Delegation to hashes and instance variables in Forwardable")
7402 (description "Forwardable Extended provides more @code{Forwardable}
7403methods for your source as @code{Forwardable::Extended}.")
7404 (license license:expat)))
37296113
JL
7405
7406(define-public ruby-pathutil
7407 (package
7408 (name "ruby-pathutil")
7409 (version "0.16.1")
7410 (source (origin
7411 (method url-fetch)
7412 (uri (rubygems-uri "pathutil" version))
7413 (sha256
7414 (base32
7415 "0wc18ms1rzi44lpjychyw2a96jcmgxqdvy2949r4vvb5f4p0lgvz"))))
7416 (build-system ruby-build-system)
7417 (propagated-inputs
7418 `(("ruby-forwardable-extended" ,ruby-forwardable-extended)))
7419 (native-inputs
7420 `(("bundler" ,bundler)
7421 ("ruby-rspec" ,ruby-rspec)))
7422 ;; Fails with: cannot load such file --
7423 ;; /tmp/guix-build-ruby-pathutil-0.16.0.drv-0/gem/benchmark/support/task
7424 (arguments `(#:tests? #f))
7425 (home-page "https://github.com/envygeeks/pathutil")
7426 (synopsis "Extended implementation of Pathname")
7427 (description "Pathutil tries to be a faster pure Ruby implementation of
7428Pathname.")
7429 (license license:expat)))
49e1dde5
JL
7430
7431(define-public jekyll
7432 (package
7433 (name "jekyll")
7434 (version "3.8.3")
7435 (source (origin
7436 (method url-fetch)
7437 (uri (rubygems-uri "jekyll" version))
7438 (sha256
7439 (base32
7440 "1iw90wihk9dscgmppf5v6lysg3kjmnx50mjyl4gghkdb4spw97xk"))))
7441 (build-system ruby-build-system)
7442 (arguments
7443 ;; No rakefile, but a test subdirectory
7444 `(#:tests? #f
7445 #:phases
7446 (modify-phases %standard-phases
7447 (add-before 'build 'fix-i18n
7448 (lambda _
7449 (substitute* ".gemspec"
7450 (("~> 0.7") ">= 0.7"))
7451 #t)))))
7452 (propagated-inputs
7453 `(("ruby-addressable" ,ruby-addressable)
7454 ("ruby-colorator" ,ruby-colorator)
7455 ("ruby-em-websocket" ,ruby-em-websocket)
7456 ("ruby-i18n" ,ruby-i18n)
7457 ("ruby-jekyll-sass-converter" ,ruby-jekyll-sass-converter)
7458 ("ruby-jekyll-watch" ,ruby-jekyll-watch)
7459 ("ruby-kramdown" ,ruby-kramdown)
7460 ("ruby-liquid" ,ruby-liquid)
7461 ("ruby-mercenary" ,ruby-mercenary)
7462 ("ruby-pathutil" ,ruby-pathutil)
7463 ("ruby-rouge" ,ruby-rouge-2)
7464 ("ruby-safe-yaml" ,ruby-safe-yaml)))
7465 (home-page "https://jekyllrb.com/")
7466 (synopsis "Static site generator")
7467 (description "Jekyll is a simple, blog aware, static site generator.")
7468 (license license:expat)))
37a0f470
JL
7469
7470(define-public ruby-jekyll-paginate-v2
7471 (package
7472 (name "ruby-jekyll-paginate-v2")
7473 (version "2.0.0")
7474 (source (origin
7475 (method url-fetch)
7476 (uri (rubygems-uri "jekyll-paginate-v2" version))
7477 (sha256
7478 (base32
7479 "154bfpyml6abxww9868hhyfvxasl8qhsc5zy2q30c7dxaj0igdib"))))
7480 (build-system ruby-build-system)
7481 (propagated-inputs
7482 `(("jekyll" ,jekyll)))
7483 (home-page "https://github.com/sverrirs/jekyll-paginate-v2")
7484 (synopsis "Pagination Generator for Jekyll 3")
7485 (description "The Pagination Generator forms the core of the pagination
7486logic in Jekyll. It calculates and generates the pagination pages.")
7487 (license license:expat)))
909eae21
CB
7488
7489(define-public ruby-faraday
7490 (package
7491 (name "ruby-faraday")
7492 (version "0.15.4")
7493 (source
7494 (origin
7495 (method url-fetch)
7496 (uri (rubygems-uri "faraday" version))
7497 (sha256
7498 (base32
7499 "0s72m05jvzc1pd6cw1i289chas399q0a14xrwg4rvkdwy7bgzrh0"))))
7500 (build-system ruby-build-system)
7501 (arguments
7502 '(#:tests? #f))
7503 (propagated-inputs
7504 `(("ruby-multipart-post" ,ruby-multipart-post)))
7505 (synopsis "Ruby HTTP/REST API client library")
7506 (description
7507 "Faraday is a HTTP/REST API client library which provides a common
7508interface over different adapters.")
7509 (home-page "https://github.com/lostisland/faraday")
7510 (license license:expat)))
a058cbfd
CB
7511
7512(define-public ruby-nio4r
7513 (package
7514 (name "ruby-nio4r")
7515 (version "2.3.1")
7516 (source
7517 (origin
7518 (method url-fetch)
7519 (uri (rubygems-uri "nio4r" version))
7520 (sha256
7521 (base32
7522 "1a41ca1kpdmrypjp9xbgvckpy8g26zxphkja9vk7j5wl4n8yvlyr"))))
7523 (build-system ruby-build-system)
7524 (arguments
7525 '(#:phases
7526 (modify-phases %standard-phases
7527 (add-after 'unpack 'remove-unnecessary-dependencies
7528 (lambda _
7529 (substitute* "spec/spec_helper.rb"
7530 ;; Coveralls is for uploading test coverage information to an
7531 ;; online service, and thus unnecessary for building the Guix
7532 ;; package
7533 (("require \"coveralls\"") "")
7534 (("Coveralls\\.wear!") "")
7535 ;; Remove rspec/retry as we are not retrying the tests
7536 (("require \"rspec/retry\"") "")
7537 (("config\\.display_try_failure_messages = true") "")
7538 (("config\\.verbose_retry = true") ""))
7539 #t))
7540 (add-before 'check 'compile
7541 (lambda _
7542 (invoke "rake" "compile")
7543 #t))
7544 (replace 'check
7545 (lambda* (#:key tests? #:allow-other-keys)
7546 (when tests?
7547 (invoke "rspec"))
7548 #t)))))
7549 (native-inputs
7550 `(("bundler" ,bundler)
7551 ("ruby-rake-compiler" ,ruby-rake-compiler)
7552 ("ruby-rspec" ,ruby-rspec)
7553 ("ruby-rubocop" ,ruby-rubocop)))
7554 (synopsis "New I/O for Ruby")
7555 (description
7556 "@code{nio} provides cross-platform asynchronous I/O primitives in Ruby
7557for scalable network clients and servers.")
7558 (home-page "https://github.com/socketry/nio4r")
7559 (license license:expat)))
f9da1ada
CB
7560
7561(define-public ruby-globalid
7562 (package
7563 (name "ruby-globalid")
7564 (version "0.4.2")
7565 (source
7566 (origin
7567 (method url-fetch)
7568 (uri (rubygems-uri "globalid" version))
7569 (sha256
7570 (base32
7571 "1zkxndvck72bfw235bd9nl2ii0lvs5z88q14706cmn702ww2mxv1"))))
7572 (build-system ruby-build-system)
7573 (arguments
7574 '(;; No included tests
7575 #:tests? #f))
7576 (propagated-inputs
7577 `(("ruby-activesupport" ,ruby-activesupport)))
7578 (synopsis "Generate URIs idenfitying model instances in Ruby")
7579 (description
7580 "@code{GlobalID} provides a way to generate URIs from a model in Ruby that
7581uniquely identify it.")
7582 (home-page "https://rubyonrails.org/")
7583 (license license:expat)))
15606d98
CB
7584
7585(define-public ruby-sprockets
7586 (package
7587 (name "ruby-sprockets")
7588 (version "3.7.2")
7589 (source
7590 (origin
7591 (method url-fetch)
7592 (uri (rubygems-uri "sprockets" version))
7593 (sha256
7594 (base32
7595 "182jw5a0fbqah5w9jancvfmjbk88h8bxdbwnl4d3q809rpxdg8ay"))))
7596 (build-system ruby-build-system)
7597 (arguments
7598 '(;; No included tests
7599 #:tests? #f))
7600 (propagated-inputs
7601 `(("ruby-concurrent" ,ruby-concurrent)
7602 ("ruby-rack" ,ruby-rack)))
7603 (synopsis "Sprockets is a Rack-based asset packaging system")
7604 (description
7605 "Sprockets is a Rack-based asset packaging system that concatenates and
7606serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.")
7607 (home-page "https://github.com/rails/sprockets")
7608 (license license:expat)))