Merge branch 'master' into staging
[jackhill/guix/guix.git] / gnu / packages / ruby.scm
1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014, 2015 Pjotr Prins <pjotr.guix@thebird.nl>
3 ;;; Copyright © 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org>
6 ;;; Copyright © 2015, 2019 Ricardo Wurmus <rekado@elephly.net>
7 ;;; Copyright © 2015, 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
8 ;;; Copyright © 2017 Nikita <nikita@n0.is>
9 ;;; Copyright © 2017, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
10 ;;; Copyright © 2017, 2018, 2019, 2020 Efraim Flashner <efraim@flashner.co.il>
11 ;;; Copyright © 2017, 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
12 ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
13 ;;; Copyright © 2017, 2018, 2019 Christopher Baines <mail@cbaines.net>
14 ;;; Copyright © 2018 Vasile Dumitrascu <va511e@yahoo.com>
15 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
16 ;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz>
17 ;;; Copyright © 2019 Mikhail Kirillov <w96k.ru@gmail.com>
18 ;;; Copyright © 2019 Jelle Licht <jlicht@fsfe.org>
19 ;;; Copyright © 2019 Brian Leung <bkleung89@gmail.com>
20 ;;; Copyright © 2019 Collin J. Doering <collin@rekahsoft.ca>
21 ;;; Copyright © 2019 Diego N. Barbato <dnbarbato@posteo.de>
22 ;;; Copyright © 2019 Brett Gilio <brettg@posteo.de>
23 ;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
24 ;;; Copyright © 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
25 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
26 ;;;
27 ;;; This file is part of GNU Guix.
28 ;;;
29 ;;; GNU Guix is free software; you can redistribute it and/or modify it
30 ;;; under the terms of the GNU General Public License as published by
31 ;;; the Free Software Foundation; either version 3 of the License, or (at
32 ;;; your option) any later version.
33 ;;;
34 ;;; GNU Guix is distributed in the hope that it will be useful, but
35 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
36 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
37 ;;; GNU General Public License for more details.
38 ;;;
39 ;;; You should have received a copy of the GNU General Public License
40 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
41
42 (define-module (gnu packages ruby)
43 #:use-module ((guix licenses) #:prefix license:)
44 #:use-module (gnu packages)
45 #:use-module (gnu packages base)
46 #:use-module (gnu packages bison)
47 #:use-module (gnu packages c)
48 #:use-module (gnu packages check)
49 #:use-module (gnu packages compression)
50 #:use-module (gnu packages crypto)
51 #:use-module (gnu packages databases)
52 #:use-module (gnu packages dbm)
53 #:use-module (gnu packages rails)
54 #:use-module (gnu packages readline)
55 #:use-module (gnu packages autotools)
56 #:use-module (gnu packages haskell-xyz)
57 #:use-module (gnu packages java)
58 #:use-module (gnu packages libffi)
59 #:use-module (gnu packages libidn)
60 #:use-module (gnu packages linux)
61 #:use-module (gnu packages lsof)
62 #:use-module (gnu packages maths)
63 #:use-module (gnu packages ncurses)
64 #:use-module (gnu packages networking)
65 #:use-module (gnu packages node)
66 #:use-module (gnu packages protobuf)
67 #:use-module (gnu packages python)
68 #:use-module (gnu packages python-xyz)
69 #:use-module (gnu packages ragel)
70 #:use-module (gnu packages rsync)
71 #:use-module (gnu packages sqlite)
72 #:use-module (gnu packages tls)
73 #:use-module (gnu packages version-control)
74 #:use-module (guix packages)
75 #:use-module (guix download)
76 #:use-module (guix git-download)
77 #:use-module (guix utils)
78 #:use-module (guix build-system gnu)
79 #:use-module (gnu packages xml)
80 #:use-module (gnu packages web)
81 #:use-module (guix build-system ruby)
82 #:use-module ((srfi srfi-1) #:select (alist-delete)))
83
84 (define %prawn-project-licenses
85 ;; This set of licenses applies to most (all?) components of the Prawn
86 ;; project (it is triple licensed).
87 (list license:ruby
88 license:gpl2+
89 license:gpl3+))
90
91 (define-public ruby
92 (package
93 (name "ruby")
94 (version "2.6.5")
95 (source
96 (origin
97 (method url-fetch)
98 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
99 (version-major+minor version)
100 "/ruby-" version ".tar.xz"))
101 (sha256
102 (base32
103 "0qhsw2mr04f3lqinkh557msr35pb5rdaqy4vdxcj91flgxqxmmnm"))
104 (modules '((guix build utils)))
105 (snippet `(begin
106 ;; Remove bundled libffi
107 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
108 #t))))
109 (build-system gnu-build-system)
110 (arguments
111 `(#:test-target "test"
112 #:configure-flags '("--enable-shared") ; dynamic linking
113 #:phases
114 (modify-phases %standard-phases
115 (add-before 'configure 'replace-bin-sh-and-remove-libffi
116 (lambda _
117 (substitute* '("Makefile.in"
118 "ext/pty/pty.c"
119 "io.c"
120 "lib/mkmf.rb"
121 "process.c"
122 "test/rubygems/test_gem_ext_configure_builder.rb"
123 "test/rdoc/test_rdoc_parser.rb"
124 "test/ruby/test_rubyoptions.rb"
125 "test/ruby/test_process.rb"
126 "test/ruby/test_system.rb"
127 "tool/rbinstall.rb")
128 (("/bin/sh") (which "sh")))
129 #t)))))
130 (inputs
131 `(("readline" ,readline)
132 ("openssl" ,openssl)
133 ("libffi" ,libffi)
134 ("gdbm" ,gdbm)))
135 (propagated-inputs
136 `(("zlib" ,zlib)))
137 (native-search-paths
138 (list (search-path-specification
139 (variable "GEM_PATH")
140 (files (list (string-append "lib/ruby/vendor_ruby"))))))
141 (synopsis "Programming language interpreter")
142 (description "Ruby is a dynamic object-oriented programming language with
143 a focus on simplicity and productivity.")
144 (home-page "https://www.ruby-lang.org")
145 (license license:ruby)))
146
147 (define-public ruby-2.7
148 (package
149 (inherit ruby)
150 (version "2.7.1")
151 (source
152 (origin
153 (method url-fetch)
154 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
155 (version-major+minor version)
156 "/ruby-" version ".tar.gz"))
157 (sha256
158 (base32
159 "0674x98f542y02r7n2yv2qhmh97blqhi2mvh2dn5f000vlxlh66l"))
160 (modules '((guix build utils)))
161 (snippet `(begin
162 ;; Remove bundled libffi
163 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
164 #t))))
165 (arguments
166 `(#:test-target "test"
167 #:configure-flags '("--enable-shared") ; dynamic linking
168 #:phases
169 (modify-phases %standard-phases
170 (add-before 'configure 'replace-bin-sh-and-remove-libffi
171 (lambda _
172 (substitute* '("configure.ac"
173 "template/Makefile.in"
174 "lib/rubygems/installer.rb"
175 "ext/pty/pty.c"
176 "io.c"
177 "lib/mkmf.rb"
178 "process.c"
179 "test/rubygems/test_gem_ext_configure_builder.rb"
180 "test/rdoc/test_rdoc_parser.rb"
181 "test/ruby/test_rubyoptions.rb"
182 "test/ruby/test_process.rb"
183 "test/ruby/test_system.rb"
184 "tool/rbinstall.rb")
185 (("/bin/sh") (which "sh")))
186 #t)))))
187 (native-inputs
188 `(("autoconf" ,autoconf)))))
189
190 (define-public ruby-2.5
191 (package
192 (inherit ruby)
193 (version "2.5.8")
194 (source
195 (origin
196 (method url-fetch)
197 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
198 (version-major+minor version)
199 "/ruby-" version ".tar.xz"))
200 (sha256
201 (base32
202 "0vad5ah1lrdhxsyqr5iqc8c7r7qczpmm76cz8rsf4crimpzv5483"))
203 (modules '((guix build utils)))
204 (snippet `(begin
205 ;; Remove bundled libffi
206 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
207 #t))))))
208
209 (define-public ruby-2.4
210 (package
211 (inherit ruby)
212 (version "2.4.10")
213 (source
214 (origin
215 (method url-fetch)
216 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
217 (version-major+minor version)
218 "/ruby-" version ".tar.xz"))
219 (sha256
220 (base32
221 "1prhqlgik1zmw9lakl6hkriqslspw48pvhxff17h7ns42p8qwrnm"))
222 (modules '((guix build utils)))
223 (snippet `(begin
224 ;; Remove bundled libffi
225 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
226 #t))))))
227
228 (define-public mruby
229 (package
230 (name "mruby")
231 (version "2.0.0")
232 (source
233 (origin
234 (method git-fetch)
235 (uri (git-reference
236 (url "https://github.com/mruby/mruby")
237 (commit version)))
238 (file-name (git-file-name name version))
239 (sha256
240 (base32
241 "1r6w1asjshff43ymdwa6xmrkggza99mi2kw88k7ic6ag2j81hcj5"))))
242 (build-system gnu-build-system)
243 (arguments
244 `(#:test-target "test"
245 #:phases
246 (modify-phases %standard-phases
247 (delete 'configure)
248 (add-after 'unpack 'enable-verbose-tests
249 (lambda _
250 (substitute* "Makefile"
251 (("ruby ./minirake" m)
252 (string-append m " --verbose")))
253 #t))
254 (add-after 'unpack 'disable-broken-tests
255 (lambda _
256 (substitute* "mrbgems/mruby-io/test/io.rb"
257 (("assert\\('IO.popen.+$" m)
258 (string-append m "skip \"Hangs in the Guix build environment\"\n"))
259 (("assert\\('IO#isatty.+$" m)
260 (string-append m "skip \"Disable for Guix; there is no /dev/tty\"\n"))
261 ;; This one is really weird. The *expected* output is all wrong.
262 (("assert\\('`cmd`.*" m)
263 (string-append m "skip \"Disable for Guix\"\n"))
264 (("echo foo")
265 (string-append (which "echo") " foo")))
266 #t))
267 ;; There is no install target
268 (replace 'install
269 (lambda* (#:key outputs #:allow-other-keys)
270 (let* ((out (assoc-ref outputs "out"))
271 (bin (string-append out "/bin"))
272 (lib (string-append out "/lib")))
273 (mkdir-p bin)
274 (copy-recursively "build/host/bin" bin)
275 (mkdir-p lib)
276 (copy-recursively "build/host/lib" lib))
277 #t)))))
278 (native-inputs
279 `(("ruby" ,ruby)
280 ("bison" ,bison)))
281 (home-page "https://github.com/mruby/mruby")
282 (synopsis "Lightweight Ruby")
283 (description "mruby is the lightweight implementation of the Ruby
284 language. Its syntax is Ruby 1.9 compatible. mruby can be linked and
285 embedded within your application.")
286 (license license:expat)))
287
288 (define-public ruby-commander
289 (package
290 (name "ruby-commander")
291 (version "4.4.7")
292 (source
293 (origin
294 (method url-fetch)
295 (uri (rubygems-uri "commander" version))
296 (sha256
297 (base32
298 "1pxakz596fjqak3cdbha6iva1dlqis86i3kjrgg6lf3sp8i5vhwg"))))
299 (build-system ruby-build-system)
300 (arguments
301 `(#:test-target "spec"
302 #:phases
303 (modify-phases %standard-phases
304 ;; Don't run or require rubocop, the code linting tool, as this is a
305 ;; bit unnecessary.
306 (add-after 'unpack 'dont-run-rubocop
307 (lambda _
308 (substitute* "Rakefile"
309 ((".*rubocop.*") "")
310 ((".*RuboCop.*") ""))
311 #t)))))
312 (propagated-inputs
313 `(("ruby-highline" ,ruby-highline)))
314 (native-inputs
315 `(("bundler" ,bundler)
316 ("ruby-rspec-core" ,ruby-rspec-core)
317 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
318 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
319 ("ruby-simplecov" ,ruby-simplecov)))
320 (home-page "https://github.com/commander-rb/commander")
321 (synopsis "Library for building Ruby command-line executables")
322 (description
323 "Commander aims to be a complete solution for Ruby command-line
324 executables. Commander bridges the gap between other terminal related
325 libraries (OptionParser, HighLine), while providing many new features, and an
326 elegant API.")
327 (license license:expat)))
328
329 (define-public ruby-highline
330 (package
331 (name "ruby-highline")
332 (version "2.0.1")
333 (source
334 (origin
335 (method url-fetch)
336 (uri (rubygems-uri "highline" version))
337 (sha256
338 (base32
339 "0gr6pckj2jayxw1gdgh9193j5jag5zrrqqlrnl4jvcwpyd3sn2zc"))))
340 (build-system ruby-build-system)
341 (arguments
342 `(#:tests? #f)) ;; TODO: NameError: uninitialized constant SPEC
343 (native-inputs
344 `(("bundler" ,bundler)
345 ("ruby-code-statistics" ,ruby-code-statistics)))
346 (synopsis
347 "HighLine helps you build command-line interfaces")
348 (description
349 "HighLine provides a high-level IO library that provides validation,
350 type conversion, and more for command-line interfaces. HighLine also includes
351 a menu system for providing multiple options to the user.")
352 (home-page "https://github.com/JEG2/highline")
353 (license (list license:gpl2 license:ruby))))
354
355 (define-public ruby-hoe
356 (package
357 (name "ruby-hoe")
358 (version "3.21.0")
359 (source (origin
360 (method url-fetch)
361 (uri (rubygems-uri "hoe" version))
362 (sha256
363 (base32
364 "0qid0n56mgsjvq5ksxajv0gb92akky8imwgvw22ajms5g4fd6nf4"))))
365 (build-system ruby-build-system)
366 (arguments
367 '(#:phases
368 (modify-phases %standard-phases
369 ;; One of the tests fails if the SOURCE_DATE_EPOCH environment
370 ;; variable is set, so unset it for the duration of the tests.
371 ;;
372 ;; TestHoe#test_possibly_better
373 ;; [/tmp/guix-build-ruby-hoe-3.20.0.drv-0/gem/test/test_hoe.rb:250]:
374 ;; Expected: 2019-11-12 00:00:00 UTC
375 ;; Actual: 1970-01-01 00:00:00 UTC
376 (add-before 'check 'unset-SOURCE-DATE-EPOCH
377 (lambda _
378 (unsetenv "SOURCE_DATE_EPOCH")
379 #t))
380 (add-after 'check 'set-SOURCE-DATE-EPOCH-again
381 (lambda _
382 (setenv "SOURCE_DATE_EPOCH" "1")
383 #t)))))
384 (synopsis "Ruby project management helper")
385 (description
386 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
387 maintain, and release projects and includes a dynamic plug-in system allowing
388 for easy extensibility. Hoe ships with plug-ins for all the usual project
389 tasks including rdoc generation, testing, packaging, deployment, and
390 announcement.")
391 (home-page "https://www.zenspider.com/projects/hoe.html")
392 (license license:expat)))
393
394 (define-public ruby-rake-compiler
395 (package
396 (name "ruby-rake-compiler")
397 (version "1.1.0")
398 (source (origin
399 (method url-fetch)
400 (uri (rubygems-uri "rake-compiler" version))
401 (sha256
402 (base32
403 "0l4hg21v0phfrfsc2hilgmwvn2imxr0byqh8dv16bya1s5d3km0q"))))
404 (build-system ruby-build-system)
405 (arguments
406 '(#:tests? #f)) ; needs cucumber
407 (synopsis "Building and packaging helper for Ruby native extensions")
408 (description "Rake-compiler provides a framework for building and
409 packaging native C and Java extensions in Ruby.")
410 (home-page "https://github.com/rake-compiler/rake-compiler")
411 (license license:expat)))
412
413 (define-public ruby-rsync
414 (package
415 (name "ruby-rsync")
416 (version "1.0.9")
417 (source
418 (origin
419 (method url-fetch)
420 (uri (rubygems-uri "rsync" version))
421 (sha256
422 (base32
423 "0p8b27q1gvxilqfq2528xpwglzcm2myikkjxpqk7mwbwg9r6knxv"))))
424 (build-system ruby-build-system)
425 (arguments
426 '(#:test-target "spec"
427 #:phases
428 (modify-phases %standard-phases
429 (add-after 'unpack 'remove-coveralls-requirement
430 (lambda _
431 (substitute* "spec/spec_helper.rb"
432 (("require 'coveralls'") "")
433 (("Coveralls.wear!") ""))
434 #t)))))
435 (native-inputs
436 `(("bundler" ,bundler)
437 ("rsync" ,rsync)
438 ("ruby-rspec-core" ,ruby-rspec-core)
439 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
440 ("ruby-rspec-mocks" ,ruby-rspec-mocks)))
441 (home-page "https://github.com/jbussdieker/ruby-rsync")
442 (synopsis "Ruby wrapper around rsync")
443 (description
444 "Ruby Rsync is a Ruby library that can synchronize files between remote
445 hosts by wrapping the @file{rsync} binary.")
446 (license license:expat)))
447
448 (define-public ruby-i18n
449 (package
450 (name "ruby-i18n")
451 (version "1.7.0")
452 (source (origin
453 (method url-fetch)
454 (uri (rubygems-uri "i18n" version))
455 (sha256
456 (base32
457 "0hmypvx9iyc0b4hski7aic2xzm09cg1c7q1qlpnk3k8s5acxzyhl"))))
458 (build-system ruby-build-system)
459 (arguments
460 '(#:tests? #f)) ; no tests
461 (propagated-inputs `(("concurrent-ruby" ,ruby-concurrent)))
462 (synopsis "Internationalization library for Ruby")
463 (description "Ruby i18n is an internationalization and localization
464 solution for Ruby programs. It features translation and localization,
465 interpolation of values to translations, pluralization, customizable
466 transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
467 translation data, custom key/scope separator, custom exception handlers, and
468 an extensible architecture with a swappable backend.")
469 (home-page "https://github.com/ruby-i18n/i18n")
470 (license license:expat)))
471
472 (define-public ruby-iruby
473 (package
474 (name "ruby-iruby")
475 (version "0.3")
476 (source
477 (origin
478 (method url-fetch)
479 (uri (rubygems-uri "iruby" version))
480 (sha256
481 (base32
482 "1wdf2c0x8y6cya0n3y0p3p7b1sxkb2fdavdn2k58rf4rs37s7rzn"))))
483 (build-system ruby-build-system)
484 (arguments
485 ;; TODO: Tests currently fail.
486 ;;
487 ;; Finished in 1.764405s, 1.1335 runs/s, 5.1009 assertions/s.
488 ;;
489 ;; 1) Failure:
490 ;; IntegrationTest#test_interaction [/tmp/guix-build-ruby-iruby-0.3.drv-0/gem/test/integration_test.rb:25]:
491 ;; In [ expected
492 ;;
493 ;; 2 runs, 9 assertions, 1 failures, 0 errors, 0 skips
494 '(#:tests? #f
495 #:phases
496 (modify-phases %standard-phases
497 (add-after 'unpack 'patch-ipython
498 (lambda* (#:key inputs #:allow-other-keys)
499 (substitute* "lib/iruby/command.rb"
500 (("version = `")
501 (string-append
502 "version = `"
503 (assoc-ref inputs "python-ipython")
504 "/bin/"))
505 (("Kernel\\.exec\\('")
506 (string-append
507 "Kernel.exec('"
508 (assoc-ref inputs "python-ipython")
509 "/bin/")))
510 #t)))))
511 (inputs
512 `(("python-ipython" ,python-ipython)))
513 (propagated-inputs
514 `(("ruby-bond" ,ruby-bond)
515 ("ruby-data_uri" ,ruby-data_uri)
516 ("ruby-mimemagic" ,ruby-mimemagic)
517 ("ruby-multi-json" ,ruby-multi-json)
518 ("ruby-cztop" ,ruby-cztop)
519 ;; Optional inputs
520 ("ruby-pry" ,ruby-pry)))
521 (synopsis "Ruby kernel for Jupyter/IPython")
522 (description
523 "This package provides a Ruby kernel for Jupyter/IPython frontends (e.g.
524 notebook).")
525 (home-page "https://github.com/SciRuby/iruby")
526 (license license:expat)))
527
528 ;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
529 ;; dependencies use RSpec for their test suites! To avoid these circular
530 ;; dependencies, we disable tests for all of the RSpec-related packages.
531 (define-public ruby-rspec-support
532 (package
533 (name "ruby-rspec-support")
534 (version "3.8.0")
535 (source (origin
536 (method url-fetch)
537 (uri (rubygems-uri "rspec-support" version))
538 (sha256
539 (base32
540 "0p3m7drixrlhvj2zpc38b11x145bvm311x6f33jjcxmvcm0wq609"))))
541 (build-system ruby-build-system)
542 (arguments
543 '(#:tests? #f)) ; avoid dependency cycles
544 (synopsis "RSpec support library")
545 (description "Support utilities for RSpec gems.")
546 (home-page "https://github.com/rspec/rspec-support")
547 (license license:expat)))
548
549 (define-public ruby-rspec-core
550 (package
551 (name "ruby-rspec-core")
552 (version "3.8.0")
553 (source (origin
554 (method url-fetch)
555 (uri (rubygems-uri "rspec-core" version))
556 (sha256
557 (base32
558 "1p1s5bnbqp3sxk67y0fh0x884jjym527r0vgmhbm81w7aq6b7l4p"))))
559 (build-system ruby-build-system)
560 (arguments
561 '(#:tests? #f)) ; avoid dependency cycles
562 (propagated-inputs
563 `(("ruby-rspec-support" ,ruby-rspec-support)))
564 (synopsis "RSpec core library")
565 (description "Rspec-core provides the RSpec test runner and example
566 groups.")
567 (home-page "https://github.com/rspec/rspec-core")
568 (license license:expat)))
569
570 (define-public ruby-rspec-core-2
571 (package (inherit ruby-rspec-core)
572 (version "2.14.8")
573 (source (origin
574 (method url-fetch)
575 (uri (rubygems-uri "rspec-core" version))
576 (sha256
577 (base32
578 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
579 (propagated-inputs `())))
580
581 (define-public ruby-diff-lcs
582 (package
583 (name "ruby-diff-lcs")
584 (version "1.3")
585 (source (origin
586 (method url-fetch)
587 (uri (rubygems-uri "diff-lcs" version))
588 (sha256
589 (base32
590 "18w22bjz424gzafv6nzv98h0aqkwz3d9xhm7cbr1wfbyas8zayza"))))
591 (build-system ruby-build-system)
592 (arguments
593 '(#:tests? #f)) ; avoid dependency cycles
594 (synopsis "Compute the difference between two Enumerable sequences")
595 (description "Diff::LCS computes the difference between two Enumerable
596 sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
597 It includes utilities to create a simple HTML diff output format and a
598 standard diff-like tool.")
599 (home-page "https://github.com/halostatue/diff-lcs")
600 (license license:expat)))
601
602 (define-public ruby-rspec-expectations
603 (package
604 (name "ruby-rspec-expectations")
605 (version "3.8.2")
606 (source (origin
607 (method url-fetch)
608 (uri (rubygems-uri "rspec-expectations" version))
609 (sha256
610 (base32
611 "18l21hy1zdc2pgc2yb17k3n2al1khpfr0z6pijlm852iz6vj0dkm"))))
612 (build-system ruby-build-system)
613 (arguments
614 '(#:tests? #f)) ; avoid dependency cycles
615 (propagated-inputs
616 `(("ruby-rspec-support" ,ruby-rspec-support)
617 ("ruby-diff-lcs" ,ruby-diff-lcs)))
618 (synopsis "RSpec expectations library")
619 (description "Rspec-expectations provides a simple API to express expected
620 outcomes of a code example.")
621 (home-page "https://github.com/rspec/rspec-expectations")
622 (license license:expat)))
623
624 (define-public ruby-rspec-expectations-2
625 (package (inherit ruby-rspec-expectations)
626 (version "2.14.5")
627 (source (origin
628 (method url-fetch)
629 (uri (rubygems-uri "rspec-expectations" version))
630 (sha256
631 (base32
632 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
633 (propagated-inputs
634 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
635
636 (define-public ruby-sorcerer
637 (package
638 (name "ruby-sorcerer")
639 (version "2.0.1")
640 (source
641 (origin
642 (method url-fetch)
643 (uri (rubygems-uri "sorcerer" version))
644 (sha256
645 (base32
646 "0d32ha9pp9slpmsm027pkdpbr9vc5jn2m8rl6hwwx6a87m8cr58h"))))
647 (build-system ruby-build-system)
648 (synopsis "Ripper-style abstract syntax tree to Ruby source generator")
649 (description "Sorcerer generates Ruby code from a Ripper-like abstract
650 syntax tree (i.e. S-Expressions). Sorcerer is targeted mainly at small
651 snippets of Ruby code, expressible in a single line. Longer examples may be
652 re-sourced, but they will be rendered in a single-line format.")
653 (home-page "https://github.com/rspec-given/sorcerer")
654 (license license:expat)))
655
656 (define-public ruby-given-core
657 (package
658 (name "ruby-given-core")
659 (version "3.8.0")
660 (source
661 (origin
662 (method url-fetch)
663 (uri (rubygems-uri "given_core" version))
664 (sha256
665 (base32
666 "1lzyqllbbv6as3qgwz2007mvy7wy247bgkch9adnmh1zfa73bkrg"))))
667 (build-system ruby-build-system)
668 (arguments '(#:tests? #f)) ;no test suite for the core package
669 (propagated-inputs
670 `(("ruby-sorcerer" ,ruby-sorcerer)))
671 (synopsis "Core abstractions used by rspec-given and minitest-given")
672 (description "Given_core is the basic functionality behind rspec-given and
673 minitest-given, extensions that allow the use of Given/When/Then terminology
674 when defining specifications.")
675 (home-page "https://github.com/rspec-given/rspec-given")
676 (license license:expat)))
677
678 (define-public ruby-rspec-given
679 (package
680 (name "ruby-rspec-given")
681 (version "3.8.0")
682 (source
683 (origin
684 (method url-fetch)
685 (uri (rubygems-uri "rspec-given" version))
686 (sha256
687 (base32
688 "1783bazja10kbha8hk15khvybsq88siyax02cpkk688604h54nji"))))
689 (build-system ruby-build-system)
690 (arguments
691 `(#:test-target "rs"
692 #:phases
693 (modify-phases %standard-phases
694 (add-after 'unpack 'fix-rakefile
695 (lambda _
696 (substitute* '("Rakefile" "rakelib/gemspec.rake")
697 (("require '\\./lib/given/.*") "")
698 (("Given::VERSION") (format #f "~s" ,version))
699 ;; Fix the error: "cannot load such file -- example_helper"
700 (("sh \"rspec")
701 "sh \"rspec -Ilib:examples"))
702 #t))
703 (add-after 'extract-gemspec 'delete-failing-tests
704 ;; See: https://github.com/jimweirich/rspec-given/issues/57.
705 (lambda _
706 (substitute* ".gemspec"
707 (("\"spec/lib/given/natural_assertion_spec.rb\".freeze, ")
708 "")
709 (("\"examples/integration/failing_messages_spec.rb\".freeze, ")
710 ""))
711 (delete-file "spec/lib/given/natural_assertion_spec.rb")
712 (delete-file "examples/integration/failing_messages_spec.rb")
713 #t)))))
714 (native-inputs
715 `(("ruby-rspec" ,ruby-rspec)
716 ("ruby-minitest" ,ruby-minitest)))
717 (propagated-inputs
718 `(("ruby-given-core" ,ruby-given-core)
719 ("ruby-rspec" ,ruby-rspec)))
720 (synopsis "Given/When/Then for RSpec and Minitest")
721 (description "Given is an RSpec extension that allows the use of
722 Given/When/Then terminology when defining specifications, in a way similar to
723 the Cucumber Gherkin language.")
724 (home-page "https://github.com/rspec-given/rspec-given")
725 (license license:expat)))
726
727 (define-public ruby-rspec-its
728 (package
729 (name "ruby-rspec-its")
730 (version "1.3.0")
731 (source
732 (origin
733 (method git-fetch)
734 (uri (git-reference
735 (url "https://github.com/rspec/rspec-its")
736 (commit (string-append "v" version))))
737 (file-name (git-file-name name version))
738 (sha256
739 (base32
740 "02mlsc9d4d1cjj5vahi8v3q8hyn9fyiv8nnlidhgfh186qp20g1p"))))
741 (build-system ruby-build-system)
742 (arguments
743 `(#:test-target "spec"
744 #:phases
745 (modify-phases %standard-phases
746 (add-after 'unpack 'dont-install-gems-from-gemfile
747 (lambda _
748 (substitute* "Gemfile"
749 (("rspec rspec-core rspec-expectations rspec-mocks rspec-support")
750 ""))
751 #t))
752 (add-before 'build 'loosen-ffi-requirement
753 (lambda _
754 ;; Accept any version of ruby-ffi.
755 (substitute* "Gemfile"
756 ((" gem 'ffi', '~> 1\\.9\\.25'")
757 " gem 'ffi'"))
758 #t))
759 (add-before 'build 'remove-unnecessary-dependency-versions-from-gemfile
760 (lambda _
761 (substitute* "rspec-its.gemspec"
762 (("rake.*") "rake'\n")
763 (("spec.add_development_dependency 'cucumber'.*")
764 "spec.add_development_dependency 'cucumber'\n")
765 (("bundler.*") "bundler'\n")
766 (("\"aruba.*") "'aruba'\n"))
767 #t)))))
768 (propagated-inputs
769 `(("ruby-rspec-core" ,ruby-rspec-core)
770 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
771 (native-inputs
772 `(("bundler" ,bundler)
773 ("ruby-cucumber" ,ruby-cucumber)
774 ("ruby-ffi" ,ruby-ffi)
775 ("ruby-aruba" ,ruby-aruba)))
776 (synopsis "RSpec extension that provides the @code{its} method")
777 (description
778 "RSpec::Its provides the its method as a short-hand to specify the expected
779 value of an attribute. For example, one can use @code{its(:size)\\{should
780 eq(1)\\}}.")
781 (home-page "https://github.com/rspec/rspec-its")
782 (license license:expat)))
783
784 ;;; This variant is used to break a cycle with ruby-protobuf.
785 (define-public ruby-rspec-its-minimal
786 (hidden-package
787 (package
788 (inherit ruby-rspec-its)
789 (arguments
790 (substitute-keyword-arguments (package-arguments ruby-rspec-its)
791 ((#:tests? _ #f) #f)))
792 (native-inputs '()))))
793
794 (define-public ruby-rspec-mocks
795 (package
796 (name "ruby-rspec-mocks")
797 (version "3.8.0")
798 (source (origin
799 (method url-fetch)
800 (uri (rubygems-uri "rspec-mocks" version))
801 (sha256
802 (base32
803 "06y508cjqycb4yfhxmb3nxn0v9xqf17qbd46l1dh4xhncinr4fyp"))))
804 (build-system ruby-build-system)
805 (arguments
806 '(#:tests? #f)) ; avoid dependency cycles
807 (propagated-inputs
808 `(("ruby-rspec-support" ,ruby-rspec-support)
809 ("ruby-diff-lcs" ,ruby-diff-lcs)))
810 (synopsis "RSpec stubbing and mocking library")
811 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
812 support for stubbing and mocking.")
813 (home-page "https://github.com/rspec/rspec-mocks")
814 (license license:expat)))
815
816 (define-public ruby-rspec-mocks-2
817 (package (inherit ruby-rspec-mocks)
818 (version "2.14.6")
819 (source (origin
820 (method url-fetch)
821 (uri (rubygems-uri "rspec-mocks" version))
822 (sha256
823 (base32
824 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
825 (propagated-inputs
826 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
827
828 (define-public ruby-rspec-rerun
829 (package
830 (name "ruby-rspec-rerun")
831 (version "1.1.0")
832 (source
833 (origin
834 (method url-fetch)
835 (uri (rubygems-uri "rspec-rerun" version))
836 (sha256
837 (base32
838 "1gy7znkcaqhpccfnk2nvaqbsvgxy3q57cmjwkl9fi1zabaq5lbkj"))))
839 (build-system ruby-build-system)
840 (arguments
841 '(;; No included tests
842 #:tests? #f))
843 (propagated-inputs `(("ruby-rspec" ,ruby-rspec)))
844 (synopsis "Track failed RSpec tests to re-run them")
845 (description
846 "This package provides an automated way to track, and then re-run failed
847 RSpec tests.")
848 (home-page "https://github.com/dblock/rspec-rerun")
849 (license license:expat)))
850
851 (define-public ruby-rspec-wait
852 (package
853 (name "ruby-rspec-wait")
854 (version "0.0.9")
855 (source
856 (origin
857 (method url-fetch)
858 (uri (rubygems-uri "rspec-wait" version))
859 (sha256
860 (base32
861 "0gvj1bp5ccx001dyvcgk2j49s5sl6vs9fdaqqb08z3bd1554hsww"))))
862 (build-system ruby-build-system)
863 (arguments
864 '(#:phases
865 (modify-phases %standard-phases
866 (replace 'check
867 (lambda _
868 (invoke "rake" "spec"))))))
869 (native-inputs
870 `(("bundler" ,bundler)))
871 (propagated-inputs
872 `(("ruby-rspec" ,ruby-rspec)))
873 (home-page "https://github.com/laserlemon/rspec-wait")
874 (synopsis "Wait for conditions in RSpec")
875 (description
876 "RSpec::Wait strives to make it easier to test asynchronous or slow
877 interactions.")
878 (license license:expat)))
879
880 (define-public ruby-rspec
881 (package
882 (name "ruby-rspec")
883 (version "3.8.0")
884 (source (origin
885 (method url-fetch)
886 (uri (rubygems-uri "rspec" version))
887 (sha256
888 (base32
889 "15ppasvb9qrscwlyjz67ppw1lnxiqnkzx5vkx1bd8x5n3dhikxc3"))))
890 (build-system ruby-build-system)
891 (arguments
892 '(#:tests? #f)) ; avoid dependency cycles
893 (propagated-inputs
894 `(("ruby-rspec-core" ,ruby-rspec-core)
895 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
896 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
897 (synopsis "Behavior-driven development framework for Ruby")
898 (description "RSpec is a behavior-driven development (BDD) framework for
899 Ruby. This meta-package includes the RSpec test runner, along with the
900 expectations and mocks frameworks.")
901 (home-page "https://rspec.info/")
902 (license license:expat)))
903
904 (define-public ruby-rspec-2
905 (package (inherit ruby-rspec)
906 (version "2.14.1")
907 (source (origin
908 (method url-fetch)
909 (uri (rubygems-uri "rspec" version))
910 (sha256
911 (base32
912 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
913 (propagated-inputs
914 `(("ruby-rspec-core" ,ruby-rspec-core-2)
915 ("ruby-rspec-mocks" ,ruby-rspec-mocks-2)
916 ("ruby-rspec-expectations" ,ruby-rspec-expectations-2)))))
917
918 ;; Bundler is yet another source of circular dependencies, so we must disable
919 ;; its test suite as well.
920 (define-public bundler
921 (package
922 (name "bundler")
923 (version "2.1.4")
924 (source (origin
925 (method url-fetch)
926 (uri (rubygems-uri "bundler" version))
927 (sha256
928 (base32
929 "12glbb1357x91fvd004jgkw7ihlkpc9dwr349pd7j83isqhls0ah"))))
930 (build-system ruby-build-system)
931 (arguments
932 '(#:tests? #f)) ; avoid dependency cycles
933 (synopsis "Ruby gem bundler")
934 (description "Bundler automatically downloads and installs a list of gems
935 specified in a \"Gemfile\", as well as their dependencies.")
936 (home-page "https://bundler.io/")
937 (license license:expat)))
938
939 (define-public ruby-builder
940 (package
941 (name "ruby-builder")
942 (version "3.2.3")
943 (source (origin
944 (method url-fetch)
945 (uri (rubygems-uri "builder" version))
946 (sha256
947 (base32
948 "0qibi5s67lpdv1wgcj66wcymcr04q6j4mzws6a479n0mlrmh5wr1"))))
949 (build-system ruby-build-system)
950 (arguments
951 `(#:phases
952 (modify-phases %standard-phases
953 (add-after 'unpack 'do-not-use-rvm
954 (lambda _
955 (substitute* "rakelib/tags.rake"
956 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
957 #t)))))
958 (synopsis "Ruby library to create structured data")
959 (description "Builder provides a number of builder objects that make it
960 easy to create structured data. Currently the following builder objects are
961 supported: XML Markup and XML Events.")
962 (home-page "https://github.com/jimweirich/builder")
963 (license license:expat)))
964
965 (define-public ruby-bump
966 (package
967 (name "ruby-bump")
968 (version "0.7.0")
969 (source
970 (origin
971 (method url-fetch)
972 (uri (rubygems-uri "bump" version))
973 (sha256
974 (base32
975 "1xinbr9rzh6cj75x24niwgqcnbhdxc68a8bc41lk8xv6fd906fym"))))
976 (build-system ruby-build-system)
977 (arguments
978 '(;; No included tests
979 #:tests? #f))
980 (synopsis "Tool for working with Rubygems")
981 (description
982 "Bump provides commands to manage Rubygem versioning, updating to the
983 next patch version for example.")
984 (home-page "https://github.com/gregorym/bump")
985 (license license:expat)))
986
987 (define-public ruby-rjb
988 (package
989 (name "ruby-rjb")
990 (version "1.5.5")
991 (source (origin
992 (method url-fetch)
993 (uri (rubygems-uri "rjb" version))
994 (sha256
995 (base32
996 "1ppj8rbicj3w0nhh7f73mflq19yd7pzdzkh2a91hcvphriy5b0ca"))))
997 (build-system ruby-build-system)
998 (arguments
999 `(#:tests? #f ; no rakefile
1000 #:phases
1001 (modify-phases %standard-phases
1002 (add-before 'build 'set-java-home
1003 (lambda* (#:key inputs #:allow-other-keys)
1004 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
1005 #t)))))
1006 (native-inputs
1007 `(("jdk" ,icedtea "jdk")))
1008 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
1009 (description "RJB is a bridge program that connects Ruby and Java via the
1010 Java Native Interface.")
1011 (home-page "https://www.artonx.org/collabo/backyard/?RubyJavaBridge")
1012 (license license:lgpl2.1+)))
1013
1014 (define-public ruby-log4r
1015 (package
1016 (name "ruby-log4r")
1017 (version "1.1.10")
1018 (source
1019 (origin
1020 (method url-fetch)
1021 (uri (rubygems-uri "log4r" version))
1022 (sha256
1023 (base32
1024 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
1025 (build-system ruby-build-system)
1026 (arguments
1027 '(#:tests? #f)) ; no Rakefile in gem
1028 (synopsis "Flexible logging library for Ruby")
1029 (description "Comprehensive and flexible logging library written
1030 in Ruby for use in Ruby programs. It features a hierarchical logging
1031 system of any number of levels, custom level names, logger
1032 inheritance, multiple output destinations per log event, execution
1033 tracing, custom formatting, thread safteyness, XML and YAML
1034 configuration, and more.")
1035 (home-page "http://log4r.rubyforge.org/")
1036 (license license:bsd-3)))
1037
1038 (define-public ruby-atoulme-antwrap
1039 (package
1040 (name "ruby-atoulme-antwrap")
1041 (version "0.7.5")
1042 (source (origin
1043 (method url-fetch)
1044 (uri (rubygems-uri "atoulme-Antwrap" version))
1045 (sha256
1046 (base32
1047 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
1048 (build-system ruby-build-system)
1049 ;; Test data required for most of the tests are not included.
1050 (arguments `(#:tests? #f))
1051 (native-inputs
1052 `(("ruby-hoe" ,ruby-hoe)))
1053 (inputs
1054 `(("ruby-rjb" ,ruby-rjb)))
1055 (synopsis "Ruby wrapper for the Ant build tool")
1056 (description "Antwrap is a Ruby module that wraps the Apache Ant build
1057 tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
1058 script.")
1059 (home-page "http://rubyforge.org/projects/antwrap/")
1060 (license license:expat)))
1061
1062 (define-public ruby-atoulme-saikuro
1063 (package
1064 (name "ruby-atoulme-saikuro")
1065 (version "1.2.1")
1066 (source (origin
1067 (method url-fetch)
1068 (uri (rubygems-uri "atoulme-Saikuro" version))
1069 (sha256
1070 (base32
1071 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
1072 (build-system ruby-build-system)
1073 ;; FIXME: There are no unit tests. The tests are demonstrations of the
1074 ;; "saikuro" tool.
1075 (arguments `(#:tests? #f))
1076 (synopsis "Cyclomatic complexity analyzer")
1077 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
1078 given Ruby source code Saikuro will generate a report listing the cyclomatic
1079 complexity of each method found. In addition, Saikuro counts the number of
1080 lines per method and can generate a listing of the number of tokens on each
1081 line of code.")
1082 (home-page "http://www.github.com/atoulme/Saikuro")
1083 ;; File headers contain the BSD-3 license and the README.rdoc says that
1084 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
1085 ;; of the Expat license.
1086 (license license:bsd-3)))
1087
1088 (define-public ruby-pandoc-ruby
1089 (package
1090 (name "ruby-pandoc-ruby")
1091 (version "2.1.4")
1092 (source
1093 (origin
1094 (method git-fetch) ;the gem lacks many test files
1095 (uri (git-reference
1096 (url "https://github.com/xwmx/pandoc-ruby")
1097 (commit version)))
1098 (file-name (git-file-name name version))
1099 (sha256
1100 (base32
1101 "03a11clhycyn0jhc7g9davpqd83sn60jqwjy1y145ag9sq6sp935"))))
1102 (build-system ruby-build-system)
1103 (arguments
1104 `(#:phases
1105 (modify-phases %standard-phases
1106 (add-after 'unpack 'disable-failing-tests
1107 ;; TODO: Remove this phase after ghc-pandoc gets upgraded to 2.9.2+
1108 ;; (see: https://github.com/xwmx/pandoc-ruby/issues/39).
1109 (lambda _
1110 (substitute* "test/test_conversions.rb"
1111 (("next if from == to.*" all)
1112 (string-append
1113 all
1114 " next if ['plain', 'beamer'].include? to\n")))
1115 #t))
1116 (add-after 'unpack 'patch-pandoc-path
1117 (lambda* (#:key inputs #:allow-other-keys)
1118 (let ((pandoc (string-append (assoc-ref inputs "pandoc")
1119 "/bin/pandoc")))
1120 (substitute* "lib/pandoc-ruby.rb"
1121 (("@@pandoc_path = 'pandoc'")
1122 (format #f "@@pandoc_path = '~a'" pandoc)))
1123 (substitute* "test/test_pandoc_ruby.rb"
1124 (("('|\")pandoc" _ quote)
1125 (string-append quote pandoc))
1126 (("\\^pandoc")
1127 ".*pandoc"))
1128 #t)))
1129 (add-after 'extract-gemspec 'remove-Gemfile.lock
1130 (lambda _
1131 (delete-file "Gemfile.lock")
1132 (substitute* "pandoc-ruby.gemspec"
1133 (("Gemfile\\.lock") ""))
1134 #t)))))
1135 (native-inputs
1136 `(("ruby-mocha" ,ruby-mocha)))
1137 (inputs
1138 `(("pandoc" ,pandoc)))
1139 (synopsis "Ruby wrapper for Pandoc")
1140 (description "PandocRuby is a wrapper for Pandoc, a Haskell library with
1141 command line tools for converting one markup format to another. Pandoc can
1142 convert documents from a variety of formats including markdown,
1143 reStructuredText, textile, HTML, DocBook, LaTeX, and MediaWiki markup to a
1144 variety of other formats, including markdown, reStructuredText, HTML, LaTeX,
1145 ConTeXt, PDF, RTF, DocBook XML, OpenDocument XML, ODT, GNU Texinfo, MediaWiki
1146 markup, groff man pages, HTML slide shows, EPUB, Microsoft Word docx, and
1147 more.")
1148 (home-page "https://github.com/xwmx/pandoc-ruby")
1149 (license license:expat)))
1150
1151 (define-public ruby-slim
1152 (package
1153 (name "ruby-slim")
1154 (version "4.1.0")
1155 (source
1156 (origin
1157 (method url-fetch)
1158 (uri (rubygems-uri "slim" version))
1159 (sha256
1160 (base32
1161 "0gjx30g84c82qzg32bd7giscvb4206v7mvg56kc839w9wjagn36n"))))
1162 (build-system ruby-build-system)
1163 (arguments
1164 `(#:phases
1165 (modify-phases %standard-phases
1166 ;; See: https://github.com/slim-template/slim/issues/857 and
1167 ;; https://github.com/slim-template/slim/issues/858.
1168 (add-after 'unpack 'skip-broken-tests
1169 (lambda _
1170 (substitute* "test/core/test_embedded_engines.rb"
1171 (("def test_render_with_markdown")
1172 "def skipped_test_render_with_markdown"))
1173 (substitute* "test/translator/test_translator.rb"
1174 (("raise (\"Missing test for.*)" _ tail)
1175 (string-append "print " tail)))
1176 #t))
1177 ;; See: https://salsa.debian.org/ruby-team/ruby-slim/-/commit/
1178 ;; 824862bd99d1675bc699d8fc71ba965a785c1f44.
1179 (add-after 'unpack 'prevent-bundler-interference
1180 (lambda _
1181 (substitute* "Rakefile"
1182 (("require 'bundler/setup'") "nil")
1183 (("Bundler::GemHelper\\.install_tasks") "nil"))
1184 #t)))))
1185 (native-inputs
1186 `(("ruby-rack-test" ,ruby-rack-test)
1187 ("ruby-sinatra" ,ruby-sinatra)))
1188 (propagated-inputs
1189 `(("ruby-temple" ,ruby-temple)
1190 ("ruby-tilt" ,ruby-tilt)))
1191 (synopsis "Minimalist template language for Ruby")
1192 (description "Slim is a template language for Ruby that aims to reduce the
1193 syntax to the minimum while remaining clear.")
1194 (home-page "http://slim-lang.com/")
1195 (license license:expat)))
1196
1197 (define-public ruby-asciidoctor
1198 (package
1199 (name "ruby-asciidoctor")
1200 (version "2.0.10")
1201 (source
1202 (origin
1203 (method git-fetch) ;the gem release lacks a Rakefile
1204 (uri (git-reference
1205 (url "https://github.com/asciidoctor/asciidoctor")
1206 (commit (string-append "v" version))))
1207 (file-name (git-file-name name version))
1208 (sha256
1209 (base32
1210 "0jaxpnsdnx3qyjw5p2lsx1swny12q1i2vxw2kgdp4vlsyjv95z95"))))
1211 (build-system ruby-build-system)
1212 (arguments
1213 `(#:test-target "test:all"
1214 #:phases
1215 (modify-phases %standard-phases
1216 (replace 'replace-git-ls-files
1217 (lambda _
1218 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1219 ;; git ls-files output is merged in ruby-build-system.
1220 (substitute* "asciidoctor.gemspec"
1221 (("`git ls-files -z`")
1222 "`find . -type f -print0 |sort -z|cut -zc3-`"))
1223 #t))
1224 (add-after 'extract-gemspec 'strip-version-requirements
1225 (lambda _
1226 (delete-file "Gemfile")
1227 (substitute* "asciidoctor.gemspec"
1228 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1229 (string-append stripped "\n")))
1230 #t)))))
1231 (native-inputs
1232 `(("ruby-erubis" ,ruby-erubis)
1233 ("ruby-minitest" ,ruby-minitest)
1234 ("ruby-nokogiri" ,ruby-nokogiri)
1235 ("ruby-asciimath" ,ruby-asciimath)
1236 ("ruby-coderay" ,ruby-coderay)
1237 ("ruby-cucumber" ,ruby-cucumber)
1238 ("ruby-haml" ,ruby-haml)
1239 ("ruby-rouge" ,ruby-rouge)
1240 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
1241 ("ruby-simplecov" ,ruby-simplecov)
1242 ("ruby-slim" ,ruby-slim)
1243 ("ruby-tilt" ,ruby-tilt)))
1244 (synopsis "Converter from AsciiDoc content to other formats")
1245 (description "Asciidoctor is a text processor and publishing toolchain for
1246 converting AsciiDoc content to HTML5, DocBook 5 (or 4.5), PDF, and other
1247 formats.")
1248 (home-page "https://asciidoctor.org")
1249 (license license:expat)))
1250
1251 (define-public ruby-prawn-icon
1252 (package
1253 (name "ruby-prawn-icon")
1254 (version "2.5.0")
1255 (source
1256 (origin
1257 (method url-fetch)
1258 (uri (rubygems-uri "prawn-icon" version))
1259 (sha256
1260 (base32
1261 "1ivkdf8rdf92hhy97vbmc2a4w97vcvqd58jcj4z9hz3hfsb1526w"))))
1262 (build-system ruby-build-system)
1263 (arguments
1264 `(#:test-target "spec"
1265 #:phases (modify-phases %standard-phases
1266 (add-after 'unpack 'remove-unnecessary-dependencies
1267 (lambda _
1268 (substitute* '("Rakefile" "spec/spec_helper.rb")
1269 ((".*[Bb]undler.*") "")
1270 (("^require 'rubocop.*") "")
1271 (("^RuboCop.*") ""))
1272 #t)))))
1273 (native-inputs
1274 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
1275 ("ruby-pdf-reader" ,ruby-pdf-reader)
1276 ("ruby-rspec" ,ruby-rspec)
1277 ("ruby-simplecov" ,ruby-simplecov)))
1278 (propagated-inputs
1279 `(("ruby-prawn" ,ruby-prawn)))
1280 (synopsis "Icon fonts for use with the Prawn PDF toolkit")
1281 (description "@code{Prawn::Icon} provides various icon fonts including
1282 FontAwesome, PaymentFont and Foundation Icons for use with the Prawn PDF
1283 toolkit.")
1284 (home-page "https://github.com/jessedoyle/prawn-icon/")
1285 (license %prawn-project-licenses)))
1286
1287 (define-public ruby-css-parser
1288 (package
1289 (name "ruby-css-parser")
1290 (version "1.7.1")
1291 (source
1292 (origin
1293 (method url-fetch)
1294 (uri (rubygems-uri "css_parser" version))
1295 (sha256
1296 (base32
1297 "04c4dl8cm5rjr50k9qa6yl9r05fk9zcb1zxh0y0cdahxlsgcydfw"))))
1298 (build-system ruby-build-system)
1299 (arguments `(#:tests? #f)) ;gem doesn't ship with test suite
1300 (propagated-inputs
1301 `(("ruby-addressable" ,ruby-addressable)))
1302 (synopsis "Ruby Cascading Style Sheets (CSS) parser")
1303 (description "This package allows loading, parsing and cascading Cascading
1304 Style Sheets (CSS) rule sets in Ruby.")
1305 (home-page "https://github.com/premailer/css_parser")
1306 (license license:expat)))
1307
1308 (define-public ruby-prawn-svg
1309 (package
1310 (name "ruby-prawn-svg")
1311 (version "0.30.0")
1312 (source
1313 (origin
1314 (method url-fetch)
1315 (uri (rubygems-uri "prawn-svg" version))
1316 (sha256
1317 (base32
1318 "0df3l49cy3xpwi0b73hmi2ykbjg9kjwrvhk0k3z7qhh5ghmmrn77"))))
1319 (build-system ruby-build-system)
1320 (arguments
1321 `(#:phases (modify-phases %standard-phases
1322 (add-after 'unpack 'do-not-use-bundler
1323 (lambda _
1324 (substitute* "spec/spec_helper.rb"
1325 ((".*[Bb]undler.*") ""))
1326 #t))
1327 (replace 'check
1328 (lambda* (#:key tests? #:allow-other-keys)
1329 (when tests?
1330 (invoke "rspec" "-Ilib" "-rprawn-svg"))
1331 #t)))))
1332 (native-inputs
1333 `(("ruby-rspec" ,ruby-rspec)))
1334 (propagated-inputs
1335 `(("ruby-css-parser" ,ruby-css-parser)
1336 ("ruby-prawn" ,ruby-prawn)))
1337 (synopsis "SVG renderer for the Prawn PDF library")
1338 (description "This library allows rendering Scalable Vector Graphics (SVG)
1339 graphics directly into a Portable Document Format (PDF) document using the
1340 Prawn module.")
1341 (home-page "https://github.com/mogest/prawn-svg")
1342 (license license:expat)))
1343
1344 (define-public ruby-prawn-templates
1345 (package
1346 (name "ruby-prawn-templates")
1347 (version "0.1.2")
1348 (source
1349 (origin
1350 (method git-fetch)
1351 (uri (git-reference
1352 (url "https://github.com/prawnpdf/prawn-templates.git")
1353 (commit version)))
1354 (file-name (git-file-name name version))
1355 (sha256
1356 (base32
1357 "0wll54wxxwixpwazfn4ffbqvqbfrl01cfsv8y11vnlzy7isx5xvl"))))
1358 (build-system ruby-build-system)
1359 (arguments
1360 `(#:phases (modify-phases %standard-phases
1361 (add-after 'unpack 'do-not-use-bundler
1362 (lambda _
1363 (substitute* "spec/spec_helper.rb"
1364 ((".*[Bb]undler.*") ""))
1365 #t))
1366 (replace 'check
1367 (lambda* (#:key tests? #:allow-other-keys)
1368 (when tests?
1369 (invoke "rspec"))
1370 #t)))))
1371 (native-inputs
1372 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
1373 ("ruby-rspec" ,ruby-rspec)))
1374 (propagated-inputs
1375 `(("ruby-pdf-reader" ,ruby-pdf-reader)
1376 ("ruby-prawn" ,ruby-prawn)))
1377 (synopsis "Prawn extension to include or combine PDF documents")
1378 (description "This @strong{unmaintained} package provides a Prawn
1379 extension that allows including other Portable Document Format (PDF) documents
1380 as background or combining several PDF documents into one. This functionality
1381 used to be part of Prawn itself, but was extracted from Prawn 0.15.0 because
1382 of its many longstanding issues.")
1383 (home-page "https://github.com/prawnpdf/prawn-templates")
1384 (license %prawn-project-licenses)))
1385
1386 (define-public ruby-polyglot
1387 (package
1388 (name "ruby-polyglot")
1389 (version "0.3.5")
1390 (source
1391 (origin
1392 (method url-fetch)
1393 (uri (rubygems-uri "polyglot" version))
1394 (sha256
1395 (base32
1396 "1bqnxwyip623d8pr29rg6m8r0hdg08fpr2yb74f46rn1wgsnxmjr"))))
1397 (build-system ruby-build-system)
1398 (arguments `(#:tests? #f)) ;no test suite
1399 (synopsis "Augment @code{require} to load non-Ruby file types")
1400 (description "The Polyglot library allows a Ruby module to register a
1401 loader for the file type associated with a filename extension, and it augments
1402 @code{require} to find and load matching files.")
1403 (home-page "https://github.com/cjheath/polyglot")
1404 (license license:expat)))
1405
1406 (define-public ruby-treetop
1407 (package
1408 (name "ruby-treetop")
1409 (version "1.6.10")
1410 (source
1411 (origin
1412 (method git-fetch) ;no test suite in distributed gem
1413 (uri (git-reference
1414 (url "https://github.com/cjheath/treetop.git")
1415 (commit (string-append "v" version))))
1416 (file-name (git-file-name name version))
1417 (sha256
1418 (base32
1419 "1dmk94z6ivhrz5hsq68vl5vgydhkz89n394rha1ymddw3rymbfcv"))))
1420 (build-system ruby-build-system)
1421 (arguments
1422 `(#:test-target "spec"
1423 #:phases
1424 (modify-phases %standard-phases
1425 (replace 'replace-git-ls-files
1426 (lambda _
1427 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1428 ;; git ls-files output is merged in ruby-build-system.
1429 (substitute* "treetop.gemspec"
1430 (("`git ls-files -z`")
1431 "`find . -type f -print0 |sort -z|cut -zc3-`"))
1432 #t)))))
1433 (native-inputs
1434 `(("ruby-activesupport" ,ruby-activesupport)
1435 ("ruby-rr" ,ruby-rr)
1436 ("ruby-rspec" ,ruby-rspec)))
1437 (propagated-inputs
1438 `(("ruby-polyglot" ,ruby-polyglot)))
1439 (synopsis "Ruby-based parsing DSL based on parsing expression grammars")
1440 (description "This package provides a Ruby-based Parsing Expression
1441 Grammar (PEG) parser generator Domain Specific Language (DSL).")
1442 (home-page "https://github.com/cjheath/treetop")
1443 (license license:expat)))
1444
1445 (define-public ruby-rubocop-performance
1446 (package
1447 (name "ruby-rubocop-performance")
1448 (version "1.7.1")
1449 (source
1450 (origin
1451 (method url-fetch)
1452 (uri (rubygems-uri "rubocop-performance" version))
1453 (sha256
1454 (base32
1455 "04r8d4x62ygv17spvz9yyfxbmbf8qxwhijs0xycfvzr0q4pyg9sw"))))
1456 (build-system ruby-build-system)
1457 (arguments
1458 `(#:tests? #f)) ;no test suite in the distributed gem
1459 (propagated-inputs
1460 `(("ruby-rubocop" ,ruby-rubocop)))
1461 (synopsis "Performance optimizations checkers for Ruby code")
1462 (description "This package provides a collection of RuboCop cops to check
1463 for performance optimizations in Ruby code.")
1464 (home-page "https://docs.rubocop.org/rubocop-performance/")
1465 (license license:expat)))
1466
1467 (define-public ruby-gimme
1468 (let ((revision "1")
1469 (commit "4e71f0236f1271871916dd403261d26533db34c0"))
1470 (package
1471 (name "ruby-gimme")
1472 (version (git-version "0.5.0" revision commit))
1473 (source
1474 (origin
1475 (method git-fetch)
1476 (uri (git-reference
1477 (url "https://github.com/searls/gimme.git")
1478 (commit commit)))
1479 (file-name (git-file-name name version))
1480 (sha256
1481 (base32
1482 "0hrd32ygvf3i7h47ak8f623cz8ns9q7g60nnnvvlnywbggjaz3h6"))))
1483 (build-system ruby-build-system)
1484 (native-inputs
1485 `(("ruby-coveralls" ,ruby-coveralls)
1486 ("ruby-cucumber" ,ruby-cucumber)
1487 ("ruby-pry" ,ruby-pry)
1488 ("ruby-simplecov" ,ruby-simplecov)
1489 ("ruby-rspec-given" ,ruby-rspec-given)))
1490 (arguments
1491 `(;; The cucumber task fails with error: "index 3 out of matches
1492 ;; (IndexError)", apparently due to our newer Cucumber version.
1493 ;; TODO: Try the "default" task with a future release.
1494 #:test-target "spec"
1495 #:phases
1496 (modify-phases %standard-phases
1497 (add-after 'extract-gemspec 'prepare-for-tests
1498 (lambda _
1499 ;; Delete failing tests (possibly due to our newer rspec
1500 ;; version).
1501 (delete-file "spec/gimme/gives_class_methods_spec.rb")
1502 (delete-file "spec/gimme/rspec_adapter_spec.rb")
1503 (delete-file "spec/gimme/verifies_class_methods_spec.rb")
1504 ;; Fix duplicate version requirements and de-register files.
1505 (delete-file "Gemfile")
1506 (delete-file "Gemfile.lock")
1507 (substitute* "gimme.gemspec"
1508 ((".*\"Gemfile\".*") "")
1509 ((".*\"Gemfile\\.lock\",.*") "")
1510 ((".*(rspec|cucumber).*\">= 0\".*") "")
1511 (("\"spec/gimme/gives_class_methods_spec.rb\",") "")
1512 (("\"spec/gimme/rspec_adapter_spec.rb\",") "")
1513 (("\"spec/gimme/verifies_class_methods_spec.rb\",") "")
1514 ;; All of these gems relate to development, and are
1515 ;; unnecessary when running the tests.
1516 ((".*(add|gem).*guard-.*") "")
1517 ((".*(add|gem).*jeweler.*") "")
1518 ((".*(add|gem).*pry.*") "")
1519 ((".*(add|gem).*growl.*") "")
1520 ((".*(add|gem).*rb-fsevent.*") ""))
1521 #t)))))
1522 (synopsis "Lightweight test double library for Ruby")
1523 (description "Gimme is a very lightweight test double library for Ruby,
1524 based on Mockito (a mocking framework for Java). It is an opinionated (but
1525 not noisy) means to facilitate test-driving by enabling the authors to specify
1526 only what they care about.")
1527 (home-page "https://github.com/searls/gimme")
1528 (license license:expat))))
1529
1530 (define-public ruby-standard
1531 (package
1532 (name "ruby-standard")
1533 (version "0.4.7")
1534 (source
1535 (origin
1536 (method git-fetch) ;no test suite in distributed gem
1537 (uri (git-reference
1538 (url "https://github.com/testdouble/standard.git")
1539 (commit (string-append "v" version))))
1540 (file-name (git-file-name name version))
1541 (sha256
1542 (base32
1543 "0ylx0lm2pbbgr5h7fban592w96bl3wxmvfcpcdfrhkxnpg5kiwgv"))))
1544 (build-system ruby-build-system)
1545 (arguments
1546 ;; TODO: the tests are currently broken due to using a newer Rubocop.
1547 `(#:tests? #f
1548 #:phases
1549 (modify-phases %standard-phases
1550 (add-after 'unpack 'relax-version-requiremens
1551 (lambda _
1552 (delete-file "Gemfile")
1553 (delete-file "Gemfile.lock")
1554 #t))
1555 (replace 'replace-git-ls-files
1556 (lambda _
1557 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1558 ;; git ls-files output is merged in ruby-build-system.
1559 (substitute* "standard.gemspec"
1560 (("`git ls-files -z`")
1561 "`find . -type f -not -regex '.*\\.gem$' -print0 \
1562 |sort -z|cut -zc3-`"))
1563 #t)))))
1564 (native-inputs
1565 `(("ruby-gimme" ,ruby-gimme)
1566 ("ruby-pry" ,ruby-pry)
1567 ("ruby-simplecov" ,ruby-simplecov)))
1568 (propagated-inputs
1569 `(("ruby-rubocop" ,ruby-rubocop)
1570 ("ruby-rubocop-performance" ,ruby-rubocop-performance)))
1571 (synopsis "Ruby Style Guide, with linter & automatic code fixer")
1572 (description "Standard is a port of StandardJS. Like StandardJS, it aims
1573 to save time in the following ways:
1574 @itemize
1575 @item No configuration.
1576 @item Automatically format code.
1577 @item Catch style issues and programmer errors early.
1578 @end itemize")
1579 (home-page "https://github.com/testdouble/standard")
1580 (license license:expat)))
1581
1582 (define-public ruby-chunky-png
1583 (package
1584 (name "ruby-chunky-png")
1585 (version "1.3.12")
1586 (source
1587 (origin
1588 (method git-fetch)
1589 (uri (git-reference
1590 (url "https://github.com/wvanbergen/chunky_png.git")
1591 (commit (string-append "v" version))))
1592 (file-name (git-file-name name version))
1593 (sha256
1594 (base32
1595 "0hn8ap7iib47qkqdp0awmxgma11z0lmk1ca3lp7c97ykhv7ij1zs"))))
1596 (build-system ruby-build-system)
1597 (arguments
1598 `(#:test-target "spec"
1599 #:phases
1600 (modify-phases %standard-phases
1601 (add-after 'unpack 'disable-bundler
1602 (lambda _
1603 (substitute* (find-files "." "\\.rb$")
1604 (("require.*bundler/setup.*") ""))
1605 #t))
1606 (replace 'replace-git-ls-files
1607 (lambda _
1608 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1609 ;; git ls-files output is merged in ruby-build-system.
1610 (substitute* "chunky_png.gemspec"
1611 (("`git ls-files`")
1612 "`find . -type f -not -regex '.*\\.gem$' |sort |cut -c3-`"))
1613 #t)))))
1614 (native-inputs
1615 `(("bundler" ,bundler)
1616 ("ruby-rspec" ,ruby-rspec)
1617 ("ruby-standard" ,ruby-standard)
1618 ("ruby-yard" ,ruby-yard)))
1619 (synopsis "Ruby library to handle PNG images")
1620 (description "ChunkyPNG is a pure Ruby library that can read and write
1621 Portable Network Graphics (PNG) images without depending on an external image
1622 library. It tries to be memory efficient and reasonably fast. It has
1623 features such as:
1624 @itemize
1625 @item
1626 Decoding support for any image that the PNG standard allows. This includes all
1627 standard color modes, all bit depths, all transparency, and interlacing and
1628 filtering options.
1629 @item
1630 Encoding support for images of all color modes (true color, grayscale, and
1631 indexed) and transparency for all these color modes. The best color mode is
1632 chosen automatically, based on the amount of used colors.
1633 @item Read/write access to the image's pixels.
1634 @item Read/write access to all image metadata that is stored in chunks.
1635 @item
1636 Memory efficiency: @code{fixnum} are used, i.e. 4 or 8 bytes of memory per
1637 pixel, depending on the hardware).
1638 @item
1639 Performance: ChunkyPNG is reasonably fast for Ruby standards, by only using
1640 integer math and a highly optimized saving routine.
1641 @item Interoperability with RMagick.
1642 @end itemize")
1643 (home-page "https://github.com/wvanbergen/chunky_png/wiki")
1644 (license license:expat)))
1645
1646 (define-public ruby-text-hyphen
1647 (package
1648 (name "ruby-text-hyphen")
1649 (version "1.4.1")
1650 (source
1651 (origin
1652 (method url-fetch)
1653 (uri (rubygems-uri "text-hyphen" version))
1654 (sha256
1655 (base32
1656 "1gj4awvs9ryf960m0iawg43jyjmfwcqgfwrbcfp890a57b9ag7q1"))))
1657 (build-system ruby-build-system)
1658 (native-inputs
1659 `(("ruby-hoe" ,ruby-hoe)))
1660 (synopsis "Ruby library to hyphenate words in various languages")
1661 (description "Text::Hyphen is a Ruby library to hyphenate words in various
1662 languages using Ruby-fied versions of TeX hyphenation patterns. It will
1663 properly hyphenate various words according to the rules of the language the
1664 word is written in. The algorithm is based on that of the TeX typesetting
1665 system by Donald E. Knuth.")
1666 (home-page "https://github.com/halostatue/text-hyphen")
1667 ;; The whole is licensed under the Expat license, but parts use various
1668 ;; versions of the LaTeX Project Public License.
1669 (license license:expat)))
1670
1671 (define-public ruby-open-uri-cached
1672 (package
1673 (name "ruby-open-uri-cached")
1674 (version "0.0.5")
1675 (source
1676 (origin
1677 (method url-fetch)
1678 (uri (rubygems-uri "open-uri-cached" version))
1679 (sha256
1680 (base32
1681 "13xy2vhrgz9mdxhklw5fszhamsdxh8ysf3l40g92hqm4hm288wap"))))
1682 (build-system ruby-build-system)
1683 (arguments
1684 `(#:tests? #f)) ;no test suite
1685 (synopsis "OpenURI with transparent disk caching")
1686 (description "OpenURI with transparent disk caching, which is
1687 useful to avoid making excessive queries, for example when scraping
1688 web pages.")
1689 (home-page "https://github.com/tigris/open-uri-cached")
1690 (license license:expat)))
1691
1692 (define-public ruby-asciidoctor-pdf
1693 ;; Use the latest commit, as the last tag doesn't build with the
1694 ;; latest Ruby dependencies in Guix.
1695 (let ((revision "1")
1696 (commit "d257440df895d1595a3825ef58b32e4b290ba1c3"))
1697 (package
1698 (name "ruby-asciidoctor-pdf")
1699 (version (git-version "1.5.3" revision commit))
1700 (source
1701 (origin
1702 (method git-fetch) ;no test suite in the distributed gem
1703 (uri (git-reference
1704 (url "https://github.com/asciidoctor/asciidoctor-pdf.git")
1705 (commit commit)))
1706 (file-name (git-file-name name version))
1707 (sha256
1708 (base32
1709 "1563d11ghzsrsg4inwfwj6b9hb5sk5b429f49fwq5qg3sq76kgjj"))))
1710 (build-system ruby-build-system)
1711 (arguments
1712 `(#:test-target "spec"
1713 #:phases
1714 (modify-phases %standard-phases
1715 (add-after 'unpack 'remove-failing-tests
1716 ;; Two tests module fail for unknown reasons, *only* when
1717 ;; ran in the build container (see:
1718 ;; https://github.com/asciidoctor/asciidoctor-pdf/issues/1725#issuecomment-658777965).
1719 (lambda _
1720 (delete-file "spec/audio_spec.rb")
1721 (delete-file "spec/video_spec.rb")
1722 #t))
1723 (add-after 'extract-gemspec 'strip-version-requirements
1724 (lambda _
1725 (substitute* "asciidoctor-pdf.gemspec"
1726 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1727 (string-append stripped "\n")))
1728 #t))
1729 (replace 'replace-git-ls-files
1730 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1731 ;; git ls-files output is merged in ruby-build-system.
1732 (lambda _
1733 (substitute* "asciidoctor-pdf.gemspec"
1734 (("`git ls-files -z`")
1735 "`find . -type f -not -regex '.*\\.gem$' -print0 \
1736 |sort -z|cut -zc3-`"))
1737 #t))
1738 ;; The tests rely on the Gem being installed, so move the check phase
1739 ;; after the install phase.
1740 (delete 'check)
1741 (add-after 'install 'check
1742 (lambda* (#:key outputs tests? #:allow-other-keys)
1743 (let ((new-gem (string-append (assoc-ref outputs "out")
1744 "/lib/ruby/vendor_ruby")))
1745 (setenv "GEM_PATH"
1746 (string-append (getenv "GEM_PATH") ":" new-gem))
1747 (when tests?
1748 (invoke "rspec" "-t" "~visual" "-t" "~cli" "-t" "~network"))
1749 #t))))))
1750 (native-inputs
1751 `(("ruby-chunky-png" ,ruby-chunky-png)
1752 ("ruby-coderay" ,ruby-coderay)
1753 ("ruby-pdf-inspector" ,ruby-pdf-inspector)
1754 ("ruby-rouge" ,ruby-rouge)
1755 ("ruby-rspec" ,ruby-rspec)))
1756 (propagated-inputs
1757 `(("ruby-asciidoctor" ,ruby-asciidoctor)
1758 ("ruby-concurrent-ruby" ,ruby-concurrent)
1759 ("ruby-open-uri-cached" ,ruby-open-uri-cached)
1760 ("ruby-prawn" ,ruby-prawn)
1761 ("ruby-prawn-icon" ,ruby-prawn-icon)
1762 ("ruby-prawn-svg" ,ruby-prawn-svg)
1763 ("ruby-prawn-table" ,ruby-prawn-table)
1764 ("ruby-prawn-templates" ,ruby-prawn-templates)
1765 ("ruby-safe-yaml" ,ruby-safe-yaml)
1766 ("ruby-text-hyphen" ,ruby-text-hyphen)
1767 ("ruby-thread-safe" ,ruby-thread-safe)
1768 ("ruby-treetop" ,ruby-treetop)
1769 ("ruby-ttfunk" ,ruby-ttfunk)))
1770 (synopsis"AsciiDoc to Portable Document Format (PDF)} converter")
1771 (description "Asciidoctor PDF is an extension for Asciidoctor that
1772 converts AsciiDoc documents to Portable Document Format (PDF) using the Prawn
1773 PDF library. It has features such as:
1774 @itemize
1775 @item Direct AsciiDoc to PDF conversion
1776 @item Configuration-driven theme (style and layout)
1777 @item Scalable Vector Graphics (SVG) support
1778 @item PDF document outline (i.e., bookmarks)
1779 @item Table of contents page(s)
1780 @item Document metadata (title, authors, subject, keywords, etc.)
1781 @item Internal cross reference links
1782 @item Syntax highlighting with Rouge, Pygments, or CodeRay
1783 @item Page numbering
1784 @item Customizable running content (header and footer)
1785 @item
1786 “Keep together” blocks (i.e., page breaks avoided in certain block content)
1787 @item Orphaned section titles avoided
1788 @item Autofit verbatim blocks (as permitted by base_font_size_min setting)
1789 @item Table border settings honored
1790 @item Font-based icons
1791 @item Custom TrueType (TTF) fonts
1792 @item Double-sided printing mode (margins alternate on recto and verso pages)
1793 @end itemize")
1794 (home-page "https://asciidoctor.org/docs/asciidoctor-pdf")
1795 (license license:expat))))
1796
1797 (define-public ruby-ast
1798 (package
1799 (name "ruby-ast")
1800 (version "2.4.1")
1801 (source
1802 (origin
1803 (method git-fetch) ;no test included in gem from v2.4.1
1804 (uri (git-reference
1805 (url "https://github.com/whitequark/ast")
1806 (commit (string-append "v" version))))
1807 (file-name (git-file-name name version))
1808 (sha256
1809 (base32
1810 "0k8vya256chimy473g818gim06m5rjgh6mz5sc5g8xz3csh3rysi"))))
1811 (build-system ruby-build-system)
1812 (arguments
1813 '(#:phases
1814 (modify-phases %standard-phases
1815 (add-after 'unpack 'remove-coveralls-requirement
1816 (lambda _
1817 (substitute* "test/helper.rb"
1818 (("require 'coveralls'") "")
1819 (("Coveralls::SimpleCov::Formatter") ""))
1820 #t))
1821 (add-after 'extract-gemspec 'remove-unnecessary-requirements
1822 (lambda _
1823 (substitute* "ast.gemspec"
1824 ((".*coveralls.*") "\n")
1825 (("%q<rest-client>.*") "%q<rest-client>.freeze, [\">= 0\"])\n")
1826 (("%q<mime-types>.*") "%q<mime-types>.freeze, [\">= 0\"])\n")
1827 (("%q<rake>.*") "%q<rake>.freeze, [\">= 0\"])\n"))
1828 #t)))))
1829 (native-inputs
1830 `(("bundler" ,bundler)
1831 ("ruby-simplecov" ,ruby-simplecov)
1832 ("ruby-json-pure" ,ruby-json-pure)
1833 ("ruby-mime-times" ,ruby-mime-types)
1834 ("ruby-yard" ,ruby-yard)
1835 ("ruby-kramdown" ,ruby-kramdown)
1836 ("ruby-rest-client" ,ruby-rest-client)
1837 ("ruby-bacon" ,ruby-bacon)
1838 ("ruby-bacon-colored-output" ,ruby-bacon-colored-output)
1839 ("ruby-racc" ,ruby-racc)))
1840 (synopsis "Library for working with Abstract Syntax Trees")
1841 (description
1842 "@code{ast} is a Ruby library for working with Abstract Syntax Trees.
1843 It does this through immutable data structures.")
1844 (home-page "https://whitequark.github.io/ast/")
1845 (license license:expat)))
1846
1847 (define-public ruby-sporkmonger-rack-mount
1848 ;; Testing the addressable gem requires a newer commit than that released, so
1849 ;; use an up to date version.
1850 (let ((revision "1")
1851 (commit "076aa2c47d9a4c081f1e9bcb56a826a9e72bd5c3"))
1852 (package
1853 (name "ruby-sporkmonger-rack-mount")
1854 (version (git-version "0.8.3" revision commit))
1855 (source (origin
1856 (method git-fetch)
1857 (uri (git-reference
1858 (url "https://github.com/sporkmonger/rack-mount")
1859 (commit commit)))
1860 (file-name (git-file-name name version))
1861 (sha256
1862 (base32
1863 "1scx273g3xd93424x9lxc4zyvcp2niknbw5mkz6wkivpf7xsyxdq"))))
1864 (build-system ruby-build-system)
1865 (arguments
1866 ;; Tests currently fail so disable them.
1867 ;; https://github.com/sporkmonger/rack-mount/pull/1
1868 `(#:tests? #f))
1869 (propagated-inputs `(("ruby-rack" ,ruby-rack)))
1870 (synopsis "Stackable dynamic tree based Rack router")
1871 (description
1872 "@code{Rack::Mount} supports Rack's @code{X-Cascade} convention to
1873 continue trying routes if the response returns pass. This allows multiple
1874 routes to be nested or stacked on top of each other.")
1875 (home-page "https://github.com/sporkmonger/rack-mount")
1876 (license license:expat))))
1877
1878 (define-public ruby-ci-reporter
1879 (package
1880 (name "ruby-ci-reporter")
1881 (version "2.0.0")
1882 (source (origin
1883 (method url-fetch)
1884 (uri (rubygems-uri "ci_reporter" version))
1885 (sha256
1886 (base32
1887 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
1888 (build-system ruby-build-system)
1889 (arguments
1890 `(#:test-target "rspec"))
1891 (propagated-inputs
1892 `(("ruby-builder" ,ruby-builder)))
1893 (native-inputs
1894 `(("bundler" ,bundler)
1895 ("ruby-rspec" ,ruby-rspec)))
1896 (synopsis "Generate XML reports of runs test")
1897 (description
1898 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
1899 you to generate XML reports of your test runs. The resulting files can be
1900 read by a continuous integration system that understands Ant's JUnit report
1901 format.")
1902 (home-page "https://github.com/nicksieger/ci_reporter")
1903 (license license:expat)))
1904
1905 (define-public ruby-contracts
1906 (package
1907 (name "ruby-contracts")
1908 (version "0.16.0")
1909 (source
1910 (origin
1911 (method url-fetch)
1912 (uri (rubygems-uri "contracts" version))
1913 (sha256
1914 (base32
1915 "119f5p1n6r5svbx8h09za6a4vrsnj5i1pzr9cqdn9hj3wrxvyl3a"))))
1916 (build-system ruby-build-system)
1917 (arguments
1918 '(#:test-target "spec"
1919 #:phases
1920 (modify-phases %standard-phases
1921 ;; Don't run or require rubocop, the code linting tool, as this is a
1922 ;; bit unnecessary.
1923 (add-after 'unpack 'dont-run-rubocop
1924 (lambda _
1925 (substitute* "Rakefile"
1926 ((".*rubocop.*") "")
1927 ((".*RuboCop.*") ""))
1928 #t)))))
1929 (native-inputs
1930 `(("ruby-rspec" ,ruby-rspec)))
1931 (synopsis "Method contracts for Ruby")
1932 (description
1933 "This library provides contracts for Ruby. A contract describes the
1934 correct inputs and output for a method, and will raise an error if a incorrect
1935 value is found.")
1936 (home-page "https://github.com/egonSchiele/contracts.ruby")
1937 (license license:bsd-2)))
1938
1939 (define-public ruby-crack
1940 (package
1941 (name "ruby-crack")
1942 (version "0.4.3")
1943 (source
1944 (origin
1945 (method url-fetch)
1946 (uri (rubygems-uri "crack" version))
1947 (sha256
1948 (base32
1949 "0abb0fvgw00akyik1zxnq7yv391va148151qxdghnzngv66bl62k"))))
1950 (build-system ruby-build-system)
1951 (arguments
1952 `(#:phases
1953 (modify-phases %standard-phases
1954 (replace 'check
1955 (lambda* (#:key tests? #:allow-other-keys)
1956 (when tests?
1957 (for-each (lambda (file)
1958 (display file)(display "\n")
1959 (invoke "ruby" "-Ilib" "-Itest" "-rrubygems" file))
1960 (find-files "test" ".*rb$")))
1961 #t)))))
1962 (propagated-inputs
1963 `(("ruby-safe-yaml" ,ruby-safe-yaml)))
1964 (synopsis "Simple JSON and XML parsing for Ruby")
1965 (description
1966 "@code{crack} provides really simple JSON and XML parsing, extracted from
1967 code in Merb and Rails.")
1968 (home-page "https://github.com/jnunemaker/crack")
1969 (license license:expat)))
1970
1971 (define-public ruby-cliver
1972 (package
1973 (name "ruby-cliver")
1974 (version "0.3.2")
1975 (source
1976 (origin
1977 (method url-fetch)
1978 (uri (rubygems-uri "cliver" version))
1979 (sha256
1980 (base32
1981 "096f4rj7virwvqxhkavy0v55rax10r4jqf8cymbvn4n631948xc7"))))
1982 (build-system ruby-build-system)
1983 (arguments
1984 '(#:phases
1985 (modify-phases %standard-phases
1986 ;; Avoid a incompatibility between rspec@2 and rake. Using rspec@3
1987 ;; would be nice, but the tests look to be incompatible:
1988 ;;
1989 ;; NoMethodError: undefined method `last_comment'
1990 (replace 'check
1991 (lambda* (#:key tests? #:allow-other-keys)
1992 (when tests?
1993 (invoke "rspec"))
1994 #t)))))
1995 (native-inputs
1996 `(("bundler" ,bundler)
1997 ("ruby-rspec" ,ruby-rspec-2)))
1998 (synopsis "Assertions for command-line dependencies in Ruby")
1999 (description
2000 "@code{cliver} provides a way to detect missing command-line
2001 dependencies, including versions.")
2002 (home-page "https://github.com/yaauie/cliver")
2003 (license license:expat)))
2004
2005 (define-public ruby-czmq-ffi-gen
2006 (package
2007 (name "ruby-czmq-ffi-gen")
2008 (version "0.13.0")
2009 (source
2010 (origin
2011 (method url-fetch)
2012 (uri (rubygems-uri "czmq-ffi-gen" version))
2013 (sha256
2014 (base32
2015 "1yf719dmf4mwks1hqdsy6i5kzfvlsha69sfnhb2fr2cgk2snbys3"))))
2016 (build-system ruby-build-system)
2017 (arguments
2018 '(#:tests? #f ;; Tests are not included in the release on rubygems.org
2019 #:phases
2020 (modify-phases %standard-phases
2021 (add-after 'unpack 'patch-lib_dirs
2022 (lambda* (#:key inputs #:allow-other-keys)
2023 (substitute* "lib/czmq-ffi-gen/czmq/ffi.rb"
2024 (("lib\\_dirs = \\[.*\\]")
2025 (string-append "lib_dirs = ['"
2026 (assoc-ref inputs "czmq") "/lib"
2027 "']")))
2028 (substitute* "lib/czmq-ffi-gen/libzmq.rb"
2029 (("lib\\_dirs = \\[.*\\]")
2030 (string-append "lib_dirs = ['"
2031 (assoc-ref inputs "zeromq") "/lib"
2032 "']"))))))))
2033 (inputs
2034 `(("zeromq" ,zeromq)
2035 ("czmq" ,czmq)))
2036 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
2037 (synopsis "Low-level Ruby bindings for CZMQ (generated using zproject)")
2038 (description
2039 "These Ruby bindings are not intended to be directly used, but rather
2040 used by higher level bindings like those provided by CZTop.")
2041 (home-page
2042 "https://github.com/paddor/czmq-ffi-gen")
2043 (license license:isc)))
2044
2045 (define-public ruby-cztop
2046 (package
2047 (name "ruby-cztop")
2048 (version "0.12.2")
2049 (source
2050 (origin
2051 (method url-fetch)
2052 (uri (rubygems-uri "cztop" version))
2053 (sha256
2054 (base32
2055 "0yqbpaiw5d7f271d73lyrsh8xpx6n4zi6xqwfgi00dacxrq3s3fa"))))
2056 (build-system ruby-build-system)
2057 (arguments
2058 '(#:test-target "spec"
2059 #:phases
2060 (modify-phases %standard-phases
2061 (add-after 'unpack 'patch-lib_paths
2062 (lambda* (#:key inputs #:allow-other-keys)
2063 (substitute* "lib/cztop/poller/zmq.rb"
2064 (("lib\\_paths = \\[.*\\]")
2065 (string-append "lib_paths = ['"
2066 (assoc-ref inputs "zeromq") "/lib"
2067 "']"))))))))
2068 (native-inputs
2069 `(("bundler" ,bundler)
2070 ("ruby-rspec" ,ruby-rspec)))
2071 (inputs
2072 `(("zeromq" ,zeromq)))
2073 (propagated-inputs
2074 `(("ruby-czmq-ffi-gen" ,ruby-czmq-ffi-gen)))
2075 (synopsis "CZMQ Ruby bindings")
2076 (description
2077 "CZMQ Ruby bindings, based on the generated low-level FFI bindings of
2078 CZMQ. The focus of of CZTop is on being easy to use and providing first class
2079 support for security mechanisms.")
2080 (home-page "https://github.com/paddor/cztop")
2081 (license license:isc)))
2082
2083 (define-public ruby-saikuro-treemap
2084 (package
2085 (name "ruby-saikuro-treemap")
2086 (version "0.2.0")
2087 (source (origin
2088 (method url-fetch)
2089 (uri (rubygems-uri "saikuro_treemap" version))
2090 (sha256
2091 (base32
2092 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
2093 (build-system ruby-build-system)
2094 ;; Some of the tests fail because the generated JSON has keys in a
2095 ;; different order. This is a problem with the test suite rather than any
2096 ;; of the involved libraries.
2097 (arguments `(#:tests? #f))
2098 (propagated-inputs
2099 `(("ruby-json-pure" ,ruby-json-pure)
2100 ("ruby-atoulme-saikuro" ,ruby-atoulme-saikuro)))
2101 (synopsis "Generate complexity treemap based on saikuro analysis")
2102 (description
2103 "This gem generates a treemap showing the complexity of Ruby code on
2104 which it is run. It uses Saikuro under the covers to analyze Ruby code
2105 complexity.")
2106 (home-page "https://github.com/ThoughtWorksStudios/saikuro_treemap")
2107 (license license:expat)))
2108
2109 (define-public ruby-oauth2
2110 (package
2111 (name "ruby-oauth2")
2112 (version "1.4.2")
2113 (source
2114 (origin
2115 (method url-fetch)
2116 (uri (rubygems-uri "oauth2" version))
2117 (sha256
2118 (base32 "15i9z4j5pcjkr30lkcd79xzbr4kpmy0bqgwa436fqyqk646fv036"))))
2119 (build-system ruby-build-system)
2120 (arguments
2121 '(#:tests? #f)) ; no included tests
2122 (propagated-inputs
2123 `(("ruby-faraday" ,ruby-faraday)
2124 ("ruby-jwt" ,ruby-jwt)
2125 ("ruby-multi-json" ,ruby-multi-json)
2126 ("ruby-multi-xml" ,ruby-multi-xml)
2127 ("ruby-rack" ,ruby-rack)))
2128 (synopsis "Ruby wrapper for the OAuth 2.0")
2129 (description
2130 "This package provides a Ruby wrapper for the OAuth 2.0 protocol built
2131 with a similar style to the original OAuth spec.")
2132 (home-page "https://github.com/oauth-xx/oauth2")
2133 (license license:expat)))
2134
2135 (define-public ruby-omniauth
2136 (package
2137 (name "ruby-omniauth")
2138 (version "1.9.1")
2139 (source
2140 (origin
2141 (method url-fetch)
2142 (uri (rubygems-uri "omniauth" version))
2143 (sha256
2144 (base32 "002vi9gwamkmhf0dsj2im1d47xw2n1jfhnzl18shxf3ampkqfmyz"))))
2145 (build-system ruby-build-system)
2146 (arguments
2147 '(#:tests? #f)) ; No included tests
2148 (propagated-inputs
2149 `(("ruby-hashie" ,ruby-hashie)
2150 ("ruby-rack" ,ruby-rack)))
2151 (synopsis "Generalized Rack framework for multiple-provider authentication")
2152 (description
2153 "This package provides a generalized Rack framework for multiple-provider
2154 authentication.")
2155 (home-page "https://github.com/omniauth/omniauth")
2156 (license license:expat)))
2157
2158 (define-public ruby-omniauth-oauth2
2159 (package
2160 (name "ruby-omniauth-oauth2")
2161 (version "1.6.0")
2162 (source
2163 (origin
2164 (method url-fetch)
2165 (uri (rubygems-uri "omniauth-oauth2" version))
2166 (sha256
2167 (base32
2168 "11mi36l9d97r77q99jnafdc1yaa0a9wahhpp7dj7ank8q52g7g79"))))
2169 (build-system ruby-build-system)
2170 (arguments
2171 '(#:phases
2172 (modify-phases %standard-phases
2173 (add-after 'unpack 'remove-unnecessary-dependencies
2174 (lambda _
2175 ;; The coveralls gem submits coverage information to an online
2176 ;; service, and is unnecessary when running the tests
2177 (substitute* "Gemfile"
2178 ((".*coveralls\"") ""))
2179 (substitute* "spec/helper.rb"
2180 (("require \"coveralls\"") "")
2181 (("Coveralls::SimpleCov::Formatter") ""))
2182 #t)))))
2183 (propagated-inputs
2184 `(("ruby-oauth2" ,ruby-oauth2)
2185 ("ruby-omniauth" ,ruby-omniauth)))
2186 (native-inputs
2187 `(("bundler" ,bundler)
2188 ("ruby-rspec" ,ruby-rspec)
2189 ("ruby-simplecov" ,ruby-simplecov)
2190 ("ruby-rack-test" ,ruby-rack-test)
2191 ("ruby-webmock" ,ruby-webmock-2)))
2192 (synopsis "Abstract OAuth2 strategy for OmniAuth")
2193 (description
2194 "This library provides a generic OAuth2 strategy for OmniAuth. It
2195 doesn't provide a way to gather user information, so should be used as a
2196 building block for authentication strategies.")
2197 (home-page "https://github.com/omniauth/omniauth-oauth2")
2198 (license license:expat)))
2199
2200 (define-public ruby-open4
2201 (package
2202 (name "ruby-open4")
2203 (version "1.3.4")
2204 (source
2205 (origin
2206 (method url-fetch)
2207 (uri (rubygems-uri "open4" version))
2208 (sha256
2209 (base32
2210 "1cgls3f9dlrpil846q0w7h66vsc33jqn84nql4gcqkk221rh7px1"))))
2211 (build-system ruby-build-system)
2212 (arguments
2213 '(#:phases
2214 (modify-phases %standard-phases
2215 (add-after 'unpack 'patch
2216 (lambda _
2217 (substitute* "rakefile"
2218 ;; Update the Rakefile so it works
2219 (("-rubygems") "-rrubygems")
2220 (("Config") "RbConfig"))
2221 #t))
2222 (add-before 'check 'set-LIB
2223 (lambda _
2224 ;; This is used in the rakefile when running the tests
2225 (setenv "LIB" "open4")
2226 #t)))))
2227 (synopsis "Open child processes from Ruby and manage them easily")
2228 (description
2229 "@code{Open4} is a Ruby library to run child processes and manage their
2230 input and output.")
2231 (home-page "https://github.com/ahoward/open4")
2232 (license license:ruby)))
2233
2234 (define-public ruby-options
2235 (package
2236 (name "ruby-options")
2237 (version "2.3.2")
2238 (source
2239 (origin
2240 (method url-fetch)
2241 (uri (rubygems-uri "options" version))
2242 (sha256
2243 (base32
2244 "1s650nwnabx66w584m1cyw82icyym6hv5kzfsbp38cinkr5klh9j"))))
2245 (build-system ruby-build-system)
2246 (arguments
2247 '(#:tests? #f ;; TODO: NameError: uninitialized constant Config
2248 #:phases
2249 (modify-phases %standard-phases
2250 (add-before 'check 'set-LIB
2251 (lambda _
2252 ;; This is used in the Rakefile, and setting it avoids an issue
2253 ;; with running the tests.
2254 (setenv "LIB" "options")
2255 #t)))))
2256 (synopsis "Ruby library to parse options from *args cleanly")
2257 (description
2258 "The @code{options} library helps with parsing keyword options in Ruby
2259 functions.")
2260 (home-page "https://github.com/ahoward/options")
2261 (license license:ruby)))
2262
2263 (define-public ruby-erubi
2264 (package
2265 (name "ruby-erubi")
2266 (version "1.8.0")
2267 (source
2268 (origin
2269 (method url-fetch)
2270 (uri (rubygems-uri "erubi" version))
2271 (sha256
2272 (base32
2273 "1kagnf6ziahj0d781s6ryy6fwqwa3ad4xbzzj84p9m4nv4c2jir1"))))
2274 (build-system ruby-build-system)
2275 (synopsis "ERB template engine for Ruby")
2276 (description
2277 "Erubi is a ERB template engine for Ruby. It is a simplified fork of
2278 Erubis")
2279 (home-page "https://github.com/jeremyevans/erubi")
2280 (license license:expat)))
2281
2282 (define-public ruby-erubis
2283 (package
2284 (name "ruby-erubis")
2285 (version "2.7.0")
2286 (source
2287 (origin
2288 (method url-fetch)
2289 (uri (rubygems-uri "erubis" version))
2290 (sha256
2291 (base32
2292 "1fj827xqjs91yqsydf0zmfyw9p4l2jz5yikg3mppz6d7fi8kyrb3"))))
2293 (build-system ruby-build-system)
2294 (arguments
2295 '(#:tests? #f)) ; tests do not run properly with Ruby 2.0
2296 (synopsis "Implementation of embedded Ruby (eRuby)")
2297 (description
2298 "Erubis is a fast implementation of embedded Ruby (eRuby) with several
2299 features such as multi-language support, auto escaping, auto trimming spaces
2300 around @code{<% %>}, a changeable embedded pattern, and Ruby on Rails
2301 support.")
2302 (home-page "http://www.kuwata-lab.com/erubis/")
2303 (license license:expat)))
2304
2305 (define-public ruby-execjs
2306 (package
2307 (name "ruby-execjs")
2308 (version "2.7.0")
2309 (source
2310 (origin
2311 ;; fetch from github as the gem does not contain testing code
2312 (method git-fetch)
2313 (uri (git-reference
2314 (url "https://github.com/rails/execjs")
2315 (commit (string-append "v" version))))
2316 (file-name (git-file-name name version))
2317 (sha256
2318 (base32
2319 "0c0vd2mmqq3ar4plbwi2wsbr31vn4h45i19r5km66skydnnbp1y6"))))
2320 (build-system ruby-build-system)
2321 (native-inputs
2322 `(("bundler" ,bundler)
2323 ;; The test suite tests all the available backends. Currenly, this just
2324 ;; means the node backend.
2325 ;;
2326 ;; PASSED: test:node
2327 ;; SKIPPED: test:duktape, ;; test:javascriptcore, test:jscript,
2328 ;; test:miniracer, test:rubyracer, ;; test:rubyrhino, test:v8
2329 ("node" ,node)))
2330 (synopsis "Run JavaScript code from Ruby")
2331 (description
2332 "ExecJS lets you run JavaScript code from Ruby. It automatically picks a
2333 runtime to evaluate your JavaScript program, then returns the result to you as
2334 a Ruby object.")
2335 (home-page "https://github.com/rails/execjs")
2336 (license license:expat)))
2337
2338 (define-public ruby-fakefs
2339 (package
2340 (name "ruby-fakefs")
2341 (version "1.2.2")
2342 (home-page "https://github.com/fakefs/fakefs")
2343 (source (origin
2344 ;; The Rubygems release does not contain tests.
2345 (method git-fetch)
2346 (uri (git-reference
2347 (url home-page)
2348 (commit (string-append "v" version))))
2349 (file-name (git-file-name name version))
2350 (sha256
2351 (base32
2352 "008dq9knyip2bfbl0mrk8b8r7bv0k3bf128wcfqsgy1rqal4mgwk"))))
2353 (build-system ruby-build-system)
2354 (arguments
2355 '(#:phases (modify-phases %standard-phases
2356 (replace 'replace-git-ls-files
2357 (lambda _
2358 (substitute* "fakefs.gemspec"
2359 (("`git ls-files lib README.md LICENSE`")
2360 "`find lib README.md LICENSE -type f | sort`"))
2361 #t))
2362 (add-before 'check 'remove-version-constraints
2363 (lambda _
2364 ;; Drop hard version requirements for test dependencies.
2365 (substitute* "fakefs.gemspec"
2366 (("(.*add_development_dependency .*), .*" _ dep)
2367 (string-append dep "\n")))
2368 #t)))))
2369 (native-inputs
2370 `(("ruby-bump" ,ruby-bump)
2371 ("ruby-maxitest" ,ruby-maxitest)
2372 ("ruby-rubocop" ,ruby-rubocop)
2373 ("ruby-rspec" ,ruby-rspec)))
2374 (synopsis "Fake file system for Ruby")
2375 (description
2376 "This package provides a fake file system for use in test suites. It
2377 avoids the need for manually creating temporary directories, or dealing
2378 with platform intricacies in @code{File} and @code{FileUtils}.")
2379 (license license:expat)))
2380
2381 (define-public ruby-orderedhash
2382 (package
2383 (name "ruby-orderedhash")
2384 (version "0.0.6")
2385 (source (origin
2386 (method url-fetch)
2387 (uri (rubygems-uri "orderedhash" version))
2388 (sha256
2389 (base32
2390 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
2391 (build-system ruby-build-system)
2392 (arguments
2393 '(#:tests? #f)) ; no test suite
2394 (synopsis "Ruby library providing an order-preserving hash")
2395 (description "Orderedhash is a Ruby library providing a hash
2396 implementation that preserves the order of items and features some array-like
2397 extensions.")
2398 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
2399 (license license:public-domain)))
2400
2401 (define-public ruby-libxml
2402 (package
2403 (name "ruby-libxml")
2404 (version "3.0.0")
2405 (source
2406 (origin
2407 (method url-fetch)
2408 (uri (rubygems-uri "libxml-ruby" version))
2409 (sha256
2410 (base32
2411 "0xy8wmjwjcnv36zi042678ncjzpxvy351ccbv7mzkns2n3kxfp54"))))
2412 (build-system ruby-build-system)
2413 (inputs
2414 `(("zlib" ,zlib)
2415 ("libxml2" ,libxml2)))
2416 (arguments
2417 '(#:tests? #f ; test suite hangs for unknown reason
2418 #:gem-flags
2419 (list "--"
2420 (string-append "--with-xml2-include="
2421 (assoc-ref %build-inputs "libxml2")
2422 "/include/libxml2" ))))
2423 (synopsis "Ruby bindings for GNOME Libxml2")
2424 (description "The Libxml-Ruby project provides Ruby language bindings for
2425 the GNOME Libxml2 XML toolkit.")
2426 (home-page "https://xml4r.github.com/libxml-ruby")
2427 (license license:expat)))
2428
2429 (define-public ruby-lino
2430 (package
2431 (name "ruby-lino")
2432 (version "1.1.0")
2433 (source
2434 (origin
2435 (method url-fetch)
2436 (uri (rubygems-uri "lino" version))
2437 (sha256
2438 (base32
2439 "11d29g0fk372b9fcpyr0k6hxm2b4j4igpysmi542hgbbgqgp9cd3"))))
2440 (build-system ruby-build-system)
2441 (arguments
2442 '(#:tests? #f)) ; No included tests
2443 (propagated-inputs
2444 `(("ruby-hamster" ,ruby-hamster)
2445 ("ruby-open4" ,ruby-open4)))
2446 (synopsis "Build and execute commands in Ruby")
2447 (description
2448 "@code{Lino} provides an interface to run external commands. It provides
2449 an interface to add options as well as managing the standard input, output and
2450 error streams.")
2451 (home-page "https://github.com/tobyclemson/lino")
2452 (license license:expat)))
2453
2454 (define-public ruby-xml-simple
2455 (package
2456 (name "ruby-xml-simple")
2457 (version "1.1.5")
2458 (source (origin
2459 (method url-fetch)
2460 (uri (rubygems-uri "xml-simple" version))
2461 (sha256
2462 (base32
2463 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
2464 (build-system ruby-build-system)
2465 (arguments
2466 '(#:tests? #f)) ; no test suite
2467 (synopsis "Simple Ruby library for XML processing")
2468 (description "This library provides a simple API for XML processing in
2469 Ruby.")
2470 (home-page "https://github.com/maik/xml-simple")
2471 (license license:ruby)))
2472
2473 (define-public ruby-thor
2474 (package
2475 (name "ruby-thor")
2476 (version "1.0.1")
2477 (source (origin
2478 ;; Pull from git because the gem has no tests.
2479 (method git-fetch)
2480 (uri (git-reference
2481 (url "https://github.com/erikhuda/thor")
2482 (commit (string-append "v" version))))
2483 (file-name (git-file-name name version))
2484 (sha256
2485 (base32
2486 "1anrx5vynk57hn5c8ig5pgkmcsbj9q5mvckd5rviw1jid7n89k57"))))
2487 (build-system ruby-build-system)
2488 (arguments
2489 '(#:phases (modify-phases %standard-phases
2490 (add-after 'unpack 'fix-readline-tests
2491 (lambda _
2492 ;; Ensure Readline is initialized before running the
2493 ;; test to avoid a type clash with the mock ::Readline.
2494 ;; See <https://github.com/erikhuda/thor/pull/717>.
2495 (substitute* "spec/line_editor/readline_spec.rb"
2496 (("unless defined\\? ::Readline" all)
2497 (string-append "Thor::LineEditor::Readline.available?\n"
2498 all)))
2499 #t))
2500 (add-after 'unpack 'remove-coveralls-dependency
2501 (lambda _
2502 ;; Do not hook the test suite into the online
2503 ;; coveralls service.
2504 (substitute* "Gemfile"
2505 ((".*coveralls.*") ""))
2506 (substitute* "spec/helper.rb"
2507 (("require \"coveralls\"") "")
2508 (("Coveralls::SimpleCov::Formatter") "")
2509 ;; Also drop the WebMock dependency which is only
2510 ;; present to allow a coveralls.io connection, and
2511 ;; would otherwise introduce a circular dependency.
2512 (("require \"webmock/rspec\"") "")
2513 (("WebMock\\.disable_net_connect.*") ""))
2514 #t))
2515 (add-after 'unpack 'disable-network-tests
2516 (lambda _
2517 ;; These tests attempt to look up example.com.
2518 (substitute* "spec/actions/file_manipulation_spec.rb"
2519 (("it \"accepts (https?) remote sources" _ proto)
2520 (string-append "xit \"accepts " proto " remote sources")))
2521 #t))
2522 (add-after 'unpack 'disable-quality-tests
2523 (lambda _
2524 ;; These tests attempt to check the git repository for
2525 ;; tabs vs spaces, double vs single quotes, etc, and
2526 ;; depend on the git checkout.
2527 (delete-file "spec/quality_spec.rb")
2528 #t))
2529 (add-before 'check 'make-files-writable
2530 (lambda _
2531 ;; The tests needs rw access to the test suite.
2532 (for-each make-file-writable (find-files "spec"))
2533 #t))
2534 (replace 'check
2535 (lambda _
2536 (invoke "rspec" "spec"))))))
2537 (native-inputs
2538 `(("ruby-rspec" ,ruby-rspec)
2539 ("ruby-simplecov" ,ruby-simplecov)))
2540 (synopsis "Ruby toolkit for building command-line interfaces")
2541 (description "Thor is a toolkit for building powerful command-line
2542 interfaces.")
2543 (home-page "http://whatisthor.com/")
2544 (license license:expat)))
2545
2546 (define-public ruby-lumberjack
2547 (package
2548 (name "ruby-lumberjack")
2549 (version "1.0.13")
2550 (source (origin
2551 (method url-fetch)
2552 (uri (rubygems-uri "lumberjack" version))
2553 (sha256
2554 (base32
2555 "06im7gcg42x77yhz2w5da2ly9xz0n0c36y5ks7xs53v0l9g0vf5n"))))
2556 (build-system ruby-build-system)
2557 (native-inputs
2558 `(("ruby-rspec" ,ruby-rspec)
2559 ("ruby-timecop" ,ruby-timecop)))
2560 (synopsis "Logging utility library for Ruby")
2561 (description "Lumberjack is a simple logging utility that can be a drop in
2562 replacement for Logger or ActiveSupport::BufferedLogger. It provides support
2563 for automatically rolling log files even with multiple processes writing the
2564 same log file.")
2565 (home-page "https://github.com/bdurand/lumberjack")
2566 (license license:expat)))
2567
2568 (define-public ruby-rbnacl
2569 (package
2570 (name "ruby-rbnacl")
2571 (version "6.0.1")
2572 (source
2573 (origin
2574 (method url-fetch)
2575 (uri (rubygems-uri "rbnacl" version))
2576 (sha256
2577 (base32
2578 "0ajxy5kj2jw09wdsla3jmha8w07vj5l14288xr9djpl327g3lzhn"))))
2579 (build-system ruby-build-system)
2580 (arguments
2581 `(#:phases
2582 (modify-phases %standard-phases
2583 (add-after 'unpack 'remove-unnecessary-dependencies
2584 (lambda _
2585 ;; Coveralls relates to a network service, and Rubocop to code
2586 ;; linting and both are unnecessary to run the tests
2587 (substitute* "Gemfile"
2588 ((".*rubocop.*") "\n")
2589 ((".*guard-rspec.*") "\n")
2590 ((".*coveralls.*") "\n"))
2591 (substitute* "spec/spec_helper.rb"
2592 (("require \"coveralls\"") "")
2593 (("Coveralls.wear!") ""))
2594 #t))
2595 (add-after 'unpack 'use-libsodium-from-store
2596 (lambda* (#:key inputs #:allow-other-keys)
2597 (substitute* '("lib/rbnacl/init.rb"
2598 "lib/rbnacl/sodium.rb")
2599 (("ffi_lib \\[.+\\]")
2600 (string-append "ffi_lib [\""
2601 (assoc-ref inputs "libsodium") "/lib/libsodium.so"
2602 "\"]")))
2603 #t))
2604 ;; Run Rspec directly to avoid the Rubocop dependency in the Rakefile
2605 (replace 'check
2606 (lambda* (#:key tests? #:allow-other-keys)
2607 (when tests?
2608 (invoke "rspec"))
2609 #t)))))
2610 (propagated-inputs
2611 `(("ruby-ffi" ,ruby-ffi)))
2612 (inputs
2613 `(("libsodium" ,libsodium)))
2614 (native-inputs
2615 `(("bundler" ,bundler)
2616 ("ruby-rspec" ,ruby-rspec)))
2617 (synopsis "Ruby FFI binding to libsodium")
2618 (description
2619 "This package provides Ruby FFI bindings to the Networking and
2620 Cryptography (NaCl) library, also known as libsodium. This provides a
2621 high-level toolkit for building cryptographic systems and protocols.")
2622 (home-page "https://github.com/crypto-rb/rbnacl")
2623 (license license:expat)))
2624
2625 (define-public ruby-nenv
2626 (package
2627 (name "ruby-nenv")
2628 (version "0.3.0")
2629 (source (origin
2630 (method url-fetch)
2631 (uri (rubygems-uri "nenv" version))
2632 (sha256
2633 (base32
2634 "0r97jzknll9bhd8yyg2bngnnkj8rjhal667n7d32h8h7ny7nvpnr"))))
2635 (build-system ruby-build-system)
2636 (arguments
2637 `(#:tests? #f)) ; no tests included
2638 (native-inputs
2639 `(("ruby-rspec" ,ruby-rspec)
2640 ("bundler" ,bundler)))
2641 (synopsis "Ruby interface for modifying the environment")
2642 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
2643 and inspect the environment.")
2644 (home-page "https://github.com/e2/nenv")
2645 (license license:expat)))
2646
2647 (define-public ruby-ptools
2648 (package
2649 (name "ruby-ptools")
2650 (version "1.3.5")
2651 (source (origin
2652 (method url-fetch)
2653 (uri (rubygems-uri "ptools" version))
2654 (sha256
2655 (base32
2656 "1jb1h1nsk9zwykpniw8filbsk26kjsdlpk5wz6w0zyamcd41h87j"))))
2657 (build-system ruby-build-system)
2658 (arguments
2659 '(#:phases (modify-phases %standard-phases
2660 (add-after 'unpack 'patch-/bin/ls
2661 (lambda _
2662 (substitute* "test/test_binary.rb"
2663 (("/bin/ls")
2664 (which "ls")))
2665 #t))
2666 (add-before 'install 'create-gem
2667 (lambda _
2668 ;; Do not attempt to sign the gem.
2669 (substitute* "Rakefile"
2670 (("spec\\.signing_key = .*")
2671 ""))
2672 (invoke "rake" "gem:create"))))))
2673 (synopsis "Extra methods for Ruby's @code{File} class")
2674 (description
2675 "The @dfn{ptools} (power tools) library extends Ruby's core @code{File}
2676 class with many additional methods modelled after common POSIX tools, such as
2677 @code{File.which} for finding executables, @code{File.tail} to print the last
2678 lines of a file, @code{File.wc} to count words, and so on.")
2679 (home-page "https://github.com/djberg96/ptools")
2680 (license license:artistic2.0)))
2681
2682 (define-public ruby-permutation
2683 (package
2684 (name "ruby-permutation")
2685 (version "0.1.8")
2686 (source (origin
2687 (method url-fetch)
2688 (uri (rubygems-uri "permutation" version))
2689 (sha256
2690 (base32
2691 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
2692 (build-system ruby-build-system)
2693 (arguments
2694 `(#:phases
2695 (modify-phases %standard-phases
2696 (add-after 'unpack 'fix-rakefile
2697 (lambda _
2698 (substitute* "Rakefile"
2699 (("require 'rake/gempackagetask'")
2700 "require 'rubygems/package_task'")
2701 (("include Config") ""))
2702 #t))
2703 (replace 'check
2704 (lambda _
2705 (invoke "ruby" "-Ilib" "test/test.rb"))))))
2706 (synopsis "Library to perform operations with sequence permutations")
2707 (description "This package provides a Ruby library to perform different
2708 operations with permutations of sequences, such as strings and arrays.")
2709 (home-page "https://flori.github.io/permutation")
2710 (license license:gpl2))) ; GPL 2 only
2711
2712 (define-public ruby-shellany
2713 (package
2714 (name "ruby-shellany")
2715 (version "0.0.1")
2716 (source (origin
2717 (method url-fetch)
2718 (uri (rubygems-uri "shellany" version))
2719 (sha256
2720 (base32
2721 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
2722 (build-system ruby-build-system)
2723 (arguments
2724 `(#:test-target "default"
2725 #:phases
2726 (modify-phases %standard-phases
2727 (add-after 'unpack 'fix-version-test
2728 (lambda _
2729 (substitute* "spec/shellany_spec.rb"
2730 (("^RSpec") "require \"shellany\"\nRSpec"))
2731 #t)))))
2732 (native-inputs
2733 `(("ruby-rspec" ,ruby-rspec)
2734 ("ruby-nenv" ,ruby-nenv)
2735 ("bundler" ,bundler)))
2736 (synopsis "Capture command output")
2737 (description "Shellany is a Ruby library providing functions to capture
2738 the output produced by running shell commands.")
2739 (home-page "https://rubygems.org/gems/shellany")
2740 (license license:expat)))
2741
2742 (define-public ruby-notiffany
2743 (package
2744 (name "ruby-notiffany")
2745 (version "0.1.3")
2746 (source (origin
2747 (method url-fetch)
2748 (uri (rubygems-uri "notiffany" version))
2749 (sha256
2750 (base32
2751 "0f47h3bmg1apr4x51szqfv3rh2vq58z3grh4w02cp3bzbdh6jxnk"))))
2752 (build-system ruby-build-system)
2753 ;; Tests are not included in the gem.
2754 (arguments `(#:tests? #f))
2755 (propagated-inputs
2756 `(("ruby-shellany" ,ruby-shellany)
2757 ("ruby-nenv" ,ruby-nenv)))
2758 (native-inputs
2759 `(("bundler" ,bundler)))
2760 (synopsis "Wrapper library for notification libraries")
2761 (description "Notiffany is a Ruby wrapper library for notification
2762 libraries such as Libnotify.")
2763 (home-page "https://github.com/guard/notiffany")
2764 (license license:expat)))
2765
2766 (define-public ruby-forking-test-runner
2767 (package
2768 (name "ruby-forking-test-runner")
2769 (version "1.6.0")
2770 (home-page "https://github.com/grosser/forking_test_runner")
2771 (source (origin
2772 (method git-fetch)
2773 (uri (git-reference (url home-page)
2774 (commit (string-append "v" version))))
2775 (file-name (git-file-name name version))
2776 (sha256
2777 (base32
2778 "1mrglzkj2nrgisccf2f30zbfmcs0awv1g3lw994b2az90fl39x8m"))))
2779 (build-system ruby-build-system)
2780 (arguments
2781 '(#:test-target "spec"
2782 ;; FIXME: ActiveRecord depends on sqlite3 1.3.6, but Guix has
2783 ;; 1.4.1, which in turn breaks the tests that use ActiveRecord.
2784 #:tests? #f
2785 #:phases (modify-phases %standard-phases
2786 (replace 'replace-git-ls-files
2787 (lambda _
2788 (substitute* "forking_test_runner.gemspec"
2789 (("`git ls-files lib/ bin/ MIT-LICENSE`")
2790 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
2791 #t))
2792 (add-before 'check 'remove-version-constraints
2793 (lambda _
2794 ;; Ignore hard coded version constraints for the tests.
2795 (delete-file "Gemfile.lock")
2796 #t))
2797 (add-before 'check 'set-HOME
2798 (lambda _
2799 ;; Many tests invoke Bundler, and fails when Bundler
2800 ;; warns that /homeless-shelter does not exist.
2801 (setenv "HOME" "/tmp")
2802 #t)))))
2803 (native-inputs
2804 `(("ruby-activerecord" ,ruby-activerecord)
2805 ("ruby-bump" ,ruby-bump)
2806 ("ruby-rspec" ,ruby-rspec)
2807 ("ruby-sqlite3" ,ruby-sqlite3)
2808 ("ruby-wwtd" ,ruby-wwtd)))
2809 (propagated-inputs
2810 `(("ruby-parallel-tests" ,ruby-parallel-tests)))
2811 (synopsis "Run every test in a fork")
2812 (description
2813 "This package is a wrapper around @code{parallel_tests} that runs every
2814 test in a fork to avoid pollution and get clean output per test.")
2815 (license license:expat)))
2816
2817 (define-public ruby-formatador
2818 (package
2819 (name "ruby-formatador")
2820 (version "0.2.5")
2821 (source (origin
2822 (method url-fetch)
2823 (uri (rubygems-uri "formatador" version))
2824 (sha256
2825 (base32
2826 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
2827 (build-system ruby-build-system)
2828 ;; Circular dependency: Tests require ruby-shindo, which requires
2829 ;; ruby-formatador at runtime.
2830 (arguments `(#:tests? #f))
2831 (synopsis "Ruby library to format text on stdout")
2832 (description "Formatador is a Ruby library to format text printed to the
2833 standard output stream.")
2834 (home-page "https://github.com/geemus/formatador")
2835 (license license:expat)))
2836
2837 (define-public ruby-fuubar
2838 (package
2839 (name "ruby-fuubar")
2840 (version "2.3.2")
2841 (source
2842 (origin
2843 ;; Fetch from the git repository, as the gem package doesn't include
2844 ;; the tests.
2845 (method git-fetch)
2846 (uri (git-reference
2847 (url "https://github.com/thekompanee/fuubar")
2848 (commit (string-append "releases/v" version))))
2849 (file-name (git-file-name name version))
2850 (sha256
2851 (base32
2852 "0jm1x2xp13csbnadixaikj7mlkp5yk4byx51npm56zi13izp7259"))))
2853 (build-system ruby-build-system)
2854 (arguments
2855 '(;; TODO: Some tests fail, unsure why.
2856 ;; 21 examples, 7 failures
2857 #:tests? #f
2858 #:phases
2859 (modify-phases %standard-phases
2860 (add-before 'build 'delete-certificate
2861 (lambda _
2862 ;; Remove 's.cert_chain' as we do not build with a private key
2863 (substitute* "fuubar.gemspec"
2864 ((".*cert_chain.*") "")
2865 ((".*signing_key.*") ""))
2866 #t))
2867 (replace 'check
2868 (lambda* (#:key tests? #:allow-other-keys)
2869 (when tests?
2870 (invoke "rspec"))
2871 #t)))))
2872 (native-inputs
2873 `(("bundler" ,bundler)))
2874 (propagated-inputs
2875 `(("ruby-rspec-core" ,ruby-rspec-core)
2876 ("ruby-progressbar" ,ruby-progressbar)))
2877 (synopsis "Fuubar is an RSpec formatter that uses a progress bar")
2878 (description
2879 "Fuubar is an RSpec formatter that uses a progress bar instead of a
2880 string of letters and dots as feedback. It also stops on the first test
2881 failure.")
2882 (home-page "https://github.com/thekompanee/fuubar")
2883 (license license:expat)))
2884
2885 (define-public ruby-haml
2886 (package
2887 (name "ruby-haml")
2888 (version "5.0.4")
2889 (source
2890 (origin
2891 (method url-fetch)
2892 (uri (rubygems-uri "haml" version))
2893 (sha256
2894 (base32
2895 "1q0a9fvqh8kn6wm97fcks6qzbjd400bv8bx748w8v87m7p4klhac"))))
2896 (build-system ruby-build-system)
2897 (arguments
2898 '(#:tests? #f)) ; No included tests
2899 (propagated-inputs
2900 `(("ruby-tilt" ,ruby-tilt)
2901 ("ruby-temple" ,ruby-temple)))
2902 (synopsis "Haml is a Ruby library to generate HTML documents")
2903 (description
2904 "@acronym{Haml, HTML Abstraction Markup Language} is a layer on top of
2905 HTML or XML that is designed to express the structure of documents using
2906 indentation rather than closing tags. It was originally envisioned as a
2907 plugin for Ruby on Rails, but it can function as a stand-alone templating
2908 engine.")
2909 (home-page "http://haml.info/")
2910 (license license:expat)))
2911
2912 (define-public ruby-hamster
2913 (package
2914 (name "ruby-hamster")
2915 (version "3.0.0")
2916 (source
2917 (origin
2918 (method url-fetch)
2919 (uri (rubygems-uri "hamster" version))
2920 (sha256
2921 (base32
2922 "1n1lsh96vnyc1pnzyd30f9prcsclmvmkdb3nm5aahnyizyiy6lar"))))
2923 (build-system ruby-build-system)
2924 (arguments
2925 '(#:phases
2926 (modify-phases %standard-phases
2927 (add-after 'unpack 'remove-unnecessary-dependencies
2928 (lambda _
2929 ;; pry is a debugging tool, and is unnecessary when running the
2930 ;; tests
2931 (substitute* "spec/lib/hamster/vector/insert_spec.rb"
2932 (("require 'pry'") ""))
2933 (substitute* "spec/spec_helper.rb"
2934 (("require \"pry\"") "")
2935 ;; CodeClimate is an online service, and is unnecessary for
2936 ;; running the tests
2937 (("require \"codeclimate-test-reporter\"") "")
2938 (("CodeClimate.*\n") ""))
2939 #t))
2940 ;; No Rakefile is included, so run rspec directly.
2941 (replace 'check
2942 (lambda* (#:key tests? #:allow-other-keys)
2943 (when tests?
2944 (invoke "rspec"))
2945 #t)))))
2946 (propagated-inputs
2947 `(("ruby-concurrent" ,ruby-concurrent)))
2948 (native-inputs
2949 `(("ruby-rspec" ,ruby-rspec)))
2950 (synopsis "Efficient, immutable, thread-safe collection classes for Ruby")
2951 (description
2952 "Hamster provides 6 persistent data structures: @code{Hash}, @code{Vector},
2953 @code{Set}, @code{SortedSet}, @code{List}, and @code{Deque} (which works as an
2954 immutable queue or stack).")
2955 (home-page "https://github.com/hamstergem/hamster")
2956 (license license:expat)))
2957
2958 (define-public ruby-hashdiff
2959 (package
2960 (name "ruby-hashdiff")
2961 (version "0.3.8")
2962 (source
2963 (origin
2964 (method url-fetch)
2965 (uri (rubygems-uri "hashdiff" version))
2966 (sha256
2967 (base32
2968 "19ykg5pax8798nh1yv71adkx0zzs7gn2rxjj86v7nsw0jba5lask"))))
2969 (build-system ruby-build-system)
2970 (arguments
2971 '(#:phases
2972 (modify-phases %standard-phases
2973 ;; Run tests directly via rspec to avoid Rake issue:
2974 ;; NoMethodError: undefined method `last_comment'
2975 (replace 'check
2976 (lambda* (#:key tests? #:allow-other-keys)
2977 (when tests?
2978 (invoke "rspec"))
2979 #t)))))
2980 (native-inputs
2981 `(("bundler" ,bundler)
2982 ("ruby-rspec" ,ruby-rspec-2)))
2983 (synopsis "HashDiff computes the smallest difference between two hashes")
2984 (description
2985 "HashDiff is a Ruby library to compute the smallest difference between
2986 two hashes.")
2987 (home-page "https://github.com/liufengyun/hashdiff")
2988 (license license:expat)))
2989
2990 (define-public ruby-hydra
2991 ;; No releases yet.
2992 (let ((commit "5abfa378743756ae4d9306cc134bcc482f5c9525")
2993 (revision "0"))
2994 (package
2995 (name "ruby-hydra")
2996 (version (git-version "0.0" revision commit))
2997 (home-page "https://github.com/hyphenation/hydra")
2998 (source (origin
2999 (method git-fetch)
3000 (uri (git-reference (url home-page) (commit commit)))
3001 (file-name (git-file-name name version))
3002 (sha256
3003 (base32
3004 "1cik398l2765y3d9sdhjzki3303hkry58ac6jlkiy7iy62nm529f"))))
3005 (build-system ruby-build-system)
3006 (arguments
3007 '(#:phases (modify-phases %standard-phases
3008 (add-after 'unpack 'make-files-writable
3009 (lambda _
3010 (for-each make-file-writable (find-files "."))
3011 #t))
3012 (replace 'check
3013 (lambda _
3014 (invoke "rspec"))))))
3015 (native-inputs
3016 `(("ruby-rspec" ,ruby-rspec)))
3017 (propagated-inputs
3018 `(("ruby-byebug" ,ruby-byebug)))
3019 (synopsis "Ruby hyphenation patterns")
3020 (description
3021 "ruby-hydra is a Ruby library for working with hyphenation patterns.")
3022 (license license:expat))))
3023
3024 (define-public ruby-shindo
3025 (package
3026 (name "ruby-shindo")
3027 (version "0.3.8")
3028 (source (origin
3029 (method url-fetch)
3030 (uri (rubygems-uri "shindo" version))
3031 (sha256
3032 (base32
3033 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
3034 (build-system ruby-build-system)
3035 (arguments
3036 `(#:test-target "shindo_tests"
3037 #:phases
3038 (modify-phases %standard-phases
3039 (add-after 'unpack 'fix-tests
3040 (lambda _
3041 (substitute* "tests/tests_helper.rb"
3042 (("-rubygems") ""))
3043 (substitute* "Rakefile"
3044 (("system \"shindo") "system \"./bin/shindo")
3045 ;; This test doesn't work, so we disable it.
3046 (("fail \"The build_error test should fail") "#")
3047 ((" -rubygems") ""))
3048 #t)))))
3049 (propagated-inputs
3050 `(("ruby-formatador" ,ruby-formatador)))
3051 (synopsis "Simple depth first Ruby testing")
3052 (description "Shindo is a simple depth first testing library for Ruby.")
3053 (home-page "https://github.com/geemus/shindo")
3054 (license license:expat)))
3055
3056 (define-public ruby-rubygems-tasks
3057 (package
3058 (name "ruby-rubygems-tasks")
3059 (version "0.2.5")
3060 (source (origin
3061 (method url-fetch)
3062 (uri (rubygems-uri "rubygems-tasks" version))
3063 (sha256
3064 (base32
3065 "1x3sz3n2dlknd3v7w1mrq6f0ag6pwzhjvg7z29p75w3p42ma1gbx"))))
3066 (build-system ruby-build-system)
3067 ;; Tests need Internet access.
3068 (arguments `(#:tests? #f))
3069 (native-inputs
3070 `(("ruby-rspec" ,ruby-rspec)
3071 ("ruby-yard" ,ruby-yard)))
3072 (synopsis "Rake tasks for managing and releasing Ruby Gems")
3073 (description "Rubygems-task provides Rake tasks for managing and releasing
3074 Ruby Gems.")
3075 (home-page "https://github.com/postmodern/rubygems-tasks")
3076 (license license:expat)))
3077
3078 (define-public ruby-rubyzip
3079 (package
3080 (name "ruby-rubyzip")
3081 (version "1.2.1")
3082 (source
3083 (origin
3084 (method url-fetch)
3085 (uri (rubygems-uri "rubyzip" version))
3086 (sha256
3087 (base32
3088 "06js4gznzgh8ac2ldvmjcmg9v1vg9llm357yckkpylaj6z456zqz"))))
3089 (build-system ruby-build-system)
3090 (arguments
3091 '(#:phases
3092 (modify-phases %standard-phases
3093 (add-before 'check 'patch-tests
3094 (lambda* (#:key inputs #:allow-other-keys)
3095 (substitute* "test/gentestfiles.rb"
3096 (("/usr/bin/zip")
3097 (string-append
3098 (assoc-ref inputs "zip") "/bin/zip")))
3099 (substitute* "test/input_stream_test.rb"
3100 (("/usr/bin/env ruby") (which "ruby")))
3101 #t)))))
3102 (native-inputs
3103 `(("bundler" ,bundler)
3104 ("ruby-simplecov" ,ruby-simplecov)
3105 ("zip" ,zip)
3106 ("unzip" ,unzip)))
3107 (synopsis "Ruby module is for reading and writing zip files")
3108 (description
3109 "The rubyzip module provides ways to read from and create zip files.")
3110 (home-page "https://github.com/rubyzip/rubyzip")
3111 (license license:bsd-2)))
3112
3113 (define-public ruby-simplecov-html
3114 (package
3115 (name "ruby-simplecov-html")
3116 (version "0.10.2")
3117 (source (origin
3118 (method url-fetch)
3119 (uri (rubygems-uri "simplecov-html" version))
3120 (sha256
3121 (base32
3122 "1lihraa4rgxk8wbfl77fy9sf0ypk31iivly8vl3w04srd7i0clzn"))))
3123 (build-system ruby-build-system)
3124 (arguments `(#:tests? #f)) ; there are no tests
3125 (native-inputs
3126 `(("bundler" ,bundler)))
3127 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
3128 (description "This package provides the default HTML formatter for
3129 the SimpleCov code coverage tool for Ruby version 1.9 and above.")
3130 (home-page "https://github.com/colszowka/simplecov-html")
3131 (license license:expat)))
3132
3133 (define-public ruby-simplecov
3134 (package
3135 (name "ruby-simplecov")
3136 (version "0.17.1")
3137 (source (origin
3138 (method url-fetch)
3139 (uri (rubygems-uri "simplecov" version))
3140 (sha256
3141 (base32
3142 "1135k46nik05sdab30yxb8264lqiz01c8v000g16cl9pjc4mxrdw"))))
3143 (build-system ruby-build-system)
3144 ;; Simplecov depends on rubocop for code style checking at build time.
3145 ;; Rubocop needs simplecov at build time.
3146 (arguments `(#:tests? #f))
3147 (propagated-inputs
3148 `(("ruby-json" ,ruby-json)
3149 ("ruby-docile" ,ruby-docile)
3150 ("ruby-simplecov-html" ,ruby-simplecov-html)))
3151 (native-inputs
3152 `(("bundler" ,bundler)))
3153 (synopsis "Code coverage framework for Ruby")
3154 (description "SimpleCov is a code coverage framework for Ruby with a
3155 powerful configuration library and automatic merging of coverage across test
3156 suites.")
3157 (home-page "https://github.com/colszowka/simplecov")
3158 (license license:expat)))
3159
3160 (define-public ruby-useragent
3161 (package
3162 (name "ruby-useragent")
3163 (version "0.16.10")
3164 (source (origin
3165 (method url-fetch)
3166 (uri (rubygems-uri "useragent" version))
3167 (sha256
3168 (base32
3169 "1fv5kvq494swy0p17h9qya9r50w15xsi9zmvhzb8gh55kq6ki50p"))))
3170 (build-system ruby-build-system)
3171 (arguments
3172 '(#:tests? #f)) ; no test suite
3173 (synopsis "HTTP user agent parser for Ruby")
3174 (description "UserAgent is a Ruby library that parses and compares HTTP
3175 User Agents.")
3176 (home-page "https://github.com/gshutler/useragent")
3177 (license license:expat)))
3178
3179 (define-public ruby-backports
3180 (package
3181 (name "ruby-backports")
3182 (version "3.11.4")
3183 (source
3184 (origin
3185 (method url-fetch)
3186 (uri (rubygems-uri "backports" version))
3187 (sha256
3188 (base32
3189 "1hshjxww2h7s0dk57njrygq4zpp0nlqrjfya7zwm27iq3rhc3y8g"))))
3190 (build-system ruby-build-system)
3191 (arguments
3192 '(;; TODO: This should be default, but there is one test failure
3193 #:test-target "all_spec"))
3194 (native-inputs
3195 `(("ruby-mspec" ,ruby-mspec)
3196 ("ruby-activesupport" ,ruby-activesupport)))
3197 (synopsis "Backports of the features in newer Ruby versions")
3198 (description
3199 "Backports enables more compatibility across Ruby versions by providing
3200 backports of some features.")
3201 (home-page "https://github.com/marcandre/backports")
3202 (license license:expat)))
3203
3204 (define-public ruby-bacon
3205 (package
3206 (name "ruby-bacon")
3207 (version "1.2.0")
3208 (source (origin
3209 (method url-fetch)
3210 (uri (rubygems-uri "bacon" version))
3211 (sha256
3212 (base32
3213 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
3214 (build-system ruby-build-system)
3215 (synopsis "Small RSpec clone")
3216 (description "Bacon is a small RSpec clone providing all essential
3217 features.")
3218 (home-page "https://github.com/chneukirchen/bacon")
3219 (license license:expat)))
3220
3221 (define-public ruby-bacon-bits
3222 (package
3223 (name "ruby-bacon-bits")
3224 (version "0.1.0")
3225 (source
3226 (origin
3227 (method url-fetch)
3228 (uri (rubygems-uri "bacon-bits" version))
3229 (sha256
3230 (base32
3231 "1ghpj8ja94lhi8rgi872hqk4fd2amz2k7g9znd64z5dj7v6l0dmx"))))
3232 (build-system ruby-build-system)
3233 (arguments
3234 ;; No tests
3235 '(#:tests? #f))
3236 (propagated-inputs `(("ruby-bacon" ,ruby-bacon)))
3237 (synopsis "Extensions to Bacon, for disabling tests, before and after
3238 blocks and more")
3239 (description
3240 "This extends the bacon testing framework with useful extensions to
3241 disable tests, have before and after blocks that run once and more.")
3242 (home-page "https://github.com/cldwalker/bacon-bits")
3243 (license license:expat)))
3244
3245 (define-public ruby-bacon-colored-output
3246 (package
3247 (name "ruby-bacon-colored-output")
3248 (version "1.1.1")
3249 (source
3250 (origin
3251 (method url-fetch)
3252 (uri (rubygems-uri "bacon-colored_output" version))
3253 (sha256
3254 (base32
3255 "1znyh3vkfdlmf19p3k4zip88ibym41dn5g4p4n5hmks2iznb7qpx"))))
3256 (build-system ruby-build-system)
3257 (arguments
3258 '(;; No included tests
3259 #:tests? #f))
3260 (propagated-inputs
3261 `(("ruby-bacon" ,ruby-bacon)))
3262 (synopsis "Colored output for Bacon test framework")
3263 (description
3264 "This package adds color through ANSI escape codes to Bacon test
3265 output.")
3266 (home-page "https://github.com/whitequark/bacon-colored_output")
3267 (license license:expat)))
3268
3269 (define-public ruby-connection-pool
3270 (package
3271 (name "ruby-connection-pool")
3272 (version "2.2.2")
3273 (source (origin
3274 (method url-fetch)
3275 (uri (rubygems-uri "connection_pool" version))
3276 (sha256
3277 (base32
3278 "0lflx29mlznf1hn0nihkgllzbj8xp5qasn8j7h838465pi399k68"))))
3279 (build-system ruby-build-system)
3280 (native-inputs
3281 `(("bundler" ,bundler)))
3282 (synopsis "Generic connection pool for Ruby")
3283 (description "Connection_pool provides a generic connection pooling
3284 interface for Ruby programs.")
3285 (home-page "https://github.com/mperham/connection_pool")
3286 (license license:expat)))
3287
3288 (define-public ruby-fast-gettext
3289 (package
3290 (name "ruby-fast-gettext")
3291 (version "2.0.3")
3292 (home-page "https://github.com/grosser/fast_gettext")
3293 (source (origin
3294 (method git-fetch)
3295 (uri (git-reference (url home-page)
3296 (commit (string-append "v" version))))
3297 (file-name (git-file-name name version))
3298 (sha256
3299 (base32
3300 "1dg14apq5sfjshhcq0idphhs7aq9ikzswhqmn689p1h76mxqr1v6"))))
3301 (build-system ruby-build-system)
3302 (arguments
3303 '(#:test-target "spec"
3304 #:phases (modify-phases %standard-phases
3305 (add-before 'check 'remove-version-constraints
3306 (lambda _
3307 (delete-file "Gemfile.lock")
3308 #t))
3309 (add-before 'check 'remove-activerecord-test
3310 (lambda _
3311 ;; FIXME: This test fails because ActiveRecord depends on
3312 ;; a different version of ruby-sqlite than the currently
3313 ;; available one.
3314 (delete-file
3315 "spec/fast_gettext/translation_repository/db_spec.rb")
3316 #t))
3317 (add-before 'check 'disable-i18n-test
3318 (lambda _
3319 ;; XXX: This test checks i18n intricasies with Rails 3 and
3320 ;; automatically disables itself for Rails 4.0, but does
3321 ;; not know about newer versions as it has not been updated
3322 ;; since 2014. Disable for later versions of Rails too.
3323 (substitute* "spec/fast_gettext/vendor/string_spec.rb"
3324 (((string-append "ActiveRecord::VERSION::MAJOR == 4 and "
3325 "ActiveRecord::VERSION::MINOR == 0"))
3326 "ActiveRecord::VERSION::MAJOR >= 4"))
3327 #t)))))
3328 (native-inputs
3329 `(;; For tests.
3330 ("ruby-activerecord" ,ruby-activerecord)
3331 ("ruby-activesupport" ,ruby-activesupport)
3332 ("ruby-bump" ,ruby-bump)
3333 ("ruby-forking-test-runner" ,ruby-forking-test-runner)
3334 ("ruby-i18n" ,ruby-i18n)
3335 ("ruby-rubocop" ,ruby-rubocop)
3336 ("ruby-rspec" ,ruby-rspec)
3337 ("ruby-single-cov" ,ruby-single-cov)
3338 ("ruby-sqlite3" ,ruby-sqlite3)
3339 ("ruby-wwtd" ,ruby-wwtd)))
3340 (synopsis "Fast implementation of @code{GetText}")
3341 (description
3342 "This package provides an alternative implementation of the Ruby
3343 @code{GetText} library that is approximately 12x faster yet thread safe.")
3344 ;; Some parts are covered by the Ruby license, see file headers.
3345 (license (list license:expat license:ruby))))
3346
3347 (define-public ruby-net-http-persistent
3348 (package
3349 (name "ruby-net-http-persistent")
3350 (version "3.0.0")
3351 (source (origin
3352 (method url-fetch)
3353 (uri (rubygems-uri "net-http-persistent" version))
3354 (sha256
3355 (base32
3356 "156rv95bgxfz6qw5y1r7c7bswr77918hygl8dyl14qzbqc5vyp18"))))
3357 (build-system ruby-build-system)
3358 (native-inputs
3359 `(("ruby-connection-pool" ,ruby-connection-pool)
3360 ("ruby-hoe" ,ruby-hoe)))
3361 (synopsis "Persistent HTTP connection manager")
3362 (description "Net::HTTP::Persistent manages persistent HTTP connections
3363 using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
3364 (home-page "https://github.com/drbrain/net-http-persistent")
3365 (license license:expat)))
3366
3367 (define-public ruby-power-assert
3368 (package
3369 (name "ruby-power-assert")
3370 (version "1.1.5")
3371 (source (origin
3372 (method url-fetch)
3373 (uri (rubygems-uri "power_assert" version))
3374 (sha256
3375 (base32
3376 "1dii0wkfa0jm8sk9b20zl1z4980dmrjh0zqnii058485pp3ws10s"))))
3377 (build-system ruby-build-system)
3378 (arguments
3379 '(#:tests? #f)) ; No included tests
3380 (native-inputs
3381 `(("bundler" ,bundler)))
3382 (synopsis "Assert library with descriptive assertion messages")
3383 (description "Power-assert is an assertion library providing descriptive
3384 assertion messages for tests.")
3385 (home-page "https://github.com/k-tsj/power_assert")
3386 (license (list license:bsd-2 license:ruby))))
3387
3388 (define-public ruby-powerpack
3389 (package
3390 (name "ruby-powerpack")
3391 (version "0.1.2")
3392 (source
3393 (origin
3394 (method url-fetch)
3395 (uri (rubygems-uri "powerpack" version))
3396 (sha256
3397 (base32
3398 "1r51d67wd467rpdfl6x43y84vwm8f5ql9l9m85ak1s2sp3nc5hyv"))))
3399 (build-system ruby-build-system)
3400 (arguments
3401 '(#:test-target "spec"))
3402 (native-inputs
3403 `(("bundler" ,bundler)
3404 ("ruby-rspec" ,ruby-rspec)
3405 ("ruby-yard" ,ruby-yard)))
3406 (synopsis "Useful extensions to core Ruby classes")
3407 (description
3408 "This package provides a few useful extensions to core Ruby classes,
3409 including @code{Array}, @code{Enumerable}, @code{Hash}, @code{Numeric}, and
3410 @code{String}.")
3411 (home-page "https://github.com/bbatsov/powerpack")
3412 (license license:expat)))
3413
3414 (define-public ruby-locale
3415 (package
3416 (name "ruby-locale")
3417 (version "2.1.2")
3418 (source (origin
3419 (method url-fetch)
3420 (uri (rubygems-uri "locale" version))
3421 (sha256
3422 (base32
3423 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
3424 (build-system ruby-build-system)
3425 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3426 ;; which needs ruby-gettext, which needs ruby-locale. To break the
3427 ;; dependency cycle we disable tests.
3428 (arguments `(#:tests? #f))
3429 (native-inputs
3430 `(("bundler" ,bundler)
3431 ("ruby-yard" ,ruby-yard)))
3432 (synopsis "Ruby library providing basic localization APIs")
3433 (description
3434 "Ruby-Locale is the pure ruby library which provides basic APIs for
3435 localization.")
3436 (home-page "https://github.com/ruby-gettext/locale")
3437 (license (list license:lgpl3+ license:ruby))))
3438
3439 (define-public ruby-temple
3440 (package
3441 (name "ruby-temple")
3442 (version "0.8.2")
3443 (source
3444 (origin
3445 (method url-fetch)
3446 (uri (rubygems-uri "temple" version))
3447 (sha256
3448 (base32
3449 "060zzj7c2kicdfk6cpnn40n9yjnhfrr13d0rsbdhdij68chp2861"))))
3450 (build-system ruby-build-system)
3451 (native-inputs
3452 `(("ruby-tilt" ,ruby-tilt)
3453 ("ruby-bacon" ,ruby-bacon)
3454 ("ruby-erubis" ,ruby-erubis)))
3455 (synopsis "Template compilation framework in Ruby")
3456 (description
3457 "Temple is an abstraction and framework for compiling templates to pure
3458 Ruby.")
3459 (home-page "https://github.com/judofyr/temple")
3460 (license license:expat)))
3461
3462 (define-public ruby-text
3463 (package
3464 (name "ruby-text")
3465 (version "1.3.1")
3466 (source (origin
3467 (method url-fetch)
3468 (uri (rubygems-uri "text" version))
3469 (sha256
3470 (base32
3471 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
3472 (build-system ruby-build-system)
3473 (synopsis "Collection of text algorithms for Ruby")
3474 (description
3475 "This package provides a collection of text algorithms: Levenshtein,
3476 Soundex, Metaphone, Double Metaphone, Porter Stemming.")
3477 (home-page "https://github.com/threedaymonk/text")
3478 (license license:expat)))
3479
3480 (define-public ruby-gettext
3481 (package
3482 (name "ruby-gettext")
3483 (version "3.1.7")
3484 (source (origin
3485 (method url-fetch)
3486 (uri (rubygems-uri "gettext" version))
3487 (sha256
3488 (base32
3489 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
3490 (build-system ruby-build-system)
3491 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3492 ;; which needs ruby-gettext. To break the dependency cycle we disable
3493 ;; tests.
3494 (arguments `(#:tests? #f))
3495 (propagated-inputs
3496 `(("ruby-locale" ,ruby-locale)
3497 ("ruby-text" ,ruby-text)))
3498 (native-inputs
3499 `(("bundler" ,bundler)
3500 ("ruby-yard" ,ruby-yard)))
3501 (synopsis "GNU gettext-like program for Ruby")
3502 (description
3503 "Gettext is a GNU gettext-like program for Ruby. The catalog
3504 file (po-file) used is the same as that used by GNU gettext, allowing you to
3505 use GNU gettext tools for maintenance.")
3506 (home-page "https://ruby-gettext.github.com/")
3507 (license (list license:lgpl3+ license:ruby))))
3508
3509 (define-public ruby-packnga
3510 (package
3511 (name "ruby-packnga")
3512 (version "1.0.4")
3513 (source (origin
3514 (method url-fetch)
3515 (uri (rubygems-uri "packnga" version))
3516 (sha256
3517 (base32
3518 "1vv2j0i43s4xid2km5hgrrxqlqpwgq8nlm8kaxfg2531c1vwfsd4"))))
3519 (build-system ruby-build-system)
3520 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
3521 ;; To break the dependency cycle we disable tests.
3522 (arguments `(#:tests? #f))
3523 (propagated-inputs
3524 `(("ruby-gettext" ,ruby-gettext)
3525 ("ruby-yard" ,ruby-yard)))
3526 (native-inputs
3527 `(("bundler" ,bundler)))
3528 (synopsis "Utility library to package internationalized libraries")
3529 (description
3530 "Packnga is a library to translate to many languages using YARD.")
3531 (home-page "http://ranguba.org/packnga/")
3532 (license license:lgpl2.0+)))
3533
3534 (define-public ruby-test-construct
3535 (package
3536 (name "ruby-test-construct")
3537 (version "2.0.1")
3538 (source
3539 (origin
3540 (method url-fetch)
3541 (uri (rubygems-uri "test_construct" version))
3542 (sha256
3543 (base32
3544 "1a2ym3l068d0pxzzr95kvqx87zpdsarxslz9ygd4qfm9frrz0kgj"))))
3545 (build-system ruby-build-system)
3546 (native-inputs
3547 `(("bundler" ,bundler)
3548 ("ruby-mocha" ,ruby-mocha)
3549 ("ruby-rspec" ,ruby-rspec)))
3550 (synopsis "Creates temporary files and directories for testing")
3551 (description
3552 "TestConstruct is a @acronym{DSL, Domain Specific Language} for creating
3553 temporary files and directories during tests.")
3554 (home-page "https://github.com/bhb/test_construct")
3555 (license license:expat)))
3556
3557 (define-public ruby-test-unit
3558 (package
3559 (name "ruby-test-unit")
3560 (version "3.2.5")
3561 (source (origin
3562 (method url-fetch)
3563 (uri (rubygems-uri "test-unit" version))
3564 (sha256
3565 (base32
3566 "05bx36fw01iqz0xqhvjfrwjgnj1zx3b2vn6w1fzp19rchd7zqc52"))))
3567 (build-system ruby-build-system)
3568 (propagated-inputs
3569 `(("ruby-power-assert" ,ruby-power-assert)))
3570 (native-inputs
3571 `(("bundler" ,bundler)
3572 ("ruby-packnga" ,ruby-packnga)
3573 ("ruby-yard" ,ruby-yard)))
3574 (synopsis "Unit testing framework for Ruby")
3575 (description "@code{Test::Unit} is unit testing framework for Ruby, based
3576 on xUnit principles. These were originally designed by Kent Beck, creator of
3577 extreme programming software development methodology, for Smalltalk's SUnit.
3578 It allows writing tests, checking results and automated testing in Ruby.")
3579 (home-page "https://test-unit.github.io/")
3580 (license (list license:psfl license:ruby))))
3581
3582 (define-public ruby-markaby
3583 (package
3584 (name "ruby-markaby")
3585 (version "0.9.0")
3586 (source
3587 (origin
3588 (method url-fetch)
3589 (uri (rubygems-uri "markaby" version))
3590 (sha256
3591 (base32
3592 "1j4jc31ycydbkh5h3q6zwidzpavg3g5mbb5lqyaczd3jrq78rd7i"))))
3593 (build-system ruby-build-system)
3594 (arguments
3595 '(#:phases
3596 (modify-phases %standard-phases
3597 ;; Run rspec manually without using the Rakefile, as the versions of
3598 ;; Rake and RSpec 2 are incompatible:
3599 ;;
3600 ;; NoMethodError: undefined method `last_comment'
3601 (replace 'check
3602 (lambda* (#:key tests? #:allow-other-keys)
3603 (when tests?
3604 (invoke "rspec"))
3605 #t)))))
3606 (propagated-inputs
3607 `(("ruby-builder" ,ruby-builder)))
3608 (native-inputs
3609 `(("bundler" ,bundler)
3610 ("ruby-rspec" ,ruby-rspec-2)))
3611 (synopsis "Write HTML pages in pure Ruby")
3612 (description
3613 "Markaby allows writing HTML packages in pure Ruby. This is similar to
3614 the functionality provided by @acronym{ERB, Embedded Ruby}, but without the
3615 mixture of HTML and additional ERB syntax.")
3616 (home-page "https://markaby.github.io/")
3617 (license license:expat)))
3618
3619 (define-public ruby-maruku
3620 (package
3621 (name "ruby-maruku")
3622 (version "0.7.3")
3623 (source
3624 (origin
3625 (method url-fetch)
3626 (uri (rubygems-uri "maruku" version))
3627 (sha256
3628 (base32
3629 "1r7bxpgnx2hp3g12bjrmdrpv663dfqxsdp0af69kjhxmaxpia56x"))))
3630 (build-system ruby-build-system)
3631 (arguments
3632 '(;; TODO: 3 tests seem to fail due to HTML encoding issues
3633 #:tests? #f
3634 #:phases
3635 (modify-phases %standard-phases
3636 (replace 'check
3637 (lambda* (#:key tests? #:allow-other-keys)
3638 (when tests?
3639 (invoke "rspec"))
3640 #t)))))
3641 (native-inputs
3642 `(("ruby-rspec" ,ruby-rspec)
3643 ("ruby-simplecov" ,ruby-simplecov)
3644 ("ruby-nokogiri-diff" ,ruby-nokogiri-diff)))
3645 (synopsis "Markdown interpreter in Ruby")
3646 (description
3647 "Maruku is a Markdown interpreter in Ruby. It can export Markdown to
3648 HTML, and PDF through LaTeX.")
3649 (home-page "https://github.com/bhollis/maruku")
3650 (license license:expat)))
3651
3652 (define-public ruby-metaclass
3653 (package
3654 (name "ruby-metaclass")
3655 (version "0.0.4")
3656 (source (origin
3657 (method url-fetch)
3658 (uri (rubygems-uri "metaclass" version))
3659 (sha256
3660 (base32
3661 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
3662 (build-system ruby-build-system)
3663 (arguments
3664 `(#:phases
3665 (modify-phases %standard-phases
3666 (add-after 'unpack 'add-test-unit-to-search-path
3667 (lambda* (#:key inputs #:allow-other-keys)
3668 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
3669 (substitute* "Rakefile"
3670 (("t\\.libs << \"test\"" line)
3671 (string-append line "; t.libs << \""
3672 test-unit "/lib/ruby/vendor_ruby"
3673 "/gems/test-unit-"
3674 ,(package-version ruby-test-unit)
3675 "/lib\""))))
3676 #t)))))
3677 (native-inputs
3678 `(("bundler" ,bundler)
3679 ("ruby-test-unit" ,ruby-test-unit)))
3680 (synopsis "Ruby library adding metaclass method to all objects")
3681 (description
3682 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
3683 objects.")
3684 (home-page "https://github.com/floehopper/metaclass")
3685 (license license:expat)))
3686
3687 (define-public ruby-mkmf-lite
3688 (package
3689 (name "ruby-mkmf-lite")
3690 (version "0.3.2")
3691 (source (origin
3692 (method url-fetch)
3693 (uri (rubygems-uri "mkmf-lite" version))
3694 (sha256
3695 (base32
3696 "0br9k6zijj1zc25n8p7f2j1mwl58nfgdknf3q13h9k156jvrir06"))))
3697 (build-system ruby-build-system)
3698 (propagated-inputs
3699 `(("ruby-ptools" ,ruby-ptools)))
3700 (synopsis "Lightweight alternative to @code{mkmf}")
3701 (description
3702 "@code{mkmf-lite} is a light version of Ruby's @code{mkmf.rb} designed
3703 for use as a library. It does not create packages, builds, or log files of
3704 any kind. Instead, it provides mixin methods that you can use in FFI or tests
3705 to check for the presence of header files, constants, and so on.")
3706 (home-page "https://github.com/djberg96/mkmf-lite")
3707 (license license:asl2.0)))
3708
3709 (define-public ruby-mspec
3710 (package
3711 (name "ruby-mspec")
3712 (version "1.9.1")
3713 (source
3714 (origin
3715 (method url-fetch)
3716 (uri (rubygems-uri "mspec" version))
3717 (sha256
3718 (base32
3719 "0wmyh2n40m4srwdx9z6h6g6p46k02pzyhcsja3hqcw5h5b0hfmhd"))))
3720 (build-system ruby-build-system)
3721 (arguments
3722 '(;; TODO: 3 test failures
3723 ;; ./spec/mocks/mock_spec.rb:82
3724 ;; ./spec/utils/name_map_spec.rb:151
3725 ;; ./spec/utils/name_map_spec.rb:155
3726 #:tests? #f
3727 #:phases
3728 (modify-phases %standard-phases
3729 (add-after 'extract-gemspec 'change-dependency-constraints
3730 (lambda _
3731 (substitute* "mspec.gemspec"
3732 (("rake.*") "rake>)\n")
3733 (("rspec.*") "rspec>)\n"))
3734 #t))
3735 (replace 'check
3736 (lambda* (#:key tests? #:allow-other-keys)
3737 (when tests?
3738 (invoke "rspec" "spec"))
3739 #t)))))
3740 (native-inputs
3741 `(("bundler" ,bundler)
3742 ("ruby-rake" ,ruby-rake)
3743 ("ruby-rspec" ,ruby-rspec)))
3744 (synopsis "MSpec is a specialized framework for RubySpec")
3745 (description
3746 "MSpec is a specialized framework that is syntax-compatible with RSpec 2
3747 for basic features. MSpec contains additional features that assist in writing
3748 specs for Ruby implementations in ruby/spec.")
3749 (home-page "http://rubyspec.org")
3750 (license license:expat)))
3751
3752 (define-public ruby-mysql2
3753 (package
3754 (name "ruby-mysql2")
3755 (version "0.5.2")
3756 (source
3757 (origin
3758 (method git-fetch)
3759 (uri (git-reference
3760 (url "https://github.com/brianmario/mysql2")
3761 (commit version)))
3762 (file-name (git-file-name name version))
3763 (sha256
3764 (base32
3765 "11lvfgc2rmvkm52jp0nbi6pvhk06klznghr7llldfw8basl9n5wv"))))
3766 (build-system ruby-build-system)
3767 (arguments
3768 '(;; TODO: Tests require a running MySQL/MariaDB service
3769 #:tests? #f
3770 #:phases
3771 (modify-phases %standard-phases
3772 (replace 'replace-git-ls-files
3773 (lambda _
3774 (substitute* "mysql2.gemspec"
3775 (("git ls-files .*`") "find . -type f |sort`"))
3776 #t))
3777 (add-before 'install 'set-MAKEFLAGS
3778 (lambda* (#:key outputs #:allow-other-keys)
3779 (setenv "MAKEFLAGS"
3780 (string-append
3781 "V=1 "
3782 "prefix=" (assoc-ref outputs "out")))
3783 #t))
3784 ;; Move the 'check phase to after 'install, as then you can test
3785 ;; using the installed mysql2 gem in the store.
3786 (delete 'check)
3787 (add-after 'install 'check
3788 (lambda* (#:key outputs tests? #:allow-other-keys)
3789 (setenv "GEM_PATH"
3790 (string-append
3791 (getenv "GEM_PATH")
3792 ":"
3793 (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))
3794 (when tests?
3795 (invoke "rspec"))
3796 #t)))))
3797 (inputs
3798 `(("mariadb-dev" ,mariadb "dev")
3799 ("zlib" ,zlib)))
3800 (native-inputs
3801 `(("ruby-rspec" ,ruby-rspec)
3802 ("ruby-rake-compiler" ,ruby-rake-compiler)))
3803 (synopsis "MySQL library for Ruby, binding to libmysql")
3804 (description
3805 "This package provides a simple, fast MySQL library for Ruby, binding to
3806 libmysql.")
3807 (home-page "https://github.com/brianmario/mysql2")
3808 (license license:expat)))
3809
3810 (define-public ruby-blankslate
3811 (package
3812 (name "ruby-blankslate")
3813 (version "3.1.3")
3814 (source (origin
3815 (method url-fetch)
3816 (uri (rubygems-uri "blankslate" version))
3817 (sha256
3818 (base32
3819 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
3820 (build-system ruby-build-system)
3821 (arguments
3822 `(#:phases
3823 (modify-phases %standard-phases
3824 (replace 'check
3825 (lambda _ (invoke "rspec" "spec/"))))))
3826 (native-inputs
3827 `(("bundler" ,bundler)
3828 ("ruby-rspec" ,ruby-rspec)))
3829 (synopsis "Abstract base class with no predefined methods")
3830 (description
3831 "BlankSlate provides an abstract base class with no predefined
3832 methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
3833 as a base class when writing classes that depend upon
3834 @code{method_missing} (e.g. dynamic proxies).")
3835 (home-page "https://github.com/masover/blankslate")
3836 (license license:expat)))
3837
3838 (define-public ruby-bond
3839 (package
3840 (name "ruby-bond")
3841 (version "0.5.1")
3842 (source
3843 (origin
3844 (method url-fetch)
3845 (uri (rubygems-uri "bond" version))
3846 (sha256
3847 (base32
3848 "1r19ifc4skyl2gxnifrxa5jvbbay9fb2in79ppgv02b6n4bhsw90"))))
3849 (build-system ruby-build-system)
3850 (native-inputs
3851 `(("ruby-bacon" ,ruby-bacon)
3852 ("ruby-bacon-bits" ,ruby-bacon-bits)
3853 ("ruby-mocha-on-bacon" ,ruby-mocha-on-bacon)))
3854 (synopsis "Bond can provide custom autocompletion for arguments, methods
3855 and more")
3856 (description
3857 "Bond can autocomplete argument(s) to methods, uniquely completing per
3858 module, per method and per argument. Bond provides a configuration system and
3859 a DSL for creating custom completions and completion rules. Bond can also
3860 load completions that ship with gems. Bond is able to offer more than irb's
3861 completion since it uses the full line of input when completing as opposed to
3862 irb's last-word approach.")
3863 (home-page "http://tagaholic.me/bond/")
3864 (license license:expat)))
3865
3866 (define-public ruby-idn-ruby
3867 (package
3868 (name "ruby-idn-ruby")
3869 (version "0.1.0")
3870 (source
3871 (origin
3872 (method url-fetch)
3873 (uri (rubygems-uri "idn-ruby" version))
3874 (sha256
3875 (base32
3876 "07vblcyk3g72sbq12xz7xj28snpxnh3sbcnxy8bglqbfqqhvmawr"))))
3877 (build-system ruby-build-system)
3878 (arguments
3879 '(#:phases
3880 (modify-phases %standard-phases
3881 (delete 'check)
3882 (add-after 'install 'check
3883 (lambda* (#:key tests? outputs #:allow-other-keys)
3884 (when tests?
3885 (let* ((gem-file (cadr (find-files "." "\\.gem")))
3886 (name-and-version (basename gem-file ".gem")))
3887 (apply invoke
3888 "ruby" "--verbose"
3889 (string-append "-I"
3890 (assoc-ref outputs "out")
3891 "/lib/ruby/vendor_ruby/gems/"
3892 name-and-version
3893 "/lib")
3894 (find-files "./test" ".*\\.rb"))))
3895 #t)))))
3896 (inputs
3897 `(("libidn" ,libidn)))
3898 (synopsis "Ruby Bindings for the GNU LibIDN library")
3899 (description
3900 "Ruby Bindings for the GNU LibIDN library, an implementation of the
3901 Stringprep, Punycode and IDNA specifications. These are used to encode and
3902 decode internationalized domain + names according to the IDNA2003
3903 specifications.
3904
3905 Included are the most important parts of the Stringprep, Punycode and IDNA
3906 APIs like performing Stringprep processings, encoding to and decoding from
3907 Punycode strings and converting entire domain names to and from the ACE
3908 encoded form.")
3909 (home-page "https://github.com/deepfryed/idn-ruby")
3910 (license license:asl2.0)))
3911
3912 (define-public ruby-instantiator
3913 (package
3914 (name "ruby-instantiator")
3915 (version "0.0.7")
3916 (source (origin
3917 (method url-fetch)
3918 (uri (rubygems-uri "instantiator" version))
3919 (sha256
3920 (base32
3921 "0w07w3gkyqr7m0vz5h13vm8b411660qywjm2xxxgdjv4wb3fazbr"))))
3922 (build-system ruby-build-system)
3923 (arguments
3924 `(#:phases
3925 (modify-phases %standard-phases
3926 (add-after 'unpack 'add-test-unit-to-search-path
3927 (lambda* (#:key inputs #:allow-other-keys)
3928 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
3929 (substitute* "Rakefile"
3930 (("t\\.libs << \"test\"" line)
3931 (string-append line "; t.libs << \""
3932 test-unit "/lib/ruby/vendor_ruby"
3933 "/gems/test-unit-"
3934 ,(package-version ruby-test-unit)
3935 "/lib\""))))
3936 #t)))))
3937 (propagated-inputs
3938 `(("ruby-blankslate" ,ruby-blankslate)))
3939 (native-inputs
3940 `(("bundler" ,bundler)
3941 ("ruby-test-unit" ,ruby-test-unit)))
3942 (synopsis "Instantiate an arbitrary Ruby class")
3943 (description
3944 "Instantiator lets you instantiate an arbitrary Ruby class without
3945 knowing anything about the constructor.")
3946 (home-page "https://github.com/floehopper/instantiator")
3947 (license license:expat)))
3948
3949 (define-public ruby-introspection
3950 (package
3951 (name "ruby-introspection")
3952 (version "0.0.4")
3953 (source (origin
3954 (method url-fetch)
3955 (uri (rubygems-uri "introspection" version))
3956 (sha256
3957 (base32
3958 "1y2nbijkc0zlfmn9ss6588ilarq2kbn2i7w7pwwsli66dj84zgca"))))
3959 (build-system ruby-build-system)
3960 (arguments
3961 `(#:phases
3962 (modify-phases %standard-phases
3963 (add-after 'unpack 'add-test-unit-to-search-path
3964 (lambda* (#:key inputs #:allow-other-keys)
3965 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
3966 (substitute* "Rakefile"
3967 (("t\\.libs << \"test\"" line)
3968 (string-append line "; t.libs << \""
3969 test-unit "/lib/ruby/vendor_ruby"
3970 "/gems/test-unit-"
3971 ,(package-version ruby-test-unit)
3972 "/lib\""))))
3973 #t)))))
3974 (propagated-inputs
3975 `(("ruby-instantiator" ,ruby-instantiator)
3976 ("ruby-metaclass" ,ruby-metaclass)))
3977 (native-inputs
3978 `(("bundler" ,bundler)
3979 ("ruby-blankslate" ,ruby-blankslate)
3980 ("ruby-test-unit" ,ruby-test-unit)))
3981 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
3982 (description
3983 "Introspection provides tools to inspect the hierarchy of method
3984 definitions on a Ruby object.")
3985 (home-page "https://github.com/floehopper/introspection")
3986 (license license:expat)))
3987
3988 (define-public ruby-redcarpet
3989 (package
3990 (name "ruby-redcarpet")
3991 (version "3.5.0")
3992 (source (origin
3993 (method url-fetch)
3994 (uri (rubygems-uri "redcarpet" version))
3995 (sha256
3996 (base32
3997 "0skcyx1h8b5ms0rp2zm3ql6g322b8c1adnkwkqyv7z3kypb4bm7k"))))
3998 (build-system ruby-build-system)
3999 (arguments
4000 `(#:phases
4001 (modify-phases %standard-phases
4002 ;; The gem archive does not include the conformance tests.
4003 (add-after 'unpack 'disable-conformance-tests
4004 (lambda _
4005 (substitute* "Rakefile"
4006 (("task :test => %w\\[test:unit test:conformance\\]")
4007 "task :test => %w[test:unit]"))
4008 #t)))))
4009 (native-inputs
4010 `(("bundler" ,bundler)
4011 ("ruby-test-unit" ,ruby-test-unit)
4012 ("ruby-rake-compiler" ,ruby-rake-compiler)))
4013 (synopsis "Extensible Markdown to (X)HTML converter")
4014 (description
4015 "Redcarpet is an extensible Ruby library for Markdown processing and
4016 conversion to (X)HTML.")
4017 (home-page "https://github.com/vmg/redcarpet")
4018 (license license:expat)))
4019
4020 (define-public ruby-rerun
4021 (package
4022 (name "ruby-rerun")
4023 (version "0.13.0")
4024 (source
4025 (origin
4026 (method url-fetch)
4027 (uri (rubygems-uri "rerun" version))
4028 (sha256
4029 (base32
4030 "1cskvxk8z8vmfail8na7hj91hs0qnvds9nydj04zi3dbddgnbmvz"))))
4031 (build-system ruby-build-system)
4032 (arguments
4033 '(#:tests? #f)) ; No included tests
4034 (propagated-inputs
4035 `(("ruby-listen" ,ruby-listen)))
4036 (synopsis "Run a process, and restart when some monitored files change")
4037 (description
4038 "Rerun is a tool to launch programs, then monitor the file system, and
4039 restart the program when any of the monitored files change. It's written in
4040 Ruby, but can be used for all programs.")
4041 (home-page "https://github.com/alexch/rerun/")
4042 (license license:expat)))
4043
4044 (define-public ruby-maxitest
4045 (package
4046 (name "ruby-maxitest")
4047 (version "3.6.0")
4048 (home-page "https://github.com/grosser/maxitest")
4049 (source (origin
4050 ;; Pull from git because the gem does not contain tests.
4051 (method git-fetch)
4052 (uri (git-reference
4053 (url home-page)
4054 (commit (string-append "v" version))))
4055 (file-name (git-file-name name version))
4056 (sha256
4057 (base32
4058 "07b3j0bv3dx5j42jlvpvl07aaxplyi6wq688y3jl8y528ww2hjz8"))))
4059 (build-system ruby-build-system)
4060 (arguments
4061 '(#:test-target "default"
4062 #:phases (modify-phases %standard-phases
4063 (replace 'replace-git-ls-files
4064 (lambda _
4065 (substitute* "maxitest.gemspec"
4066 (("`git ls-files lib/ bin/ MIT-LICENSE Readme.md`")
4067 "`find lib/ bin/ MIT-LICENSE Readme.md -type f | sort`"))
4068 #t))
4069 (add-before 'check 'remove-version-constraints
4070 (lambda _
4071 ;; Don't use specific versions of dependencies, instead
4072 ;; take whatever is available in Guix.
4073 (delete-file "Gemfile.lock")
4074 #t))
4075 (add-before 'check 'add-mtest-on-PATH
4076 (lambda _
4077 ;; Tests use 'mtest' which is not automatically added on
4078 ;; PATH.
4079 (setenv "PATH" (string-append (getcwd) "/bin:"
4080 (getenv "PATH")))
4081 #t)))))
4082 (native-inputs
4083 `(("ps" ,procps)
4084 ("ruby-bump" ,ruby-bump)
4085 ("ruby-byebug" ,ruby-byebug)
4086 ("ruby-rspec" ,ruby-rspec)
4087 ("ruby-wwtd" ,ruby-wwtd)))
4088 (propagated-inputs
4089 `(("ruby-minitest" ,ruby-minitest)))
4090 (synopsis "Minitest with extra features")
4091 (description
4092 "Maxitest is a wrapper around Minitest with extra functionality such
4093 as timeouts, an @command{mtest} executable that can run tests by line
4094 number, support for interrupted tests, better backtraces, and more.")
4095 (license license:expat)))
4096
4097 (define-public ruby-mocha
4098 (package
4099 (name "ruby-mocha")
4100 (version "1.11.2")
4101 (source (origin
4102 (method url-fetch)
4103 (uri (rubygems-uri "mocha" version))
4104 (sha256
4105 (base32
4106 "0hxmkm8qxd04vwj8mqnpyrf2dwy7g1k9zipdfhl4y71cw7ijm9n4"))))
4107 (build-system ruby-build-system)
4108 (arguments
4109 `(#:phases
4110 (modify-phases %standard-phases
4111 (add-before 'check 'remove-rubocop-dependency
4112 (lambda _
4113 ;; Disable dependency on Rubocop, which is just a linter,
4114 ;; and would introduce a circular dependency.
4115 (substitute* "mocha.gemspec"
4116 ((".*rubocop.*")
4117 "true\n"))
4118 #t)))))
4119 (native-inputs
4120 `(("ruby-introspection" ,ruby-introspection)))
4121 (synopsis "Mocking and stubbing library for Ruby")
4122 (description
4123 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
4124 allows mocking and stubbing of methods on real (non-mock) classes.")
4125 (home-page "http://gofreerange.com/mocha/docs")
4126 ;; Mocha can be used with either license at the users choice.
4127 (license (list license:expat license:ruby))))
4128
4129 (define-public ruby-mocha-on-bacon
4130 (package
4131 (name "ruby-mocha-on-bacon")
4132 (version "0.2.3")
4133 (source
4134 (origin
4135 (method url-fetch)
4136 (uri (rubygems-uri "mocha-on-bacon" version))
4137 (sha256
4138 (base32
4139 "1h49b33rq889hn8x3wp9byczl91va16jh1w4d2wyy4yj23icdrcp"))))
4140 (build-system ruby-build-system)
4141 (arguments
4142 ;; rubygems.org release missing tests
4143 '(#:tests? #f))
4144 (propagated-inputs `(("ruby-mocha" ,ruby-mocha)))
4145 (synopsis "Mocha adapter for Bacon")
4146 (description
4147 "This package provides a Mocha adapter for Bacon, allowing you to use the
4148 Mocha stubbing and mocking library with Bacon, a small RSpec clone.")
4149 (home-page
4150 "https://github.com/alloy/mocha-on-bacon")
4151 (license license:expat)))
4152
4153 (define-public ruby-net-ssh
4154 (package
4155 (name "ruby-net-ssh")
4156 (version "4.2.0")
4157 (source (origin
4158 (method url-fetch)
4159 (uri (rubygems-uri "net-ssh" version))
4160 (sha256
4161 (base32
4162 "07c4v97zl1daabmri9zlbzs6yvkl56z1q14bw74d53jdj0c17nhx"))))
4163 (build-system ruby-build-system)
4164 (native-inputs
4165 `(("bundler" ,bundler)
4166 ("ruby-mocha" ,ruby-mocha)
4167 ("ruby-test-unit" ,ruby-test-unit)))
4168 (synopsis "Ruby implementation of the SSH2 client protocol")
4169 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
4170 client protocol. It allows you to write programs that invoke and interact
4171 with processes on remote servers, via SSH2.")
4172 (home-page "https://github.com/net-ssh/net-ssh")
4173 (license license:expat)))
4174
4175 (define-public ruby-net-scp
4176 (package
4177 (name "ruby-net-scp")
4178 ;; The 1.2.1 release would be incompatible with ruby-net-ssh >= 4.
4179 (version "1.2.2.rc2")
4180 (source
4181 (origin
4182 (method git-fetch)
4183 (uri (git-reference
4184 (url "https://github.com/net-ssh/net-scp")
4185 (commit (string-append "v" version))))
4186 (file-name (git-file-name name version))
4187 (sha256
4188 (base32 "1nyn17sy71fn7zs3y6wbgcn35318c10flqgc0582409095x4h0sx"))))
4189 (build-system ruby-build-system)
4190 (native-inputs
4191 `(("bundler" ,bundler)
4192 ("ruby-test-unit" ,ruby-test-unit)
4193 ("ruby-mocha" ,ruby-mocha)))
4194 (propagated-inputs
4195 `(("ruby-net-ssh" ,ruby-net-ssh)))
4196 (synopsis "Pure-Ruby SCP client library")
4197 (description "@code{Net::SCP} is a pure-Ruby implementation of the SCP
4198 client protocol.")
4199 (home-page "https://github.com/net-ssh/net-scp")
4200 (license license:expat)))
4201
4202 (define-public ruby-minitest
4203 (package
4204 (name "ruby-minitest")
4205 (version "5.11.3")
4206 (source (origin
4207 (method url-fetch)
4208 (uri (rubygems-uri "minitest" version))
4209 (sha256
4210 (base32
4211 "0icglrhghgwdlnzzp4jf76b0mbc71s80njn5afyfjn4wqji8mqbq"))))
4212 (build-system ruby-build-system)
4213 (native-inputs
4214 `(("ruby-hoe" ,ruby-hoe)))
4215 (synopsis "Small test suite library for Ruby")
4216 (description "Minitest provides a complete suite of Ruby testing
4217 facilities supporting TDD, BDD, mocking, and benchmarking.")
4218 (home-page "https://github.com/seattlerb/minitest")
4219 (license license:expat)))
4220
4221 ;; This is the last release of Minitest 4, which is used by some packages.
4222 (define-public ruby-minitest-4
4223 (package (inherit ruby-minitest)
4224 (version "4.7.5")
4225 (source (origin
4226 (method url-fetch)
4227 (uri (rubygems-uri "minitest" version))
4228 (sha256
4229 (base32
4230 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
4231 (arguments
4232 `(#:phases
4233 (modify-phases %standard-phases
4234 (add-after 'unpack 'remove-unsupported-method
4235 (lambda _
4236 (substitute* "Rakefile"
4237 (("self\\.rubyforge_name = .*") ""))
4238 #t))
4239 (add-after 'build 'exclude-failing-tests
4240 (lambda _
4241 ;; Some tests are failing on Ruby 2.4 due to the deprecation of
4242 ;; Fixnum.
4243 (delete-file "test/minitest/test_minitest_spec.rb")
4244 #t)))))))
4245
4246 (define-public ruby-minitest-around
4247 (package
4248 (name "ruby-minitest-around")
4249 (version "0.5.0")
4250 (source
4251 (origin
4252 (method url-fetch)
4253 (uri (rubygems-uri "minitest-around" version))
4254 (sha256
4255 (base32
4256 "15ywnqx0719jl9c25yqfshmwcir57i5f4hr1ra9v9vay9ylcwndr"))))
4257 (build-system ruby-build-system)
4258 (arguments
4259 '(#:phases
4260 (modify-phases %standard-phases
4261 (add-after 'extract-gemspec 'remove-unnecessary-dependency-versions
4262 (lambda _
4263 (substitute* "minitest-around.gemspec"
4264 (("%q<cucumber>.*") "%q<cucumber>, [\">= 0\"])\n"))
4265 #t)))))
4266 (propagated-inputs
4267 `(("ruby-minitest" ,ruby-minitest)))
4268 (native-inputs
4269 `(("bundler" ,bundler)
4270 ("ruby-cucumber" ,ruby-cucumber)
4271 ("ruby-bump" ,ruby-bump)
4272 ("ruby-test-construct" ,ruby-test-construct)))
4273 (synopsis "Run code around tests in Minitest")
4274 (description
4275 "This library provides a way to run code around tests in Minitest,
4276 written using either the unit test or spec style.")
4277 (home-page "https://github.com/splattael/minitest-around")
4278 (license license:expat)))
4279
4280 (define-public ruby-minitest-sprint
4281 (package
4282 (name "ruby-minitest-sprint")
4283 (version "1.1.0")
4284 (source (origin
4285 (method url-fetch)
4286 (uri (rubygems-uri "minitest-sprint" version))
4287 (sha256
4288 (base32
4289 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
4290 (build-system ruby-build-system)
4291 (native-inputs
4292 `(("ruby-hoe" ,ruby-hoe)
4293 ("ruby-minitest" ,ruby-minitest)))
4294 (synopsis "Fast test suite runner for minitest")
4295 (description "Minitest-sprint is a test runner for minitest that makes it
4296 easier to re-run individual failing tests.")
4297 (home-page "https://github.com/seattlerb/minitest-sprint")
4298 (license license:expat)))
4299
4300 (define-public ruby-minitest-bacon
4301 (package
4302 (name "ruby-minitest-bacon")
4303 (version "1.0.3")
4304 (source (origin
4305 (method url-fetch)
4306 (uri (rubygems-uri "minitest-bacon" version))
4307 (sha256
4308 (base32
4309 "0zhdwcl6bgha61qiyfvr7zs7ywaxc33wmj9xhxl8jdmpdvifvfaj"))))
4310 (build-system ruby-build-system)
4311 (native-inputs
4312 `(("ruby-hoe" ,ruby-hoe)))
4313 (inputs
4314 `(("ruby-minitest" ,ruby-minitest)))
4315 (synopsis "Bacon compatibility library for minitest")
4316 (description "Minitest-bacon extends minitest with bacon-like
4317 functionality, making it easier to migrate test suites from bacon to minitest.")
4318 (home-page "https://github.com/seattlerb/minitest-bacon")
4319 (license license:expat)))
4320
4321 (define-public ruby-minitest-focus
4322 (package
4323 (name "ruby-minitest-focus")
4324 (version "1.1.2")
4325 (source
4326 (origin
4327 (method url-fetch)
4328 (uri (rubygems-uri "minitest-focus" version))
4329 (sha256
4330 (base32
4331 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
4332 (build-system ruby-build-system)
4333 (propagated-inputs
4334 `(("ruby-minitest" ,ruby-minitest)))
4335 (native-inputs
4336 `(("ruby-hoe" ,ruby-hoe)))
4337 (synopsis "Allows a few specific tests to be focused on")
4338 (description
4339 "@code{minitest-focus} gives the ability focus on a few tests with ease
4340 without having to use command-line arguments. It introduces a @code{focus}
4341 class method for use in testing classes, specifying that the next defined test
4342 is to be run.")
4343 (home-page "https://github.com/seattlerb/minitest-focus")
4344 (license license:expat)))
4345
4346 (define-public ruby-minitest-pretty-diff
4347 ;; Use git reference because gem is out of date and does not contain testing
4348 ;; script. There are no releases on GitHub.
4349 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
4350 (package
4351 (name "ruby-minitest-pretty-diff")
4352 (version (string-append "0.1-1." (string-take commit 8)))
4353 (source (origin
4354 (method git-fetch)
4355 (uri (git-reference
4356 (url "https://github.com/adammck/minitest-pretty_diff")
4357 (commit commit)))
4358 (file-name (string-append name "-" version "-checkout"))
4359 (sha256
4360 (base32
4361 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
4362 (build-system ruby-build-system)
4363 (arguments
4364 `(#:phases
4365 (modify-phases %standard-phases
4366 (replace 'check
4367 (lambda _
4368 (invoke "script/test"))))))
4369 (native-inputs
4370 `(("bundler" ,bundler)
4371 ("ruby-turn" ,ruby-turn)))
4372 (synopsis "Pretty-print hashes and arrays in MiniTest")
4373 (description
4374 "@code{minitest-pretty_diff} monkey-patches
4375 @code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
4376 diffing them. This makes it easier to spot differences between nested
4377 structures when tests fail.")
4378 (home-page "https://github.com/adammck/minitest-pretty_diff")
4379 (license license:expat))))
4380
4381 (define-public ruby-minitest-moar
4382 (package
4383 (name "ruby-minitest-moar")
4384 (version "0.0.4")
4385 (source
4386 (origin
4387 (method url-fetch)
4388 (uri (rubygems-uri "minitest-moar" version))
4389 (sha256
4390 (base32
4391 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
4392 (build-system ruby-build-system)
4393 (arguments
4394 `(#:phases
4395 (modify-phases %standard-phases
4396 (add-before 'check 'clean-dependencies
4397 (lambda _
4398 ;; Remove all gems defined in the Gemfile because these are not
4399 ;; truly needed.
4400 (substitute* "Gemfile"
4401 (("gem .*") ""))
4402 ;; Remove byebug as not needed to run tests.
4403 (substitute* "test/test_helper.rb"
4404 (("require 'byebug'") ""))
4405 #t)))))
4406 (native-inputs
4407 `(("bundler" ,bundler)
4408 ("ruby-minitest" ,ruby-minitest)))
4409 (synopsis "Extra features and changes to MiniTest")
4410 (description "@code{MiniTest Moar} add some additional features and
4411 changes some default behaviours in MiniTest. For instance, Moar replaces the
4412 MiniTest @code{Object#stub} with a global @code{stub} method.")
4413 (home-page "https://github.com/dockyard/minitest-moar")
4414 (license license:expat)))
4415
4416 (define-public ruby-minitest-bonus-assertions
4417 (package
4418 (name "ruby-minitest-bonus-assertions")
4419 (version "3.0")
4420 (source
4421 (origin
4422 (method url-fetch)
4423 (uri (rubygems-uri "minitest-bonus-assertions" version))
4424 (sha256
4425 (base32
4426 "1hbq9jk904xkz868yha1bqcm6azm7kmjsll2k4pn2nrcib508h2a"))))
4427 (build-system ruby-build-system)
4428 (arguments
4429 `(#:phases
4430 (modify-phases %standard-phases
4431 (add-before 'check 'clean-dependencies
4432 (lambda _
4433 ;; Remove unneeded require statement that would entail another
4434 ;; dependency.
4435 (substitute* "test/minitest_config.rb"
4436 (("require 'minitest/bisect'") ""))
4437 #t)))))
4438 (native-inputs
4439 `(("ruby-hoe" ,ruby-hoe)
4440 ("ruby-minitest-pretty-diff" ,ruby-minitest-pretty-diff)
4441 ("ruby-minitest-focus" ,ruby-minitest-focus)
4442 ("ruby-minitest-moar" ,ruby-minitest-moar)))
4443 (synopsis "Bonus assertions for @code{Minitest}")
4444 (description
4445 "Minitest bonus assertions provides extra MiniTest assertions. For
4446 instance, it provides @code{assert_true}, @code{assert_false} and
4447 @code{assert_set_equal}.")
4448 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
4449 (license license:expat)))
4450
4451 (define-public ruby-minitest-reporters
4452 (package
4453 (name "ruby-minitest-reporters")
4454 (version "1.3.6")
4455 (source
4456 (origin
4457 (method url-fetch)
4458 (uri (rubygems-uri "minitest-reporters" version))
4459 (sha256
4460 (base32
4461 "1a3das80rwgys5rj48i5ly144nvszyqyi748bk9bss74jblcf5ay"))))
4462 (build-system ruby-build-system)
4463 (arguments
4464 '(#:phases
4465 (modify-phases %standard-phases
4466 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
4467 ;; including it as an input can lead to circular dependencies.
4468 (add-after 'unpack 'remove-rubocop-from-Rakefile
4469 (lambda _
4470 (substitute* "Rakefile"
4471 (("require 'rubocop/rake\\_task'") "")
4472 (("RuboCop::RakeTask\\.new\\(:rubocop\\)") "[].each"))
4473 #t))
4474 (add-after 'extract-gemspec 'remove-rubocop-from-gemspec
4475 (lambda _
4476 (substitute* "minitest-reporters.gemspec"
4477 ((".*%q<rubocop>.*") "\n"))
4478 #t)))))
4479 (propagated-inputs
4480 `(("ruby-ansi" ,ruby-ansi)
4481 ("ruby-builder" ,ruby-builder)
4482 ("ruby-minitest" ,ruby-minitest)
4483 ("ruby-progressbar" ,ruby-progressbar)))
4484 (native-inputs
4485 `(("bundler" ,bundler)
4486 ("ruby-maruku" ,ruby-maruku)))
4487 (synopsis "Enhanced reporting for Minitest tests")
4488 (description
4489 "@code{minitest/reporters} provides a custom Minitest runner to improve
4490 how the test state is reported. A number of different reporters are
4491 available, including a spec reporter, progress bar reporter, a HTML
4492 reporter.")
4493 (home-page "https://github.com/kern/minitest-reporters")
4494 (license license:expat)))
4495
4496 (define-public ruby-minitest-rg
4497 (package
4498 (name "ruby-minitest-rg")
4499 (version "5.2.0")
4500 (source
4501 (origin
4502 (method url-fetch)
4503 (uri (rubygems-uri "minitest-rg" version))
4504 (sha256
4505 (base32
4506 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
4507 (build-system ruby-build-system)
4508 (arguments
4509 ;; Some tests fail even outside Guix, so disable tests.
4510 ;; https://github.com/blowmage/minitest-rg/issues/12
4511 ;; https://github.com/blowmage/minitest-rg/pull/13
4512 `(#:tests? #f))
4513 (propagated-inputs
4514 `(("ruby-minitest" ,ruby-minitest)))
4515 (synopsis "Coloured output for Minitest")
4516 (description
4517 "@code{minitest-rg} changes the colour of the output from Minitest.")
4518 (home-page "https://blowmage.com/minitest-rg/")
4519 (license license:expat)))
4520
4521 (define-public ruby-minitest-hooks
4522 (package
4523 (name "ruby-minitest-hooks")
4524 (version "1.4.2")
4525 (source
4526 (origin
4527 (method url-fetch)
4528 (uri (rubygems-uri "minitest-hooks" version))
4529 (sha256
4530 (base32
4531 "0lnpvzijbjrvxjc43d155jnbk2mkfshrz22an711wh004scavlzc"))))
4532 (build-system ruby-build-system)
4533 (arguments
4534 '(#:test-target "spec"))
4535 (native-inputs
4536 `(("ruby-sequel" ,ruby-sequel)
4537 ("ruby-sqlite3" ,ruby-sqlite3)))
4538 (synopsis "Hooks for the minitest framework")
4539 (description
4540 "Minitest-hooks adds @code{around}, @code{before_all}, @code{after_all},
4541 @code{around_all} hooks for Minitest. This allows, for instance, running each
4542 suite of specs inside a database transaction, running each spec inside its own
4543 savepoint inside that transaction. This can significantly speed up testing
4544 for specs that share expensive database setup code.")
4545 (home-page "https://github.com/jeremyevans/minitest-hooks")
4546 (license license:expat)))
4547
4548 (define-public ruby-daemons
4549 (package
4550 (name "ruby-daemons")
4551 (version "1.2.5")
4552 (source (origin
4553 (method url-fetch)
4554 (uri (rubygems-uri "daemons" version))
4555 (sha256
4556 (base32
4557 "15smbsg0gxb7nf0nrlnplc68y0cdy13dm6fviavpmw7c630sring"))))
4558 (build-system ruby-build-system)
4559 (arguments
4560 `(#:tests? #f)) ; no test suite
4561 (synopsis "Daemonize Ruby programs")
4562 (description "Daemons provides a way to wrap existing Ruby scripts to be
4563 run as a daemon and to be controlled by simple start/stop/restart commands.")
4564 (home-page "https://github.com/thuehlinger/daemons")
4565 (license license:expat)))
4566
4567 (define-public ruby-data_uri
4568 (package
4569 (name "ruby-data_uri")
4570 (version "0.1.0")
4571 (source
4572 (origin
4573 (method url-fetch)
4574 (uri (rubygems-uri "data_uri" version))
4575 (sha256
4576 (base32
4577 "0fzkxgdxrlbfl4537y3n9mjxbm28kir639gcw3x47ffchwsgdcky"))))
4578 (build-system ruby-build-system)
4579 (synopsis "URI class for parsing data URIs")
4580 (description
4581 "Data @acronym{URI, universal resource idenfitier}s allow resources to be
4582 embedded inside a URI. The URI::Data class provides support for parsing these
4583 URIs using the normal URI.parse method.")
4584 (home-page "https://github.com/dball/data_uri")
4585 (license license:expat)))
4586
4587 (define-public ruby-deep-merge
4588 (package
4589 (name "ruby-deep-merge")
4590 (version "1.2.1")
4591 (home-page "https://github.com/danielsdeleo/deep_merge")
4592 ;; The Rubygem source does not contain the gemspec required for tests.
4593 (source (origin
4594 (method git-fetch)
4595 (uri (git-reference (url home-page) (commit version)))
4596 (file-name (git-file-name name version))
4597 (sha256
4598 (base32
4599 "0c9rk23ilhc0n4489y6lda2wzphpzh6ish6fahlbpjhxn82wb931"))))
4600 (build-system ruby-build-system)
4601 (native-inputs
4602 `(("ruby-minitest" ,ruby-minitest)))
4603 (synopsis "Recursively merge hashes")
4604 (description
4605 "Deep Merge is a set of utility functions for @code{Hash}. It permits
4606 you to merge elements inside a hash together recursively.")
4607 (license license:expat)))
4608
4609 (define-public ruby-git
4610 (package
4611 (name "ruby-git")
4612 (version "1.3.0")
4613 (source (origin
4614 (method url-fetch)
4615 (uri (rubygems-uri "git" version))
4616 (sha256
4617 (base32
4618 "1waikaggw7a1d24nw0sh8fd419gbf7awh000qhsf411valycj6q3"))))
4619 (build-system ruby-build-system)
4620 (arguments
4621 `(#:tests? #f ; no tests
4622 #:phases (modify-phases %standard-phases
4623 (add-after 'install 'patch-git-binary
4624 (lambda* (#:key inputs outputs #:allow-other-keys)
4625 ;; Make the default git binary an absolute path to the
4626 ;; store.
4627 (let ((git (string-append (assoc-ref inputs "git")
4628 "/bin/git"))
4629 (config (string-append
4630 (assoc-ref outputs "out")
4631 "/lib/ruby/vendor_ruby/gems/git-"
4632 ,version "/lib/git/config.rb")))
4633 (substitute* (list config)
4634 (("'git'")
4635 (string-append "'" git "'")))
4636 #t))))))
4637 (inputs
4638 `(("git" ,git)))
4639 (synopsis "Ruby wrappers for Git")
4640 (description "Ruby/Git is a Ruby library that can be used to create, read
4641 and manipulate Git repositories by wrapping system calls to the git binary.")
4642 (home-page "https://github.com/schacon/ruby-git")
4643 (license license:expat)))
4644
4645 (define-public ruby-hocon
4646 (package
4647 (name "ruby-hocon")
4648 (version "1.3.1")
4649 (home-page "https://github.com/puppetlabs/ruby-hocon")
4650 (source (origin
4651 (method git-fetch)
4652 (uri (git-reference (url home-page) (commit version)))
4653 (file-name (git-file-name name version))
4654 (sha256
4655 (base32
4656 "172hh2zr0n9nnszv0qvlgwszgkrq84yahrg053m68asy79zpmbqr"))))
4657 (build-system ruby-build-system)
4658 (arguments
4659 '(#:phases (modify-phases %standard-phases
4660 (replace 'check
4661 (lambda* (#:key tests? #:allow-other-keys)
4662 (if tests?
4663 (invoke "rspec")
4664 (format #t "test suite not run~%"))
4665 #t)))))
4666 (native-inputs
4667 `(("bundler" ,bundler)
4668 ("ruby-rspec" ,ruby-rspec)))
4669 (synopsis "HOCON config library")
4670 (description
4671 "This package provides Ruby support for the @acronym{HOCON,
4672 Human-Optimized Config Object Notation} configuration file format. It
4673 supports parsing and modifying HOCON and JSON files, and rendering parsed
4674 objects back to a @code{String}.")
4675 (license license:asl2.0)))
4676
4677 (define-public ruby-slop
4678 (package
4679 (name "ruby-slop")
4680 (version "4.5.0")
4681 (source (origin
4682 (method url-fetch)
4683 (uri (rubygems-uri "slop" version))
4684 (sha256
4685 (base32
4686 "0bfm8535g0rkn9cbjndkckf0f7a3wj0rg4rqhrpsgxnbfdf2lm0p"))))
4687 (build-system ruby-build-system)
4688 (native-inputs
4689 `(("ruby-minitest" ,ruby-minitest)))
4690 (synopsis "Ruby command line option parser")
4691 (description "Slop provides a Ruby domain specific language for gathering
4692 options and parsing command line flags.")
4693 (home-page "https://github.com/leejarvis/slop")
4694 (license license:expat)))
4695
4696 (define-public ruby-slop-3
4697 (package (inherit ruby-slop)
4698 (version "3.6.0")
4699 (source (origin
4700 (method url-fetch)
4701 (uri (rubygems-uri "slop" version))
4702 (sha256
4703 (base32
4704 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
4705
4706 (define-public ruby-multi-xml
4707 (package
4708 (name "ruby-multi-xml")
4709 (version "0.6.0")
4710 (source
4711 (origin
4712 (method url-fetch)
4713 (uri (rubygems-uri "multi_xml" version))
4714 (sha256
4715 (base32
4716 "0lmd4f401mvravi1i1yq7b2qjjli0yq7dfc4p1nj5nwajp7r6hyj"))))
4717 (build-system ruby-build-system)
4718 (arguments
4719 '(#:tests? #f)) ; No included tests
4720 (synopsis "Swappable XML backends for Ruby")
4721 (description
4722 "@code{MultiXml} provides swappable XML backends utilizing either LibXML,
4723 Nokogiri, Ox, or REXML.")
4724 (home-page "https://github.com/sferik/multi_xml")
4725 (license license:expat)))
4726
4727 (define-public ruby-multipart-post
4728 (package
4729 (name "ruby-multipart-post")
4730 (version "2.0.0")
4731 (source (origin
4732 (method url-fetch)
4733 (uri (rubygems-uri "multipart-post" version))
4734 (sha256
4735 (base32
4736 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
4737 (build-system ruby-build-system)
4738 (native-inputs
4739 `(("bundler" ,bundler)))
4740 (synopsis "Multipart POST library for Ruby")
4741 (description "Multipart-Post Adds multipart POST capability to Ruby's
4742 net/http library.")
4743 (home-page "https://github.com/nicksieger/multipart-post")
4744 (license license:expat)))
4745
4746 (define-public ruby-multi-json
4747 (package
4748 (name "ruby-multi-json")
4749 (version "1.13.1")
4750 (source
4751 (origin
4752 (method git-fetch)
4753 ;; Tests are not distributed at rubygems.org so download from GitHub
4754 ;; instead.
4755 (uri (git-reference
4756 (url "https://github.com/intridea/multi_json")
4757 (commit (string-append "v" version))))
4758 (file-name (git-file-name name version))
4759 (sha256
4760 (base32
4761 "18wpb6p01rrkl4v33byh70vxj2a5jxkfxzv3pz8z6pssy4ymwkm4"))))
4762 (build-system ruby-build-system)
4763 (arguments
4764 `(#:phases
4765 (modify-phases %standard-phases
4766 (add-after 'unpack 'remove-signing-key-reference
4767 (lambda _
4768 (substitute* "multi_json.gemspec"
4769 ((".*spec.signing_key.*") ""))
4770 #t)))))
4771 (native-inputs
4772 `(("bundler" ,bundler)
4773 ("ruby-rspec" ,ruby-rspec)
4774 ("ruby-yard" ,ruby-yard)
4775 ("ruby-json-pure" ,ruby-json-pure)
4776 ("ruby-oj" ,ruby-oj)
4777 ("ruby-yajl-ruby" ,ruby-yajl-ruby)))
4778 (synopsis "Common interface to multiple JSON libraries for Ruby")
4779 (description
4780 "This package provides a common interface to multiple JSON libraries,
4781 including Oj, Yajl, the JSON gem (with C-extensions), the pure-Ruby JSON gem,
4782 NSJSONSerialization, gson.rb, JrJackson, and OkJson.")
4783 (home-page "https://github.com/intridea/multi_json")
4784 (license license:expat)))
4785
4786 (define-public ruby-multi-test
4787 (package
4788 (name "ruby-multi-test")
4789 (version "0.1.2")
4790 (source
4791 (origin
4792 (method url-fetch)
4793 (uri (rubygems-uri "multi_test" version))
4794 (sha256
4795 (base32
4796 "1sx356q81plr67hg16jfwz9hcqvnk03bd9n75pmdw8pfxjfy1yxd"))))
4797 (build-system ruby-build-system)
4798 (arguments
4799 '(;; Tests require different sets of specific gem versions to be available,
4800 ;; and there is no gemfile that specifies the newest versions of
4801 ;; dependencies to be tested.
4802 #:tests? #f))
4803 (synopsis
4804 "Interface to testing libraries loaded into a running Ruby process")
4805 (description
4806 "@code{multi_test} provides a uniform interface onto whatever testing
4807 libraries that have been loaded into a running Ruby process to help control
4808 rogue test/unit/autorun requires.")
4809 (home-page "https://github.com/cucumber/multi_test")
4810 (license license:expat)))
4811
4812 (define-public ruby-arel
4813 (package
4814 (name "ruby-arel")
4815 (version "9.0.0")
4816 (source (origin
4817 (method url-fetch)
4818 (uri (rubygems-uri "arel" version))
4819 (sha256
4820 (base32
4821 "1jk7wlmkr61f6g36w9s2sn46nmdg6wn2jfssrhbhirv5x9n95nk0"))))
4822 (build-system ruby-build-system)
4823 (arguments '(#:tests? #f)) ; no tests
4824 (home-page "https://github.com/rails/arel")
4825 (synopsis "SQL AST manager for Ruby")
4826 (description "Arel is an SQL @dfn{Abstract Syntax Tree} (AST) manager for
4827 Ruby. It simplifies the generation of complex SQL queries and adapts to
4828 various relational database implementations.")
4829 (license license:expat)))
4830
4831 (define-public ruby-marcel
4832 (package
4833 (name "ruby-marcel")
4834 (version "0.3.3")
4835 (source
4836 (origin
4837 (method url-fetch)
4838 (uri (rubygems-uri "marcel" version))
4839 (sha256
4840 (base32
4841 "1nxbjmcyg8vlw6zwagf17l9y2mwkagmmkg95xybpn4bmf3rfnksx"))))
4842 (build-system ruby-build-system)
4843 (arguments
4844 '(;; No included tests
4845 #:tests? #f))
4846 (propagated-inputs
4847 `(("ruby-mimemagic" ,ruby-mimemagic)))
4848 (synopsis "MIME type detection using magic numbers, filenames and extensions")
4849 (description
4850 "@code{marcel} provides @acronym{MIME, Multipurpose Internet Mail
4851 Extensions} type detection using magic numbers, filenames, and extensions")
4852 (home-page "https://github.com/basecamp/marcel")
4853 (license license:expat)))
4854
4855 (define-public ruby-minitar
4856 ;; We package from the GitHub source to fix the security issue reported at
4857 ;; https://github.com/halostatue/minitar/issues/16.
4858 (let ((commit "e25205ecbb6277ae8a3df1e6a306d7ed4458b6e4"))
4859 (package
4860 (name "ruby-minitar")
4861 (version (string-append "0.5.4-1." (string-take commit 8)))
4862 (source
4863 (origin
4864 (method git-fetch)
4865 (uri (git-reference
4866 (url "https://github.com/halostatue/minitar")
4867 (commit commit)))
4868 (file-name (string-append name "-" version "-checkout"))
4869 (sha256
4870 (base32
4871 "1iywfx07jgjqcmixzkxk9zdwfmij1fyg1z2jlwzj15cj7s99qlfv"))))
4872 (build-system ruby-build-system)
4873 (arguments
4874 '(#:tests? #f)) ; missing a gemspec
4875 (synopsis "Ruby library and utility for handling tar archives")
4876 (description
4877 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
4878 that provides the ability to deal with POSIX tar archive files.")
4879 (home-page "http://www.github.com/atoulme/minitar")
4880 (license (list license:gpl2+ license:ruby)))))
4881
4882 (define-public ruby-mini-portile
4883 (package
4884 (name "ruby-mini-portile")
4885 (version "0.6.2")
4886 (source
4887 (origin
4888 (method url-fetch)
4889 (uri (rubygems-uri "mini_portile" version))
4890 (sha256
4891 (base32
4892 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
4893 (build-system ruby-build-system)
4894 (arguments
4895 '(#:tests? #f)) ; tests require network access
4896 (synopsis "Ports system for Ruby developers")
4897 (description "Mini-portile is a port/recipe system for Ruby developers.
4898 It provides a standard way to compile against specific versions of libraries
4899 to reproduce user environments.")
4900 (home-page "https://github.com/flavorjones/mini_portile")
4901 (license license:expat)))
4902
4903 (define-public ruby-mini-portile-2
4904 (package (inherit ruby-mini-portile)
4905 (version "2.4.0")
4906 (source (origin
4907 (method url-fetch)
4908 (uri (rubygems-uri "mini_portile2" version))
4909 (sha256
4910 (base32
4911 "15zplpfw3knqifj9bpf604rb3wc1vhq6363pd6lvhayng8wql5vy"))))))
4912
4913 (define-public ruby-nokogiri
4914 (package
4915 (name "ruby-nokogiri")
4916 (version "1.10.9")
4917 (source (origin
4918 (method url-fetch)
4919 (uri (rubygems-uri "nokogiri" version))
4920 (sha256
4921 (base32
4922 "12j76d0bp608932xkzmfi638c7aqah57l437q8494znzbj610qnm"))))
4923 (build-system ruby-build-system)
4924 (arguments
4925 ;; Tests fail because Nokogiri can only test with an installed extension,
4926 ;; and also because many test framework dependencies are missing.
4927 `(#:tests? #f
4928 #:gem-flags (list "--" "--use-system-libraries"
4929 (string-append "--with-xml2-include="
4930 (assoc-ref %build-inputs "libxml2")
4931 "/include/libxml2" ))
4932 #:phases
4933 (modify-phases %standard-phases
4934 (add-before 'build 'patch-extconf
4935 ;; 'pkg-config' is not included in the GEM_PATH during
4936 ;; installation, so we add it directly to the load path.
4937 (lambda* (#:key inputs #:allow-other-keys)
4938 (let* ((pkg-config (assoc-ref inputs "ruby-pkg-config")))
4939 (substitute* "ext/nokogiri/extconf.rb"
4940 (("gem 'pkg-config'.*")
4941 (string-append "$:.unshift '"
4942 pkg-config "/lib/ruby/vendor_ruby"
4943 "/gems/pkg-config-"
4944 ,(package-version ruby-pkg-config)
4945 "/lib'\n"))))
4946 #t)))))
4947 (native-inputs
4948 `(("ruby-hoe" ,ruby-hoe)))
4949 (inputs
4950 `(("zlib" ,zlib)
4951 ("libxml2" ,libxml2)
4952 ("libxslt" ,libxslt)))
4953 (propagated-inputs
4954 `(("ruby-mini-portile" ,ruby-mini-portile-2)
4955 ("ruby-pkg-config" ,ruby-pkg-config)))
4956 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
4957 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
4958 both CSS3 selector and XPath 1.0 support.")
4959 (home-page "http://www.nokogiri.org/")
4960 (license license:expat)))
4961
4962 (define-public ruby-method-source
4963 (package
4964 (name "ruby-method-source")
4965 (version "1.0.0")
4966 (source
4967 (origin
4968 (method url-fetch)
4969 (uri (rubygems-uri "method_source" version))
4970 (sha256
4971 (base32
4972 "1pnyh44qycnf9mzi1j6fywd5fkskv3x7nmsqrrws0rjn5dd4ayfp"))))
4973 (build-system ruby-build-system)
4974 (arguments
4975 `(#:test-target "spec"))
4976 (native-inputs
4977 `(("ruby-rspec" ,ruby-rspec)
4978 ("git" ,git)))
4979 (synopsis "Retrieve the source code for Ruby methods")
4980 (description "Method_source retrieves the source code for Ruby methods.
4981 Additionally, it can extract source code from Proc and Lambda objects or just
4982 extract comments.")
4983 (home-page "https://github.com/banister/method_source")
4984 (license license:expat)))
4985
4986 (define-public ruby-coderay
4987 (package
4988 (name "ruby-coderay")
4989 (version "1.1.2")
4990 (source
4991 (origin
4992 (method url-fetch)
4993 (uri (rubygems-uri "coderay" version))
4994 (sha256
4995 (base32
4996 "15vav4bhcc2x3jmi3izb11l4d9f3xv8hp2fszb7iqmpsccv1pz4y"))))
4997 (build-system ruby-build-system)
4998 (arguments
4999 '(#:tests? #f)) ; missing test files
5000 (synopsis "Ruby syntax highlighting library")
5001 (description "Coderay is a Ruby library that provides syntax highlighting
5002 for select languages.")
5003 (home-page "http://coderay.rubychan.de")
5004 (license license:expat)))
5005
5006 (define-public ruby-cuke-modeler
5007 (package
5008 (name "ruby-cuke-modeler")
5009 (version "3.1.0")
5010 (source
5011 (origin
5012 (method url-fetch)
5013 (uri (rubygems-uri "cuke_modeler" version))
5014 (sha256
5015 (base32
5016 "19smj3g3wvz0203l549sadpcxgh0ir350a6k78gq0bmlv9cchmjb"))))
5017 (build-system ruby-build-system)
5018 (arguments `(#:tests? #f)) ;no test suite in gem
5019 (propagated-inputs
5020 `(("ruby-gherkin" ,ruby-gherkin)))
5021 (synopsis "Gherkin test suite analysis tool")
5022 (description "CukeModeler facilitates modeling a test suite that is
5023 written in Gherkin (e.g. Cucumber, SpecFlow, Lettuce, etc.). It does this by
5024 providing an abstraction layer on top of the Abstract Syntax Tree (AST) that
5025 the @code{cucumber-gherkin} generates when parsing features, as well as
5026 providing models for feature files and directories in order to be able to have
5027 a fully traversable model tree of a test suite's structure. These models can
5028 then be analyzed or manipulated more easily than the underlying AST layer.")
5029 (home-page "https://github.com/enkessler/cuke_modeler")
5030 (license license:expat)))
5031
5032 (define-public ruby-parallel-tests
5033 (package
5034 (name "ruby-parallel-tests")
5035 (version "3.0.0")
5036 (home-page "https://github.com/grosser/parallel_tests")
5037 (source (origin
5038 (method git-fetch)
5039 (uri (git-reference
5040 (url home-page)
5041 (commit (string-append "v" version))))
5042 (file-name (string-append name version))
5043 (sha256
5044 (base32
5045 "08a6ndqn2dqacmc7yg48k0dh2rfrynvhkd5hiay16dl9m1r9q8pz"))))
5046 (build-system ruby-build-system)
5047 (arguments
5048 '(#:test-target "default"
5049 #:phases (modify-phases %standard-phases
5050 (add-after 'patch-source-shebangs 'patch-shell-invokations
5051 (lambda _
5052 (substitute* '("lib/parallel_tests/tasks.rb"
5053 "spec/parallel_tests/tasks_spec.rb")
5054 (("/bin/sh") (which "sh"))
5055 (("/bin/bash") (which "bash")))
5056 #t))
5057 (add-before 'check 'remove-version-constraints
5058 (lambda _
5059 ;; Remove hard coded version constraints, instead just
5060 ;; use whatever versions are available in Guix.
5061 (delete-file "Gemfile.lock")
5062 (substitute* "Gemfile"
5063 (("'minitest',.*")
5064 "'minitest'\n")
5065 (("'cucumber',.*")
5066 "'cucumber'\n"))
5067 #t))
5068 (add-before 'check 'disable-rails-test
5069 (lambda _
5070 ;; XXX: This test attempts to download and run the test
5071 ;; suites of multiple Rails versions(!) directly.
5072 (delete-file "spec/rails_spec.rb")
5073 #t))
5074 (add-before 'check 'set-HOME
5075 (lambda _
5076 ;; Some tests check the output of Bundler, and fail when
5077 ;; Bundler warns that /homeless-shelter does not exist.
5078 (setenv "HOME" "/tmp")
5079 #t)))))
5080 (native-inputs
5081 `(("ruby-bump" ,ruby-bump)
5082 ("ruby-cucumber" ,ruby-cucumber)
5083 ("ruby-cuke-modeler" ,ruby-cuke-modeler)
5084 ("ruby-minitest" ,ruby-minitest)
5085 ("ruby-rake" ,ruby-rake)
5086 ("ruby-rspec" ,ruby-rspec)
5087 ("ruby-spinach" ,ruby-spinach)))
5088 (propagated-inputs
5089 `(("ruby-parallel" ,ruby-parallel)))
5090 (synopsis "Run tests in parallel")
5091 (description
5092 "This package can speed up @code{Test::Unit}, @code{RSpec},
5093 @code{Cucumber}, and @code{Spinach} tests by running them concurrently
5094 across multiple CPU cores.")
5095 (license license:expat)))
5096
5097 (define-public ruby-parser
5098 (package
5099 (name "ruby-parser")
5100 (version "2.7.1.4")
5101 (source
5102 (origin
5103 (method url-fetch)
5104 (uri (rubygems-uri "parser" version))
5105 (sha256
5106 (base32
5107 "1030znhvhkfn39svwbj6qn4xb6hgl94gnvg57k4d3r76f9bryqmn"))))
5108 (build-system ruby-build-system)
5109 (native-inputs
5110 `(("bundler" ,bundler)
5111 ("ruby-cliver" ,ruby-cliver)
5112 ("ruby-simplecov" ,ruby-simplecov)
5113 ("ruby-racc" ,ruby-racc)))
5114 (inputs
5115 `(("ragel" ,ragel)))
5116 (propagated-inputs
5117 `(("ruby-ast" ,ruby-ast)))
5118 (synopsis "Ruby parser written in pure Ruby")
5119 (description
5120 "This package provides a Ruby parser written in pure Ruby.")
5121 (home-page "https://github.com/whitequark/parser")
5122 (license license:expat)))
5123
5124 (define-public ruby-sexp-processor
5125 (package
5126 (name "ruby-sexp-processor")
5127 (version "4.15.0")
5128 (source
5129 (origin
5130 (method url-fetch)
5131 (uri (rubygems-uri "sexp_processor" version))
5132 (sha256
5133 (base32
5134 "0d1vks77xnd0m3s94a58f9bkdwlaml5qdkmprx279m2s0pc2gv55"))))
5135 (build-system ruby-build-system)
5136 (native-inputs
5137 ;; TODO: Add ruby-minitest-proveit once available.
5138 `(("hoe" ,ruby-hoe)))
5139 (synopsis "ParseTree fork which includes generic S-exp processing tools")
5140 (description "The sexp_processor package is derived from ParseTree, but
5141 contrary to ParseTree, it includes all the generic S-exp processing tools.
5142 Amongst the included tools are @code{Sexp}, @code{SexpProcessor} and
5143 @code{Environment}")
5144 (home-page "https://github.com/seattlerb/sexp_processor")
5145 (license license:expat)))
5146
5147 (define-public ruby-ruby-parser
5148 (package
5149 (name "ruby-ruby-parser")
5150 (version "3.14.2")
5151 (source
5152 (origin
5153 (method url-fetch)
5154 (uri (rubygems-uri "ruby_parser" version))
5155 (sha256
5156 (base32
5157 "09qcdyjjw3p7g6cjm5m9swkms1xnv35ndiy7yw24cas16qrhha6c"))))
5158 (build-system ruby-build-system)
5159 (native-inputs
5160 `(("hoe" ,ruby-hoe)
5161 ("racc" ,ruby-racc)
5162 ("unifdef" ,unifdef)))
5163 (propagated-inputs
5164 `(("ruby-sexp-processor" ,ruby-sexp-processor)))
5165 (home-page "https://github.com/seattlerb/ruby_parser/")
5166 (synopsis "Ruby parser written in pure Ruby")
5167 (description "The ruby_parser (RP) package provides a Ruby parser written
5168 in pure Ruby. It outputs S-expressions which can be manipulated and converted
5169 back to Ruby via the @code{ruby2ruby} library.")
5170 (license license:expat)))
5171
5172 (define-public ruby-prawn-manual-builder
5173 (package
5174 (name "ruby-prawn-manual-builder")
5175 (version "0.3.1")
5176 (source
5177 (origin
5178 (method url-fetch)
5179 (uri (rubygems-uri "prawn-manual_builder" version))
5180 (sha256
5181 (base32 "1vlg5w7wq43g2hgpgra2nrcxj1kb4ayqliz4gmja2rhs037j2vzs"))))
5182 (build-system ruby-build-system)
5183 (arguments
5184 '(#:tests? #f ; no included tests
5185 #:phases
5186 (modify-phases %standard-phases
5187 (add-after 'extract-gemspec 'patch-gemspec
5188 (lambda _
5189 (substitute* ".gemspec"
5190 ;; Loosen the requirement for pdf-inspector
5191 (("~> 1\\.0\\.7") ">= 0")))))))
5192 (propagated-inputs
5193 `(("ruby-coderay" ,ruby-coderay)))
5194 (synopsis "Tool for writing manuals for Prawn and Prawn accessories")
5195 (description
5196 "This package provides a tool for writing manuals for Prawn and Prawn
5197 accessories")
5198 (home-page "https://github.com/prawnpdf/prawn-manual_builder")
5199 (license %prawn-project-licenses)))
5200
5201 (define-public ruby-progress_bar
5202 (package
5203 (name "ruby-progress_bar")
5204 (version "1.1.0")
5205 (source
5206 (origin
5207 (method url-fetch)
5208 (uri (rubygems-uri "progress_bar" version))
5209 (sha256
5210 (base32
5211 "1qc40mr6p1z9a3vlpnsg1zfgk1qswviql2a31y63wpv3vr6b5f48"))))
5212 (build-system ruby-build-system)
5213 (arguments
5214 '(#:test-target "spec"))
5215 (propagated-inputs
5216 `(("ruby-highline" ,ruby-highline)
5217 ("ruby-options" ,ruby-options)))
5218 (native-inputs
5219 `(("bundler" ,bundler)
5220 ("ruby-rspec" ,ruby-rspec)
5221 ("ruby-timecop" ,ruby-timecop)))
5222 (synopsis
5223 "Ruby library for displaying progress bars")
5224 (description
5225 "ProgressBar is a simple library for displaying progress bars. The
5226 maximum value is configurable, and additional information can be displayed
5227 like the percentage completion, estimated time remaining, elapsed time and
5228 rate.")
5229 (home-page "https://github.com/paul/progress_bar")
5230 (license license:wtfpl2)))
5231
5232 (define-public ruby-dep
5233 (package
5234 (name "ruby-dep")
5235 (version "1.5.0")
5236 (source
5237 (origin
5238 (method url-fetch)
5239 (uri (rubygems-uri "ruby_dep" version))
5240 (sha256
5241 (base32
5242 "1c1bkl97i9mkcvkn1jks346ksnvnnp84cs22gwl0vd7radybrgy5"))))
5243 (build-system ruby-build-system)
5244 (arguments
5245 '(#:tests? #f)) ; No included tests
5246 (synopsis "Creates a version constraint of supported Rubies")
5247 (description
5248 "This package helps create a version constraint of supported Rubies,
5249 suitable for a gemspec file.")
5250 (home-page "https://github.com/e2/ruby_dep")
5251 (license license:expat)))
5252
5253 (define-public ruby-progressbar
5254 (package
5255 (name "ruby-progressbar")
5256 (version "1.10.1")
5257 (source
5258 (origin
5259 (method url-fetch)
5260 (uri (rubygems-uri "ruby-progressbar" version))
5261 (sha256
5262 (base32 "1k77i0d4wsn23ggdd2msrcwfy0i376cglfqypkk2q77r2l3408zf"))))
5263 (build-system ruby-build-system)
5264 (arguments
5265 '(;; TODO: There looks to be a circular dependency with ruby-fuubar.
5266 #:tests? #f))
5267 (synopsis "Text progress bar library for Ruby")
5268 (description
5269 "Ruby/ProgressBar is an flexible text progress bar library for Ruby.
5270 The output can be customized with a formatting system.")
5271 (home-page "https://github.com/jfelchner/ruby-progressbar")
5272 (license license:expat)))
5273
5274 (define-public ruby-pry
5275 (package
5276 (name "ruby-pry")
5277 (version "0.13.1")
5278 (source
5279 (origin
5280 (method url-fetch)
5281 (uri (rubygems-uri "pry" version))
5282 (sha256
5283 (base32
5284 "0iyw4q4an2wmk8v5rn2ghfy2jaz9vmw2nk8415nnpx2s866934qk"))))
5285 (build-system ruby-build-system)
5286 (arguments
5287 '(#:tests? #f)) ; no tests
5288 (propagated-inputs
5289 `(("ruby-coderay" ,ruby-coderay)
5290 ("ruby-method-source" ,ruby-method-source)))
5291 (synopsis "Ruby REPL")
5292 (description "Pry is an IRB alternative and runtime developer console for
5293 Ruby. It features syntax highlighting, a plugin architecture, runtime
5294 invocation, and source and documentation browsing.")
5295 (home-page "https://cobaltbluemedia.com/pryrepl/")
5296 (license license:expat)))
5297
5298 (define-public ruby-single-cov
5299 (package
5300 (name "ruby-single-cov")
5301 (version "1.3.2")
5302 (home-page "https://github.com/grosser/single_cov")
5303 (source (origin
5304 (method git-fetch)
5305 (uri (git-reference (url home-page)
5306 (commit (string-append "v" version))))
5307 (file-name (git-file-name name version))
5308 (sha256
5309 (base32
5310 "05qdzpcai1p23a120gb9bxkfl4y73k9hicx34ch2lsk31lgi9bl7"))))
5311 (build-system ruby-build-system)
5312 (arguments
5313 '(#:test-target "default"
5314 #:phases (modify-phases %standard-phases
5315 (replace 'replace-git-ls-files
5316 (lambda _
5317 (substitute* "single_cov.gemspec"
5318 (("`git ls-files lib/ bin/ MIT-LICENSE`")
5319 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
5320 #t))
5321 (add-before 'check 'remove-version-constraints
5322 (lambda _
5323 (delete-file "Gemfile.lock")
5324 #t))
5325 (add-before 'check 'make-files-writable
5326 (lambda _
5327 ;; Tests need to create local directories and open files
5328 ;; with write permissions.
5329 (for-each make-file-writable
5330 (find-files "specs" #:directories? #t))
5331 #t))
5332 (add-before 'check 'disable-failing-test
5333 (lambda _
5334 ;; XXX: This test copies assets from minitest, but can
5335 ;; not cope with the files being read-only. Just skip
5336 ;; it for now.
5337 (substitute* "specs/single_cov_spec.rb"
5338 (("it \"complains when coverage is bad\"")
5339 "xit \"complains when coverage is bad\""))
5340 #t)))))
5341 (native-inputs
5342 `(("ruby-bump" ,ruby-bump)
5343 ("ruby-minitest" ,ruby-minitest)
5344 ("ruby-rspec" ,ruby-rspec)
5345 ("ruby-simplecov" ,ruby-simplecov)))
5346 (synopsis "Code coverage reporting tool")
5347 (description
5348 "This package provides actionable code coverage reports for Ruby
5349 projects. It has very little overhead and can be easily integrated with
5350 development tools to catch coverage problems early.")
5351 (license license:expat)))
5352
5353 (define-public ruby-guard
5354 (package
5355 (name "ruby-guard")
5356 (version "2.13.0")
5357 (source (origin
5358 (method git-fetch)
5359 ;; The gem does not include a Rakefile, nor does it contain a
5360 ;; gemspec file, nor does it come with the tests. This is why
5361 ;; we fetch the tarball from Github.
5362 (uri (git-reference
5363 (url "https://github.com/guard/guard")
5364 (commit (string-append "v" version))))
5365 (file-name (git-file-name name version))
5366 (sha256
5367 (base32
5368 "16pxcszr0g2jnl3090didxh1d8z5m2mly14m3w4rspb8fmclsnjs"))))
5369 (build-system ruby-build-system)
5370 (arguments
5371 `(#:tests? #f ; tests require cucumber
5372 #:phases
5373 (modify-phases %standard-phases
5374 (add-after 'unpack 'remove-git-ls-files
5375 (lambda* (#:key outputs #:allow-other-keys)
5376 (substitute* "guard.gemspec"
5377 (("git ls-files -z") "find . -type f -print0"))
5378 #t))
5379 (replace 'build
5380 (lambda _
5381 (invoke "gem" "build" "guard.gemspec"))))))
5382 (propagated-inputs
5383 `(("ruby-formatador" ,ruby-formatador)
5384 ("ruby-listen" ,ruby-listen)
5385 ("ruby-lumberjack" ,ruby-lumberjack)
5386 ("ruby-nenv" ,ruby-nenv)
5387 ("ruby-notiffany" ,ruby-notiffany)
5388 ("ruby-pry" ,ruby-pry)
5389 ("ruby-shellany" ,ruby-shellany)
5390 ("ruby-thor" ,ruby-thor)))
5391 (native-inputs
5392 `(("bundler" ,bundler)
5393 ("ruby-rspec" ,ruby-rspec)))
5394 (synopsis "Tool to handle events on file system modifications")
5395 (description
5396 "Guard is a command line tool to easily handle events on file system
5397 modifications. Guard automates various tasks by running custom rules whenever
5398 file or directories are modified.")
5399 (home-page "https://guardgem.org/")
5400 (license license:expat)))
5401
5402 (define-public ruby-spinach
5403 (package
5404 (name "ruby-spinach")
5405 (version "0.11.0")
5406 (home-page "https://github.com/codegram/spinach")
5407 (source (origin
5408 (method url-fetch)
5409 (uri (rubygems-uri "spinach" version))
5410 (sha256
5411 (base32
5412 "1mv053mqz9c8ngqa6wp1ymk2fax6j0yqzax6918akrdr7c3fx3c6"))))
5413 (build-system ruby-build-system)
5414 (arguments
5415 ;; FIXME: Disable tests altogether because they depend on 'capybara'
5416 ;; which in turn depends on many other unpackaged gems. Enable once
5417 ;; capybara is available.
5418 '(#:tests? #f))
5419 (propagated-inputs
5420 `(("ruby-colorize" ,ruby-colorize)
5421 ("ruby-gherkin-ruby" ,ruby-gherkin-ruby)
5422 ("ruby-json" ,ruby-json)))
5423 (synopsis "Gherkin-based BDD framework")
5424 (description
5425 "Spinach is a high-level @acronym{BDD, Behavior-driven development}
5426 framework that leverages the expressive @code{Gherkin} language to help you
5427 define executable specifications of your code.")
5428 (license license:expat)))
5429
5430 (define-public ruby-tilt
5431 (package
5432 (name "ruby-tilt")
5433 (version "2.0.10")
5434 (source
5435 (origin
5436 (method git-fetch) ;the distributed gem lacks tests
5437 (uri (git-reference
5438 (url "https://github.com/rtomayko/tilt")
5439 (commit (string-append "v" version))))
5440 (file-name (git-file-name name version))
5441 (sha256
5442 (base32
5443 "0adb7fg7925n2rd9a8kkqz3mgylw2skp9hkh9qc1rnph72mqsm6r"))))
5444 (build-system ruby-build-system)
5445 (arguments
5446 '(#:phases
5447 (modify-phases %standard-phases
5448 (add-after 'unpack 'remove-some-dependencies
5449 (lambda _
5450 (substitute* "Gemfile"
5451 ;; TODO ronn is used for generating the manual
5452 (("gem 'ronn'.*") "\n")
5453 ;; ruby-haml has a runtime dependency on ruby-tilt, so don't
5454 ;; pass it in as a native-input
5455 (("gem 'haml'.*") "\n")
5456 ;; TODO Not all of these gems are packaged for Guix yet:
5457 ;; less, coffee-script, livescript, babel-transpiler,
5458 ;; typescript-node
5459 (("if can_execjs") "if false")
5460 ;; Disable the secondary group to reduce the number of
5461 ;; dependencies. None of the normal approaches work, so patch
5462 ;; the Gemfile instead.
5463 (("group :secondary") "[].each"))
5464 #t)))))
5465 (propagated-inputs
5466 `(("ruby-pandoc-ruby" ,ruby-pandoc-ruby)
5467 ("ruby-sassc" ,ruby-sassc)))
5468 (native-inputs
5469 `(("bundler" ,bundler)
5470 ("ruby-yard" ,ruby-yard)
5471 ("ruby-builder" ,ruby-builder)
5472 ("ruby-erubis" ,ruby-erubis)
5473 ("ruby-markaby" ,ruby-markaby)))
5474 (synopsis "Generic interface to multiple Ruby template engines")
5475 (description
5476 "Tilt is a thin interface over a number of different Ruby template
5477 engines in an attempt to make their usage as generic as possible.")
5478 (home-page "https://github.com/rtomayko/tilt/")
5479 (license license:expat)))
5480
5481 (define-public ruby-thread-safe
5482 (package
5483 (name "ruby-thread-safe")
5484 (version "0.3.6")
5485 (source
5486 (origin
5487 (method url-fetch)
5488 (uri (rubygems-uri "thread_safe" version))
5489 (sha256
5490 (base32
5491 "0nmhcgq6cgz44srylra07bmaw99f5271l0dpsvl5f75m44l0gmwy"))))
5492 (build-system ruby-build-system)
5493 (arguments
5494 '(#:tests? #f)) ; needs simplecov, among others
5495 (synopsis "Thread-safe utilities for Ruby")
5496 (description "The thread_safe library provides thread-safe collections and
5497 utilities for Ruby.")
5498 (home-page "https://github.com/ruby-concurrency/thread_safe")
5499 (license license:asl2.0)))
5500
5501 (define-public ruby-tzinfo
5502 (package
5503 (name "ruby-tzinfo")
5504 (version "1.2.4")
5505 (source
5506 (origin
5507 (method url-fetch)
5508 (uri (rubygems-uri "tzinfo" version))
5509 (sha256
5510 (base32
5511 "09dpbrih054mn42flbbcdpzk2727mzfvjrgqb12zdafhx7p9rrzp"))))
5512 (build-system ruby-build-system)
5513 (arguments
5514 '(#:phases
5515 (modify-phases %standard-phases
5516 (add-after 'unpack 'skip-safe-tests
5517 (lambda _
5518 (substitute* "test/test_utils.rb"
5519 (("def safe_test\\(options = \\{\\}\\)")
5520 "def safe_test(options = {})
5521 skip('The Guix build environment has an unsafe load path')"))
5522 #t)))))
5523 (propagated-inputs
5524 `(("ruby-thread-safe" ,ruby-thread-safe)))
5525 (synopsis "Time zone library for Ruby")
5526 (description "TZInfo is a Ruby library that provides daylight savings
5527 aware transformations between times in different time zones.")
5528 (home-page "https://tzinfo.github.io")
5529 (license license:expat)))
5530
5531 (define-public ruby-tzinfo-data
5532 (package
5533 (name "ruby-tzinfo-data")
5534 (version "1.2017.3")
5535 (source
5536 (origin
5537 (method git-fetch)
5538 ;; Download from GitHub because the rubygems version does not contain
5539 ;; Rakefile or tests.
5540 (uri (git-reference
5541 (url "https://github.com/tzinfo/tzinfo-data")
5542 (commit (string-append "v" version))))
5543 (file-name (git-file-name name version))
5544 (sha256
5545 (base32
5546 "0v3phl5l3jrm6waxcszqmj2dkjhqawxfsxb6mss7vkp1hlckqcdp"))
5547 ;; Remove the known test failure.
5548 ;; https://github.com/tzinfo/tzinfo-data/issues/10
5549 ;; https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1587128
5550 (patches (search-patches
5551 "ruby-tzinfo-data-ignore-broken-test.patch"))))
5552 (build-system ruby-build-system)
5553 (propagated-inputs
5554 `(("ruby-tzinfo" ,ruby-tzinfo)))
5555 (synopsis "Data from the IANA Time Zone database")
5556 (description
5557 "This library provides @code{TZInfo::Data}, which contains data from the
5558 IANA Time Zone database packaged as Ruby modules for use with @code{TZInfo}.")
5559 (home-page "https://tzinfo.github.io")
5560 (license license:expat)))
5561
5562 (define-public ruby-rb-inotify
5563 (package
5564 (name "ruby-rb-inotify")
5565 (version "0.9.10")
5566 (source
5567 (origin
5568 (method url-fetch)
5569 (uri (rubygems-uri "rb-inotify" version))
5570 (sha256
5571 (base32
5572 "0yfsgw5n7pkpyky6a9wkf1g9jafxb0ja7gz0qw0y14fd2jnzfh71"))))
5573 (build-system ruby-build-system)
5574 (arguments
5575 '(#:tests? #f ; there are no tests
5576 #:phases
5577 (modify-phases %standard-phases
5578 ;; Building the gemspec with rake is not working here since it is
5579 ;; generated with Jeweler. It is also unnecessary because the
5580 ;; existing gemspec does not use any development tools to generate a
5581 ;; list of files.
5582 (replace 'build
5583 (lambda _
5584 (invoke "gem" "build" "rb-inotify.gemspec"))))))
5585 (propagated-inputs
5586 `(("ruby-ffi" ,ruby-ffi)))
5587 (native-inputs
5588 `(("ruby-yard" ,ruby-yard)))
5589 (synopsis "Ruby wrapper for Linux's inotify")
5590 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
5591 kernel subsystem for monitoring changes to files and directories.")
5592 (home-page "https://github.com/nex3/rb-inotify")
5593 (license license:expat)))
5594
5595 (define-public ruby-pry-editline
5596 (package
5597 (name "ruby-pry-editline")
5598 (version "1.1.2")
5599 (source (origin
5600 (method url-fetch)
5601 (uri (rubygems-uri "pry-editline" version))
5602 (sha256
5603 (base32
5604 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
5605 (build-system ruby-build-system)
5606 (arguments `(#:tests? #f)) ; no tests included
5607 (native-inputs
5608 `(("bundler" ,bundler)))
5609 (synopsis "Open the current REPL line in an editor")
5610 (description
5611 "This gem provides a plugin for the Ruby REPL to enable opening the
5612 current line in an external editor.")
5613 (home-page "https://github.com/tpope/pry-editline")
5614 (license license:expat)))
5615
5616 (define-public ruby-sdoc
5617 (package
5618 (name "ruby-sdoc")
5619 (version "1.1.0")
5620 (source (origin
5621 (method url-fetch)
5622 (uri (rubygems-uri "sdoc" version))
5623 (sha256
5624 (base32
5625 "1am73dldx1fqlw2xny5vyk00pgkisg6bvs0pa8jjd7c19drjczrd"))))
5626 (build-system ruby-build-system)
5627 (arguments
5628 `(#:phases
5629 (modify-phases %standard-phases
5630 (add-before 'check 'set-rubylib-and-patch-gemfile
5631 (lambda _
5632 (setenv "RUBYLIB" "lib")
5633 (substitute* "sdoc.gemspec"
5634 (("s.add_runtime_dependency.*") "\n")
5635 (("s.add_dependency.*") "\n"))
5636 (substitute* "Gemfile"
5637 (("gem \"rake\".*")
5638 "gem 'rake'\ngem 'rdoc'\ngem 'json'\n"))
5639 #t)))))
5640 (propagated-inputs
5641 `(("ruby-json" ,ruby-json)))
5642 (native-inputs
5643 `(("bundler" ,bundler)
5644 ("ruby-minitest" ,ruby-minitest)
5645 ("ruby-hoe" ,ruby-hoe)))
5646 (synopsis "Generate searchable RDoc documentation")
5647 (description
5648 "SDoc is an RDoc documentation generator to build searchable HTML
5649 documentation for Ruby code.")
5650 (home-page "https://github.com/voloko/sdoc")
5651 (license license:expat)))
5652
5653 (define-public ruby-tins
5654 (package
5655 (name "ruby-tins")
5656 (version "1.15.0")
5657 (source (origin
5658 (method url-fetch)
5659 (uri (rubygems-uri "tins" version))
5660 (sha256
5661 (base32
5662 "09whix5a7ics6787zrkwjmp16kqyh6560p9f317syks785805f7s"))))
5663 (build-system ruby-build-system)
5664 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
5665 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
5666 ;; the gemspec.
5667 (arguments
5668 `(#:tests? #f ; there are no tests
5669 #:phases
5670 (modify-phases %standard-phases
5671 (replace 'build
5672 (lambda _
5673 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
5674 ;; causes an error.
5675 (substitute* "tins.gemspec"
5676 (("\"lib/spruz\", ") ""))
5677 (invoke "gem" "build" "tins.gemspec"))))))
5678 (synopsis "Assorted tools for Ruby")
5679 (description "Tins is a Ruby library providing assorted tools.")
5680 (home-page "https://github.com/flori/tins")
5681 (license license:expat)))
5682
5683 (define-public ruby-gem-hadar
5684 (package
5685 (name "ruby-gem-hadar")
5686 (version "1.9.1")
5687 (source (origin
5688 (method url-fetch)
5689 (uri (rubygems-uri "gem_hadar" version))
5690 (sha256
5691 (base32
5692 "1zxvd9l95rbks7x3cxn396w0sn7nha5542bf97v8akkn4vm7nby9"))))
5693 (build-system ruby-build-system)
5694 ;; This gem needs itself at development time. We disable rebuilding of the
5695 ;; gemspec to avoid this loop.
5696 (arguments
5697 `(#:tests? #f ; there are no tests
5698 #:phases
5699 (modify-phases %standard-phases
5700 (replace 'build
5701 (lambda _
5702 (invoke "gem" "build" "gem_hadar.gemspec"))))))
5703 (propagated-inputs
5704 `(("git" ,git)
5705 ("ruby-tins" ,ruby-tins)
5706 ("ruby-yard" ,ruby-yard)))
5707 (synopsis "Library for the development of Ruby gems")
5708 (description
5709 "This library contains some useful functionality to support the
5710 development of Ruby gems.")
5711 (home-page "https://github.com/flori/gem_hadar")
5712 (license license:expat)))
5713
5714 (define-public ruby-minitest-tu-shim
5715 (package
5716 (name "ruby-minitest-tu-shim")
5717 (version "1.3.3")
5718 (source (origin
5719 (method url-fetch)
5720 (uri (rubygems-uri "minitest_tu_shim" version))
5721 (sha256
5722 (base32
5723 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
5724 (build-system ruby-build-system)
5725 (arguments
5726 `(#:phases
5727 (modify-phases %standard-phases
5728 (add-after 'unpack 'fix-test-include-path
5729 (lambda* (#:key inputs #:allow-other-keys)
5730 (let* ((minitest (assoc-ref inputs "ruby-minitest-4")))
5731 (substitute* "Rakefile"
5732 (("Hoe\\.add_include_dirs .*")
5733 (string-append "Hoe.add_include_dirs \""
5734 minitest "/lib/ruby/vendor_ruby"
5735 "/gems/minitest-"
5736 ,(package-version ruby-minitest-4)
5737 "/lib" "\""))))
5738 #t))
5739 (add-before 'check 'fix-test-assumptions
5740 (lambda _
5741 ;; The test output includes the file name, so a couple of tests
5742 ;; fail. Changing the regular expressions slightly fixes this
5743 ;; problem.
5744 (substitute* "test/test_mini_test.rb"
5745 (("output.sub!\\(.*, 'FILE:LINE'\\)")
5746 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
5747 (("gsub\\(/.*, 'FILE:LINE'\\)")
5748 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
5749 #t)))))
5750 (propagated-inputs
5751 `(("ruby-minitest-4" ,ruby-minitest-4)))
5752 (native-inputs
5753 `(("ruby-hoe" ,ruby-hoe)))
5754 (synopsis "Adapter library between minitest and test/unit")
5755 (description
5756 "This library bridges the gap between the small and fast minitest and
5757 Ruby's large and slower test/unit.")
5758 (home-page "https://rubygems.org/gems/minitest_tu_shim")
5759 (license license:expat)))
5760
5761 (define-public ruby-term-ansicolor
5762 (package
5763 (name "ruby-term-ansicolor")
5764 (version "1.6.0")
5765 (source (origin
5766 (method url-fetch)
5767 (uri (rubygems-uri "term-ansicolor" version))
5768 (sha256
5769 (base32
5770 "1b1wq9ljh7v3qyxkk8vik2fqx2qzwh5lval5f92llmldkw7r7k7b"))))
5771 (build-system ruby-build-system)
5772 ;; Rebuilding the gemspec seems to require git, even though this is not a
5773 ;; git repository, so we just build the gem from the existing gemspec.
5774 (arguments
5775 `(#:phases
5776 (modify-phases %standard-phases
5777 (add-after 'unpack 'fix-test
5778 (lambda -
5779 (substitute* "tests/hsl_triple_test.rb"
5780 (("0\\\\\\.0%")
5781 "0\\.?0?%"))))
5782 (replace 'build
5783 (lambda _
5784 (invoke "gem" "build" "term-ansicolor.gemspec"))))))
5785 (propagated-inputs
5786 `(("ruby-tins" ,ruby-tins)))
5787 (native-inputs
5788 `(("ruby-gem-hadar" ,ruby-gem-hadar)
5789 ("ruby-minitest-tu-shim" ,ruby-minitest-tu-shim)))
5790 (synopsis "Ruby library to control the attributes of terminal output")
5791 (description
5792 "This Ruby library uses ANSI escape sequences to control the attributes
5793 of terminal output.")
5794 (home-page "https://flori.github.io/term-ansicolor/")
5795 ;; There is no mention of the "or later" clause.
5796 (license license:gpl2)))
5797
5798 (define-public ruby-terraform
5799 (package
5800 (name "ruby-terraform")
5801 (version "0.22.0")
5802 (source
5803 (origin
5804 (method url-fetch)
5805 (uri (rubygems-uri "ruby-terraform" version))
5806 (sha256
5807 (base32
5808 "13zjkp71cd19j2ds2h9rqwcfr1zdg5nsh63p89l6qcsc9z39z324"))))
5809 (build-system ruby-build-system)
5810 (arguments
5811 '(#:tests? #f)) ; No included tests
5812 (propagated-inputs
5813 `(("ruby-lino" ,ruby-lino)))
5814 (synopsis "Ruby wrapper around the Terraform command line interface")
5815 (description
5816 "This package provides a Ruby wrapper around the Terraform command line
5817 interface so that Terraform can be more easily invoked from Ruby code.")
5818 (home-page "https://github.com/infrablocks/ruby_terraform")
5819 (license license:expat)))
5820
5821 (define-public ruby-pstree
5822 (package
5823 (name "ruby-pstree")
5824 (version "0.1.0")
5825 (source (origin
5826 (method url-fetch)
5827 (uri (rubygems-uri "pstree" version))
5828 (sha256
5829 (base32
5830 "1mig1sv5qx1cdyhjaipy8jlh9j8pnja04vprrzihyfr54x0215p1"))))
5831 (build-system ruby-build-system)
5832 (native-inputs
5833 `(("ruby-gem-hadar" ,ruby-gem-hadar)
5834 ("bundler" ,bundler)))
5835 (synopsis "Create a process tree data structure")
5836 (description
5837 "This library uses the output of the @code{ps} command to create a
5838 process tree data structure for the current host.")
5839 (home-page "https://github.com/flori/pstree")
5840 ;; There is no mention of the "or later" clause.
5841 (license license:gpl2)))
5842
5843 (define-public ruby-utils
5844 (package
5845 (name "ruby-utils")
5846 (version "0.9.0")
5847 (source (origin
5848 (method url-fetch)
5849 (uri (rubygems-uri "utils" version))
5850 (sha256
5851 (base32
5852 "196zhgcygrnx09bb9mh22qas03rl9avzx8qs0wnxznpin4pffwcl"))))
5853 (build-system ruby-build-system)
5854 (propagated-inputs
5855 `(("ruby-tins" ,ruby-tins)
5856 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
5857 ("ruby-pstree" ,ruby-pstree)
5858 ("ruby-pry-editline" ,ruby-pry-editline)))
5859 (native-inputs
5860 `(("ruby-gem-hadar" ,ruby-gem-hadar)
5861 ("bundler" ,bundler)))
5862 (synopsis "Command line tools for working with Ruby")
5863 (description
5864 "This package provides assorted command line tools that may be useful
5865 when working with Ruby code.")
5866 (home-page "https://github.com/flori/utils")
5867 ;; There is no mention of the "or later" clause.
5868 (license license:gpl2)))
5869
5870 (define-public ruby-jaro-winkler
5871 (package
5872 (name "ruby-jaro-winkler")
5873 (version "1.5.4")
5874 (source
5875 (origin
5876 (method url-fetch)
5877 (uri (rubygems-uri "jaro_winkler" version))
5878 (sha256
5879 (base32 "1y8l6k34svmdyqxya3iahpwbpvmn3fswhwsvrz0nk1wyb8yfihsh"))))
5880 (build-system ruby-build-system)
5881 (arguments
5882 '(#:tests? #f)) ; no included tests
5883 (synopsis "Ruby implementation of Jaro-Winkler distance algorithm")
5884 (description
5885 "@code{jaro_winkler} is an implementation of Jaro-Winkler distance
5886 algorithm. It is written as a C extension and will fallback to a pure Ruby
5887 implementation on platforms where this is unsupported.")
5888 (home-page "https://github.com/tonytonyjan/jaro_winkler")
5889 (license license:expat)))
5890
5891 (define-public ruby-json
5892 (package
5893 (name "ruby-json")
5894 (version "2.1.0")
5895 (source
5896 (origin
5897 (method url-fetch)
5898 (uri (rubygems-uri "json" version))
5899 (sha256
5900 (base32
5901 "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp"))))
5902 (build-system ruby-build-system)
5903 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
5904 (synopsis "JSON library for Ruby")
5905 (description "This Ruby library provides a JSON implementation written as
5906 a native C extension.")
5907 (home-page "http://json-jruby.rubyforge.org/")
5908 (license (list license:ruby license:gpl2)))) ; GPL2 only
5909
5910 (define-public ruby-json-pure
5911 (package
5912 (name "ruby-json-pure")
5913 (version "2.2.0")
5914 (source (origin
5915 (method url-fetch)
5916 (uri (rubygems-uri "json_pure" version))
5917 (sha256
5918 (base32
5919 "0m0j1mfwv0mvw72kzqisb26xjl236ivqypw1741dkis7s63b8439"))))
5920 (build-system ruby-build-system)
5921 (arguments
5922 `(#:phases
5923 (modify-phases %standard-phases
5924 (add-after 'unpack 'fix-rakefile
5925 (lambda _
5926 (substitute* "Rakefile"
5927 ;; Since this is not a git repository, do not call 'git'.
5928 (("`git ls-files`") "`find . -type f |sort`")
5929 ;; Loosen dependency constraint.
5930 (("'test-unit', '~> 2.0'") "'test-unit', '>= 2.0'"))
5931 #t))
5932 (add-after 'replace-git-ls-files 'regenerate-gemspec
5933 (lambda _
5934 ;; Regenerate gemspec so loosened dependency constraints are
5935 ;; propagated.
5936 (invoke "rake" "gemspec")))
5937 (add-after 'regenerate-gemspec 'fix-json-java.gemspec
5938 (lambda _
5939 ;; This gemspec doesn't look to be generated by the above
5940 ;; command, so patch it separately.
5941 (substitute* "json-java.gemspec"
5942 (("%q<test-unit>\\.freeze, \\[\"~> 2\\.0\"\\]")
5943 "%q<test-unit>.freeze, [\">= 2.0\"]"))
5944 #t)))))
5945 (native-inputs
5946 `(("bundler" ,bundler)
5947 ("ragel" ,ragel)
5948 ("ruby-simplecov" ,ruby-simplecov)
5949 ("ruby-test-unit" ,ruby-test-unit)))
5950 (synopsis "JSON implementation in pure Ruby")
5951 (description
5952 "This package provides a JSON implementation written in pure Ruby.")
5953 (home-page "https://flori.github.com/json/")
5954 (license license:ruby)))
5955
5956 (define-public ruby-jwt
5957 (package
5958 (name "ruby-jwt")
5959 (version "2.1.0")
5960 (source
5961 (origin
5962 (method url-fetch)
5963 (uri (rubygems-uri "jwt" version))
5964 (sha256
5965 (base32
5966 "1w0kaqrbl71cq9sbnixc20x5lqah3hs2i93xmhlfdg2y3by7yzky"))))
5967 (build-system ruby-build-system)
5968 (arguments
5969 '(#:test-target "test"
5970 #:phases
5971 (modify-phases %standard-phases
5972 (add-after 'unpack 'remove-unnecessary-dependencies
5973 (lambda _
5974 (substitute* "spec/spec_helper.rb"
5975 (("require 'simplecov.*") "\n")
5976 ;; Use [].each to disable running the SimpleCov configuration
5977 ;; block
5978 (("SimpleCov\\.configure") "[].each")
5979 (("require 'codeclimate-test-reporter'") "")
5980 (("require 'codacy-coverage'") "")
5981 (("Codacy::Reporter\\.start") ""))
5982 #t)))))
5983 (native-inputs
5984 `(("bundler" ,bundler)
5985 ("ruby-rspec" ,ruby-rspec)
5986 ("ruby-rbnacl" ,ruby-rbnacl)))
5987 (synopsis "Ruby implementation of the JSON Web Token standard")
5988 (description
5989 "This package provides a pure Ruby implementation of the RFC 7519 OAuth
5990 @acronym{JWT, JSON Web Token} standard.")
5991 (home-page "https://github.com/jwt/ruby-jwt")
5992 (license license:expat)))
5993
5994 ;; Even though this package only provides bindings for a Mac OSX API it is
5995 ;; required by "ruby-listen" at runtime.
5996 (define-public ruby-rb-fsevent
5997 (package
5998 (name "ruby-rb-fsevent")
5999 (version "0.10.3")
6000 (source (origin
6001 (method url-fetch)
6002 (uri (rubygems-uri "rb-fsevent" version))
6003 (sha256
6004 (base32
6005 "1lm1k7wpz69jx7jrc92w3ggczkjyjbfziq5mg62vjnxmzs383xx8"))))
6006 (build-system ruby-build-system)
6007 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
6008 ;; "listen", which needs "rb-fsevent" at runtime.
6009 (arguments `(#:tests? #f))
6010 (synopsis "FSEvents API with signals catching")
6011 (description
6012 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
6013 (home-page "https://rubygems.org/gems/rb-fsevent")
6014 (license license:expat)))
6015
6016 (define-public ruby-listen
6017 (package
6018 (name "ruby-listen")
6019 (version "3.2.0")
6020 (source
6021 (origin
6022 ;; The gem does not include a Rakefile, so fetch from the Git
6023 ;; repository.
6024 (method git-fetch)
6025 (uri (git-reference
6026 (url "https://github.com/guard/listen")
6027 (commit (string-append "v" version))))
6028 (file-name (git-file-name name version))
6029 (sha256
6030 (base32
6031 "1hkp1g6hk5clsmbd001gkc12ma6s459x820piajyasv61m87if24"))))
6032 (build-system ruby-build-system)
6033 (arguments
6034 `(#:test-target "spec"
6035 #:phases
6036 (modify-phases %standard-phases
6037 (add-after 'unpack 'fix-files-in-gemspec
6038 (lambda _
6039 (substitute* "listen.gemspec"
6040 (("`git ls-files -z`") "`find . -type f -printf '%P\\\\0' |sort -z`"))
6041 #t))
6042 (add-before 'check 'remove-unnecessary-dependencies'
6043 (lambda _
6044 (substitute* "Rakefile"
6045 ;; Rubocop is for code linting, and is unnecessary for running
6046 ;; the tests.
6047 ((".*rubocop.*") ""))
6048 #t)))))
6049 (native-inputs
6050 `(("bundler" ,bundler)
6051 ("ruby-rspec" ,ruby-rspec)))
6052 (inputs
6053 `(;; ruby-thor is used for the command line interface, and is referenced
6054 ;; in the wrapper, and therefore just needs to be an input.
6055 ("ruby-thor" ,ruby-thor)))
6056 (propagated-inputs
6057 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
6058 ("ruby-rb-inotify" ,ruby-rb-inotify)
6059 ("ruby-dep" ,ruby-dep)))
6060 (synopsis "Listen to file modifications")
6061 (description "The Listen gem listens to file modifications and notifies
6062 you about the changes.")
6063 (home-page "https://github.com/guard/listen")
6064 (license license:expat)))
6065
6066 (define-public ruby-loofah
6067 (package
6068 (name "ruby-loofah")
6069 (version "2.2.3")
6070 (source
6071 (origin
6072 (method url-fetch)
6073 (uri (rubygems-uri "loofah" version))
6074 (sha256
6075 (base32
6076 "1ccsid33xjajd0im2xv941aywi58z7ihwkvaf1w2bv89vn5bhsjg"))))
6077 (build-system ruby-build-system)
6078 (arguments
6079 '(#:phases
6080 (modify-phases %standard-phases
6081 (add-after 'unpack 'remove-unnecessary-dependencies
6082 (lambda _
6083 ;; concourse is a development tool which is unused, so remove it
6084 ;; so it's not required.
6085 (substitute* "Gemfile"
6086 ((".*\"concourse\".*") "\n"))
6087 (substitute* "Rakefile"
6088 (("require 'concourse'") "")
6089 (("Concourse\\.new.*") "\n"))
6090 #t)))))
6091 (native-inputs
6092 `(("ruby-hoe" ,ruby-hoe)
6093 ("ruby-rr" ,ruby-rr)))
6094 (propagated-inputs
6095 `(("ruby-nokogiri" ,ruby-nokogiri)
6096 ("ruby-crass" ,ruby-crass)))
6097 (synopsis "Ruby library for manipulating and transforming HTML/XML")
6098 (description
6099 "Loofah is a general library for manipulating and transforming HTML/XML
6100 documents and fragments. It's built on top of Nokogiri and libxml2.")
6101 (home-page "https://github.com/flavorjones/loofah")
6102 (license license:expat)))
6103
6104 (define-public ruby-activesupport
6105 (package
6106 (name "ruby-activesupport")
6107 (version "5.2.2.1")
6108 (source
6109 (origin
6110 (method url-fetch)
6111 (uri (rubygems-uri "activesupport" version))
6112 (sha256
6113 (base32
6114 "161bp4p01v1a1lvszrhd1a02zf9x1p1l1yhw79a3rix1kvzkkdqb"))))
6115 (build-system ruby-build-system)
6116 (arguments
6117 `(#:phases
6118 (modify-phases %standard-phases
6119 (replace 'check
6120 (lambda _
6121 ;; There are no tests, instead attempt to load the library.
6122 (invoke "ruby" "-Ilib" "-r" "active_support"))))))
6123 (propagated-inputs
6124 `(("ruby-concurrent" ,ruby-concurrent)
6125 ("ruby-i18n" ,ruby-i18n)
6126 ("ruby-minitest" ,ruby-minitest)
6127 ("ruby-tzinfo" ,ruby-tzinfo)
6128 ("ruby-tzinfo-data" ,ruby-tzinfo-data)))
6129 (synopsis "Ruby on Rails utility library")
6130 (description "ActiveSupport is a toolkit of support libraries and Ruby
6131 core extensions extracted from the Rails framework. It includes support for
6132 multibyte strings, internationalization, time zones, and testing.")
6133 (home-page "http://www.rubyonrails.org")
6134 (license license:expat)))
6135
6136 (define-public ruby-crass
6137 (package
6138 (name "ruby-crass")
6139 (version "1.0.6")
6140 (home-page "https://github.com/rgrove/crass")
6141 (source (origin
6142 ;; The gem does not contain tests, so pull from git.
6143 (method git-fetch)
6144 (uri (git-reference
6145 (url home-page)
6146 (commit (string-append "v" version))))
6147 (file-name (git-file-name name version))
6148 (sha256
6149 (base32
6150 "1gbsb81psgb6xhnwpx4s409jc0mk0gijh039sy5xyi8jpaaadp40"))))
6151 (build-system ruby-build-system)
6152 (synopsis "Pure Ruby CSS parser")
6153 (description
6154 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
6155 (license license:expat)))
6156
6157 (define-public ruby-nokogumbo
6158 (package
6159 (name "ruby-nokogumbo")
6160 (version "2.0.2")
6161 (source (origin
6162 ;; We use the git reference, because there's no Rakefile in the
6163 ;; published gem and the tarball on Github is outdated.
6164 (method git-fetch)
6165 (uri (git-reference
6166 (url "https://github.com/rubys/nokogumbo")
6167 (commit (string-append "v" version))))
6168 (file-name (string-append name "-" version "-checkout"))
6169 (sha256
6170 (base32
6171 "1qg0iyw450lw6d0j1ghzg79a6l60nm1m4qmrzwzybi585861jxcx"))))
6172 (build-system ruby-build-system)
6173 (native-inputs
6174 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
6175 (inputs
6176 `(("gumbo-parser" ,gumbo-parser)))
6177 (propagated-inputs
6178 `(("ruby-nokogiri" ,ruby-nokogiri)))
6179 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
6180 (description
6181 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
6182 access the result as a Nokogiri parsed document.")
6183 (home-page "https://github.com/rubys/nokogumbo/")
6184 (license license:asl2.0)))
6185
6186 (define-public ruby-sanitize
6187 (package
6188 (name "ruby-sanitize")
6189 (version "5.1.0")
6190 (home-page "https://github.com/rgrove/sanitize")
6191 (source (origin
6192 (method git-fetch)
6193 ;; The gem does not include the Rakefile, so we download the
6194 ;; source from Github.
6195 (uri (git-reference
6196 (url home-page)
6197 (commit (string-append "v" version))))
6198 (file-name (git-file-name name version))
6199 (patches (search-patches "ruby-sanitize-system-libxml.patch"))
6200 (sha256
6201 (base32
6202 "0lj0q9yhjp0q0in5majkshnki07mw8m2vxgndx4m5na6232aszl0"))))
6203 (build-system ruby-build-system)
6204 (propagated-inputs
6205 `(("ruby-crass" ,ruby-crass)
6206 ("ruby-nokogiri" ,ruby-nokogiri)
6207 ("ruby-nokogumbo" ,ruby-nokogumbo)))
6208 (native-inputs
6209 `(("ruby-minitest" ,ruby-minitest)))
6210 (synopsis "Whitelist-based HTML and CSS sanitizer")
6211 (description
6212 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
6213 acceptable elements, attributes, and CSS properties, Sanitize will remove all
6214 unacceptable HTML and/or CSS from a string.")
6215 (license license:expat)))
6216
6217 (define-public ruby-oj
6218 (package
6219 (name "ruby-oj")
6220 (version "3.10.1")
6221 (source
6222 (origin
6223 (method git-fetch)
6224 ;; Version on rubygems.org does not contain Rakefile, so download from
6225 ;; GitHub instead.
6226 (uri (git-reference
6227 (url "https://github.com/ohler55/oj")
6228 (commit (string-append "v" version))))
6229 (file-name (git-file-name name version))
6230 (sha256
6231 (base32
6232 "0i5xjx4sh816zx2c1a4d1q67k7vllg5jnnc4jy6zhbmwi1dvp5vw"))))
6233 (build-system ruby-build-system)
6234 (arguments
6235 '(#:test-target "test_all"
6236 #:phases
6237 (modify-phases %standard-phases
6238 (add-before 'check 'disable-bundler
6239 (lambda _
6240 (substitute* "Rakefile"
6241 (("Bundler\\.with_clean_env") "1.times")
6242 (("bundle exec ") "")))))))
6243 (native-inputs
6244 `(("bundler" ,bundler)
6245 ("ruby-rspec" ,ruby-rspec)
6246 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6247 (synopsis "JSON parser for Ruby optimized for speed")
6248 (description
6249 "Oj is a JSON parser and generator for Ruby, where the encoding and
6250 decoding of JSON is implemented as a C extension to Ruby.")
6251 (home-page "http://www.ohler.com/oj/")
6252 (license (list license:expat ; Ruby code
6253 license:bsd-3)))) ; extension code
6254
6255 (define-public ruby-ox
6256 (package
6257 (name "ruby-ox")
6258 (version "2.6.0")
6259 (source
6260 (origin
6261 (method url-fetch)
6262 (uri (rubygems-uri "ox" version))
6263 (sha256
6264 (base32
6265 "0fmk62b1h2i79dfzjj8wmf8qid1rv5nhwfc17l489ywnga91xl83"))))
6266 (build-system ruby-build-system)
6267 (arguments
6268 '(#:tests? #f)) ; no tests
6269 (synopsis "Optimized XML library for Ruby")
6270 (description
6271 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
6272 written as a native C extension. It was designed to be an alternative to
6273 Nokogiri and other Ruby XML parsers for generic XML parsing and as an
6274 alternative to Marshal for Object serialization. ")
6275 (home-page "http://www.ohler.com/ox")
6276 (license license:expat)))
6277
6278 (define-public ruby-redcloth
6279 (package
6280 (name "ruby-redcloth")
6281 (version "4.3.2")
6282 (source (origin
6283 (method url-fetch)
6284 (uri (rubygems-uri "RedCloth" version))
6285 (sha256
6286 (base32
6287 "0m9dv7ya9q93r8x1pg2gi15rxlbck8m178j1fz7r5v6wr1avrrqy"))))
6288 (build-system ruby-build-system)
6289 (arguments
6290 `(#:tests? #f ; no tests
6291 #:phases
6292 (modify-phases %standard-phases
6293 ;; Redcloth has complicated rake tasks to build various versions for
6294 ;; multiple targets using RVM. We don't want this so we just use the
6295 ;; existing gemspec.
6296 (replace 'build
6297 (lambda _
6298 (invoke "gem" "build" "redcloth.gemspec"))))))
6299 (native-inputs
6300 `(("bundler" ,bundler)
6301 ("ruby-diff-lcs" ,ruby-diff-lcs)
6302 ("ruby-rspec-2" ,ruby-rspec-2)))
6303 (synopsis "Textile markup language parser for Ruby")
6304 (description
6305 "RedCloth is a Ruby parser for the Textile markup language.")
6306 (home-page "http://redcloth.org")
6307 (license license:expat)))
6308
6309 (define-public ruby-pg
6310 (package
6311 (name "ruby-pg")
6312 (version "1.1.4")
6313 (source
6314 (origin
6315 (method url-fetch)
6316 (uri (rubygems-uri "pg" version))
6317 (sha256
6318 (base32
6319 "0fmnyxcyrvgdbgq7m09whgn9i8rwfybk0w8aii1nc4g5kqw0k2jy"))))
6320 (build-system ruby-build-system)
6321 (arguments
6322 '(#:test-target "spec"))
6323 (native-inputs
6324 `(("ruby-rake-compiler" ,ruby-rake-compiler)
6325 ("ruby-hoe" ,ruby-hoe)
6326 ("ruby-rspec" ,ruby-rspec)))
6327 (inputs
6328 `(("postgresql" ,postgresql)))
6329 (synopsis "Ruby interface to PostgreSQL")
6330 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
6331 with PostgreSQL 9.0 and later.")
6332 (home-page "https://bitbucket.org/ged/ruby-pg")
6333 (license license:ruby)))
6334
6335 (define-public ruby-byebug
6336 (package
6337 (name "ruby-byebug")
6338 (version "9.0.6")
6339 (source
6340 (origin
6341 (method url-fetch)
6342 (uri (rubygems-uri "byebug" version))
6343 (sha256
6344 (base32
6345 "1kbfcn65rgdhi72n8x9l393b89rvi5z542459k7d1ggchpb0idb0"))))
6346 (build-system ruby-build-system)
6347 (arguments
6348 '(#:tests? #f)) ; no tests
6349 (synopsis "Debugger for Ruby 2")
6350 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
6351 TracePoint C API for execution control and the Debug Inspector C API for call
6352 stack navigation. The core component provides support that front-ends can
6353 build on. It provides breakpoint handling and bindings for stack frames among
6354 other things and it comes with a command line interface.")
6355 (home-page "https://github.com/deivid-rodriguez/byebug")
6356 (license license:bsd-2)))
6357
6358 ;;; TODO: Make it the default byebug in core-updates.
6359 (define-public ruby-byebug-11
6360 (package
6361 (inherit ruby-byebug)
6362 (name "ruby-byebug")
6363 (version "11.1.3")
6364 (source
6365 (origin
6366 (method git-fetch)
6367 (uri (git-reference
6368 (url "https://github.com/deivid-rodriguez/byebug")
6369 (commit (string-append "v" version))))
6370 (file-name (git-file-name name version))
6371 (sha256
6372 (base32
6373 "0vyy3k2s7dcndngj6m8kxhs1vxc2c93dw8b3yyand3srsg9ffpij"))
6374 (modules '((guix build utils)))
6375 (snippet
6376 '(begin
6377 ;; Remove wrappers that try to setup a bundle environment.
6378 (with-directory-excursion "bin"
6379 (for-each delete-file '("bundle" "rake" "rubocop"))
6380 ;; ruby-minitest doesn't come with a launcher, so fix the one
6381 ;; provided.
6382 (substitute* "minitest"
6383 (("load File\\.expand_path\\(\"bundle\".*") "")
6384 (("require \"bundler/setup\".*") "")))
6385 #t))))
6386 (arguments
6387 `(#:tests? #t
6388 #:phases
6389 (modify-phases %standard-phases
6390 (add-after 'unpack 'skip-tmp-path-sensitive-test
6391 (lambda _
6392 (substitute* "test/commands/where_test.rb"
6393 (("unless /cygwin\\|mswin\\|mingw\\|darwin/.*")
6394 "unless true\n"))
6395 #t))
6396 (add-before 'build 'compile
6397 (lambda _
6398 (invoke "rake" "compile")))
6399 (add-before 'check 'set-home
6400 (lambda _
6401 (setenv "HOME" (getcwd))
6402 #t)))))
6403 (native-inputs
6404 `(("bundler" ,bundler)
6405 ("ruby-chandler" ,ruby-chandler)
6406 ("ruby-minitest" ,ruby-minitest)
6407 ("ruby-pry" ,ruby-pry)
6408 ("ruby-rake-compiler" ,ruby-rake-compiler)
6409 ("ruby-rubocop" ,ruby-rubocop)
6410 ("ruby-yard" ,ruby-yard)))))
6411
6412 (define-public ruby-netrc
6413 (package
6414 (name "ruby-netrc")
6415 (version "0.11.0")
6416 (source (origin
6417 (method url-fetch)
6418 (uri (rubygems-uri "netrc" version))
6419 (sha256
6420 (base32
6421 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
6422 (build-system ruby-build-system)
6423 (arguments
6424 `(#:phases
6425 (modify-phases %standard-phases
6426 (replace 'check
6427 ;; There is no Rakefile and minitest can only run one file at once,
6428 ;; so we have to iterate over all test files.
6429 (lambda _
6430 (for-each (lambda (file)
6431 (invoke "ruby" "-Itest" file))
6432 (find-files "./test" "test_.*\\.rb"))
6433 #t)))))
6434 (native-inputs
6435 `(("ruby-minitest" ,ruby-minitest)))
6436 (synopsis "Library to read and update netrc files")
6437 (description
6438 "This library can read and update netrc files, preserving formatting
6439 including comments and whitespace.")
6440 (home-page "https://github.com/geemus/netrc")
6441 (license license:expat)))
6442
6443 (define-public ruby-unf-ext
6444 (package
6445 (name "ruby-unf-ext")
6446 (version "0.0.7.6")
6447 (source (origin
6448 (method url-fetch)
6449 (uri (rubygems-uri "unf_ext" version))
6450 (sha256
6451 (base32
6452 "1ll6w64ibh81qwvjx19h8nj7mngxgffg7aigjx11klvf5k2g4nxf"))))
6453 (build-system ruby-build-system)
6454 (arguments
6455 `(#:phases
6456 (modify-phases %standard-phases
6457 (add-after 'build 'build-ext
6458 (lambda _ (invoke "rake" "compile:unf_ext")))
6459 (add-before 'check 'lose-rake-compiler-dock-dependency
6460 (lambda _
6461 ;; rake-compiler-dock is listed in the gemspec, but only
6462 ;; required when cross-compiling.
6463 (substitute* "unf_ext.gemspec"
6464 ((".*rake-compiler-dock.*") ""))
6465 #t)))))
6466 (native-inputs
6467 `(("bundler" ,bundler)
6468 ("ruby-rake-compiler" ,ruby-rake-compiler)
6469 ("ruby-test-unit" ,ruby-test-unit)))
6470 (synopsis "Unicode normalization form support library")
6471 (description
6472 "This package provides unicode normalization form support for Ruby.")
6473 (home-page "https://github.com/knu/ruby-unf_ext")
6474 (license license:expat)))
6475
6476 (define-public ruby-tdiff
6477 ;; Use a newer than released snapshot so that rspec-2 is not required.
6478 (let ((commit "b662a6048f08abc45c1a834e5f34dd1c662935e2"))
6479 (package
6480 (name "ruby-tdiff")
6481 (version (string-append "0.3.3-1." (string-take commit 8)))
6482 (source (origin
6483 (method git-fetch)
6484 (uri (git-reference
6485 (url "https://github.com/postmodern/tdiff")
6486 (commit commit)))
6487 (file-name (string-append name "-" version "-checkout"))
6488 (sha256
6489 (base32
6490 "0n3gq8rx49f7ln6zqlshqfg2mgqyy30rsdjlnki5mv307ykc7ad4"))))
6491 (build-system ruby-build-system)
6492 (native-inputs
6493 `(("ruby-rspec" ,ruby-rspec)
6494 ("ruby-yard" ,ruby-yard)
6495 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
6496 (synopsis "Calculate the differences between two tree-like structures")
6497 (description
6498 "This library provides functions to calculate the differences between two
6499 tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
6500 (home-page "https://github.com/postmodern/tdiff")
6501 (license license:expat))))
6502
6503 (define-public ruby-nokogiri-diff
6504 ;; Use a newer than released snapshot so that rspec-2 is not required.
6505 (let ((commit "a38491e4d8709b7406f2cae11a50226d927d06f5"))
6506 (package
6507 (name "ruby-nokogiri-diff")
6508 (version (string-append "0.2.0-1." (string-take commit 8)))
6509 (source (origin
6510 (method git-fetch)
6511 (uri (git-reference
6512 (url "https://github.com/postmodern/nokogiri-diff")
6513 (commit commit)))
6514 (file-name (string-append name "-" version "-checkout"))
6515 (sha256
6516 (base32
6517 "1ah2sfjh9n1p0ln2wkqzfl448ml7j4zfy6dhp1qgzq2m41php6rf"))))
6518 (build-system ruby-build-system)
6519 (propagated-inputs
6520 `(("ruby-tdiff" ,ruby-tdiff)
6521 ("ruby-nokogiri" ,ruby-nokogiri)))
6522 (native-inputs
6523 `(("ruby-rspec" ,ruby-rspec)
6524 ("ruby-yard" ,ruby-yard)
6525 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
6526 (synopsis "Calculate the differences between two XML/HTML documents")
6527 (description
6528 "@code{Nokogiri::Diff} adds the ability to calculate the
6529 differences (added or removed nodes) between two XML/HTML documents.")
6530 (home-page "https://github.com/postmodern/nokogiri-diff")
6531 (license license:expat))))
6532
6533 (define-public ruby-racc
6534 (package
6535 (name "ruby-racc")
6536 (version "1.4.14")
6537 (source
6538 (origin
6539 (method url-fetch)
6540 (uri (rubygems-uri "racc" version))
6541 (sha256
6542 (base32
6543 "00yhs2ag7yy5v83mqvkbnhk9bvsh6mx3808k53n61ddzx446v1zl"))))
6544 (build-system ruby-build-system)
6545 (native-inputs
6546 `(("ruby-hoe" ,ruby-hoe)
6547 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6548 (synopsis "LALR(1) parser generator for Ruby")
6549 (description
6550 "Racc is a LALR(1) parser generator. It is written in Ruby itself, and
6551 generates Ruby program.")
6552 (home-page "http://i.loveruby.net/en/projects/racc/")
6553 (license (list
6554 ;; Generally licensed under the LGPL2.1, and some files also
6555 ;; available under the same license as Ruby.
6556 license:lgpl2.1
6557 license:ruby))))
6558
6559 (define-public ruby-rack
6560 (package
6561 (name "ruby-rack")
6562 (version "2.0.6")
6563 (source
6564 (origin
6565 (method git-fetch)
6566 ;; Download from GitHub so that the patch can be applied.
6567 (uri (git-reference
6568 (url "https://github.com/rack/rack")
6569 (commit version)))
6570 (file-name (git-file-name name version))
6571 (sha256
6572 (base32
6573 "1n7z4g1x6yxip096cdc04wq7yk7ywpinq28g2xjb46r4nlv5h0j6"))
6574 ;; Ignore test which fails inside the build environment but works
6575 ;; outside.
6576 (patches (search-patches "ruby-rack-ignore-failing-test.patch"))))
6577 (build-system ruby-build-system)
6578 (arguments
6579 '(#:phases
6580 (modify-phases %standard-phases
6581 (add-before 'check 'fix-tests
6582 (lambda _
6583 ;; A few of the tests use the length of a file on disk for
6584 ;; Content-Length and Content-Range headers. However, this file
6585 ;; has a shebang in it which an earlier phase patches, growing
6586 ;; the file size from 193 to 239 bytes when the store prefix is
6587 ;; "/gnu/store".
6588 (let ((size-diff (- (string-length (which "ruby"))
6589 (string-length "/usr/bin/env ruby"))))
6590 (substitute* '("test/spec_file.rb")
6591 (("193")
6592 (number->string (+ 193 size-diff)))
6593 (("bytes(.)22-33" all delimiter)
6594 (string-append "bytes"
6595 delimiter
6596 (number->string (+ 22 size-diff))
6597 "-"
6598 (number->string (+ 33 size-diff))))))
6599 #t))
6600 (add-before 'reset-gzip-timestamps 'make-files-writable
6601 (lambda* (#:key outputs #:allow-other-keys)
6602 ;; Make sure .gz files are writable so that the
6603 ;; 'reset-gzip-timestamps' phase can do its work.
6604 (let ((out (assoc-ref outputs "out")))
6605 (for-each make-file-writable
6606 (find-files out "\\.gz$"))
6607 #t))))))
6608 (native-inputs
6609 `(("ruby-minitest" ,ruby-minitest)
6610 ("ruby-minitest-sprint" ,ruby-minitest-sprint)
6611 ("which" ,which)))
6612 (propagated-inputs
6613 `(("ruby-concurrent" ,ruby-concurrent)))
6614 (synopsis "Unified web application interface for Ruby")
6615 (description "Rack provides a minimal, modular and adaptable interface for
6616 developing web applications in Ruby. By wrapping HTTP requests and responses,
6617 it unifies the API for web servers, web frameworks, and software in between
6618 into a single method call.")
6619 (home-page "https://rack.github.io/")
6620 (license license:expat)))
6621
6622 (define-public ruby-rack-test
6623 (package
6624 (name "ruby-rack-test")
6625 (version "0.8.3")
6626 (source
6627 (origin
6628 (method url-fetch)
6629 (uri (rubygems-uri "rack-test" version))
6630 (sha256
6631 (base32
6632 "14ij39zywvr1i9f6jsixfg4zxi2q1m1n1nydvf47f0b6sfc9mv1g"))))
6633 (build-system ruby-build-system)
6634 (arguments
6635 ;; Disable tests because of circular dependencies: requires sinatra,
6636 ;; which requires rack-protection, which requires rack-test. Instead
6637 ;; simply require the library.
6638 `(#:phases
6639 (modify-phases %standard-phases
6640 (replace 'check
6641 (lambda _
6642 (invoke "ruby" "-Ilib" "-r" "rack/test"))))))
6643 (propagated-inputs
6644 `(("ruby-rack" ,ruby-rack)))
6645 (synopsis "Testing API for Rack applications")
6646 (description
6647 "Rack::Test is a small, simple testing API for Rack applications. It can
6648 be used on its own or as a reusable starting point for Web frameworks and
6649 testing libraries to build on.")
6650 (home-page "https://github.com/rack-test/rack-test")
6651 (license license:expat)))
6652
6653 (define-public ruby-rack-protection
6654 (package
6655 (name "ruby-rack-protection")
6656 (version "2.0.5")
6657 (source
6658 (origin
6659 (method url-fetch)
6660 (uri (rubygems-uri "rack-protection" version))
6661 (sha256
6662 (base32
6663 "15167q25rmxipqwi6hjqj3i1byi9iwl3xq9b7mdar7qiz39pmjsk"))))
6664 (build-system ruby-build-system)
6665 (arguments
6666 '(;; Tests missing from the gem.
6667 #:tests? #f))
6668 (propagated-inputs
6669 `(("ruby-rack" ,ruby-rack)))
6670 (native-inputs
6671 `(("bundler" ,bundler)
6672 ("ruby-rspec" ,ruby-rspec-2)
6673 ("ruby-rack-test" ,ruby-rack-test)))
6674 (synopsis "Rack middleware that protects against typical web attacks")
6675 (description "Rack middleware that can be used to protect against typical
6676 web attacks. It can protect all Rack apps, including Rails. For instance, it
6677 protects against cross site request forgery, cross site scripting,
6678 clickjacking, directory traversal, session hijacking and IP spoofing.")
6679 (home-page "https://github.com/sinatra/sinatra/tree/master/rack-protection")
6680 (license license:expat)))
6681
6682 (define-public ruby-rainbow
6683 (package
6684 (name "ruby-rainbow")
6685 (version "3.0.0")
6686 (source
6687 (origin
6688 (method url-fetch)
6689 (uri (rubygems-uri "rainbow" version))
6690 (sha256
6691 (base32
6692 "0bb2fpjspydr6x0s8pn1pqkzmxszvkfapv0p4627mywl7ky4zkhk"))))
6693 (build-system ruby-build-system)
6694 (arguments
6695 '(#:phases
6696 (modify-phases %standard-phases
6697 ;; Run rspec directly, to avoid requiring Rubocop which is used from
6698 ;; the Rakefile.
6699 (replace 'check
6700 (lambda* (#:key tests? #:allow-other-keys)
6701 (when tests?
6702 (invoke "rspec"))
6703 #t)))))
6704 (native-inputs
6705 `(("bundler" ,bundler)
6706 ("ruby-rspec" ,ruby-rspec)))
6707 (synopsis "Colorize printed text on ANSI terminals")
6708 (description
6709 "@code{rainbow} provides a string presenter object to colorize strings by
6710 wrapping them in ANSI escape codes.")
6711 (home-page "https://github.com/sickill/rainbow")
6712 (license license:expat)))
6713
6714 (define-public ruby-rr
6715 (package
6716 (name "ruby-rr")
6717 (version "1.2.1")
6718 (source
6719 (origin
6720 (method url-fetch)
6721 (uri (rubygems-uri "rr" version))
6722 (sha256
6723 (base32
6724 "1n9g78ba4c2zzmz8cdb97c38h1xm0clircag00vbcxwqs4dq0ymp"))))
6725 (build-system ruby-build-system)
6726 (arguments
6727 '(#:tests? #f)) ; test files not included
6728 (native-inputs
6729 `(("bundler" ,bundler)
6730 ("ruby-rspec" ,ruby-rspec)))
6731 (synopsis "Ruby test double framework")
6732 (description
6733 "RR is a test double framework that features a rich selection of double
6734 techniques and a terse syntax.")
6735 (home-page "https://rr.github.io/rr/")
6736 (license license:expat)))
6737
6738 (define-public ruby-rest-client
6739 (package
6740 (name "ruby-rest-client")
6741 (version "2.0.2")
6742 (source
6743 (origin
6744 (method url-fetch)
6745 (uri (rubygems-uri "rest-client" version))
6746 (sha256
6747 (base32
6748 "1hzcs2r7b5bjkf2x2z3n8z6082maz0j8vqjiciwgg3hzb63f958j"))))
6749 (build-system ruby-build-system)
6750 (arguments
6751 '(#:phases
6752 (modify-phases %standard-phases
6753 (add-before 'check 'remove-unnecessary-development-dependencies
6754 (lambda _
6755 (substitute* "rest-client.gemspec"
6756 ;; Remove rubocop as it's unused. Rubocop also indirectly
6757 ;; depends on this package through ruby-parser and ruby-ast so
6758 ;; this avoids a dependency loop.
6759 ((".*rubocop.*") "\n")
6760 ;; Remove pry as it's unused, it's a debugging tool
6761 ((".*pry.*") "\n")
6762 ;; Remove an unnecessarily strict rdoc dependency
6763 ((".*rdoc.*") "\n"))
6764 #t))
6765 (add-before 'check 'delete-network-dependent-tests
6766 (lambda _
6767 (delete-file "spec/integration/request_spec.rb")
6768 (delete-file "spec/integration/httpbin_spec.rb")
6769 #t)))))
6770 (propagated-inputs
6771 `(("ruby-http-cookie" ,ruby-http-cookie)
6772 ("ruby-mime-types" ,ruby-mime-types)
6773 ("ruby-netrc" ,ruby-netrc)))
6774 (native-inputs
6775 `(("bundler" ,bundler)
6776 ("ruby-webmock" ,ruby-webmock-2)
6777 ("ruby-rspec" ,ruby-rspec)))
6778 (synopsis "Simple HTTP and REST client for Ruby")
6779 (description
6780 "@code{rest-client} provides a simple HTTP and REST client for Ruby,
6781 inspired by the Sinatra microframework style of specifying actions:
6782 @code{get}, @code{put}, @code{post}, @code{delete}.")
6783 (home-page "https://github.com/rest-client/rest-client")
6784 (license license:expat)))
6785
6786 (define-public ruby-rubocop-ast
6787 (package
6788 (name "ruby-rubocop-ast")
6789 (version "0.3.0")
6790 (source
6791 (origin
6792 (method git-fetch) ;no test suite in distributed gem
6793 (uri (git-reference
6794 (url "https://github.com/rubocop-hq/rubocop-ast.git")
6795 (commit (string-append "v" version))))
6796 (file-name (git-file-name name version))
6797 (sha256
6798 (base32
6799 "1ycf6qcj8nbzk2js72priim4642lkn56w5kbny1nlryjkckxgm04"))))
6800 (build-system ruby-build-system)
6801 (arguments
6802 `(#:test-target "spec"
6803 #:phases (modify-phases %standard-phases
6804 (add-after 'unpack 'disable-bundler
6805 (lambda _
6806 (substitute* "Rakefile"
6807 (("Bundler\\.setup.*") "nil\n"))
6808 #t))
6809 (replace 'replace-git-ls-files
6810 (lambda _
6811 (substitute* "rubocop-ast.gemspec"
6812 (("`git ls-files(.*)`" _ files)
6813 (format #f "`find ~a -type f| sort`" files)))
6814 #t)))))
6815 (native-inputs
6816 `(("ruby-bump" ,ruby-bump)
6817 ("ruby-rspec" ,ruby-rspec)))
6818 (propagated-inputs
6819 `(("ruby-parser" ,ruby-parser)))
6820 (synopsis "RuboCop's AST extensions and NodePattern functionality")
6821 (description "Rubocop::AST extends @code{ruby-parser} with classes used
6822 by RuboCop to deal with Ruby's Abstract Syntax Tree (AST), in particular:
6823 @itemize
6824 @item @code{RuboCop::AST::Node}
6825 @item @code{RuboCop::AST::NodePattern}
6826 @end itemize")
6827 (home-page "https://rubocop.org/")
6828 (license license:expat)))
6829
6830 (define-public ruby-rexml
6831 (package
6832 (name "ruby-rexml")
6833 (version "3.2.4")
6834 (source
6835 (origin
6836 (method git-fetch) ;no tests in distributed gem
6837 (uri (git-reference
6838 (url "https://github.com/ruby/rexml.git")
6839 (commit (string-append "v" version))))
6840 (file-name (git-file-name name version))
6841 (sha256
6842 (base32
6843 "0rhjjbkaq2f2cs8hyr2i4yjqpcyl8m0wmr2cypa401m3fvz4221i"))))
6844 (build-system ruby-build-system)
6845 (synopsis "XML toolkit for Ruby")
6846 (description "Inspired by Electric XML library for Java, REXML aims to be
6847 easy-to-use API, small and fast. It supports both tree and stream document
6848 parsing.")
6849 (home-page "https://github.com/ruby/rexml")
6850 (license license:bsd-2)))
6851
6852 (define-public ruby-character-set
6853 (package
6854 (name "ruby-character-set")
6855 (version "1.4.0")
6856 (source
6857 (origin
6858 (method url-fetch)
6859 (uri (rubygems-uri "character_set" version))
6860 (sha256
6861 (base32
6862 "0affq9n77vwy897ri2zhmfinfagf37hcwwimrccy1bcxan9mj3h3"))))
6863 (build-system ruby-build-system)
6864 (arguments '(#:tests? #f)) ;avoid a cycle with ruby-regexp-parser
6865 (synopsis "Ruby library to manipulate Unicode")
6866 (description "CharacterSet is a C-extended Ruby library to work with sets
6867 of Unicode code points. It can read and write these sets in various formats
6868 and implements the @code{stdlib} @code{Set} interface for them. It also
6869 offers an alternate paradigm of @code{String} processing which grants much
6870 better performance than @code{Regexp} and @code{String} methods from the
6871 @code{stdlib} where applicable. Many parts can be used independently, e.g.:
6872 @itemize
6873 @item @code{CharacterSet::Character}
6874 @item @code{CharacterSet::Parser}
6875 @item @code{CharacterSet::Writer}
6876 @item @code{RangeCompressor}
6877 @end itemize")
6878 (home-page "https://github.com/jaynetics/character_set")
6879 (license license:expat)))
6880
6881 (define-public ruby-range-compressor
6882 (package
6883 (name "ruby-range-compressor")
6884 (version "1.0.0")
6885 (source
6886 (origin
6887 (method git-fetch)
6888 (uri (git-reference
6889 (url "https://github.com/janosch-x/range_compressor.git")
6890 (commit (string-append "v" version))))
6891 (file-name (git-file-name name version))
6892 (sha256
6893 (base32
6894 "0y8slri2msyyg2szgwgriqd6qw9hkxycssdrcl5lk2dbcq5zvn54"))))
6895 (build-system ruby-build-system)
6896 (arguments
6897 `(#:test-target "spec"
6898 #:phases (modify-phases %standard-phases
6899 (add-after 'extract-gemspec 'strip-version-requirements
6900 (lambda _
6901 (substitute* "range_compressor.gemspec"
6902 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
6903 (string-append stripped "\n")))
6904 #t)))))
6905 (native-inputs
6906 `(("ruby-rspec" ,ruby-rspec)))
6907 (synopsis "Simple arrays of objects to arrays of ranges compressor")
6908 (description "RangeCompresses is a tiny library that allows compressing
6909 arrays of objects into arrays of ranges. For example, it can turn the
6910 following: @code{[1, 2, 3, 4, 6, 8, 9, 10]} into @code{[1..4, 6..6, 8..10]}.")
6911 (home-page "https://github.com/janosch-x/range_compressor")
6912 (license license:expat)))
6913
6914 (define-public ruby-regexp-property-values
6915 (package
6916 (name "ruby-regexp-property-values")
6917 (version "1.0.0")
6918 (source
6919 (origin
6920 (method git-fetch)
6921 (uri (git-reference ;no test suite in distributed gem
6922 (url "https://github.com/jaynetics/regexp_property_values.git")
6923 (commit (string-append "v" version))))
6924 (file-name (git-file-name name version))
6925 (sha256
6926 (base32
6927 "0l3fjmscg1wxn7kc6bl022cc6k5d91pwb7daq1b5w36kvsx52w1j"))))
6928 (build-system ruby-build-system)
6929 (arguments
6930 '(#:test-target "default"))
6931 (native-inputs
6932 `(("ruby-character-set" ,ruby-character-set)
6933 ("ruby-rake-compiler" ,ruby-rake-compiler)
6934 ("ruby-range-compressor" ,ruby-range-compressor)
6935 ("ruby-rspec" ,ruby-rspec)))
6936 (synopsis "Inspect Ruby's regex engine property values")
6937 (description "This small library lets you see which property values are
6938 supported by the regular expression engine of the Ruby version you are running
6939 and can directly read out their code point ranges. In other words, it
6940 determines all supported values for @code{\\p{value}} expressions and what
6941 they match.")
6942 (home-page "https://github.com/jaynetics/regexp_property_values")
6943 (license license:expat)))
6944
6945 (define-public ruby-regexp-parser
6946 (package
6947 (name "ruby-regexp-parser")
6948 (version "1.7.1")
6949 (source
6950 (origin
6951 (method git-fetch) ;bin/test missing from gem
6952 (uri (git-reference
6953 (url "https://github.com/ammar/regexp_parser.git")
6954 (commit (string-append "v" version))))
6955 (file-name (git-file-name name version))
6956 (sha256
6957 (base32
6958 "0dk9d4vpw31cc06s29fqyr1kq0kipym1mydifkcrnppvpl3pd53r"))))
6959 (build-system ruby-build-system)
6960 (arguments
6961 '(#:test-target "default"
6962 #:phases (modify-phases %standard-phases
6963 (add-before 'build 'compile-scanner.rb
6964 (lambda _
6965 (invoke "rake" "build")
6966 ;; XXX: This is needed otherwise the install
6967 ;; phase fails to delete the installed cached
6968 ;; gem file.
6969 (delete-file-recursively "pkg")
6970 #t)))))
6971 (native-inputs
6972 `(("ragel" ,ragel)
6973 ("ruby-regexp-property-values" ,ruby-regexp-property-values)
6974 ("ruby-rspec" ,ruby-rspec)))
6975 (synopsis "A regular expression parser library for Ruby ")
6976 (description "A Ruby gem for tokenizing, parsing, and transforming regular
6977 expressions. It comprises the following components:
6978 @itemize
6979 @item A scanner/tokenizer based on Ragel,
6980 @item A lexer that produces a stream of token objects,
6981 @item A parser that produces a tree of Expression objects.
6982 @end itemize")
6983 (home-page "https://github.com/ammar/regexp_parser")
6984 (license license:expat)))
6985
6986 (define-public ruby-test-queue
6987 (package
6988 (name "ruby-test-queue")
6989 (version "0.4.2")
6990 (source
6991 (origin
6992 (method url-fetch)
6993 (uri (rubygems-uri "test-queue" version))
6994 (sha256
6995 (base32
6996 "0hvm3n1qrqxqilhqk4rjivw3gcrd08zz1i6am9qzg1ppjxv6f36f"))))
6997 (build-system ruby-build-system)
6998 (arguments
6999 '(#:phases
7000 (modify-phases %standard-phases
7001 (replace 'check
7002 (lambda* (#:key tests? #:allow-other-keys)
7003 (when tests?
7004 (invoke "rspec"))
7005 #t)))))
7006 (native-inputs
7007 `(("ruby-rspec" ,ruby-rspec)))
7008 (synopsis "Minitest/RSpec parallel test runner for CI environments")
7009 (description "The test-queue module is a parallel test runner,
7010 built using a centralized queue to ensure optimal distribution of
7011 tests between workers. It is specifically optimized for Continuous
7012 Integration (CI) environments: build statistics from each run are
7013 stored locally and used to sort the queue at the beginning of the next
7014 run.")
7015 (home-page "https://github.com/tmm1/test-queue")
7016 (license license:expat)))
7017
7018 (define-public ruby-rubocop
7019 (package
7020 (name "ruby-rubocop")
7021 (version "0.88.0")
7022 (source
7023 (origin
7024 (method git-fetch) ;no tests in distributed gem
7025 (uri (git-reference
7026 (url "https://github.com/rubocop-hq/rubocop.git")
7027 (commit (string-append "v" version))))
7028 (file-name (git-file-name name version))
7029 (sha256
7030 (base32
7031 "1d06893jp8pd85fvgp5d16vqcf31bafi430v4f4y746ihyvhzz5r"))
7032 (patches (search-patches "ruby-rubocop-break-dependency-cycle.patch"))))
7033 (build-system ruby-build-system)
7034 (arguments
7035 '(#:test-target "default"
7036 #:phases
7037 (modify-phases %standard-phases
7038 (add-after 'unpack 'remove-problematic-tests
7039 ;; These tests depend on Rubocop extensions, which cannot be
7040 ;; included as they cause a dependency cycle with Rubocop itself.
7041 (lambda _
7042 (delete-file "spec/rubocop/config_loader_spec.rb")
7043 (substitute* "Gemfile"
7044 ((".*'rubocop-performance'.*") "")
7045 ((".*'rubocop-rspec'.*") ""))
7046 ;; Prevent "Unnecessary disabling of RSpec/* (unknown cop)"
7047 ;; errors.
7048 (substitute* (find-files "spec/rubocop/cop/" "_spec\\.rb$")
7049 (("# (rubocop:(enable|disable) RSpec.*)" _ what)
7050 (string-append "# Disabled: " what)))
7051 #t))
7052 (add-after 'unpack 'disable-bundler
7053 (lambda _
7054 (substitute* "Rakefile"
7055 (("Bundler\\.setup.*") "nil\n"))
7056 #t))
7057 (replace 'replace-git-ls-files
7058 (lambda _
7059 (substitute* "rubocop.gemspec"
7060 (("`git ls-files(.*)`" _ files)
7061 (format #f "`find ~a -type f| sort`" files)))
7062 #t))
7063 (add-before 'check 'set-home
7064 (lambda _
7065 (setenv "HOME" (getcwd))
7066 #t))
7067 (add-before 'check 'make-adoc-files-writable
7068 (lambda _
7069 (let ((adoc-files (find-files "docs/modules/ROOT/pages"
7070 "\\.adoc$")))
7071 (for-each make-file-writable adoc-files))
7072 #t)))))
7073 (native-inputs
7074 `(("ruby-bump" ,ruby-bump)
7075 ("ruby-pry" ,ruby-pry)
7076 ("ruby-rspec" ,ruby-rspec)
7077 ("ruby-test-queue" ,ruby-test-queue)
7078 ("ruby-webmock" ,ruby-webmock-2)
7079 ("ruby-yard" ,ruby-yard)))
7080 (propagated-inputs
7081 `(("ruby-parallel" ,ruby-parallel)
7082 ("ruby-parser" ,ruby-parser)
7083 ("ruby-rainbow" ,ruby-rainbow)
7084 ("ruby-regexp-parser" ,ruby-regexp-parser)
7085 ("ruby-rexml" ,ruby-rexml)
7086 ("ruby-rubocop-ast" ,ruby-rubocop-ast)
7087 ("ruby-progressbar" ,ruby-progressbar)
7088 ("ruby-unicode-display-width" ,ruby-unicode-display-width)))
7089 (synopsis "Ruby code style checking tool")
7090 (description
7091 "@code{rubocop} is a Ruby code style checking tool. It aims to enforce
7092 the community-driven Ruby Style Guide.")
7093 (home-page "https://github.com/rubocop-hq/rubocop")
7094 (license license:expat)))
7095
7096 (define-public ruby-contest
7097 (package
7098 (name "ruby-contest")
7099 (version "0.1.3")
7100 (source
7101 (origin
7102 (method url-fetch)
7103 (uri (rubygems-uri "contest" version))
7104 (sha256
7105 (base32
7106 "1p9f2292b7b0fbrcjswvj9v01z7ig5ig52328wyqcabgb553qsdf"))))
7107 (build-system ruby-build-system)
7108 (synopsis "Write declarative tests using nested contexts")
7109 (description
7110 "Contest allows writing declarative @code{Test::Unit} tests using nested
7111 contexts without performance penalties.")
7112 (home-page "https://github.com/citrusbyte/contest")
7113 (license license:expat)))
7114
7115 (define-public ruby-creole
7116 (package
7117 (name "ruby-creole")
7118 (version "0.5.0")
7119 (source
7120 (origin
7121 (method url-fetch)
7122 (uri (rubygems-uri "creole" version))
7123 (sha256
7124 (base32
7125 "00rcscz16idp6dx0dk5yi5i0fz593i3r6anbn5bg2q07v3i025wm"))))
7126 (build-system ruby-build-system)
7127 (native-inputs
7128 `(("ruby-bacon" ,ruby-bacon)))
7129 (synopsis "Creole markup language converter")
7130 (description
7131 "Creole is a lightweight markup language and this library for converting
7132 creole to @code{HTML}.")
7133 (home-page "https://github.com/minad/creole")
7134 (license license:ruby)))
7135
7136 (define-public ruby-docile
7137 (package
7138 (name "ruby-docile")
7139 (version "1.1.5")
7140 (source
7141 (origin
7142 (method url-fetch)
7143 (uri (rubygems-uri "docile" version))
7144 (sha256
7145 (base32
7146 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
7147 (build-system ruby-build-system)
7148 (arguments
7149 '(#:tests? #f)) ; needs github-markup, among others
7150 (synopsis "Ruby EDSL helper library")
7151 (description "Docile is a Ruby library that provides an interface for
7152 creating embedded domain specific languages (EDSLs) that manipulate existing
7153 Ruby classes.")
7154 (home-page "https://ms-ati.github.io/docile/")
7155 (license license:expat)))
7156
7157 (define-public ruby-middleware
7158 (package
7159 (name "ruby-middleware")
7160 (version "0.1.0")
7161 (source
7162 (origin
7163 (method url-fetch)
7164 (uri (rubygems-uri "middleware" version))
7165 (sha256
7166 (base32
7167 "0703nkf2v371wqr41c04x5qid7ww45cxqv3hnlg07if3b3xrm9xl"))))
7168 (build-system ruby-build-system)
7169 (arguments '(#:tests? #f)) ;no test suite
7170 (synopsis "Implementation of a middleware abstraction for Ruby")
7171 (description "Middleware is a generalized implementation of a middleware
7172 abstraction for Ruby.")
7173 (home-page "https://github.com/mitchellh/middleware")
7174 (license license:expat)))
7175
7176 (define-public ruby-benchmark-ips
7177 (package
7178 (name "ruby-benchmark-ips")
7179 (version "2.8.2")
7180 (source
7181 (origin
7182 (method url-fetch)
7183 (uri (rubygems-uri "benchmark-ips" version))
7184 (sha256
7185 (base32
7186 "1n9397j7kh4vvikfann1467qgksc679imlr50hax3lk1q3af8kdw"))))
7187 (build-system ruby-build-system)
7188 (native-inputs
7189 `(("ruby-hoe" ,ruby-hoe)))
7190 (synopsis "Iterations per second enhancement for the Ruby Benchmark module")
7191 (description "Benchmark-ips enhances the Ruby Benchmark module with the
7192 iterations per second count. For short snippets of code, it can automatically
7193 figure out how many times to run the code to get interesting data.")
7194 (home-page "https://github.com/evanphx/benchmark-ips")
7195 (license license:expat)))
7196
7197 (define-public ruby-ffi-rzmq-core
7198 (package
7199 (name "ruby-ffi-rzmq-core")
7200 (version "1.0.7")
7201 (source
7202 (origin
7203 (method url-fetch)
7204 (uri (rubygems-uri "ffi-rzmq-core" version))
7205 (sha256
7206 (base32
7207 "0amkbvljpjfnv0jpdmz71p1i3mqbhyrnhamjn566w0c01xd64hb5"))))
7208 (build-system ruby-build-system)
7209 (arguments
7210 `(#:phases
7211 (modify-phases %standard-phases
7212 (add-after 'unpack 'patch-libzmq-search-path
7213 (lambda* (#:key inputs #:allow-other-keys)
7214 (let ((zeromq (assoc-ref inputs "zeromq")))
7215 (substitute* "lib/ffi-rzmq-core/libzmq.rb"
7216 (("/usr/local/lib")
7217 (string-append zeromq "/lib")))
7218 #t)))
7219 (replace 'check
7220 (lambda _
7221 (invoke "rspec"))))))
7222 (native-inputs
7223 `(("ruby-rspec" ,ruby-rspec)))
7224 (inputs
7225 `(("zeromq" ,zeromq)))
7226 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
7227 (synopsis "Low-level Ruby FFI wrapper for the ZeroMQ networking library")
7228 (description "This library only provides the FFI wrapper for the ZeroMQ
7229 networking library. It can be used to implement a Ruby API for the ZeroMQ
7230 library.")
7231 (home-page "https://github.com/chuckremes/ffi-rzmq-core")
7232 (license license:expat)))
7233
7234 (define-public ruby-ffi-rzmq
7235 (package
7236 (name "ruby-ffi-rzmq")
7237 (version "2.0.7")
7238 (source
7239 (origin
7240 (method url-fetch)
7241 (uri (rubygems-uri "ffi-rzmq" version))
7242 (sha256
7243 (base32
7244 "14a5kxfnf8l3ngyk8hgmk30z07aj1324ll8i48z67ps6pz2kpsrg"))))
7245 (build-system ruby-build-system)
7246 (arguments '(#:tests? #t
7247 #:phases (modify-phases %standard-phases
7248 (replace 'check
7249 (lambda _
7250 (invoke "rspec"))))))
7251 (native-inputs
7252 `(("ruby-rspec" ,ruby-rspec)))
7253 (propagated-inputs
7254 `(("ruby-ffi-rzmq-core" ,ruby-ffi-rzmq-core)))
7255 (synopsis "High-level Ruby wrapper for the ZeroMQ networking library")
7256 (description "This library provides a high-level API that wraps the ZeroMQ
7257 networking library using the Ruby foreign function interface (FFI). It is a
7258 pure Ruby wrapper, hence is compatible with any Ruby runtime that has support
7259 for FFI.")
7260 (home-page "https://github.com/chuckremes/ffi-rzmq")
7261 (license license:expat)))
7262
7263 (define-public ruby-sawyer
7264 (package
7265 (name "ruby-sawyer")
7266 (version "0.8.2")
7267 (source
7268 (origin
7269 (method url-fetch)
7270 (uri (rubygems-uri "sawyer" version))
7271 (sha256
7272 (base32
7273 "0yrdchs3psh583rjapkv33mljdivggqn99wkydkjdckcjn43j3cz"))))
7274 (build-system ruby-build-system)
7275 (propagated-inputs
7276 `(("ruby-addressable" ,ruby-addressable)
7277 ("ruby-faraday" ,ruby-faraday)))
7278 (synopsis "Experimental hypermedia agent for Ruby")
7279 (description "Sawyer is an experimental hypermedia agent for Ruby built on
7280 top of Faraday.")
7281 (home-page "https://github.com/lostisland/sawyer")
7282 (license license:expat)))
7283
7284 (define-public ruby-octokit
7285 (package
7286 (name "ruby-octokit")
7287 (version "4.18.0")
7288 (source
7289 (origin
7290 (method url-fetch)
7291 (uri (rubygems-uri "octokit" version))
7292 (sha256
7293 (base32
7294 "0zvfr9njmj5svi39fcsi2b0g7pcxb0vamw9dlyas8bg814jlzhi6"))))
7295 (build-system ruby-build-system)
7296 (arguments '(#:tests? #f)) ;no test suite in the gem release
7297 (propagated-inputs
7298 `(("ruby-faraday" ,ruby-faraday)
7299 ("ruby-sawyer" ,ruby-sawyer)))
7300 (synopsis "Ruby toolkit for the GitHub API")
7301 (description "Octokit wraps the GitHub API in a flat API client that
7302 follows Ruby conventions and requires little knowledge of REST.")
7303 (home-page "https://github.com/octokit/octokit.rb")
7304 (license license:expat)))
7305
7306 (define-public ruby-chandler
7307 (package
7308 (name "ruby-chandler")
7309 (version "0.9.0")
7310 (source
7311 (origin
7312 (method url-fetch)
7313 (uri (rubygems-uri "chandler" version))
7314 (sha256
7315 (base32
7316 "1n8a4mr2jkcz5vaaps45g2rxa2pzy1wb7cylgw85xmmyyp14lnrr"))))
7317 (build-system ruby-build-system)
7318 (native-inputs
7319 `(("ruby-rubocop" ,ruby-rubocop)))
7320 (propagated-inputs
7321 `(("ruby-netrc" ,ruby-netrc)
7322 ("ruby-octokit" ,ruby-octokit)))
7323 (synopsis "Sync CHANGELOG entries to GitHub's release notes")
7324 (description "Chandler syncs a project's CHANGELOG file entries to
7325 GitHub's release notes to remove the need of manually entering release
7326 notes.")
7327 (home-page "https://github.com/mattbrictson/chandler")
7328 (license license:expat)))
7329
7330 (define-public ruby-pry-byebug
7331 (package
7332 (name "ruby-pry-byebug")
7333 (version "3.9.0")
7334 (source
7335 (origin
7336 (method git-fetch)
7337 (uri (git-reference
7338 (url "https://github.com/deivid-rodriguez/pry-byebug")
7339 (commit (string-append "v" version))))
7340 (file-name (git-file-name name version))
7341 (sha256
7342 (base32
7343 "1kchrwccai92068p50zyd6mh524ywqnm0jw5g3lks7iwmf0xkmgc"))))
7344 (build-system ruby-build-system)
7345 (arguments
7346 `(#:phases (modify-phases %standard-phases
7347 (add-before 'check 'set-home
7348 (lambda _
7349 (setenv "HOME" (getcwd))
7350 #t)))))
7351 (native-inputs
7352 `(("ruby-chandler" ,ruby-chandler)
7353 ("ruby-rubocop" ,ruby-rubocop)
7354 ("ruby-simplecov" ,ruby-simplecov)))
7355 (propagated-inputs
7356 `(("ruby-byebug" ,ruby-byebug-11)
7357 ("ruby-pry" ,ruby-pry)))
7358 (synopsis "Step-by-step debugging and stack navigation in Pry")
7359 (description "This package adds step-by-step debugging and stack
7360 navigation capabilities to @code{pry}, using @code{byebug}.")
7361 (home-page "https://github.com/deivid-rodriguez/pry-byebug")
7362 (license license:expat)))
7363
7364 (define-public ruby-binding-of-caller
7365 (package
7366 (name "ruby-binding-of-caller")
7367 (version "0.8.0")
7368 (source
7369 (origin
7370 (method url-fetch)
7371 (uri (rubygems-uri "binding_of_caller" version))
7372 (sha256
7373 (base32
7374 "05syqlks7463zsy1jdfbbdravdhj9hpj5pv2m74blqpv8bq4vv5g"))))
7375 (build-system ruby-build-system)
7376 ;; Attempting to run the test suite fails with a rake deprecation error
7377 ;; (see: https://github.com/banister/binding_of_caller/issues/76).
7378 (arguments '(#:tests? #f))
7379 (propagated-inputs
7380 `(("ruby-debug-inspector" ,ruby-debug-inspector)))
7381 (synopsis "Retrieve the binding of a method's caller")
7382 (description "The @code{binding_of_caller} module provides the
7383 @code{Binding#of_caller} method. It allows accessing bindings from upper
7384 frames in the call stack and can evaluate code in that context.")
7385 (home-page "https://github.com/banister/binding_of_caller")
7386 (license license:expat)))
7387
7388 (define-public ruby-pry-stack-explorer
7389 (package
7390 (name "ruby-pry-stack-explorer")
7391 (version "0.5.1")
7392 (source
7393 (origin
7394 (method url-fetch)
7395 (uri (rubygems-uri "pry-stack_explorer" version))
7396 (sha256
7397 (base32
7398 "157rd2n9pfvcmmicm0xkq8z4p6famaj13syrpra6b4032qpb1wn0"))))
7399 (build-system ruby-build-system)
7400 (arguments '(#:tests? #f)) ;no test suite in gem release
7401 (propagated-inputs
7402 `(("ruby-binding-of-caller" ,ruby-binding-of-caller)
7403 ("ruby-pry" ,ruby-pry)))
7404 (synopsis "Call-stack navigation plugin for the Pry REPL")
7405 (description "@code{pry-stack_explorer} is a plugin for the Pry REPL that
7406 add support to navigate the call-stack.")
7407 (home-page "https://github.com/pry/pry-stack_explorer")
7408 (license license:expat)))
7409
7410 (define-public ruby-varint
7411 (package
7412 (name "ruby-varint")
7413 (version "0.1.1")
7414 (source
7415 (origin
7416 (method url-fetch)
7417 (uri (rubygems-uri "varint" version))
7418 (sha256
7419 (base32
7420 "1y0l2qc64cwsyv76ygg9bbjnk86riz2kq73kmn87gdrlmpiyrdac"))))
7421 (build-system ruby-build-system)
7422 (arguments '(#:tests? #f)) ;no test suite
7423 (synopsis "Variable length integers (varint) C extension for Ruby")
7424 (description "This package provides a small C extension to speed up
7425 variable length integers (varint) in Ruby Protocol Buffers.")
7426 (home-page "https://github.com/liquidm/varint")
7427 (license license:bsd-3)))
7428
7429 (define-public ruby-ruby-prof
7430 (package
7431 (name "ruby-ruby-prof")
7432 (version "1.4.1")
7433 (source
7434 (origin
7435 (method url-fetch)
7436 (uri (rubygems-uri "ruby-prof" version))
7437 (sha256
7438 (base32
7439 "12cd91m08ih0imfpy4k87618hd4mhyz291a6bx2hcskza4nf6d27"))))
7440 (build-system ruby-build-system)
7441 (arguments
7442 `(#:phases
7443 (modify-phases %standard-phases
7444 (add-after 'unpack 'patch-rakefile
7445 ;; This fixes the following error: "NameError: uninitialized
7446 ;; constant Bundler::GemHelper" (see:
7447 ;; https://github.com/ruby-prof/ruby-prof/issues/274).
7448 (lambda _
7449 (substitute* "Rakefile"
7450 ((".*require \"bundler/setup\".*" all)
7451 (string-append all " require 'bundler/gem_tasks'\n")))
7452 #t))
7453 ;; The LineNumbersTest test fails non-deterministically (see:
7454 ;; https://github.com/ruby-prof/ruby-prof/issues/276).
7455 (add-after 'extract-gemspec 'delete-flaky-test
7456 (lambda _
7457 (delete-file "test/line_number_test.rb")
7458 (substitute* "ruby-prof.gemspec"
7459 (("\"test/line_number_test\\.rb\"\\.freeze, ") ""))
7460 #t))
7461 (add-before 'check 'compile
7462 (lambda _
7463 (invoke "rake" "compile"))))))
7464 (native-inputs
7465 `(("bundler" ,bundler)
7466 ("ruby-minitest" ,ruby-minitest)
7467 ("ruby-rake-compiler" ,ruby-rake-compiler)
7468 ("ruby-rdoc" ,ruby-rdoc)))
7469 (synopsis "Fast code profiler for Ruby")
7470 (description "RubyProf is a fast code profiler for Ruby. Its features
7471 include:
7472 @table @asis
7473 @item Speed
7474 Being a C extension, it is many times faster than the standard Ruby profiler.
7475 @item Measurement Modes
7476 It can measure program wall time, process time, object allocations and memory
7477 usage.
7478 @item Reports
7479 A variety of text and cross-referenced HTML reports can be generated.
7480 @item Threads
7481 Profiling multiple threads simultaneously is supported.
7482 @end table")
7483 (home-page "https://github.com/ruby-prof/ruby-prof")
7484 (license license:bsd-2)))
7485
7486 (define-public ruby-cucumber-messages
7487 (package
7488 (name "ruby-cucumber-messages")
7489 (version "12.2.0")
7490 (source (origin
7491 (method git-fetch)
7492 (uri (git-reference
7493 (url "https://github.com/cucumber/messages-ruby")
7494 (commit "12cd07eac87bce7843fd1bb0bf64bc4da09f097c")))
7495 (file-name (git-file-name name version))
7496 (sha256
7497 (base32
7498 "16wwqfpsq7crvxc3q08lphgyh12cl2d83p1c79p312q4jmy9cn5a"))))
7499 (build-system ruby-build-system)
7500 (arguments
7501 `(#:phases (modify-phases %standard-phases
7502 (add-after 'unpack 'patch-protobuf.rb
7503 (lambda _
7504 (substitute* "rake/protobuf.rb"
7505 (("load 'protobuf/tasks/compile.rake'")
7506 "require 'protobuf/tasks'"))
7507 #t))
7508 (add-before 'build 'compile
7509 (lambda _
7510 (substitute* "Makefile"
7511 (("bundle exec ") "")
7512 (("include default.mk.*" all)
7513 (string-append "#" all)))
7514 (invoke "make")))
7515 (replace 'check
7516 (lambda _
7517 (invoke "rspec"))))))
7518 (propagated-inputs
7519 `(("ruby-protobuf" ,ruby-protobuf-cucumber)))
7520 (native-inputs
7521 `(("ruby-rspec" ,ruby-rspec)))
7522 (home-page "https://github.com/cucumber/messages-ruby")
7523 (synopsis "Cucumber Messages for Ruby (Protocol Buffers)")
7524 (description "Cucumber Messages for Ruby is a library which allows
7525 serialization and deserialization of the protocol buffer messages used in
7526 Cucumber.")
7527 (license license:expat)))
7528
7529 (define-public ruby-gherkin
7530 (package
7531 (name "ruby-gherkin")
7532 (version "14.0.1")
7533 (source (origin
7534 (method git-fetch)
7535 (uri (git-reference
7536 (url "https://github.com/cucumber/gherkin-ruby")
7537 (commit (string-append "v" version))))
7538 (file-name (git-file-name name version))
7539 (sha256
7540 (base32
7541 "1dwa8632nc6kijv8p257jl64rsjmc0fimlaqvxlkdi2h9n1nympb"))))
7542 (build-system ruby-build-system)
7543 (native-inputs
7544 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
7545 ("ruby-rspec" ,ruby-rspec)))
7546 (arguments
7547 `(#:test-target "spec"))
7548 (synopsis "Gherkin parser for Ruby")
7549 (description "Gherkin is a parser and compiler for the Gherkin language.
7550 It is intended be used by all Cucumber implementations to parse
7551 @file{.feature} files.")
7552 (home-page "https://github.com/cucumber/gherkin-ruby")
7553 (license license:expat)))
7554
7555 (define-public ruby-gherkin-ruby
7556 (package
7557 (name "ruby-gherkin-ruby")
7558 (version "0.3.2")
7559 (home-page "https://github.com/codegram/gherkin-ruby")
7560 (source (origin
7561 (method url-fetch)
7562 (uri (rubygems-uri "gherkin-ruby" version))
7563 (sha256
7564 (base32
7565 "18ay7yiibf4sl9n94k7mbi4k5zj2igl4j71qcmkswv69znyx0sn1"))))
7566 (build-system ruby-build-system)
7567 (synopsis "Pure Ruby Gherkin parser")
7568 (description
7569 "Gherkin-ruby is a Gherkin parser written in pure Ruby and less than
7570 200 lines of code.")
7571 ;; XXX: No license information anywhere but Readme.md.
7572 (license license:expat)))
7573
7574 (define-public ruby-aruba
7575 (package
7576 (name "ruby-aruba")
7577 (version "0.14.14")
7578 (source
7579 (origin
7580 (method url-fetch)
7581 (uri (rubygems-uri "aruba" version))
7582 (sha256
7583 (base32
7584 "0l2mfpdxc03gdrbwc2hv4vdhjhqhfcdp6d02j05j64ncpi9srlqn"))))
7585 (build-system ruby-build-system)
7586 (arguments
7587 '(#:test-target "spec"
7588 #:phases
7589 (modify-phases %standard-phases
7590 (add-after 'unpack 'patch
7591 (lambda _
7592 (substitute* "spec/aruba/api_spec.rb"
7593 ;; This resolves some errors in the specs
7594 ;;
7595 ;; undefined method `parse' for Time:Class
7596 (("require 'spec_helper'")
7597 "require 'spec_helper'\nrequire 'time'"))
7598 ;; Avoid shebang issues in this spec file
7599 (substitute* "spec/aruba/matchers/command_spec.rb"
7600 (("/usr/bin/env bash")
7601 (which "bash")))
7602 #t))
7603 (add-before 'check 'remove-unnecessary-dependencies
7604 (lambda _
7605 (substitute* "Gemfile"
7606 ((".*byebug.*") "\n")
7607 ((".*pry.*") "\n")
7608 ((".*yaml.*") "\n")
7609 ((".*bcat.*") "\n")
7610 ((".*kramdown.*") "\n")
7611 ((".*rubocop.*") "\n")
7612 ((".*cucumber-pro.*") "\n")
7613 ((".*cucumber.*") "\n")
7614 ((".*license_finder.*") "\n")
7615 ((".*rake.*") "gem 'rake'\n")
7616 ((".*relish.*") "\n"))
7617 (substitute* "aruba.gemspec"
7618 (("spec\\.add\\_runtime\\_dependency 'cucumber'.*")
7619 "spec.add_runtime_dependency 'cucumber'"))
7620 #t))
7621 (add-before 'check 'set-home
7622 (lambda _ (setenv "HOME" "/tmp") #t)))))
7623 (native-inputs
7624 `(("bundler" ,bundler)
7625 ("ruby-rspec" ,ruby-rspec)
7626 ("ruby-fuubar" ,ruby-fuubar)
7627 ("ruby-simplecov" ,ruby-simplecov)))
7628 (propagated-inputs
7629 `(("ruby-childprocess" ,ruby-childprocess)
7630 ("ruby-contracts" ,ruby-contracts)
7631 ("ruby-cucumber" ,ruby-cucumber)
7632 ("ruby-ffi" ,ruby-ffi)
7633 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
7634 ("ruby-thor" ,ruby-thor)
7635 ("ruby-yard" ,ruby-yard)))
7636 (synopsis "Test command-line applications with Cucumber, RSpec or Minitest")
7637 (description
7638 "Aruba is an extension for Cucumber, RSpec and Minitest for testing
7639 command-line applications. It supports applications written in any
7640 language.")
7641 (home-page "https://github.com/cucumber/aruba")
7642 (license license:expat)))
7643
7644 ;; A version of ruby-aruba without tests run so that circular dependencies can
7645 ;; be avoided.
7646 (define ruby-aruba-without-tests
7647 (package
7648 (inherit ruby-aruba)
7649 (arguments '(#:tests? #f))
7650 (propagated-inputs
7651 `(("ruby-cucumber" ,ruby-cucumber-without-tests)
7652 ,@(alist-delete "ruby-cucumber"
7653 (package-propagated-inputs ruby-aruba))))
7654 (native-inputs '())))
7655
7656 (define-public ruby-sys-uname
7657 (package
7658 (name "ruby-sys-uname")
7659 (version "1.2.1")
7660 (source
7661 (origin
7662 (method url-fetch)
7663 (uri (rubygems-uri "sys-uname" version))
7664 (sha256
7665 (base32
7666 "00p3wwvkdbg6pl38bchaagncv3i4fq4y0ks470imwykjanpy2ic0"))))
7667 (build-system ruby-build-system)
7668 (arguments
7669 `(#:test-target "spec"))
7670 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
7671 (native-inputs `(("ruby-rspec" ,ruby-rspec)))
7672 (synopsis "Ruby interface for gathering system information")
7673 (description "The sys-uname library provides an interface for gathering
7674 information about your current platform. It allows retrieving information
7675 such as the OS name, OS version, system name, etc.")
7676 (home-page "https://github.com/djberg96/sys-uname")
7677 (license license:asl2.0)))
7678
7679 (define-public ruby-cucumber-create-meta
7680 (package
7681 (name "ruby-cucumber-create-meta")
7682 (version "1.0.0")
7683 (source
7684 (origin
7685 (method url-fetch)
7686 (uri (rubygems-uri "cucumber-create-meta" version))
7687 (sha256
7688 (base32
7689 "0i0i3arymjrnjk72mg79w1a11607x4d0lrqafm9sz2gq9l52zasw"))))
7690 (build-system ruby-build-system)
7691 (arguments
7692 `(#:phases (modify-phases %standard-phases
7693 (add-after 'extract-gemspec 'relax-version-requirements
7694 (lambda _
7695 (substitute* ".gemspec"
7696 ((" 12\\.2")
7697 " 12.1"))
7698 #t))
7699 (replace 'check
7700 (lambda _
7701 (invoke "rspec"))))))
7702 (native-inputs
7703 `(("ruby-rspec" ,ruby-rspec)))
7704 (propagated-inputs
7705 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
7706 ("ruby-sys-uname" ,ruby-sys-uname)))
7707 (synopsis "Function to create @code{Meta} messages for Cucumber Ruby")
7708 (description "The @code{createMeta} utility function allows generating
7709 system-specific @code{Meta} messages for Cucumber Ruby.")
7710 (home-page "https://github.com/cucumber/cucumber/tree/master/create-meta/ruby")
7711 (license license:expat)))
7712
7713 (define-public ruby-cucumber-html-formatter
7714 (package
7715 (name "ruby-cucumber-html-formatter")
7716 (version "7.0.0")
7717 (source
7718 (origin
7719 (method url-fetch)
7720 (uri (rubygems-uri "cucumber-html-formatter" version))
7721 (sha256
7722 (base32
7723 "0lshj4sw9jw7687wrhknyb9kffblai3l843zgrznyqij3ga0bc62"))))
7724 (build-system ruby-build-system)
7725 (arguments
7726 `(#:phases (modify-phases %standard-phases
7727 (replace 'check
7728 (lambda _
7729 (invoke "rspec"))))))
7730 (native-inputs
7731 `(("ruby-rspec" ,ruby-rspec)))
7732 (propagated-inputs
7733 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)))
7734 (synopsis "HTML formatter for Cucumber")
7735 (description "Cucumber HTML Formatter produces a HTML report for Cucumber
7736 runs. It is built on top of cucumber-react and works with any Cucumber
7737 implementation with a protocol buffer formatter that outputs Cucumber
7738 messages.")
7739 (home-page "https://github.com/cucumber/cucumber/tree/\
7740 master/html-formatter/ruby")
7741 (license license:expat)))
7742
7743 (define-public ruby-cucumber
7744 (package
7745 (name "ruby-cucumber")
7746 (version "4.1.0")
7747 (source
7748 (origin
7749 (method git-fetch)
7750 (uri (git-reference
7751 (url "https://github.com/cucumber/cucumber-ruby")
7752 (commit (string-append "v" version))))
7753 (file-name (git-file-name name version))
7754 (sha256
7755 (base32
7756 "0g9rqfslbzkkrq2kvl14fgknrhfbji3bjjpjxff5nc9wzd3hd549"))))
7757 (build-system ruby-build-system)
7758 (arguments
7759 '(#:test-target "default"
7760 #:phases
7761 (modify-phases %standard-phases
7762 (add-after 'unpack 'disable-rubocop
7763 ;; Rubocop lint check fails with our more recent version.
7764 (lambda _
7765 (substitute* "Rakefile"
7766 (("spec cucumber rubocop")
7767 "spec cucumber"))
7768 #t))
7769 (add-after 'extract-gemspec 'strip-version-requirements
7770 (lambda _
7771 (delete-file "Gemfile") ;do not use Bundler
7772 (substitute* "cucumber.gemspec"
7773 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
7774 (string-append stripped "\n")))
7775 #t))
7776 (add-before 'check 'set-home
7777 (lambda _
7778 (setenv "HOME" (getcwd))
7779 #t)))))
7780 (propagated-inputs
7781 `(("ruby-builder" ,ruby-builder)
7782 ("ruby-cucumber-core" ,ruby-cucumber-core)
7783 ("ruby-cucumber-create-meta" ,ruby-cucumber-create-meta)
7784 ("ruby-cucumber-html-formatter" ,ruby-cucumber-html-formatter)
7785 ("ruby-cucumber-messages" ,ruby-cucumber-messages)
7786 ("ruby-cucumber-wire" ,ruby-cucumber-wire)
7787 ("ruby-diff-lcs" ,ruby-diff-lcs)
7788 ("ruby-gherkin" ,ruby-gherkin)
7789 ("ruby-multi-json" ,ruby-multi-json)
7790 ("ruby-multi-test" ,ruby-multi-test)))
7791 (native-inputs
7792 `(;; Use a untested version of aruba, to avoid a circular dependency, as
7793 ;; ruby-aruba depends on ruby-cucumber.
7794 ("ruby-aruba" ,ruby-aruba-without-tests)
7795 ("ruby-rspec" ,ruby-rspec)
7796 ("ruby-pry" ,ruby-pry)
7797 ("ruby-nokogiri" ,ruby-nokogiri)
7798 ("ruby-rubocop" ,ruby-rubocop)))
7799 (synopsis "Describe automated tests in plain language")
7800 (description "Cucumber is a tool for running automated tests written in
7801 plain language. It's designed to support a Behaviour Driven Development (BDD)
7802 software development workflow.")
7803 (home-page "https://cucumber.io/")
7804 (license license:expat)))
7805
7806 (define ruby-cucumber-without-tests
7807 (package (inherit ruby-cucumber)
7808 (arguments
7809 '(#:tests? #f))
7810 (native-inputs
7811 '())))
7812
7813 (define-public ruby-coveralls
7814 (package
7815 (name "ruby-coveralls")
7816 (version "0.8.23")
7817 (source
7818 (origin
7819 (method url-fetch)
7820 (uri (rubygems-uri "coveralls" version))
7821 (sha256
7822 (base32
7823 "1mv4fn5lfxhy7bc2f1lpnc5yp9mvv97az77j4r7jgrxcqwn8fqxc"))))
7824 (build-system ruby-build-system)
7825 ;; The test suite depends on ruby-vcr, which cannot be included in Guix
7826 ;; because of its nonfree, Hippocratic-derived license.
7827 (arguments
7828 `(#:tests? #f
7829 #:phases (modify-phases %standard-phases
7830 (add-after 'extract-gemspec 'strip-version-requirements
7831 ;; Keeping strict version requirements can cause problems
7832 ;; to users of the library, such as: Gem::ConflictError:
7833 ;; Unable to activate coveralls-0.8.23, because
7834 ;; simplecov-0.17.1 conflicts with simplecov (~> 0.16.1).
7835 (lambda _
7836 (substitute* "coveralls-ruby.gemspec"
7837 (("(.*add_.*dependency\\([^,]+), .*" _ stripped)
7838 (string-append stripped ")\n")))
7839 #t)))))
7840 (propagated-inputs
7841 `(("ruby-json" ,ruby-json)
7842 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
7843 ("ruby-thor" ,ruby-thor)
7844 ("ruby-tins" ,ruby-tins)))
7845 (synopsis "Ruby implementation of the Coveralls API")
7846 (description "This package provides a Ruby implementation of the Coveralls
7847 API.")
7848 (home-page "https://coveralls.io")
7849 (license license:expat)))
7850
7851 (define-public ruby-unindent
7852 (package
7853 (name "ruby-unindent")
7854 (version "1.0")
7855 (source
7856 (origin
7857 (method url-fetch)
7858 (uri (rubygems-uri "unindent" version))
7859 (sha256
7860 (base32
7861 "1wqh3rzv8589yzibigminxx3qpmj2nqj28f90xy1sczk1pijmcrd"))))
7862 (build-system ruby-build-system)
7863 (synopsis "Ruby method to unindent strings")
7864 (description "This module provides a @code{String#unindent} Ruby method to
7865 unindent strings, which can be useful to unindent multiline strings embedded
7866 in already-indented code.")
7867 (home-page "https://github.com/mynyml/unindent")
7868 (license license:expat)))
7869
7870 (define-public ruby-cucumber-core
7871 (package
7872 (name "ruby-cucumber-core")
7873 (version "7.1.0")
7874 (source
7875 (origin
7876 (method git-fetch)
7877 (uri (git-reference
7878 (url "https://github.com/cucumber/cucumber-ruby-core")
7879 (commit (string-append "v" version))))
7880 (file-name (git-file-name name version))
7881 (sha256
7882 (base32
7883 "1p5wb6wbggbw37ariyag4kxpiczznvgm3c8cnz1744dmbj79q1rn"))))
7884 (build-system ruby-build-system)
7885 (arguments
7886 `(#:test-target "spec"
7887 #:phases
7888 (modify-phases %standard-phases
7889 (add-after 'extract-gemspec 'relax-version-requirements
7890 (lambda _
7891 (substitute* "cucumber-core.gemspec"
7892 (("'cucumber-tag-expressions',.*")
7893 "'cucumber-tag-expressions', '>=2.0.0'\n"))
7894 #t)))))
7895 (native-inputs
7896 `(("ruby-rspec" ,ruby-rspec)
7897 ("ruby-coveralls" ,ruby-coveralls)
7898 ("ruby-rubocop" ,ruby-rubocop)
7899 ("ruby-simplecov" ,ruby-simplecov)
7900 ("ruby-unindent" ,ruby-unindent)))
7901 (propagated-inputs
7902 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
7903 ("ruby-gherkin" ,ruby-gherkin)
7904 ("ruby-cucumber-tag-expressions" ,ruby-cucumber-tag-expressions)))
7905 (synopsis "Core library for the Cucumber BDD app")
7906 (description "Cucumber is a tool for running automated tests
7907 written in plain language. Because they're written in plain language,
7908 they can be read by anyone on your team. Because they can be read by
7909 anyone, you can use them to help improve communication, collaboration
7910 and trust on your team.")
7911 (home-page "https://cucumber.io/")
7912 (license license:expat)))
7913
7914 (define-public ruby-cucumber-expressions
7915 (package
7916 (name "ruby-cucumber-expressions")
7917 (version "10.2.0")
7918 (source
7919 (origin
7920 (method git-fetch)
7921 (uri (git-reference
7922 (url "https://github.com/cucumber/cucumber-expressions-ruby")
7923 (commit (string-append "v" version))))
7924 (file-name (git-file-name name version))
7925 (sha256
7926 (base32
7927 "1aivhcpjrmbvp9bg0y7g6zxh2swfvylvg0sapq5jc4i1y74k8npd"))))
7928 (build-system ruby-build-system)
7929 (arguments
7930 '(#:test-target "spec"))
7931 (native-inputs
7932 `(("ruby-rspec" ,ruby-rspec)
7933 ("ruby-simplecov" ,ruby-simplecov)))
7934 (synopsis "Simpler alternative to Regular Expressions")
7935 (description "Cucumber Expressions offer similar functionality to Regular
7936 Expressions, with a syntax that is easier to read and write. Cucumber
7937 Expressions are extensible with parameter types.")
7938 (home-page "https://github.com/cucumber/cucumber-expressions-ruby")
7939 (license license:expat)))
7940
7941 (define-public ruby-cucumber-wire
7942 (package
7943 (name "ruby-cucumber-wire")
7944 (version "3.1.0")
7945 (source
7946 (origin
7947 (method url-fetch)
7948 (uri (rubygems-uri "cucumber-wire" version))
7949 (sha256
7950 (base32
7951 "0z1n13lqv70zb2lcrvs2263lm0gsb3gz8gbv890kxzwp8cvd433k"))))
7952 (build-system ruby-build-system)
7953 (arguments
7954 '(#:tests? #f ;tests use cucumber, causing a cycle
7955 #:phases
7956 (modify-phases %standard-phases
7957 (add-after 'extract-gemspec 'relax-version-requirements
7958 (lambda _
7959 (substitute* ".gemspec"
7960 ((" 10\\.1") " 10.2"))
7961 #t)))))
7962 (propagated-inputs
7963 `(("ruby-cucumber-core" ,ruby-cucumber-core)
7964 ("ruby-cucumber-expressions" ,ruby-cucumber-expressions)
7965 ("ruby-cucumber-messages" ,ruby-cucumber-messages)))
7966 (synopsis "Cucumber wire protocol plugin")
7967 (description "Cucumber's wire protocol allows step definitions to be
7968 implemented and invoked on any platform.")
7969 (home-page "https://github.com/cucumber/cucumber-ruby-wire")
7970 (license license:expat)))
7971
7972 (define-public ruby-cucumber-tag-expressions
7973 (package
7974 (name "ruby-cucumber-tag-expressions")
7975 (version "3.0.0")
7976 (source
7977 (origin
7978 (method git-fetch)
7979 (uri (git-reference
7980 (url "https://github.com/cucumber/tag-expressions-ruby")
7981 (commit (string-append "v" version))))
7982 (file-name (git-file-name name version))
7983 (sha256
7984 (base32
7985 "15dw4w0npd4m6aw7zhqkjxxzngp42kswrkwfygxkxcxnhy5zl1vx"))))
7986 (build-system ruby-build-system)
7987 (arguments
7988 `(#:test-target "spec"))
7989 (native-inputs
7990 `(("ruby-rspec" ,ruby-rspec)))
7991 (synopsis "Cucumber tag expressions for Ruby")
7992 (description "Cucumber tag expression parser for Ruby. A tag expression
7993 is an infix boolean expression used by Cucumber.")
7994 (home-page "https://github.com/cucumber/tag-expressions-ruby")
7995 (license license:expat)))
7996
7997 (define-public ruby-bindex
7998 (package
7999 (name "ruby-bindex")
8000 (version "0.5.0")
8001 (source
8002 (origin
8003 (method url-fetch)
8004 (uri (rubygems-uri "bindex" version))
8005 (sha256
8006 (base32
8007 "1wvhf4v8sk5x8li03pcc0v0wglmyv7ikvvg05bnms83dfy7s4k8i"))))
8008 (build-system ruby-build-system)
8009 (arguments
8010 '(#:test-target "default"))
8011 (native-inputs
8012 `(("bundler" ,bundler)
8013 ("ruby-rake-compiler" ,ruby-rake-compiler)))
8014 (synopsis "Provides access for bindings relating to Ruby exceptions")
8015 (description
8016 "@code{bindex} provides a way to access the bindings that relate to
8017 exceptions in Ruby, providing more information about the context in which the
8018 exception occurred.")
8019 (home-page "https://github.com/gsamokovarov/bindex")
8020 (license license:expat)))
8021
8022 (define-public ruby-bio-logger
8023 (package
8024 (name "ruby-bio-logger")
8025 (version "1.0.1")
8026 (source
8027 (origin
8028 (method url-fetch)
8029 (uri (rubygems-uri "bio-logger" version))
8030 (sha256
8031 (base32
8032 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
8033 (build-system ruby-build-system)
8034 (arguments
8035 `(#:tests? #f)) ; rake errors, missing shoulda
8036 (propagated-inputs
8037 `(("ruby-log4r" ,ruby-log4r)))
8038 (synopsis "Log4r wrapper for Ruby")
8039 (description "Bio-logger is a wrapper around Log4r adding extra logging
8040 features such as filtering and fine grained logging.")
8041 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
8042 (license license:expat)))
8043
8044 (define-public ruby-yajl-ruby
8045 (package
8046 (name "ruby-yajl-ruby")
8047 (version "1.4.1")
8048 (source
8049 (origin
8050 (method url-fetch)
8051 (uri (rubygems-uri "yajl-ruby" version))
8052 (sha256
8053 (base32
8054 "16v0w5749qjp13xhjgr2gcsvjv6mf35br7iqwycix1n2h7kfcckf"))))
8055 (build-system ruby-build-system)
8056 (arguments
8057 '(#:test-target "spec"
8058 #:phases
8059 (modify-phases %standard-phases
8060 (add-before 'check 'patch-test-to-update-load-path
8061 (lambda _
8062 (substitute* "spec/parsing/large_number_spec.rb"
8063 (("require \"yajl\"")
8064 "$LOAD_PATH << 'lib'; require 'yajl'"))
8065 #t)))))
8066 (native-inputs
8067 `(("ruby-rake-compiler" ,ruby-rake-compiler)
8068 ("ruby-rspec" ,ruby-rspec)))
8069 (synopsis "Streaming JSON parsing and encoding library for Ruby")
8070 (description
8071 "Ruby C bindings to the Yajl JSON stream-based parser library. The API
8072 is compatible with the JSON gem, so yajl-ruby can act as a drop in
8073 replacement.
8074
8075 A modified copy of yajl is used, and included in the package.")
8076 (home-page "https://github.com/brianmario/yajl-ruby")
8077 (license (list license:expat ; Ruby code, yajl_ext.c and yajl_ext.h
8078 license:bsd-3)))) ; Included, modified copy of yajl
8079
8080 (define-public ruby-yard
8081 (package
8082 (name "ruby-yard")
8083 (version "0.9.25")
8084 (source
8085 (origin
8086 (method git-fetch)
8087 ;; Tests do not pass if we build from the distributed gem.
8088 (uri (git-reference
8089 (url "https://github.com/lsegal/yard")
8090 (commit (string-append "v" version))))
8091 (file-name (git-file-name name version))
8092 (sha256
8093 (base32
8094 "1x7y4s557hrnq439lih7nqg1y7ximardw75jx9i92x3yzpviqqwa"))))
8095 (build-system ruby-build-system)
8096 (arguments
8097 ;; Note: Tests are willfully disabled to alleviate dependency cycle
8098 ;; problems.
8099 `(#:tests? #f
8100 #:phases (modify-phases %standard-phases
8101 (add-after 'unpack 'do-not-set-date-in-gemspec
8102 ;; Fix a reproducibility issue (see:
8103 ;; https://github.com/lsegal/yard/issues/1343).
8104 (lambda _
8105 (substitute* "yard.gemspec"
8106 ((".*s\\.date.*") ""))
8107 #t)))))
8108 (synopsis "Documentation generation tool for Ruby")
8109 (description "YARD is a documentation generation tool for the Ruby
8110 programming language. It enables the user to generate consistent, usable
8111 documentation that can be exported to a number of formats very easily, and
8112 also supports extending for custom Ruby constructs such as custom class level
8113 definitions.")
8114 (home-page "https://yardoc.org")
8115 (license license:expat)))
8116
8117 (define-public ruby-yard-with-tests
8118 (package
8119 (inherit ruby-yard)
8120 (name "ruby-yard-with-tests")
8121 (arguments
8122 (substitute-keyword-arguments (package-arguments ruby-yard)
8123 ((#:tests? _ #t) #t)
8124 ((#:test-target _ "default") "default")
8125 ((#:phases phases '%standard-phases)
8126 `(modify-phases ,phases
8127 (add-before 'check 'prepare-for-tests
8128 (lambda* (#:key tests? #:allow-other-keys)
8129 (when tests?
8130 (substitute* "Rakefile"
8131 ((".*[Ss]amus.*") ""))
8132 ;; Delete the Gemfile to avoid errors relating to it.
8133 (delete-file "Gemfile")
8134 ;; $HOME needs to be set to somewhere writeable for tests to
8135 ;; run.
8136 (setenv "HOME" "/tmp"))
8137 #t))))))
8138 (native-inputs
8139 `(("ruby-rspec" ,ruby-rspec)
8140 ("ruby-rack" ,ruby-rack)
8141 ("ruby-redcloth" ,ruby-redcloth)
8142 ("ruby-asciidoc" ,ruby-asciidoctor)))))
8143
8144 (define-public ruby-spectroscope
8145 (package
8146 (name "ruby-spectroscope")
8147 (version "0.1.0")
8148 (source
8149 (origin
8150 (method url-fetch)
8151 (uri (rubygems-uri "spectroscope" version))
8152 (sha256
8153 (base32
8154 "0iiid9sm110qhx0i1zkds710cvsnmhd308wbqa7slkzbq2akrb3y"))))
8155 (build-system ruby-build-system)
8156 (arguments
8157 `(#:phases
8158 (modify-phases %standard-phases
8159 (replace 'check
8160 (lambda _
8161 (with-output-to-file ".test"
8162 (lambda _
8163 (display
8164 "\
8165 require 'ae/should'
8166 require 'rspec'
8167
8168 include RSpec
8169
8170 Test.run :default do |run|
8171 run.files << 'spec/*_spec.rb'
8172 end")))
8173 (invoke "ruby" "-Ilib" "-rrubytest" ".test"))))))
8174 (native-inputs
8175 `(("ruby-ae" ,ruby-ae)
8176 ("ruby-rspec" ,ruby-rspec)))
8177 (propagated-inputs
8178 `(("ruby-rubytest" ,ruby-rubytest)))
8179 (synopsis "Behavior-Driven Development (BDD) framework built on RubyTest")
8180 (description "Spectroscope is a Behavior-Driven Development (BDD)
8181 framework built on RubyTest, designed to emulate RSpec in most respects. It
8182 is assertion framework independent so any number of assertion systems can be
8183 used, such as Assay or AE.")
8184 (home-page "http://rubyworks.github.com/spectroscope/")
8185 (license license:bsd-2)))
8186
8187 (define-public ruby-tomparse
8188 (package
8189 (name "ruby-tomparse")
8190 (version "0.4.2")
8191 (source
8192 (origin
8193 (method url-fetch)
8194 (uri (rubygems-uri "tomparse" version))
8195 (sha256
8196 (base32
8197 "06xakk41f1kgj6j1ahkwn4r6cvidixvm4phhlrvmwb7c3pr8ygc8"))))
8198 (build-system ruby-build-system)
8199 ;; TODO: Tests require citron and rulebow, not yet packaged.
8200 (arguments '(#:tests? #f))
8201 (synopsis "TomDoc parser for Ruby")
8202 (description "TomParse is a TomDoc parser for Ruby. It takes a code
8203 comment as input and parses it into a convenient object-oriented structure in
8204 accordance with the TomDoc standard. See
8205 @url{https://github.com/mojombo/tomdoc, TomDoc} for more information about the
8206 TomDoc format.")
8207 (home-page "http://rubyworks.github.com/tomparse/")
8208 (license license:bsd-2)))
8209
8210 (define-public ruby-yard-tomdoc
8211 (package
8212 (name "ruby-yard-tomdoc")
8213 (version "0.7.1")
8214 (source
8215 (origin
8216 (method url-fetch)
8217 (uri (rubygems-uri "yard-tomdoc" version))
8218 (sha256
8219 (base32
8220 "1725gs8b8klpwhrvnf2wwp7dw3zxs9vz2la983l2d8c4r4fn1j2z"))))
8221 (build-system ruby-build-system)
8222 (arguments
8223 `(#:phases (modify-phases %standard-phases
8224 (replace 'check
8225 (lambda _
8226 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
8227 (native-inputs
8228 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
8229 ("ruby-spectroscope" ,ruby-spectroscope)
8230 ("ruby-ae" ,ruby-ae)))
8231 (propagated-inputs
8232 `(("ruby-tomparse" ,ruby-tomparse)
8233 ("ruby-yard" ,ruby-yard)))
8234 (synopsis "TomDoc syntax for YARD")
8235 (description "This module adds support for the TomDoc documentation format
8236 to YARD, a documentation generation tool for Ruby.")
8237 (home-page "http://rubyworks.github.com/yard-tomdoc/")
8238 (license license:expat)))
8239
8240 (define-public ruby-clap
8241 (package
8242 (name "ruby-clap")
8243 (version "1.0.0")
8244 (source (origin
8245 (method url-fetch)
8246 (uri (rubygems-uri "clap" version))
8247 (sha256
8248 (base32
8249 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
8250 (build-system ruby-build-system)
8251 ;; Clap needs cutest for running tests, but cutest needs clap.
8252 (arguments `(#:tests? #f))
8253 (synopsis "Command line argument parsing for simple applications")
8254 (description
8255 "Clap provides command line argument parsing features. It covers the
8256 simple case of executing code based on the flags or parameters passed.")
8257 (home-page "https://github.com/djanowski/cutest")
8258 (license license:expat)))
8259
8260 (define-public ruby-cutest
8261 (package
8262 (name "ruby-cutest")
8263 (version "1.2.2")
8264 (source (origin
8265 (method url-fetch)
8266 (uri (rubygems-uri "cutest" version))
8267 (sha256
8268 (base32
8269 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
8270 (build-system ruby-build-system)
8271 (propagated-inputs
8272 `(("ruby-clap" ,ruby-clap)))
8273 (synopsis "Run tests in separate processes")
8274 (description
8275 "Cutest runs tests in separate processes to avoid shared state.")
8276 (home-page "https://github.com/djanowski/cutest")
8277 (license license:expat)))
8278
8279 (define-public ruby-pygmentize
8280 (package
8281 (name "ruby-pygmentize")
8282 (version "0.0.3")
8283 (source (origin
8284 (method url-fetch)
8285 (uri (rubygems-uri "pygmentize" version))
8286 (sha256
8287 (base32
8288 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
8289 (build-system ruby-build-system)
8290 (arguments
8291 `(#:phases
8292 (modify-phases %standard-phases
8293 (add-after 'unpack 'fix-pygmentize-path
8294 (lambda _
8295 (substitute* "lib/pygmentize.rb"
8296 (("\"/usr/bin/env python.*")
8297 (string-append "\"" (which "pygmentize") "\"\n")))
8298 #t))
8299 (add-after 'build 'do-not-use-vendor-directory
8300 (lambda _
8301 ;; Remove bundled pygments sources
8302 ;; FIXME: ruby-build-system does not support snippets.
8303 (delete-file-recursively "vendor")
8304 (substitute* "pygmentize.gemspec"
8305 (("\"vendor/\\*\\*/\\*\",") ""))
8306 #t)))))
8307 (inputs
8308 `(("pygments" ,python-pygments)))
8309 (native-inputs
8310 `(("ruby-cutest" ,ruby-cutest)
8311 ("ruby-nokogiri" ,ruby-nokogiri)))
8312 (synopsis "Thin Ruby wrapper around pygmentize")
8313 (description
8314 "Pygmentize provides a simple way to call pygmentize from within a Ruby
8315 application.")
8316 (home-page "https://github.com/djanowski/pygmentize")
8317 (license license:expat)))
8318
8319 (define-public ruby-eventmachine
8320 (package
8321 (name "ruby-eventmachine")
8322 (version "1.2.7")
8323 (source
8324 (origin
8325 (method url-fetch)
8326 (uri (rubygems-uri "eventmachine" version))
8327 (sha256
8328 (base32
8329 "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"))))
8330 (build-system ruby-build-system)
8331 (arguments
8332 '(#:tests? #f)) ; test suite tries to connect to google.com
8333 (native-inputs
8334 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
8335 (synopsis "Single-threaded network event framework for Ruby")
8336 (description
8337 "EventMachine implements a single-threaded engine for arbitrary network
8338 communications. EventMachine wraps all interactions with sockets, allowing
8339 programs to concentrate on the implementation of network protocols. It can be
8340 used to create both network servers and clients.")
8341 ;; The ‘official’ rubyeventmachine.com domain is now registrar-squatted.
8342 (home-page "https://github.com/eventmachine/eventmachine")
8343 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
8344
8345 (define-public ruby-ruby-engine
8346 (package
8347 (name "ruby-ruby-engine")
8348 (version "2.0.0")
8349 (source
8350 (origin
8351 (method url-fetch)
8352 (uri (rubygems-uri "ruby_engine" version))
8353 (sha256
8354 (base32
8355 "0wqdcv8gxybp1y7kjhh18g3r9dczacs62d4ahcvyhz32bih8c9fm"))))
8356 (build-system ruby-build-system)
8357 (arguments
8358 `(#:phases
8359 (modify-phases %standard-phases
8360 (add-after 'extract-gemspec 'clean-up
8361 (lambda _
8362 (delete-file "Gemfile.lock")
8363 (substitute* "ruby_engine.gemspec"
8364 ;; Remove unnecessary imports that would entail further
8365 ;; dependencies.
8366 ((".*<rdoc.*") "")
8367 ((".*<rubygems-tasks.*") "")
8368 ;; Remove extraneous .gem file
8369 (("\"pkg/ruby_engine-[0-9.]+\\.gem\".freeze, ") "")
8370 (("\"Gemfile.lock\".freeze, ") "")
8371 ;; Soften rake dependency
8372 (("%q<rake>.freeze, \\[\"~> 10.0\"\\]")
8373 "%q<rake>.freeze, [\">= 10.0\"]")
8374 ;; Soften the rspec dependency
8375 (("%q<rspec>.freeze, \\[\"~> 2.4\"\\]")
8376 "%q<rspec>.freeze, [\">= 2.4\"]"))
8377 (substitute* "Rakefile"
8378 (("require 'rubygems/tasks'") "")
8379 (("Gem::Tasks.new") ""))
8380 ;; Remove extraneous .gem file that otherwise gets installed.
8381 (delete-file-recursively "pkg")
8382 #t)))))
8383 (native-inputs
8384 `(("bundler" ,bundler)
8385 ("ruby-rake" ,ruby-rake)
8386 ("ruby-rspec" ,ruby-rspec)))
8387 (synopsis "Simplifies checking for Ruby implementation")
8388 (description
8389 "@code{ruby_engine} provides an RubyEngine class that can be used to
8390 check which implementation of Ruby is in use. It can provide the interpreter
8391 name and provides query methods such as @{RubyEngine.mri?}.")
8392 (home-page "https://github.com/janlelis/ruby_engine")
8393 (license license:expat)))
8394
8395 (define-public ruby-turn
8396 (package
8397 (name "ruby-turn")
8398 (version "0.9.7")
8399 (source
8400 (origin
8401 (method url-fetch)
8402 (uri (rubygems-uri "turn" version))
8403 (sha256
8404 (base32
8405 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
8406 (build-system ruby-build-system)
8407 (arguments
8408 `(#:phases
8409 (modify-phases %standard-phases
8410 ;; Tests fail because turn changes its environment so can no longer
8411 ;; find test/unit. Instead simply test if the executable runs
8412 ;; without issue.
8413 (replace 'check
8414 (lambda _
8415 (invoke "ruby" "-Ilib" "bin/turn" "-h"))))))
8416 (propagated-inputs
8417 `(("ruby-ansi" ,ruby-ansi)
8418 ("ruby-minitest" ,ruby-minitest-4)))
8419 (synopsis "Alternate set of alternative runners for MiniTest")
8420 (description
8421 "TURN provides a set of alternative runners for MiniTest which are both
8422 colorful and informative. TURN displays each test on a separate line with
8423 failures being displayed immediately instead of at the end of the tests. Note
8424 that TURN is no longer being maintained.")
8425 (home-page "https://rubygems.org/gems/turn")
8426 (license license:expat)))
8427
8428 (define-public ruby-mimemagic
8429 (package
8430 (name "ruby-mimemagic")
8431 (version "0.3.3")
8432 (source
8433 (origin
8434 (method url-fetch)
8435 (uri (rubygems-uri "mimemagic" version))
8436 (sha256
8437 (base32 "04cp5sfbh1qx82yqxn0q75c7hlcx8y1dr5g3kyzwm4mx6wi2gifw"))))
8438 (build-system ruby-build-system)
8439 (arguments
8440 '(#:phases
8441 (modify-phases %standard-phases
8442 ;; This phase breaks the tests, as it patches some of the test data.
8443 (delete 'patch-source-shebangs))))
8444 (native-inputs
8445 `(("ruby-bacon" ,ruby-bacon)))
8446 (synopsis "Ruby library for MIME detection by extension or content")
8447 (description
8448 "@acronym{MIME, Multipurpose Internet Mail Extensions} detection by
8449 extension or content, using the freedesktop.org.xml shared-mime-info
8450 database.")
8451 (home-page "https://github.com/minad/mimemagic")
8452 (license license:expat)))
8453
8454 (define-public ruby-mime-types-data
8455 (package
8456 (name "ruby-mime-types-data")
8457 (version "3.2016.0521")
8458 (source
8459 (origin
8460 (method url-fetch)
8461 (uri (rubygems-uri "mime-types-data" version))
8462 (sha256
8463 (base32
8464 "04my3746hwa4yvbx1ranhfaqkgf6vavi1kyijjnw8w3dy37vqhkm"))))
8465 (build-system ruby-build-system)
8466 (native-inputs
8467 `(("ruby-hoe" ,ruby-hoe)))
8468 (synopsis "Registry for information about MIME media type definitions")
8469 (description
8470 "@code{mime-types-data} provides a registry for information about
8471 Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
8472 be used with the Ruby mime-types library or other software to determine
8473 defined filename extensions for MIME types, or to use filename extensions to
8474 look up the likely MIME type definitions.")
8475 (home-page "https://github.com/mime-types/mime-types-data/")
8476 (license license:expat)))
8477
8478 (define-public ruby-mime-types
8479 (package
8480 (name "ruby-mime-types")
8481 (version "3.1")
8482 (source
8483 (origin
8484 (method url-fetch)
8485 (uri (rubygems-uri "mime-types" version))
8486 (sha256
8487 (base32
8488 "0087z9kbnlqhci7fxh9f6il63hj1k02icq2rs0c6cppmqchr753m"))))
8489 (build-system ruby-build-system)
8490 (propagated-inputs
8491 `(("ruby-mime-types-data" ,ruby-mime-types-data)))
8492 (native-inputs
8493 `(("ruby-hoe" ,ruby-hoe)
8494 ("ruby-fivemat" ,ruby-fivemat)
8495 ("ruby-minitest-focus" ,ruby-minitest-focus)
8496 ("ruby-minitest-rg" ,ruby-minitest-rg)
8497 ("ruby-minitest-bonus-assertions" ,ruby-minitest-bonus-assertions)
8498 ("ruby-minitest-hooks" ,ruby-minitest-hooks)))
8499 (synopsis "Library and registry for MIME content type definitions")
8500 (description "The mime-types library provides a library and registry for
8501 information about Multipurpose Internet Mail Extensions (MIME) content type
8502 definitions. It can be used to determine defined filename extensions for MIME
8503 types, or to use filename extensions to look up the likely MIME type
8504 definitions.")
8505 (home-page "https://github.com/mime-types/ruby-mime-types")
8506 (license license:expat)))
8507
8508 (define-public ruby-fivemat
8509 (package
8510 (name "ruby-fivemat")
8511 (version "1.3.7")
8512 (source
8513 (origin
8514 (method url-fetch)
8515 (uri (rubygems-uri "fivemat" version))
8516 (sha256
8517 (base32
8518 "0pzlycasvwmg4bbx7plllpqnhd9zlmmff8l2w3yii86nrm2nvf9n"))))
8519 (build-system ruby-build-system)
8520 (arguments
8521 `(#:tests? #f)) ; no tests
8522 (synopsis "Each test file given its own line of dots")
8523 (description
8524 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
8525 its own line of dots during testing. It aims to provide test output that is
8526 neither too verbose nor too minimal.")
8527 (home-page "https://github.com/tpope/fivemat")
8528 (license license:expat)))
8529
8530 (define-public ruby-sqlite3
8531 (package
8532 (name "ruby-sqlite3")
8533 (version "1.4.2")
8534 (source
8535 (origin
8536 (method url-fetch)
8537 (uri (rubygems-uri "sqlite3" version))
8538 (sha256
8539 (base32
8540 "0lja01cp9xd5m6vmx99zwn4r7s97r1w5cb76gqd8xhbm1wxyzf78"))))
8541 (build-system ruby-build-system)
8542 (arguments
8543 `(#:phases
8544 (modify-phases %standard-phases
8545 (add-before 'check 'add-gemtest-file
8546 ;; This file exists in the repository but is not distributed.
8547 (lambda _ (invoke "touch" ".gemtest"))))))
8548 (inputs
8549 `(("sqlite" ,sqlite)))
8550 (native-inputs
8551 `(("ruby-hoe" ,ruby-hoe)
8552 ("ruby-rake-compiler" ,ruby-rake-compiler)
8553 ("ruby-mini-portile" ,ruby-mini-portile)))
8554 (synopsis "Interface with SQLite3 databases")
8555 (description
8556 "This module allows Ruby programs to interface with the SQLite3 database
8557 engine.")
8558 (home-page
8559 "https://github.com/sparklemotion/sqlite3-ruby")
8560 (license license:bsd-3)))
8561
8562 (define-public ruby-shoulda-context
8563 (package
8564 (name "ruby-shoulda-context")
8565 (version "1.2.2")
8566 (source
8567 (origin
8568 (method url-fetch)
8569 (uri (rubygems-uri "shoulda-context" version))
8570 (sha256
8571 (base32
8572 "1l0ncsxycb4s8n47dml97kdnixw4mizljbkwqc3rh05r70csq9bc"))))
8573 (build-system ruby-build-system)
8574 (arguments
8575 `(#:phases
8576 (modify-phases %standard-phases
8577 (replace 'check
8578 (lambda _
8579 ;; Do not run tests to avoid circular dependence with rails.
8580 ;; Instead just import the library to test.
8581 (invoke "ruby" "-Ilib" "-r" "shoulda-context"))))))
8582 (synopsis "Test::Unit context framework extracted from Shoulda")
8583 (description
8584 "@code{shoulda-context} is the context framework extracted from Shoulda.
8585 Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
8586 context, setup, and should blocks combine to produce natural test method
8587 names.")
8588 (home-page "https://github.com/thoughtbot/shoulda-context")
8589 (license license:expat)))
8590
8591 (define-public ruby-shoulda-matchers
8592 (package
8593 (name "ruby-shoulda-matchers")
8594 (version "3.1.2")
8595 (source
8596 (origin
8597 (method url-fetch)
8598 (uri (rubygems-uri "shoulda-matchers" version))
8599 (sha256
8600 (base32
8601 "1zvv94pqk5b5my3w1shdz7h34xf2ldhg5k4qfdpbwi2iy0j9zw2a"))))
8602 (build-system ruby-build-system)
8603 (arguments
8604 `(#:phases
8605 (modify-phases %standard-phases
8606 (replace 'check
8607 (lambda _
8608 ;; Do not run tests to avoid circular dependence with rails. Instead
8609 ;; just import the library to test.
8610 (invoke "ruby" "-Ilib" "-r" "shoulda-matchers"))))))
8611 (propagated-inputs
8612 `(("ruby-activesupport" ,ruby-activesupport)))
8613 (synopsis "Collection of testing matchers extracted from Shoulda")
8614 (description
8615 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
8616 test common Rails functionality. These tests would otherwise be much longer,
8617 more complex, and error-prone.")
8618 (home-page "https://github.com/thoughtbot/shoulda-matchers")
8619 (license license:expat)))
8620
8621 (define-public ruby-shoulda-matchers-2
8622 (package
8623 (inherit ruby-shoulda-matchers)
8624 (version "2.8.0")
8625 (source (origin
8626 (method url-fetch)
8627 (uri (rubygems-uri "shoulda-matchers" version))
8628 (sha256
8629 (base32
8630 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
8631
8632 (define-public ruby-shoulda
8633 (package
8634 (name "ruby-shoulda")
8635 (version "3.5.0")
8636 (source
8637 (origin
8638 (method url-fetch)
8639 (uri (rubygems-uri "shoulda" version))
8640 (sha256
8641 (base32
8642 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
8643 (build-system ruby-build-system)
8644 (arguments
8645 `(#:phases
8646 (modify-phases %standard-phases
8647 (replace 'check
8648 ;; Don't run tests to avoid circular dependence with rails. Instead
8649 ;; just import the library to test.
8650 (lambda _ (invoke "ruby" "-Ilib" "-r" "shoulda"))))))
8651 (propagated-inputs
8652 `(("ruby-shoulda-context" ,ruby-shoulda-context)
8653 ("ruby-shoulda-matchers" ,ruby-shoulda-matchers-2)))
8654 (synopsis "Context framework and matchers for testing")
8655 (description
8656 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
8657 @code{shoulda-matchers} providing tools for writing tests.")
8658 (home-page "https://github.com/thoughtbot/shoulda")
8659 (license license:expat)))
8660
8661 (define-public ruby-unf
8662 (package
8663 (name "ruby-unf")
8664 (version "0.1.4")
8665 (source
8666 (origin
8667 (method url-fetch)
8668 (uri (rubygems-uri "unf" version))
8669 (sha256
8670 (base32
8671 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
8672 (build-system ruby-build-system)
8673 (arguments
8674 `(#:phases
8675 (modify-phases %standard-phases
8676 (add-before 'check 'add-dependency-to-bundler
8677 (lambda _
8678 ;; test-unit is required but not provided by the bundler
8679 ;; environment. This is fixed in the upstream repository but fix
8680 ;; has not been released.
8681 (substitute* "Gemfile"
8682 (("^gemspec") "gem 'test-unit'\ngemspec"))
8683 #t)))))
8684 (propagated-inputs
8685 `(("ruby-unf-ext" ,ruby-unf-ext)))
8686 (native-inputs
8687 `(("ruby-shoulda" ,ruby-shoulda)
8688 ("bundler" ,bundler)
8689 ("ruby-test-unit" ,ruby-test-unit)))
8690 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
8691 (description
8692 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
8693 support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
8694 @code{java.text.Normalizer} on JRuby.")
8695 (home-page "https://github.com/knu/ruby-unf")
8696 (license license:bsd-2)))
8697
8698 (define-public ruby-warden
8699 (package
8700 (name "ruby-warden")
8701 (version "1.2.8")
8702 (source
8703 (origin
8704 (method url-fetch)
8705 (uri (rubygems-uri "warden" version))
8706 (sha256
8707 (base32
8708 "1fr9n9i9r82xb6i61fdw4xgc7zjv7fsdrr4k0njchy87iw9fl454"))))
8709 (build-system ruby-build-system)
8710 (arguments
8711 '(#:tests? #f)) ; No included tests
8712 (propagated-inputs
8713 `(("ruby-rack" ,ruby-rack)))
8714 (synopsis "Rack middleware providing authentication")
8715 (description
8716 "Warden is a Rack-based middleware that provides a mechanism for
8717 authentication in Ruby web applications.")
8718 (home-page "https://github.com/wardencommunity/warden")
8719 (license license:expat)))
8720
8721 (define-public ruby-warden-oauth2
8722 (package
8723 (name "ruby-warden-oauth2")
8724 (version "0.0.1")
8725 (source
8726 (origin
8727 (method url-fetch)
8728 (uri (rubygems-uri "warden-oauth2" version))
8729 (sha256
8730 (base32
8731 "1z9154lvzrnnfjbjkmirh4n811nygp6pm2fa6ikr7y1ysa4zv3cz"))))
8732 (build-system ruby-build-system)
8733 (arguments
8734 '(#:test-target "spec"
8735 #:phases
8736 (modify-phases %standard-phases
8737 (add-after 'unpack 'remove-unnecessary-dependencies
8738 (lambda _
8739 (substitute* "Gemfile"
8740 ;; All of these gems relate to development, and are unnecessary
8741 ;; when running the tests
8742 (("gem 'guard-bundler'") "")
8743 (("gem 'guard'") "")
8744 (("gem 'guard-rspec'") "")
8745 (("gem 'rb-fsevent'") "")
8746 (("gem 'pry'") "")
8747 (("gem 'growl'") ""))
8748 #t))
8749 ;; The test suite doesn't work with rspec@2, and this is incompatible
8750 ;; with the current version of Rake, so invoke Rspec directly
8751 (replace 'check
8752 (lambda* (#:key tests? #:allow-other-keys)
8753 (when tests?
8754 (invoke "bundle" "exec" "rspec"))
8755 #t)))))
8756 (propagated-inputs
8757 `(("ruby-warden" ,ruby-warden)))
8758 (native-inputs
8759 `(("bundler" ,bundler)
8760 ("ruby-rspec" ,ruby-rspec-2)
8761 ("ruby-rack-test" ,ruby-rack-test)))
8762 (synopsis "OAuth 2.0 strategies for Warden")
8763 (description
8764 "This library extends Warden to support OAuth 2.0 authorized API
8765 requests.")
8766 (home-page "https://github.com/opperator/warden-oauth2")
8767 (license license:expat)))
8768
8769 (define-public ruby-webmock-2
8770 (package
8771 (name "ruby-webmock")
8772 (version "2.3.2")
8773 (source
8774 (origin
8775 (method url-fetch)
8776 (uri (rubygems-uri "webmock" version))
8777 (sha256
8778 (base32
8779 "04hkcqsmbfnp8g237pisnc834vpgildklicbjbyikqg0bg1rwcy5"))))
8780 (build-system ruby-build-system)
8781 (native-inputs
8782 `(("bundler" ,bundler)
8783 ("ruby-rspec" ,ruby-rspec)))
8784 (propagated-inputs
8785 `(("ruby-addressable" ,ruby-addressable)
8786 ("ruby-crack" ,ruby-crack)
8787 ("ruby-hashdiff" ,ruby-hashdiff)))
8788 (synopsis "Allows stubbing and setting expectations on HTTP requests")
8789 (description
8790 "WebMock allows stubbing HTTP requests and setting expectations on HTTP
8791 requests. This is useful when testing software.")
8792 (home-page "https://github.com/bblimke/webmock")
8793 (license license:expat)))
8794
8795 (define-public ruby-unicode-display-width
8796 (package
8797 (name "ruby-unicode-display-width")
8798 (version "1.6.0")
8799 (source
8800 (origin
8801 (method url-fetch)
8802 (uri (rubygems-uri "unicode-display_width" version))
8803 (sha256
8804 (base32
8805 "08kfiniak1pvg3gn5k6snpigzvhvhyg7slmm0s2qx5zkj62c1z2w"))))
8806 (build-system ruby-build-system)
8807 (arguments
8808 '(;; Test data not included.
8809 #:tests? #f))
8810 (synopsis "Determine the monospace display width of Ruby strings")
8811 (description
8812 "@code{Unicode::DisplayWidth} is a Ruby library which can determine the
8813 display width of strings in Ruby.")
8814 (home-page "https://github.com/janlelis/unicode-display_width")
8815 (license license:expat)))
8816
8817 ;; There is another gem called 'ruby-version' so we use an underscore in this
8818 ;; name
8819 (define-public ruby_version
8820 (package
8821 (name "ruby_version")
8822 (version "1.0.2")
8823 (source
8824 (origin
8825 (method url-fetch)
8826 (uri (rubygems-uri "ruby_version" version))
8827 (sha256
8828 (base32
8829 "0lvc7bd5ps3w2vq2wb02i0pi3vfcx2rnckx2ix4rjym1qf52kb2j"))))
8830 (build-system ruby-build-system)
8831 (arguments
8832 `(#:phases
8833 (modify-phases %standard-phases
8834 (add-before 'check 'fix-dependencies
8835 (lambda _
8836 ;; Remove the Gemfile.lock, as we want to use Guix packages at
8837 ;; whatever versions.
8838 (delete-file "Gemfile.lock")
8839 ;; Remove the included gem files as they unnecessary.
8840 (delete-file-recursively "pkg/")
8841 ;; Accept any version of rake, rdoc and rspec
8842 (substitute* "ruby_version.gemspec"
8843 (("%q<rake.*") "%q<rake>)\n")
8844 (("%q<rdoc.*") "%q<rdoc>)\n")
8845 (("%q<rspec.*") "%q<rspec>)\n"))
8846 ;; Do not use bundler.
8847 (substitute* "Rakefile"
8848 (("Bundler\\.setup.*") "nil\n"))
8849 #t)))))
8850 (native-inputs
8851 `(("ruby-rdoc" ,ruby-rdoc)
8852 ("ruby-rspec" ,ruby-rspec)
8853 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
8854 (synopsis "Ruby library to help check the Ruby version")
8855 (description "@code{ruby_version} provides a @code{RubyVersion} module to simplify
8856 checking for the right Ruby version in software.")
8857 (home-page "https://github.com/janlelis/ruby_version")
8858 (license license:expat)))
8859
8860 (define-public ruby-websocket-driver
8861 (package
8862 (name "ruby-websocket-driver")
8863 (version "0.7.1")
8864 (source
8865 (origin
8866 (method url-fetch)
8867 (uri (rubygems-uri "websocket-driver" version))
8868 (sha256
8869 (base32 "1bxamwqldmy98hxs5pqby3andws14hl36ch78g0s81gaz9b91nj2"))))
8870 (build-system ruby-build-system)
8871 (arguments
8872 '(#:tests? #f)) ; no included tests
8873 (propagated-inputs
8874 `(("ruby-websocket-extensions" ,ruby-websocket-extensions)))
8875 (synopsis "WebSocket protocol handler with pluggable I/O")
8876 (description
8877 "@code{websocket-driver} provides a complete implementation of the
8878 WebSocket protocols that can be hooked up to any TCP library")
8879 (home-page "https://github.com/faye/websocket-driver-ruby")
8880 (license license:expat)))
8881
8882 (define-public ruby-websocket-extensions
8883 (package
8884 (name "ruby-websocket-extensions")
8885 (version "0.1.3")
8886 (source
8887 (origin
8888 (method url-fetch)
8889 (uri (rubygems-uri "websocket-extensions" version))
8890 (sha256
8891 (base32
8892 "034sdr7fd34yag5l6y156rkbhiqgmy395m231dwhlpcswhs6d270"))))
8893 (build-system ruby-build-system)
8894 (arguments
8895 '(;; No included tests
8896 #:tests? #f))
8897 (synopsis "Generic extension manager for WebSocket connections")
8898 (description
8899 "@code{websocket-extensions} provides a container for registering
8900 extension plugins.")
8901 (home-page "https://github.com/faye/websocket-extensions-ruby")
8902 (license license:expat)))
8903
8904 (define-public ruby-domain-name
8905 (package
8906 (name "ruby-domain-name")
8907 (version "0.5.20190701")
8908 (source
8909 (origin
8910 (method url-fetch)
8911 (uri (rubygems-uri "domain_name" version))
8912 (sha256
8913 (base32 "0lcqjsmixjp52bnlgzh4lg9ppsk52x9hpwdjd53k8jnbah2602h0"))))
8914 (build-system ruby-build-system)
8915 (arguments
8916 `(#:phases
8917 (modify-phases %standard-phases
8918 (add-before 'check 'fix-versions
8919 (lambda _
8920 ;; Fix NameError that appears to already be fixed upstream.
8921 (substitute* "Rakefile"
8922 (("DomainName::VERSION")
8923 "Bundler::GemHelper.gemspec.version"))
8924 ;; Loosen unnecessarily strict test-unit version specification.
8925 (substitute* "domain_name.gemspec"
8926 (("<test-unit>.freeze, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
8927 #t)))))
8928 (propagated-inputs
8929 `(("ruby-unf" ,ruby-unf)))
8930 (native-inputs
8931 `(("ruby-shoulda" ,ruby-shoulda)
8932 ("bundler" ,bundler)
8933 ("ruby-test-unit" ,ruby-test-unit)))
8934 (synopsis "Domain name manipulation library")
8935 (description
8936 "@code{domain_name} is a Domain name manipulation library. It parses a
8937 domain name ready for extracting the registered domain and TLD (Top Level
8938 Domain). It can also be used for cookie domain validation based on the Public
8939 Suffix List.")
8940 (home-page "https://github.com/knu/ruby-domain_name")
8941 (license license:bsd-2)))
8942
8943 (define-public ruby-http-cookie
8944 (package
8945 (name "ruby-http-cookie")
8946 (version "1.0.3")
8947 (source
8948 (origin
8949 (method url-fetch)
8950 (uri (rubygems-uri "http-cookie" version))
8951 (sha256
8952 (base32
8953 "004cgs4xg5n6byjs7qld0xhsjq3n6ydfh897myr2mibvh6fjc49g"))))
8954 (build-system ruby-build-system)
8955 (arguments
8956 `(#:phases
8957 (modify-phases %standard-phases
8958 (add-before 'check 'add-dependency-to-bundler
8959 (lambda _
8960 ;; Fix NameError
8961 (substitute* "Rakefile"
8962 (("HTTP::Cookie::VERSION")
8963 "Bundler::GemHelper.gemspec.version"))
8964 #t)))))
8965 (propagated-inputs
8966 `(("ruby-domain-name" ,ruby-domain-name)))
8967 (native-inputs
8968 `(("rubysimplecov" ,ruby-simplecov)
8969 ("bundler" ,bundler)
8970 ("ruby-sqlite3" ,ruby-sqlite3)
8971 ("ruby-test-unit" ,ruby-test-unit)))
8972 (synopsis "Handle HTTP Cookies based on RFC 6265")
8973 (description
8974 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
8975 RFC 6265. It has been designed with security, standards compliance and
8976 compatibility in mind, to behave just the same as today's major web browsers.
8977 It has built-in support for the legacy @code{cookies.txt} and
8978 @code{cookies.sqlite} formats of Mozilla Firefox.")
8979 (home-page "https://github.com/sparklemotion/http-cookie")
8980 (license license:expat)))
8981
8982 (define-public ruby-httpclient
8983 (package
8984 (name "ruby-httpclient")
8985 (version "2.8.3")
8986 (source
8987 (origin
8988 (method url-fetch)
8989 (uri (rubygems-uri "httpclient" version))
8990 (sha256
8991 (base32
8992 "19mxmvghp7ki3klsxwrlwr431li7hm1lczhhj8z4qihl2acy8l99"))))
8993 (build-system ruby-build-system)
8994 (arguments
8995 '(;; TODO: Some tests currently fail
8996 ;; ------
8997 ;; 211 tests, 729 assertions, 13 failures, 4 errors, 0 pendings,
8998 ;; 2 omissions, 0 notifications
8999 ;; 91.866% passed
9000 ;; ------
9001 ;; 6.49 tests/s, 22.41 assertions/s
9002 #:tests? #f
9003 #:phases
9004 (modify-phases %standard-phases
9005 (replace 'check
9006 (lambda* (#:key tests? #:allow-other-keys)
9007 (if tests?
9008 (invoke "ruby"
9009 "-Ilib"
9010 "test/runner.rb")
9011 #t))))))
9012 (native-inputs
9013 `(("ruby-rack" ,ruby-rack)))
9014 (synopsis
9015 "Make HTTP requests with support for HTTPS, Cookies, authentication and more")
9016 (description
9017 "The @code{httpclient} ruby library provides functionality related to
9018 HTTP. Compared to the @code{net/http} library, @{httpclient} also provides
9019 Cookie, multithreading and authentication (digest, NTLM) support.
9020
9021 Also provided is a @command{httpclient} command, which can perform HTTP
9022 requests either using arguments or with an interactive prompt.")
9023 (home-page "https://github.com/nahi/httpclient")
9024 (license license:ruby)))
9025
9026 (define-public ruby-ansi
9027 (package
9028 (name "ruby-ansi")
9029 (version "1.5.0")
9030 (source
9031 (origin
9032 (method git-fetch)
9033 ;; Fetch from GitHub as the gem does not contain testing code.
9034 (uri (git-reference
9035 (url "https://github.com/rubyworks/ansi")
9036 (commit version)))
9037 (file-name (git-file-name name version))
9038 (sha256
9039 (base32
9040 "1wsz7xxwl3vkh277jb7fd7akqnqqgbvalxzpjwniiqk8ghfprbi5"))))
9041 (build-system ruby-build-system)
9042 (arguments
9043 `(#:phases
9044 (modify-phases %standard-phases
9045 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
9046 ;; cycle ansi, qed, ansi. Instead simply test that the library can
9047 ;; be require'd.
9048 (replace 'check
9049 (lambda _
9050 (invoke "ruby" "-Ilib" "-r" "ansi")))
9051 (add-before 'validate-runpath 'replace-broken-symlink
9052 (lambda* (#:key outputs #:allow-other-keys)
9053 (let* ((out (assoc-ref outputs "out"))
9054 (file (string-append
9055 out "/lib/ruby/vendor_ruby/gems/ansi-"
9056 ,version "/lib/ansi.yml")))
9057 ;; XXX: This symlink is broken since ruby 2.4.
9058 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9059 (delete-file file)
9060 (symlink "../.index" file)
9061 #t))))))
9062 (synopsis "ANSI escape code related libraries")
9063 (description
9064 "This package is a collection of ANSI escape code related libraries
9065 enabling ANSI colorization and stylization of console output. Included in the
9066 library are the @code{Code} module, which defines ANSI codes as constants and
9067 methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
9068 @code{ProgressBar}, and a @code{String} subclass. The library also includes a
9069 @code{Terminal} module which provides information about the current output
9070 device.")
9071 (home-page "https://rubyworks.github.io/ansi/")
9072 (license license:bsd-2)))
9073
9074 (define-public ruby-systemu
9075 (package
9076 (name "ruby-systemu")
9077 (version "2.6.5")
9078 (source
9079 (origin
9080 (method url-fetch)
9081 (uri (rubygems-uri "systemu" version))
9082 (sha256
9083 (base32
9084 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
9085 (build-system ruby-build-system)
9086 (arguments
9087 `(#:phases
9088 (modify-phases %standard-phases
9089 (add-before 'check 'set-version
9090 (lambda _
9091 (setenv "VERSION" ,version)
9092 #t)))))
9093 (synopsis "Capture of stdout/stderr and handling of child processes")
9094 (description
9095 "Systemu can be used on any platform to return status, stdout, and stderr
9096 of any command. Unlike other methods like @code{open3} and @code{popen4}
9097 there is no danger of full pipes or threading issues hanging your process or
9098 subprocess.")
9099 (home-page "https://github.com/ahoward/systemu")
9100 (license license:ruby)))
9101
9102 (define-public ruby-bio-commandeer
9103 (package
9104 (name "ruby-bio-commandeer")
9105 (version "0.4.0")
9106 (source
9107 (origin
9108 (method url-fetch)
9109 (uri (rubygems-uri "bio-commandeer" version))
9110 (sha256
9111 (base32
9112 "0khpfw1yl5l3d2m8nxpkk32ybc4c3pa5hic3agd160jdfjjjnlni"))))
9113 (build-system ruby-build-system)
9114 (arguments
9115 `(#:phases
9116 (modify-phases %standard-phases
9117 (replace 'check
9118 ;; Run test without calling 'rake' so that jeweler is
9119 ;; not required as an input.
9120 (lambda _
9121 (invoke "rspec" "spec/bio-commandeer_spec.rb"))))))
9122 (propagated-inputs
9123 `(("ruby-bio-logger" ,ruby-bio-logger)
9124 ("ruby-systemu" ,ruby-systemu)))
9125 (native-inputs
9126 `(("bundler" ,bundler)
9127 ("ruby-rspec" ,ruby-rspec)))
9128 (synopsis "Simplified running of shell commands from within Ruby")
9129 (description
9130 "Bio-commandeer provides an opinionated method of running shell commands
9131 from within Ruby. The advantage of bio-commandeer over other methods of
9132 running external commands is that when something goes wrong, messages printed
9133 to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
9134 detail to ease debugging.")
9135 (home-page "https://github.com/wwood/bioruby-commandeer")
9136 (license license:expat)))
9137
9138 (define-public ruby-rubytest
9139 (package
9140 (name "ruby-rubytest")
9141 (version "0.8.1")
9142 (source
9143 (origin
9144 (method url-fetch)
9145 (uri (rubygems-uri "rubytest" version))
9146 (sha256
9147 (base32
9148 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
9149 (build-system ruby-build-system)
9150 (arguments
9151 ;; Disable regular testing to break the cycle rubytest, qed, brass,
9152 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
9153 ;; simply test that the library can be require'd.
9154 `(#:phases
9155 (modify-phases %standard-phases
9156 (replace 'check
9157 (lambda _
9158 (invoke "ruby" "-Ilib" "-r" "rubytest"))))))
9159 (propagated-inputs
9160 `(("ruby-ansi" ,ruby-ansi)))
9161 (synopsis "Universal test harness for Ruby")
9162 (description
9163 "Rubytest is a testing meta-framework for Ruby. It can handle any
9164 compliant test framework and can run tests from multiple frameworks in a
9165 single pass.")
9166 (home-page "https://rubyworks.github.io/rubytest")
9167 (license license:bsd-2)))
9168
9169 (define-public ruby-brass
9170 (package
9171 (name "ruby-brass")
9172 (version "1.2.1")
9173 (source
9174 (origin
9175 (method url-fetch)
9176 (uri (rubygems-uri "brass" version))
9177 (sha256
9178 (base32
9179 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
9180 (build-system ruby-build-system)
9181 (arguments
9182 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
9183 ;; Instead simply test that the library can be require'd.
9184 `(#:phases
9185 (modify-phases %standard-phases
9186 (replace 'check
9187 (lambda _
9188 (invoke "ruby" "-Ilib" "-r" "brass"))))))
9189 (synopsis "Basic foundational assertions framework")
9190 (description
9191 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
9192 foundational assertions framework for other assertion and test frameworks to
9193 make use of.")
9194 (home-page "https://rubyworks.github.io/brass")
9195 (license license:bsd-2)))
9196
9197 (define-public ruby-qed
9198 (package
9199 (name "ruby-qed")
9200 (version "2.9.2")
9201 (source
9202 (origin
9203 (method url-fetch)
9204 (uri (rubygems-uri "qed" version))
9205 (sha256
9206 (base32
9207 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
9208 (build-system ruby-build-system)
9209 (arguments
9210 ;; Disable testing to break the cycle qed, ansi, qed, among others.
9211 ;; Instead simply test that the executable runs using --copyright.
9212 `(#:phases
9213 (modify-phases %standard-phases
9214 (replace 'check
9215 (lambda _
9216 (invoke "ruby" "-Ilib" "bin/qed" "--copyright"))))))
9217 (propagated-inputs
9218 `(("ruby-ansi" ,ruby-ansi)
9219 ("ruby-brass" ,ruby-brass)))
9220 (synopsis "Test framework utilizing literate programming techniques")
9221 (description
9222 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
9223 @dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
9224 Development} (BDD) utilizing Literate Programming techniques. QED sits
9225 somewhere between lower-level testing tools like @code{Test::Unit} and
9226 requirement specifications systems like Cucumber.")
9227 (home-page "https://rubyworks.github.io/qed")
9228 (license license:bsd-2)))
9229
9230 (define-public ruby-que
9231 (package
9232 (name "ruby-que")
9233 (version "1.0.0.beta3")
9234 (source
9235 (origin
9236 (method url-fetch)
9237 (uri (rubygems-uri "que" version))
9238 (sha256
9239 (base32
9240 "0gr9pb814d4qj3ds98g6cjrdk7wv0yg8aqbm7c1lmgl87jkg8q04"))))
9241 (build-system ruby-build-system)
9242 (arguments
9243 '(#:tests? #f)) ; No included tests
9244 (synopsis "Job queue using PostgreSQL written in Ruby")
9245 (description
9246 "This package provides a job queue that uses PostgreSQL for storing jobs
9247 and locking between worker processes.")
9248 (home-page "https://github.com/chanks/que")
9249 (license license:expat)))
9250
9251 (define-public ruby-ae
9252 (package
9253 (name "ruby-ae")
9254 (version "1.8.2")
9255 (source
9256 (origin
9257 (method git-fetch)
9258 ;; Fetch from github so tests are included.
9259 (uri (git-reference
9260 (url "https://github.com/rubyworks/ae")
9261 (commit version)))
9262 (file-name (git-file-name name version))
9263 (sha256
9264 (base32
9265 "11299jj5ma8mi7b4majkyjy70y6zlqpgl8aql1c5lvfjavlpwmlp"))))
9266 (build-system ruby-build-system)
9267 (arguments
9268 `(#:phases
9269 (modify-phases %standard-phases
9270 (replace 'check
9271 (lambda _ (invoke "qed")))
9272 (add-before 'validate-runpath 'replace-broken-symlink
9273 (lambda* (#:key outputs #:allow-other-keys)
9274 (let* ((out (assoc-ref outputs "out"))
9275 (file (string-append
9276 out "/lib/ruby/vendor_ruby/gems/ae-"
9277 ,version "/lib/ae.yml")))
9278 ;; XXX: This symlink is broken since ruby 2.4.
9279 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9280 (delete-file file)
9281 (symlink "../.index" file)
9282 #t))))))
9283 (propagated-inputs
9284 `(("ruby-ansi" ,ruby-ansi)))
9285 (native-inputs
9286 `(("ruby-qed" ,ruby-qed)))
9287 (synopsis "Assertions library")
9288 (description
9289 "Assertive Expressive (AE) is an assertions library specifically designed
9290 for reuse by other test frameworks.")
9291 (home-page "https://rubyworks.github.io/ae/")
9292 (license license:bsd-2)))
9293
9294 (define-public ruby-lemon
9295 (package
9296 (name "ruby-lemon")
9297 (version "0.9.1")
9298 (source
9299 (origin
9300 (method url-fetch)
9301 (uri (rubygems-uri "lemon" version))
9302 (sha256
9303 (base32
9304 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
9305 (build-system ruby-build-system)
9306 (arguments
9307 `(#:phases
9308 (modify-phases %standard-phases
9309 (replace 'check (lambda _ (invoke "qed"))))))
9310 (propagated-inputs
9311 `(("ruby-ae" ,ruby-ae)
9312 ("ruby-ansi" ,ruby-ansi)
9313 ("ruby-rubytest" ,ruby-rubytest)))
9314 (native-inputs
9315 `(("ruby-qed" ,ruby-qed)))
9316 (synopsis "Test framework correlating code structure and test unit")
9317 (description
9318 "Lemon is a unit testing framework that enforces highly formal
9319 case-to-class and unit-to-method test construction. This enforcement can help
9320 focus concern on individual units of behavior.")
9321 (home-page "https://rubyworks.github.io/lemon")
9322 (license license:bsd-2)))
9323
9324 (define-public ruby-rubytest-cli
9325 (package
9326 (name "ruby-rubytest-cli")
9327 (version "0.2.0")
9328 (source
9329 (origin
9330 (method url-fetch)
9331 (uri (rubygems-uri "rubytest-cli" version))
9332 (sha256
9333 (base32
9334 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
9335 (build-system ruby-build-system)
9336 (arguments
9337 `(#:tests? #f)) ; no tests
9338 (propagated-inputs
9339 `(("ruby-ansi" ,ruby-ansi)
9340 ("ruby-rubytest" ,ruby-rubytest)))
9341 (synopsis "Command-line interface for rubytest")
9342 (description
9343 "Rubytest CLI is a command-line interface for running tests for
9344 Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
9345 (home-page "https://rubyworks.github.io/rubytest-cli")
9346 (license license:bsd-2)))
9347
9348 (define-public ruby-hashery
9349 (package
9350 (name "ruby-hashery")
9351 (version "2.1.2")
9352 (source
9353 (origin
9354 (method url-fetch)
9355 (uri (rubygems-uri "hashery" version))
9356 (sha256
9357 (base32
9358 "0qj8815bf7q6q7llm5rzdz279gzmpqmqqicxnzv066a020iwqffj"))))
9359 (build-system ruby-build-system)
9360 (arguments
9361 `(#:phases
9362 (modify-phases %standard-phases
9363 (replace 'check
9364 (lambda _
9365 (invoke "qed")
9366 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
9367 (native-inputs
9368 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
9369 ("ruby-qed" ,ruby-qed)
9370 ("ruby-lemon" ,ruby-lemon)))
9371 (synopsis "Hash-like classes with extra features")
9372 (description
9373 "The Hashery is a tight collection of @code{Hash}-like classes.
9374 Included are the auto-sorting @code{Dictionary} class, the efficient
9375 @code{LRUHash}, the flexible @code{OpenHash} and the convenient
9376 @code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
9377 defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
9378 standard @code{Hash} making it possible to subclass and augment to fit any
9379 specific use case.")
9380 (home-page "https://rubyworks.github.io/hashery")
9381 (license license:bsd-2)))
9382
9383 (define-public ruby-rc4
9384 (package
9385 (name "ruby-rc4")
9386 (version "0.1.5")
9387 (source
9388 (origin
9389 (method url-fetch)
9390 (uri (rubygems-uri "ruby-rc4" version))
9391 (sha256
9392 (base32
9393 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
9394 (build-system ruby-build-system)
9395 (arguments
9396 `(#:phases
9397 (modify-phases %standard-phases
9398 (replace 'check
9399 (lambda _
9400 (invoke "rspec" "spec/rc4_spec.rb"))))))
9401 (native-inputs
9402 `(("ruby-rspec" ,ruby-rspec-2)))
9403 (synopsis "Implementation of the RC4 algorithm")
9404 (description
9405 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
9406 (home-page "https://github.com/caiges/Ruby-RC4")
9407 (license license:expat)))
9408
9409 (define-public ruby-afm
9410 (package
9411 (name "ruby-afm")
9412 (version "0.2.2")
9413 (source
9414 (origin
9415 (method url-fetch)
9416 (uri (rubygems-uri "afm" version))
9417 (sha256
9418 (base32
9419 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
9420 (build-system ruby-build-system)
9421 (native-inputs
9422 `(("bundler" ,bundler)))
9423 (synopsis "Read Adobe Font Metrics (afm) files")
9424 (description
9425 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
9426 files and use the data therein.")
9427 (home-page "https://github.com/halfbyte/afm")
9428 (license license:expat)))
9429
9430 (define-public ruby-ascii85
9431 (package
9432 (name "ruby-ascii85")
9433 (version "1.0.3")
9434 (source
9435 (origin
9436 (method url-fetch)
9437 (uri (rubygems-uri "Ascii85" version))
9438 (sha256
9439 (base32
9440 "0658m37jjjn6drzqg1gk4p6c205mgp7g1jh2d00n4ngghgmz5qvs"))))
9441 (build-system ruby-build-system)
9442 (native-inputs
9443 `(("bundler" ,bundler)))
9444 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
9445 (description
9446 "This library provides methods to encode and decode Ascii85
9447 binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
9448 @dfn{Portable Document Format} (PDF) file formats.")
9449 (home-page "https://github.com/datawraith/ascii85gem")
9450 (license license:expat)))
9451
9452 (define-public ruby-ttfunk
9453 (package
9454 (name "ruby-ttfunk")
9455 (version "1.6.2.1")
9456 (source
9457 (origin
9458 (method git-fetch)
9459 ;; fetch from github as the gem does not contain testing code
9460 (uri (git-reference
9461 (url "https://github.com/prawnpdf/ttfunk")
9462 (commit version)))
9463 (file-name (git-file-name name version))
9464 (sha256
9465 (base32
9466 "0rsf4j6s97wbcnjbvmmh6xrc7imw4g9lrlcvn945wh400lc8r53z"))))
9467 (build-system ruby-build-system)
9468 (arguments
9469 `(#:test-target "spec"
9470 #:phases
9471 (modify-phases %standard-phases
9472 (add-before 'build 'remove-ssh
9473 (lambda _
9474 ;; remove dependency on an ssh key pair that doesn't exist
9475 (substitute* "ttfunk.gemspec"
9476 (("spec.signing_key.*") ""))
9477 #t))
9478 (add-before 'check 'remove-rubocop
9479 (lambda _
9480 ;; remove rubocop as a dependency as not needed for testing
9481 (substitute* "ttfunk.gemspec"
9482 (("spec.add_development_dependency\\('rubocop'.*") ""))
9483 (substitute* "Rakefile"
9484 (("require 'rubocop/rake_task'") "")
9485 (("RuboCop::RakeTask.new") ""))
9486 #t)))))
9487 (native-inputs
9488 `(("ruby-rspec" ,ruby-rspec)
9489 ("ruby-yard" ,ruby-yard)
9490 ("bundler" ,bundler)))
9491 (synopsis "Font metrics parser for the Prawn PDF generator")
9492 (description
9493 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
9494 part of the Prawn PDF generator.")
9495 (home-page "https://github.com/prawnpdf/ttfunk")
9496 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
9497 ;; for details."
9498 (license %prawn-project-licenses)))
9499
9500 (define-public ruby-puma
9501 (package
9502 (name "ruby-puma")
9503 (version "3.9.1")
9504 (source
9505 (origin
9506 (method git-fetch)
9507 ;; Fetch from GitHub because distributed gem does not contain tests.
9508 (uri (git-reference
9509 (url "https://github.com/puma/puma")
9510 (commit (string-append "v" version))))
9511 (file-name (git-file-name name version))
9512 (sha256
9513 (base32
9514 "1kj75k81iik3aj73pkc9ixj9rwf95ipkyma65n28m64dgw02qi1f"))))
9515 (build-system ruby-build-system)
9516 (arguments
9517 `(#:tests? #f ; Tests require an out-dated version of minitest.
9518 #:phases
9519 (modify-phases %standard-phases
9520 (add-before 'build 'fix-gemspec
9521 (lambda _
9522 (substitute* "puma.gemspec"
9523 (("git ls-files") "find * |sort"))
9524 #t)))))
9525 (synopsis "Simple, concurrent HTTP server for Ruby/Rack")
9526 (description
9527 "Puma is a simple, fast, threaded, and highly concurrent HTTP 1.1 server
9528 for Ruby/Rack applications. Puma is intended for use in both development and
9529 production environments. In order to get the best throughput, it is highly
9530 recommended that you use a Ruby implementation with real threads like Rubinius
9531 or JRuby.")
9532 (home-page "https://puma.io/")
9533 (license license:expat)))
9534
9535 (define-public ruby-hoe-git
9536 (package
9537 (name "ruby-hoe-git")
9538 (version "1.6.0")
9539 (source
9540 (origin
9541 (method url-fetch)
9542 (uri (rubygems-uri "hoe-git" version))
9543 (sha256
9544 (base32
9545 "10jmmbjm0lkglwxbn4rpqghgg1ipjxrswm117n50adhmy8yij650"))))
9546 (build-system ruby-build-system)
9547 (propagated-inputs
9548 `(("ruby-hoe" ,ruby-hoe)))
9549 (synopsis "Hoe plugins for tighter Git integration")
9550 (description
9551 "This package provides a set of Hoe plugins for tighter Git integration.
9552 It provides tasks to automate release tagging and pushing and changelog
9553 generation.")
9554 (home-page "https://github.com/jbarnette/hoe-git")
9555 (license license:expat)))
9556
9557 (define-public ruby-sequel
9558 (package
9559 (name "ruby-sequel")
9560 (version "4.49.0")
9561 (source
9562 (origin
9563 (method url-fetch)
9564 (uri (rubygems-uri "sequel" version))
9565 (sha256
9566 (base32
9567 "010p4a60npppvgbyw7pq5xia8aydpgxdlhh3qjm2615kwjsw3fl8"))))
9568 (build-system ruby-build-system)
9569 (arguments
9570 '(#:tests? #f)) ; Avoid dependency loop with ruby-minitest-hooks.
9571 (synopsis "Database toolkit for Ruby")
9572 (description "Sequel provides thread safety, connection pooling and a
9573 concise DSL for constructing SQL queries and table schemas. It includes a
9574 comprehensive ORM layer for mapping records to Ruby objects and handling
9575 associated records.")
9576 (home-page "https://sequel.jeremyevans.net")
9577 (license license:expat)))
9578
9579 (define-public ruby-timecop
9580 (package
9581 (name "ruby-timecop")
9582 (version "0.9.1")
9583 (source
9584 (origin
9585 (method url-fetch)
9586 (uri (rubygems-uri "timecop" version))
9587 (sha256
9588 (base32
9589 "0d7mm786180v4kzvn1f77rhfppsg5n0sq2bdx63x9nv114zm8jrp"))))
9590 (build-system ruby-build-system)
9591 (arguments
9592 `(#:phases
9593 (modify-phases %standard-phases
9594 (add-before 'check 'set-check-rubylib
9595 (lambda _
9596 ;; Set RUBYLIB so timecop tests finds its own lib.
9597 (setenv "RUBYLIB" "lib")
9598 #t)))))
9599 (native-inputs
9600 `(("bundler" ,bundler)
9601 ("ruby-minitest-rg" ,ruby-minitest-rg)
9602 ("ruby-mocha" ,ruby-mocha)
9603 ("ruby-activesupport" ,ruby-activesupport)))
9604 (synopsis "Test mocks for time-dependent functions")
9605 (description
9606 "Timecop provides \"time travel\" and \"time freezing\" capabilities,
9607 making it easier to test time-dependent code. It provides a unified method to
9608 mock @code{Time.now}, @code{Date.today}, and @code{DateTime.now} in a single
9609 call.")
9610 (home-page "https://github.com/travisjeffery/timecop")
9611 (license license:expat)))
9612
9613 (define-public ruby-concurrent
9614 (package
9615 (name "ruby-concurrent")
9616 (version "1.1.5")
9617 (source
9618 (origin
9619 (method git-fetch)
9620 ;; Download from GitHub because the rubygems version does not contain
9621 ;; Rakefile.
9622 (uri (git-reference
9623 (url "https://github.com/ruby-concurrency/concurrent-ruby")
9624 (commit (string-append "v" version))))
9625 (file-name (git-file-name name version))
9626 (sha256
9627 (base32
9628 "193q2k47vk7qdvv9hlhmmdxgy91xl4imapyk1ijdg9vgf46knyzj"))))
9629 (build-system ruby-build-system)
9630 (arguments
9631 `(#:test-target "ci"
9632 #:phases
9633 (modify-phases %standard-phases
9634 (add-before 'replace-git-ls-files 'remove-extra-gemspecs
9635 (lambda _
9636 ;; Delete extra gemspec files so 'first-gemspec' chooses the
9637 ;; correct one.
9638 (delete-file "concurrent-ruby-edge.gemspec")
9639 (delete-file "concurrent-ruby-ext.gemspec")
9640 #t))
9641 (replace 'replace-git-ls-files
9642 (lambda _
9643 ;; XXX: The default substitution made by this phase is not fully
9644 ;; compatible with "git ls-files". The latter produces file names
9645 ;; such as "lib/foo", whereas ruby-build-system uses "find . [...]"
9646 ;; which gives "./lib/foo". That difference in turn breaks the
9647 ;; comparison against a glob pattern in this script.
9648 (substitute* "concurrent-ruby.gemspec"
9649 (("git ls-files") "find * -type f | sort"))
9650 #t))
9651 (add-before 'build 'remove-jar-from-gemspec
9652 (lambda _
9653 ;; The gemspec wants to include a JAR file that we do not build
9654 ;; nor need.
9655 (substitute* "concurrent-ruby.gemspec"
9656 (("'lib/concurrent/concurrent_ruby.jar'")
9657 ""))
9658 #t))
9659 (add-before 'build 'remove-rake_compiler_dock-dependency
9660 (lambda _
9661 ;; This library is only used when building for non-MRI targets.
9662 (substitute* "Rakefile"
9663 (("require 'rake_compiler_dock'")
9664 ""))
9665 #t))
9666 (add-before 'check 'remove-timecop-dependency
9667 ;; Remove timecop-dependent tests as having timecop as a depedency
9668 ;; causes circular depedencies.
9669 (lambda _
9670 (delete-file "spec/concurrent/executor/timer_set_spec.rb")
9671 (delete-file "spec/concurrent/scheduled_task_spec.rb")
9672 #t)))))
9673 (native-inputs
9674 `(("ruby-rake-compiler" ,ruby-rake-compiler)
9675 ("ruby-rspec" ,ruby-rspec)))
9676 (synopsis "Concurrency tools for Ruby")
9677 (description
9678 "This library provides modern concurrency tools including agents,
9679 futures, promises, thread pools, actors, supervisors, and more. It is
9680 inspired by Erlang, Clojure, Go, JavaScript, actors and classic concurrency
9681 patterns.")
9682 (home-page "http://www.concurrent-ruby.com")
9683 (license license:expat)))
9684
9685 (define-public ruby-pkg-config
9686 (package
9687 (name "ruby-pkg-config")
9688 (version "1.2.5")
9689 (source
9690 (origin
9691 (method url-fetch)
9692 (uri (rubygems-uri "pkg-config" version))
9693 (sha256
9694 (base32
9695 "056mzqdh4yjznsg36fi0xiq76f24vxlhzh2n4az919l3x5k318ar"))))
9696 (build-system ruby-build-system)
9697 (arguments
9698 ;; Tests require extra files not included in the gem.
9699 `(#:tests? #f))
9700 (synopsis "Detect libraries for compiling Ruby native extensions")
9701 (description
9702 "@code{pkg-config} can be used in your extconf.rb to properly detect need
9703 libraries for compiling Ruby native extensions.")
9704 (home-page "https://github.com/ruby-gnome2/pkg-config")
9705 (license license:lgpl2.0+)))
9706
9707 (define-public ruby-net-http-digest-auth
9708 (package
9709 (name "ruby-net-http-digest-auth")
9710 (version "1.4.1")
9711 (source
9712 (origin
9713 (method url-fetch)
9714 (uri (rubygems-uri "net-http-digest_auth" version))
9715 (sha256
9716 (base32
9717 "1nq859b0gh2vjhvl1qh1zrk09pc7p54r9i6nnn6sb06iv07db2jb"))))
9718 (build-system ruby-build-system)
9719 (native-inputs
9720 `(("ruby-hoe" ,ruby-hoe)))
9721 (synopsis "RFC 2617 HTTP digest authentication library")
9722 (description
9723 "This library implements HTTP's digest authentication scheme based on
9724 RFC 2617. This enables the use of the digest authentication scheme instead
9725 of the more insecure basic authentication scheme.")
9726 (home-page "https://github.com/drbrain/net-http-digest_auth")
9727 (license license:expat)))
9728
9729 (define-public ruby-mail
9730 (package
9731 (name "ruby-mail")
9732 (version "2.6.6")
9733 (source
9734 (origin
9735 (method url-fetch)
9736 (uri (rubygems-uri "mail" version))
9737 (sha256
9738 (base32
9739 "0d7lhj2dw52ycls6xigkfz6zvfhc6qggply9iycjmcyj9760yvz9"))))
9740 (build-system ruby-build-system)
9741 (propagated-inputs
9742 `(("ruby-mime-types" ,ruby-mime-types)))
9743 (arguments
9744 ;; Tests require extra gems not included in the Gemfile.
9745 ;; XXX: Try enabling this for the next version with mini_mime.
9746 `(#:tests? #f))
9747 (synopsis "Mail library for Ruby")
9748 (description
9749 "Mail is an internet library for Ruby that is designed to handle email
9750 generation, parsing and sending. The purpose of this library is to provide
9751 a single point of access to handle all email functions, including sending
9752 and receiving emails. All network type actions are done through proxy
9753 methods to @code{Net::SMTP}, @code{Net::POP3} etc.
9754
9755 Mail has been designed with a very simple object oriented system that
9756 really opens up the email messages you are parsing, if you know what you
9757 are doing, you can fiddle with every last bit of your email directly.")
9758 (home-page "https://github.com/mikel/mail")
9759 (license license:expat)))
9760
9761 (define-public ruby-mathn
9762 (package
9763 (name "ruby-mathn")
9764 (version "0.1.0")
9765 (source
9766 (origin
9767 (method url-fetch)
9768 (uri (rubygems-uri "mathn" version))
9769 (sha256
9770 (base32
9771 "1wn812llln9jzgybz2d7536q39z3gi99i6fi0j1dapcpzvhgrr0p"))))
9772 (build-system ruby-build-system)
9773 (native-inputs
9774 `(("bundler" ,bundler)
9775 ("ruby-rake-compiler" ,ruby-rake-compiler)))
9776 (synopsis "Extends math operations for increased precision")
9777 (description
9778 "This gem makes mathematical operations more precise in Ruby and
9779 integrates other mathematical standard libraries. Prior to Ruby 2.5,
9780 @code{mathn} was part of the Ruby standard library.")
9781 (home-page "https://github.com/ruby/mathn")
9782 (license license:bsd-2)))
9783
9784 (define-public ruby-code-statistics
9785 (package
9786 (name "ruby-code-statistics")
9787 (version "0.2.13")
9788 (source
9789 (origin
9790 (method url-fetch)
9791 (uri (rubygems-uri "code_statistics" version))
9792 (sha256
9793 (base32
9794 "07rdpsbwbmh4vp8nxyh308cj7am2pbrfhv9v5xr2d5gq8hnnsm93"))))
9795 (build-system ruby-build-system)
9796 (arguments
9797 `(#:tests? #f)) ; Not all test code is included in gem.
9798 (synopsis "Port of the rails 'rake stats' method")
9799 (description
9800 "This gem is a port of the rails 'rake stats' method so it can be made
9801 more robust and work for non rails projects.")
9802 (home-page "https://github.com/danmayer/code_statistics")
9803 (license license:expat)))
9804
9805 (define-public ruby-rubypants
9806 (package
9807 (name "ruby-rubypants")
9808 (version "0.6.0")
9809 (source (origin
9810 (method url-fetch)
9811 (uri (rubygems-uri "rubypants" version))
9812 (sha256
9813 (base32
9814 "0xpqkslan2wkyal2h9qhplkr5d4sdn7q6csigrhnljjpp8j4qfsh"))))
9815 (build-system ruby-build-system)
9816 (arguments
9817 '(#:tests? #f)) ; need Codecov
9818 (synopsis "Port of the smart-quotes library SmartyPants")
9819 (description
9820 "RubyPants is a Ruby port of the smart-quotes library SmartyPants. The
9821 original SmartyPants is a web publishing plug-in for Movable Type, Blosxom,
9822 and BBEdit that easily translates plain ASCII punctuation characters into
9823 smart typographic punctuation HTML entities.")
9824 (home-page "https://github.com/jmcnevin/rubypants")
9825 (license license:bsd-2)))
9826
9827 (define-public ruby-org-ruby
9828 (package
9829 (name "ruby-org-ruby")
9830 (version "0.9.12")
9831 (source (origin
9832 (method url-fetch)
9833 (uri (rubygems-uri "org-ruby" version))
9834 (sha256
9835 (base32
9836 "0x69s7aysfiwlcpd9hkvksfyld34d8kxr62adb59vjvh8hxfrjwk"))))
9837 (build-system ruby-build-system)
9838 (arguments
9839 '(#:tests? #f)) ; no rakefile
9840 (propagated-inputs
9841 `(("ruby-rubypants" ,ruby-rubypants)))
9842 (synopsis "Org-mode parser written in Ruby")
9843 (description
9844 "Org-ruby is an org-mode parser written in Ruby. The most significant
9845 thing this library does today is convert org-mode files to HTML or Textile or
9846 Markdown.")
9847 (home-page "https://github.com/wallyqs/org-ruby")
9848 (license license:expat)))
9849
9850 (define-public ruby-rake
9851 (package
9852 (name "ruby-rake")
9853 (version "13.0.1")
9854 (source
9855 (origin
9856 (method url-fetch)
9857 (uri (rubygems-uri "rake" version))
9858 (sha256
9859 (base32
9860 "0w6qza25bq1s825faaglkx1k6d59aiyjjk3yw3ip5sb463mhhai9"))))
9861 (build-system ruby-build-system)
9862 (native-inputs
9863 `(("bundler" ,bundler)))
9864 (synopsis "Rake is a Make-like program implemented in Ruby")
9865 (description
9866 "Rake is a Make-like program where tasks and dependencies are specified
9867 in standard Ruby syntax.")
9868 (home-page "https://github.com/ruby/rake")
9869 (license license:expat)))
9870
9871 (define-public ruby-childprocess
9872 (package
9873 (name "ruby-childprocess")
9874 (version "3.0.0")
9875 (source
9876 (origin
9877 (method url-fetch)
9878 (uri (rubygems-uri "childprocess" version))
9879 (sha256
9880 (base32
9881 "1ic028k8xgm2dds9mqnvwwx3ibaz32j8455zxr9f4bcnviyahya5"))))
9882 (build-system ruby-build-system)
9883 (arguments
9884 `(#:tests? #f))
9885 (native-inputs
9886 `(("bundler" ,bundler)
9887 ("ruby-rspec" ,ruby-rspec)))
9888 (propagated-inputs
9889 `(("ruby-ffi" ,ruby-ffi)))
9890 (synopsis "Control external programs running in the background, in Ruby")
9891 (description "@code{childprocess} provides a gem to control external
9892 programs running in the background, in Ruby.")
9893 (home-page "https://github.com/enkessler/childprocess")
9894 (license license:expat)))
9895
9896 (define-public ruby-public-suffix
9897 (package
9898 (name "ruby-public-suffix")
9899 (version "4.0.5")
9900 (source (origin
9901 (method url-fetch)
9902 (uri (rubygems-uri "public_suffix" version))
9903 (sha256
9904 (base32
9905 "0vywld400fzi17cszwrchrzcqys4qm6sshbv73wy5mwcixmrgg7g"))))
9906 (build-system ruby-build-system)
9907 (arguments
9908 '(#:phases
9909 (modify-phases %standard-phases
9910 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
9911 ;; including it as an input can lead to circular dependencies.
9912 (add-after 'unpack 'remove-rubocop-from-Rakefile
9913 (lambda _
9914 (substitute* "Rakefile"
9915 (("require \"rubocop/rake\\_task\"") "")
9916 (("RuboCop::RakeTask\\.new") ""))
9917 #t)))))
9918 (native-inputs
9919 `(("bundler" ,bundler)
9920 ("ruby-yard" ,ruby-yard)
9921 ("ruby-mocha" ,ruby-mocha)
9922 ("ruby-minitest-reporters" ,ruby-minitest-reporters)))
9923 (home-page "https://simonecarletti.com/code/publicsuffix-ruby/")
9924 (synopsis "Domain name parser")
9925 (description "The gem @code{public_suffix} is a domain name parser,
9926 written in Ruby, and based on the @dfn{Public Suffix List}. A public suffix
9927 is one under which Internet users can (or historically could) directly
9928 register names. Some examples of public suffixes are @code{.com},
9929 @code{.co.uk} and @code{pvt.k12.ma.us}. The Public Suffix List is a list of
9930 all known public suffixes.")
9931 (license license:expat)))
9932
9933 (define-public ruby-addressable
9934 (package
9935 (name "ruby-addressable")
9936 (version "2.7.0")
9937 (source (origin
9938 (method url-fetch)
9939 (uri (rubygems-uri "addressable" version))
9940 (sha256
9941 (base32
9942 "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy"))))
9943 (build-system ruby-build-system)
9944 (arguments
9945 '(#:test-target "spec"
9946 #:phases
9947 (modify-phases %standard-phases
9948 (add-after 'unpack 'remove-unnecessary-dependencies-from-Gemfile
9949 (lambda _
9950 (substitute* "Gemfile"
9951 (("git: 'https://github.com/sporkmonger/rack-mount.git',") "")
9952 ((".*launchy.*") "")
9953 ((".*rake.*") "gem 'rake'\n")
9954 ((".*redcarpet.*") ""))
9955 #t))
9956 (add-before 'check 'delete-network-dependent-test
9957 (lambda _
9958 (delete-file "spec/addressable/net_http_compat_spec.rb")
9959 #t)))))
9960 (native-inputs
9961 `(("ruby-rspec" ,ruby-rspec)
9962 ("bundler" ,bundler)
9963 ("ruby-idn-ruby" ,ruby-idn-ruby)
9964 ("ruby-sporkmonger-rack-mount" ,ruby-sporkmonger-rack-mount)
9965 ("ruby-rspec-its" ,ruby-rspec-its-minimal)
9966 ("ruby-yard" ,ruby-yard)
9967 ("ruby-simplecov" ,ruby-simplecov)))
9968 (propagated-inputs
9969 `(("ruby-public-suffix" ,ruby-public-suffix)))
9970 (home-page "https://github.com/sporkmonger/addressable")
9971 (synopsis "Alternative URI implementation")
9972 (description "Addressable is a replacement for the URI implementation that
9973 is part of Ruby's standard library. It more closely conforms to RFC 3986,
9974 RFC 3987, and RFC 6570 (level 4), providing support for IRIs and URI templates.")
9975 (license license:asl2.0)))
9976
9977 (define-public ruby-colorize
9978 (package
9979 (name "ruby-colorize")
9980 (version "0.8.1")
9981 (source (origin
9982 (method url-fetch)
9983 (uri (rubygems-uri "colorize" version))
9984 (sha256
9985 (base32
9986 "133rqj85n400qk6g3dhf2bmfws34mak1wqihvh3bgy9jhajw580b"))))
9987 (build-system ruby-build-system)
9988 (arguments
9989 '(#:phases (modify-phases %standard-phases
9990 (add-before 'check 'remove-codeclimate-dependency
9991 (lambda _
9992 (substitute* "test/test_colorize.rb"
9993 ;; Do not hook the tests into the online CodeClimate
9994 ;; service which is unnecessary for these tests.
9995 (("require 'codeclimate-test-reporter'")
9996 "")
9997 (("CodeClimate.*") ""))
9998 #t)))))
9999 (synopsis "Add color effects to the @code{String} class")
10000 (description
10001 "This package extends the @code{String} class and adds a
10002 @code{ColorizedString} with methods to set text color, background color,
10003 and text effects.")
10004 (home-page "https://github.com/fazibear/colorize")
10005 (license license:gpl2+)))
10006
10007 (define-public ruby-colorator
10008 (package
10009 (name "ruby-colorator")
10010 (version "1.1.0")
10011 (source (origin
10012 (method url-fetch)
10013 (uri (rubygems-uri "colorator" version))
10014 (sha256
10015 (base32
10016 "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"))))
10017 (build-system ruby-build-system)
10018 (arguments
10019 ;; No test target
10020 `(#:tests? #f))
10021 (home-page "http://octopress.org/colorator/")
10022 (synopsis "Terminal color library")
10023 (description "Colorator is a Ruby gem that helps you colorize your text
10024 for the terminal.")
10025 (license license:expat)))
10026
10027 (define-public ruby-command-line-reporter
10028 (package
10029 (name "ruby-command-line-reporter")
10030 (version "4.0.1")
10031 (source (origin
10032 (method url-fetch)
10033 (uri (rubygems-uri "command_line_reporter" version))
10034 (sha256
10035 (base32
10036 "1l0zxkh5n9dxfw46lpkg416ljpldlq1bgdhqh0d118dk338nz4ll"))))
10037 (build-system ruby-build-system)
10038 (arguments
10039 ;; No Rakefile
10040 `(#:tests? #f
10041 #:phases
10042 (modify-phases %standard-phases
10043 (add-before 'build 'fix-dependencies
10044 (lambda _
10045 (substitute* ".gemspec"
10046 ;; colored is unmaintained
10047 (("colored") "colorator")
10048 ;; colorator version
10049 (("= 1.2") "= 1.1"))
10050 #t)))))
10051 (propagated-inputs `(("ruby-colorator" ,ruby-colorator)))
10052 (home-page "https://github.com/wbailey/command_line_reporter")
10053 (synopsis "Report production while executing Ruby scripts")
10054 (description "This gem provides a DSL that makes it easy to write reports
10055 of various types in ruby. It eliminates the need to litter your source with
10056 puts statements, instead providing a more readable, expressive interface to
10057 your application.")
10058 (license license:asl2.0)))
10059
10060 (define-public ruby-command-line-reporter-3
10061 (package
10062 (inherit ruby-command-line-reporter)
10063 (version "3.3.6")
10064 (source (origin
10065 (method url-fetch)
10066 (uri (rubygems-uri "command_line_reporter" version))
10067 (sha256
10068 (base32
10069 "1h39zqqxp3k4qk49ajpx0jps1vmvxgkh43mqkb6znk583bl0fv71"))))))
10070
10071 (define-public ruby-kpeg
10072 (package
10073 (name "ruby-kpeg")
10074 (version "1.1.0")
10075 (source
10076 (origin
10077 (method url-fetch)
10078 (uri (rubygems-uri "kpeg" version))
10079 (sha256
10080 (base32
10081 "0x2kpfrcagj931masm5y1kwbnc6nxl60cqdcd3lyd1d2hz7kzlia"))))
10082 (build-system ruby-build-system)
10083 (native-inputs
10084 `(("ruby-hoe" ,ruby-hoe)))
10085 (synopsis "PEG library for Ruby")
10086 (description "KPeg is a simple PEG library for Ruby. It provides an API as
10087 well as native grammar to build the grammar. KPeg supports direct left
10088 recursion of rules via the
10089 @uref{http://www.vpri.org/pdf/tr2008003_experimenting.pdf,OMeta memoization}
10090 technique.")
10091 (home-page "https://github.com/evanphx/kpeg")
10092 (license license:expat)))
10093
10094 (define-public ruby-rdoc
10095 (package
10096 (name "ruby-rdoc")
10097 (version "6.2.0")
10098 (source
10099 (origin
10100 (method git-fetch)
10101 (uri (git-reference
10102 (url "https://github.com/ruby/rdoc")
10103 (commit (string-append "v" version))))
10104 (file-name (git-file-name name version))
10105 (sha256
10106 (base32
10107 "0dhk29nidv93b5vnjvlm9gcixgn4i0jcyzrgxdk6pdg019bw4cj6"))))
10108 (build-system ruby-build-system)
10109 (arguments
10110 `(#:phases
10111 (modify-phases %standard-phases
10112 (add-after 'unpack 'patch-gemspec
10113 ;; TODO: Remove after next release is tagged.
10114 (lambda _
10115 (substitute* "rdoc.gemspec"
10116 (("\"lib/rdoc/generator/template/darkfish/js/\
10117 jquery\\.js\", ") ""))
10118 #t))
10119 (add-before 'build 'generate
10120 ;; 'gem build' doesn't honor Rakefile dependencies (see:
10121 ;; https://github.com/ruby/rdoc/issues/432#issuecomment-650808977).
10122 (lambda _
10123 (invoke "rake" "generate"))))))
10124 (native-inputs
10125 `(("bundler" ,bundler)
10126 ("ruby-kpeg" ,ruby-kpeg)
10127 ("ruby-racc" ,ruby-racc)
10128 ("ruby-rubocop" ,ruby-rubocop)))
10129 (home-page "https://ruby.github.io/rdoc/")
10130 (synopsis "HTML and command-line documentation utility")
10131 (description "RDoc produces HTML and command-line documentation for Ruby
10132 projects. RDoc includes the +rdoc+ and +ri+ tools for generating and displaying
10133 documentation from the command-line.")
10134 (license license:gpl2+)))
10135
10136 (define-public ruby-sass-listen
10137 (package
10138 (name "ruby-sass-listen")
10139 (version "4.0.0")
10140 (source (origin
10141 (method url-fetch)
10142 (uri (rubygems-uri "sass-listen" version))
10143 (sha256
10144 (base32
10145 "0xw3q46cmahkgyldid5hwyiwacp590zj2vmswlll68ryvmvcp7df"))))
10146 (build-system ruby-build-system)
10147 (arguments
10148 ;; No test target
10149 `(#:tests? #f))
10150 (propagated-inputs
10151 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
10152 ("ruby-rb-inotify" ,ruby-rb-inotify)))
10153 (home-page "https://github.com/sass/listen")
10154 (synopsis "File modification notification library")
10155 (description "The Listen gem listens to file modifications and notifies you
10156 about the changes.")
10157 (license license:expat)))
10158
10159 (define-public ruby-terminfo
10160 (package
10161 (name "ruby-terminfo")
10162 (version "0.1.1")
10163 (source
10164 (origin
10165 (method url-fetch)
10166 (uri (rubygems-uri "ruby-terminfo" version))
10167 (sha256
10168 (base32
10169 "0rl4ic5pzvrpgd42z0c1s2n3j39c9znksblxxvmhkzrc0ckyg2cm"))))
10170 (build-system ruby-build-system)
10171 (arguments
10172 `(#:test-target "test"
10173 ;; Rakefile requires old packages and would need modification to
10174 ;; work with current software.
10175 #:tests? #f))
10176 (inputs
10177 `(("ncurses" ,ncurses)))
10178 (native-inputs
10179 `(("ruby-rubygems-tasks" ,ruby-rubygems-tasks)
10180 ("ruby-rdoc" ,ruby-rdoc)))
10181 (home-page "http://www.a-k-r.org/ruby-terminfo/")
10182 (synopsis "Terminfo binding for Ruby")
10183 (description "Ruby-terminfo provides terminfo binding for Ruby.")
10184 (license license:bsd-3)))
10185
10186 (define-public ruby-diffy
10187 (package
10188 (name "ruby-diffy")
10189 (version "3.2.1")
10190 (source
10191 (origin
10192 (method url-fetch)
10193 (uri (rubygems-uri "diffy" version))
10194 (sha256
10195 (base32
10196 "119imrkn01agwhx5raxhknsi331y5i4yda7r0ws0an6905ximzjg"))))
10197 (build-system ruby-build-system)
10198 (arguments
10199 ;; No tests
10200 `(#:tests? #f))
10201 (native-inputs
10202 `(("ruby-rspec" ,ruby-rspec)))
10203 (home-page "https://github.com/samg/diffy")
10204 (synopsis "Convenient diffing in ruby")
10205 (description "Diffy provides a convenient way to generate a diff from two
10206 strings or files.")
10207 (license license:expat)))
10208
10209 (define-public ruby-sass-spec
10210 (package
10211 (name "ruby-sass-spec")
10212 (version "3.5.4")
10213 (source
10214 (origin
10215 (method git-fetch)
10216 (uri (git-reference
10217 (url "https://github.com/sass/sass-spec")
10218 (commit (string-append "v" version))))
10219 (file-name (git-file-name name version))
10220 (sha256
10221 (base32 "1zsw66830w0xlc7kxz6fm4b5nyb44vdsdgm9mgy06s5aixx83pwr"))))
10222 (build-system ruby-build-system)
10223 (propagated-inputs
10224 `(("ruby-command-line-reporter-3" ,ruby-command-line-reporter-3)
10225 ("ruby-diffy" ,ruby-diffy)
10226 ("ruby-terminfo" ,ruby-terminfo)))
10227 (arguments
10228 `(;; This package contains tests for a sass implementation, and the to
10229 ;; avoid any circular dependencies, the tests are not run here
10230 #:tests? #f
10231 #:phases
10232 (modify-phases %standard-phases
10233 (add-after 'unpack 'patch-test
10234 (lambda _
10235 (delete-file "spec/values/colors/alpha_hex-3.5/error")
10236 (substitute* "spec/values/colors/alpha_hex-3.5/expected_output.css"
10237 (("string") "color")))))))
10238 (home-page "https://github.com/sass/sass-spec")
10239 (synopsis "Test suite for Sass")
10240 (description "Sass Spec is a test suite for Sass. Test cases are all in
10241 the @file{spec} directory.")
10242 (license license:expat)))
10243
10244 (define-public ruby-sass
10245 (package
10246 (name "ruby-sass")
10247 (version "3.6.0")
10248 (source (origin
10249 (method url-fetch)
10250 (uri (rubygems-uri "sass" version))
10251 (sha256
10252 (base32
10253 "18c6prbw9wl8bqhb2435pd9s0lzarl3g7xf8pmyla28zblvwxmyh"))))
10254 (build-system ruby-build-system)
10255 (propagated-inputs
10256 `(("ruby-sass-listen" ,ruby-sass-listen)))
10257 (native-inputs
10258 `(("ruby-sass-spec" ,ruby-sass-spec)
10259 ("ruby-mathn" ,ruby-mathn)))
10260 (home-page "https://sass-lang.com/")
10261 (synopsis "CSS extension language")
10262 (description "Sass is a CSS extension language. It extends CSS with
10263 features that don't exist yet like variables, nesting, mixins and inheritance.")
10264 (license license:expat)))
10265
10266 (define-public ruby-sassc
10267 (package
10268 (name "ruby-sassc")
10269 (version "2.2.1")
10270 (source
10271 (origin
10272 (method url-fetch)
10273 (uri (rubygems-uri "sassc" version))
10274 (sha256
10275 (base32
10276 "09bnid7r5z5hcin5hykvpvv8xig27wbbckxwis60z2aaxq4j9siz"))))
10277 (build-system ruby-build-system)
10278 (arguments
10279 '(#:modules ((guix build ruby-build-system)
10280 (guix build utils)
10281 (ice-9 textual-ports))
10282 #:phases
10283 (modify-phases %standard-phases
10284 ;; TODO: This would be better as a snippet, but the ruby-build-system
10285 ;; doesn't seem to support that
10286 (add-after 'unpack 'remove-libsass
10287 (lambda _
10288 (delete-file-recursively "ext")
10289 (with-atomic-file-replacement "sassc.gemspec"
10290 (lambda (in out)
10291 (let* ((gemspec (get-string-all in))
10292 (index (string-contains gemspec "libsass_dir")))
10293 (display (string-append
10294 (string-take gemspec index)
10295 "\nend\n")
10296 out))))
10297 #t))
10298 (add-after 'unpack 'dont-check-the-libsass-version
10299 (lambda _
10300 (substitute* "test/native_test.rb"
10301 (("assert_equal.*Native\\.version") ""))
10302 #t))
10303 (add-after 'unpack 'remove-git-from-gemspec
10304 (lambda _
10305 (substitute* "sassc.gemspec"
10306 (("`git ls-files -z`") "`find . -type f -print0 |sort -z`"))
10307 #t))
10308 (add-after 'unpack 'remove-extensions-from-gemspec
10309 (lambda _
10310 (substitute* "sassc.gemspec"
10311 (("\\[\"ext/extconf.rb\"\\]") "[]"))
10312 #t))
10313 (add-after 'unpack 'fix-Rakefile
10314 (lambda _
10315 (substitute* "Rakefile"
10316 (("test: 'compile:libsass'") ":test"))
10317 #t))
10318 (add-after 'unpack 'remove-unnecessary-dependencies
10319 (lambda _
10320 (substitute* "test/test_helper.rb"
10321 (("require \"pry\"") ""))
10322 #t))
10323 (add-before 'build 'patch-native.rb
10324 (lambda* (#:key inputs #:allow-other-keys)
10325 (substitute* "lib/sassc/native.rb"
10326 ((".*gem_root = spec.gem_dir") "")
10327 (("ffi_lib .*\n")
10328 (string-append
10329 "ffi_lib '" (assoc-ref inputs "libsass") "/lib/libsass.so'")))
10330 #t))
10331 ;; The gemspec still references the libsass files, so just keep the
10332 ;; one in the gem.
10333 (delete 'extract-gemspec))))
10334 (propagated-inputs
10335 `(("ruby-ffi" ,ruby-ffi)
10336 ("ruby-rake" ,ruby-rake)))
10337 (inputs
10338 `(("libsass" ,libsass)))
10339 (native-inputs
10340 `(("bundler" ,bundler)
10341 ("ruby-rake-compiler" ,ruby-rake-compiler)
10342 ("ruby-minitest-around" ,ruby-minitest-around)
10343 ("ruby-test-construct" ,ruby-test-construct)))
10344 (synopsis "Use libsss from Ruby")
10345 (description
10346 "This library provides Ruby q@acronym{FFI, Foreign Function Interface}
10347 bindings to the libsass library. This enables rendering
10348 @acronym{SASS,Syntactically awesome style sheets} from Ruby code.")
10349 (home-page "https://github.com/sass/sassc-ruby")
10350 (license license:expat)))
10351
10352 (define-public ruby-jekyll-sass-converter
10353 (package
10354 (name "ruby-jekyll-sass-converter")
10355 (version "1.5.2")
10356 (source (origin
10357 (method url-fetch)
10358 (uri (rubygems-uri "jekyll-sass-converter" version))
10359 (sha256
10360 (base32
10361 "008ikh5fk0n6ri54mylcl8jn0mq8p2nfyfqif2q3pp0lwilkcxsk"))))
10362 (build-system ruby-build-system)
10363 (propagated-inputs
10364 `(("ruby-sass" ,ruby-sass)))
10365 (arguments
10366 ;; No rakefile
10367 `(#:tests? #f))
10368 (home-page "https://github.com/jekyll/jekyll-sass-converter")
10369 (synopsis "Sass converter for Jekyll")
10370 (description "This gem provide built-in support for the Sass converter
10371 in Jekyll.")
10372 (license license:expat)))
10373
10374 (define-public ruby-jekyll-watch
10375 (package
10376 (name "ruby-jekyll-watch")
10377 (version "2.1.2")
10378 (source (origin
10379 (method url-fetch)
10380 (uri (rubygems-uri "jekyll-watch" version))
10381 (sha256
10382 (base32
10383 "1s9ly83sp8albvgdff12xy2h4xd8lm6z2fah4lzmk2yvp85jzdzv"))))
10384 (build-system ruby-build-system)
10385 (propagated-inputs
10386 `(("ruby-listen" ,ruby-listen)))
10387 (arguments
10388 ;; No rakefile
10389 `(#:tests? #f))
10390 (home-page "https://github.com/jekyll/jekyll-watch")
10391 (synopsis "Jekyll auto-rebuild support")
10392 (description "This gems add the @code{--watch} switch to the jekyll CLI
10393 interface. It allows Jekyll to rebuild your site when a file changes.")
10394 (license license:expat)))
10395
10396 (define-public ruby-parallel
10397 (package
10398 (name "ruby-parallel")
10399 (version "1.13.0")
10400 (source
10401 (origin
10402 (method git-fetch)
10403 (uri (git-reference
10404 (url "https://github.com/grosser/parallel")
10405 (commit (string-append "v" version))))
10406 (file-name (git-file-name name version))
10407 (sha256
10408 (base32
10409 "1isqzbqxz2ndad4i5z3lb9ldrhaijfncj8bmffv04sq44sv87ikv"))))
10410 (build-system ruby-build-system)
10411 (arguments
10412 `(;; TODO 3 test failures
10413 ;; rspec ./spec/parallel_spec.rb:190 # Parallel.in_processes does not
10414 ;; open unnecessary pipes
10415 ;; rspec './spec/parallel_spec.rb[1:9:7]' # Parallel.each works with
10416 ;; SQLite in processes
10417 ;; rspec './spec/parallel_spec.rb[1:9:16]' # Parallel.each works with
10418 ;; SQLite in threads
10419 #:tests? #f
10420 #:test-target "rspec-rerun:spec"
10421 #:phases
10422 (modify-phases %standard-phases
10423 (add-after 'unpack 'patch-Gemfile
10424 (lambda _
10425 (substitute* "Gemfile"
10426 (("gem 'rspec-legacy_formatters'") "")
10427 (("gem 'activerecord.*$") "gem 'activerecord'\n"))))
10428 (add-before 'check 'delete-Gemfile.lock
10429 (lambda _
10430 ;; Bundler isn't being used for fetching dependendencies, so
10431 ;; delete the Gemfile.lock
10432 (delete-file "Gemfile.lock")
10433 #t))
10434 (add-before 'build 'patch-gemspec
10435 (lambda _
10436 (substitute* "parallel.gemspec"
10437 (("git ls-files") "find"))
10438 #t)))))
10439 (native-inputs
10440 `(("ruby-rspec" ,ruby-rspec)
10441 ("ruby-rspec-rerun" ,ruby-rspec-rerun)
10442 ("bundler" ,bundler)
10443 ("ruby-activerecord" ,ruby-activerecord)
10444 ("ruby-progressbar" ,ruby-progressbar)
10445 ("ruby-bump" ,ruby-bump)
10446 ("procps" ,procps)
10447 ("lsof" ,lsof)
10448 ("ruby-mysql2" ,ruby-mysql2)
10449 ("ruby-sqlite3" ,ruby-sqlite3)
10450 ("ruby-i18n" ,ruby-i18n)))
10451 (home-page "https://github.com/grosser/parallel")
10452 (synopsis "Parallel processing in Ruby")
10453 (description "Parallel allows you to run any code in parallel Processes
10454 (to use all CPUs) or Threads(to speedup blocking operations). It is best
10455 suited for map-reduce or e.g. parallel downloads/uploads.")
10456 (license license:expat)))
10457
10458 (define-public ruby-cane
10459 (package
10460 (name "ruby-cane")
10461 (version "3.0.0")
10462 (source (origin
10463 (method url-fetch)
10464 (uri (rubygems-uri "cane" version))
10465 (sha256
10466 (base32
10467 "0yf5za3l7lhrqa3g56sah73wh33lbxy5y3cb7ij0a2bp1b4kwhih"))))
10468 (build-system ruby-build-system)
10469 (arguments `(#:tests? #f)); No rakefile
10470 (home-page "https://github.com/square/cane")
10471 (propagated-inputs
10472 `(("ruby-parallel" ,ruby-parallel)))
10473 (synopsis "Code quality threshold checking")
10474 (description "Cane fails your build if code quality thresholds are not met.")
10475 (license license:asl2.0)))
10476
10477 (define-public ruby-morecane
10478 (package
10479 (name "ruby-morecane")
10480 (version "0.2.0")
10481 (source (origin
10482 (method url-fetch)
10483 (uri (rubygems-uri "morecane" version))
10484 (sha256
10485 (base32
10486 "0w70vb8z5bdhvr21h660aa43m5948pv0bd27z7ngai2iwdvqd771"))))
10487 (build-system ruby-build-system)
10488 (home-page "https://github.com/yob/morecane")
10489 (arguments `(#:tests? #f)); No rakefile
10490 (propagated-inputs
10491 `(("ruby-parallel" ,ruby-parallel)))
10492 (synopsis "Extra checks for cane")
10493 (description "The cane gem provides a great framework for running quality
10494 checks over your ruby project as part of continuous integration build. It
10495 comes with a few checks out of the box, but also provides an API for loading
10496 custom checks. This gem provides a set of additional checks.")
10497 (license license:expat)))
10498
10499 (define-public ruby-pdf-reader
10500 (package
10501 (name "ruby-pdf-reader")
10502 (version "2.4.0")
10503 (source (origin
10504 (method git-fetch) ;no test in distributed gem archive
10505 (uri (git-reference
10506 (url "https://github.com/yob/pdf-reader.git")
10507 (commit (string-append "v" version))))
10508 (file-name (git-file-name name version))
10509 (sha256
10510 (base32
10511 "1yh8yrlssf5ppnkvk4m78vmh5r5vqwdcd0gm3lqipw162llz0rai"))))
10512 (build-system ruby-build-system)
10513 (arguments `(#:test-target "spec"
10514 #:phases (modify-phases %standard-phases
10515 (add-after 'unpack 'do-not-use-bundler
10516 (lambda _
10517 (substitute* "spec/spec_helper.rb"
10518 ((".*[Bb]undler.*") ""))
10519 #t)))))
10520 (native-inputs
10521 `(("ruby-rspec" ,ruby-rspec)
10522 ("ruby-cane" ,ruby-cane)
10523 ("ruby-morecane" ,ruby-morecane)))
10524 (propagated-inputs
10525 `(("ruby-afm" ,ruby-afm)
10526 ("ruby-ascii85" ,ruby-ascii85)
10527 ("ruby-hashery" ,ruby-hashery)
10528 ("ruby-rc4" ,ruby-rc4)
10529 ("ruby-ttfunk" ,ruby-ttfunk)))
10530 (home-page "https://github.com/yob/pdf-reader")
10531 (synopsis "PDF parser in Ruby")
10532 (description "The PDF::Reader library implements a PDF parser conforming as
10533 much as possible to the PDF specification from Adobe. It provides programmatic
10534 access to the contents of a PDF file with a high degree of flexibility.")
10535 (license license:gpl3+)))
10536
10537 (define-public ruby-pdf-inspector
10538 (let ((revision "1")
10539 (commit "00ee4c92ff917118785ebec188e81effc968abeb"))
10540 (package
10541 (name "ruby-pdf-inspector")
10542 (version (git-version "1.3.0" revision commit))
10543 (source (origin
10544 (method git-fetch)
10545 (uri (git-reference
10546 (url "https://github.com/prawnpdf/pdf-inspector.git")
10547 (commit commit)))
10548 (file-name (git-file-name name version))
10549 (sha256
10550 (base32
10551 "0h9w81ddd0gvkh5n2cvny9ddb5qiac1si0dhinkk0xxh5382qs0m"))))
10552 (build-system ruby-build-system)
10553 (arguments
10554 `(#:test-target "spec"
10555 #:phases (modify-phases %standard-phases
10556 (add-before 'build 'drop-signing-key-requirement
10557 (lambda _
10558 (substitute* "pdf-inspector.gemspec"
10559 (("spec.signing_key =.*")
10560 "spec.signing_key = nil"))
10561 #t))
10562 (replace 'check
10563 (lambda _
10564 (substitute* "pdf-inspector.gemspec"
10565 ((".*rubocop.*") "")
10566 ((".*yard.*") ""))
10567 (invoke "rspec"))))))
10568 (native-inputs
10569 `(("ruby-rspec" ,ruby-rspec)))
10570 (propagated-inputs
10571 `(("ruby-pdf-reader" ,ruby-pdf-reader)))
10572 (home-page "https://github.com/prawnpdf/pdf-inspector")
10573 (synopsis "Analysis classes for inspecting PDF output")
10574 (description "This library provides a number of PDF::Reader based tools for
10575 use in testing PDF output. Presently, the primary purpose of this tool is to
10576 support the tests found in Prawn, a pure Ruby PDF generation library.")
10577 (license %prawn-project-licenses))))
10578
10579 (define-public ruby-pdf-core
10580 (package
10581 (name "ruby-pdf-core")
10582 (version "0.8.1")
10583 (source (origin
10584 (method url-fetch)
10585 (uri (rubygems-uri "pdf-core" version))
10586 (sha256
10587 (base32
10588 "15d6m99bc8bbzlkcg13qfpjjzphfg5x905pjbfygvpcxsm8gnsvg"))))
10589 (build-system ruby-build-system)
10590 (arguments
10591 ; No test target
10592 `(#:tests? #f))
10593 (home-page "https://github.com/prawnpdf/pdf-core")
10594 (synopsis "Low level PDF features for Prawn")
10595 (description "This is an experimental gem that extracts low-level PDF
10596 functionality from Prawn.")
10597 (license license:gpl3+)))
10598
10599 (define-public ruby-prawn
10600 ;; There hasn't been a new release since 2017/03/17.
10601 (let ((revision "1")
10602 (commit "d980247be8a00e7c59cd4e5785e3aa98f9856db1"))
10603 (package
10604 (name "ruby-prawn")
10605 (version (git-version "2.2.2" revision commit))
10606 (source (origin
10607 (method git-fetch)
10608 (uri (git-reference
10609 (url "https://github.com/prawnpdf/prawn.git")
10610 (commit commit)))
10611 (file-name (git-file-name name version))
10612 (sha256
10613 (base32
10614 "0mcmvf22h8il93yq48v9f31qpy27pvjxgv9172p0f4x9lqy0imwr"))))
10615 (build-system ruby-build-system)
10616 (arguments
10617 `(#:phases
10618 (modify-phases %standard-phases
10619 (add-before 'build 'drop-signing-key-requirement
10620 (lambda _
10621 (substitute* "prawn.gemspec"
10622 (("spec.signing_key =.*")
10623 "spec.signing_key = nil"))
10624 #t))
10625 (replace 'check
10626 (lambda* (#:key tests? #:allow-other-keys)
10627 (when tests?
10628 ;; The Prawn manual test fails (see:
10629 ;; https://github.com/prawnpdf/prawn/issues/1163), so exclude
10630 ;; it.
10631 (invoke "rspec" "--exclude-pattern" "prawn_manual_spec.rb"))
10632 #t)))))
10633 (propagated-inputs
10634 `(("ruby-pdf-core" ,ruby-pdf-core)
10635 ("ruby-ttfunk" ,ruby-ttfunk)))
10636 (native-inputs
10637 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
10638 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
10639 ("ruby-rspec" ,ruby-rspec)
10640 ("ruby-simplecov" ,ruby-simplecov)
10641 ("ruby-yard" ,ruby-yard)))
10642 (home-page "https://prawnpdf.org/api-docs/2.0/")
10643 (synopsis "PDF generation for Ruby")
10644 (description "Prawn is a pure Ruby PDF generation library.")
10645 (license %prawn-project-licenses))))
10646
10647 (define-public ruby-prawn-table
10648 (package
10649 (name "ruby-prawn-table")
10650 (version "0.2.2")
10651 (source (origin
10652 (method url-fetch)
10653 (uri (rubygems-uri "prawn-table" version))
10654 (sha256
10655 (base32
10656 "1nxd6qmxqwl850icp18wjh5k0s3amxcajdrkjyzpfgq0kvilcv9k"))))
10657 (build-system ruby-build-system)
10658 (propagated-inputs
10659 `(("ruby-prawn" ,ruby-prawn)
10660 ("ruby-pdf-inspector" ,ruby-pdf-inspector)))
10661 (native-inputs
10662 `(("bundler" ,bundler)
10663 ("ruby-yard" ,ruby-yard)
10664 ("ruby-mocha" ,ruby-mocha)
10665 ("ruby-coderay" ,ruby-coderay)
10666 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
10667 ("ruby-simplecov" ,ruby-simplecov)
10668 ("ruby-rspec-2" ,ruby-rspec-2)))
10669 (arguments
10670 '(;; TODO: 1 test fails
10671 ;; Failure/Error: pdf.page_count.should == 1
10672 ;; expected: 1
10673 ;; got: 2 (using ==)
10674 ;; # ./spec/table_spec.rb:1308
10675 ;;
10676 ;; 225 examples, 1 failure
10677 #:tests? #f
10678 #:phases
10679 (modify-phases %standard-phases
10680 (add-before 'check 'patch-gemspec
10681 (lambda _
10682 (substitute* "prawn-table.gemspec"
10683 ;; Loosen the requirement for pdf-inspector
10684 (("~> 1\\.1\\.0") ">= 0")
10685 ;; Loosen the requirement for pdf-reader
10686 (("~> 1\\.2") ">= 0"))))
10687 (replace 'check
10688 (lambda* (#:key tests? #:allow-other-keys)
10689 (when tests?
10690 (invoke "rspec"))
10691 #t)))))
10692 (home-page "https://github.com/prawnpdf/prawn-table")
10693 (synopsis "Tables support for Prawn")
10694 (description "This gem provides tables support for Prawn.")
10695 (license license:gpl3+)))
10696
10697 (define-public ruby-kramdown
10698 (package
10699 (name "ruby-kramdown")
10700 (version "2.3.0")
10701 (source (origin
10702 (method url-fetch)
10703 (uri (rubygems-uri "kramdown" version))
10704 (sha256
10705 (base32
10706 "1vmw752c26ny2jwl0npn0gbyqwgz4hdmlpxnsld9qi9xhk5b1qh7"))))
10707 (build-system ruby-build-system)
10708 (arguments `(#:tests? #f)); FIXME: some test failures
10709 (native-inputs
10710 `(("ruby-prawn" ,ruby-prawn)
10711 ("ruby-prawn-table" ,ruby-prawn-table)))
10712 (home-page "https://kramdown.gettalong.org/")
10713 (synopsis "Markdown parsing and converting library")
10714 (description "Kramdown is a library for parsing and converting a superset
10715 of Markdown. It is completely written in Ruby, supports standard Markdown
10716 (with some minor modifications) and various extensions that have been made
10717 popular by the PHP @code{Markdown Extra} package and @code{Maruku}.")
10718 (license license:expat)))
10719
10720 (define-public ruby-kramdown-parser-gfm
10721 (package
10722 (name "ruby-kramdown-parser-gfm")
10723 (version "1.1.0")
10724 (source
10725 (origin
10726 (method url-fetch)
10727 (uri (rubygems-uri "kramdown-parser-gfm" version))
10728 (sha256
10729 (base32 "0a8pb3v951f4x7h968rqfsa19c8arz21zw1vaj42jza22rap8fgv"))))
10730 (build-system ruby-build-system)
10731 (arguments
10732 `(#:tests? #f)) ;no rakefile
10733 (propagated-inputs
10734 `(("ruby-kramdown" ,ruby-kramdown)))
10735 (synopsis "Kramdown parser for the GFM dialect of Markdown")
10736 (description
10737 "This is a parser for kramdown that converts Markdown documents in the
10738 GFM dialect to HTML.")
10739 (home-page "https://github.com/kramdown/parser-gfm")
10740 (license license:expat)))
10741
10742 (define-public ruby-http-parser.rb
10743 (package
10744 (name "ruby-http-parser.rb")
10745 (version "0.6.0")
10746 (source
10747 (origin
10748 (method url-fetch)
10749 (uri (rubygems-uri "http_parser.rb" version))
10750 (sha256
10751 (base32
10752 "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"))))
10753 (build-system ruby-build-system)
10754 (arguments
10755 ;; No tests
10756 `(#:tests? #f))
10757 (native-inputs
10758 `(("ruby-rake-compiler" ,ruby-rake-compiler)
10759 ("ruby-rspec" ,ruby-rspec)))
10760 (home-page "https://github.com/tmm1/http_parser.rb")
10761 (synopsis "HTTP parser un Ruby")
10762 (description "This gem is a simple callback-based HTTP request/response
10763 parser for writing http servers, clients and proxies.")
10764 (license license:expat)))
10765
10766 (define-public ruby-em-websocket
10767 (package
10768 (name "ruby-em-websocket")
10769 (version "0.5.1")
10770 (source
10771 (origin
10772 (method url-fetch)
10773 (uri (rubygems-uri "em-websocket" version))
10774 (sha256
10775 (base32
10776 "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"))))
10777 (build-system ruby-build-system)
10778 (arguments
10779 ;; No tests
10780 `(#:tests? #f))
10781 (propagated-inputs
10782 `(("ruby-eventmachine" ,ruby-eventmachine)
10783 ("ruby-http-parser.rb" ,ruby-http-parser.rb)))
10784 (native-inputs
10785 `(("bundler" ,bundler)
10786 ("ruby-rspec" ,ruby-rspec)))
10787 (home-page "https://github.com/igrigorik/em-websocket")
10788 (synopsis "EventMachine based WebSocket server")
10789 (description "Em-websocket is an EventMachine based WebSocket server
10790 implementation.")
10791 (license license:expat)))
10792
10793 (define-public ruby-rouge
10794 (package
10795 (name "ruby-rouge")
10796 (version "3.21.0")
10797 (source (origin
10798 (method url-fetch)
10799 (uri (rubygems-uri "rouge" version))
10800 (sha256
10801 (base32
10802 "1agrrmj88k9jkk36ra1ml2c1jffpp595pkxmcla74ac9ia09vn3s"))))
10803 (build-system ruby-build-system)
10804 (arguments `(#:tests? #f)); No rakefile
10805 (home-page "http://rouge.jneen.net/")
10806 (synopsis "Code highlighter")
10807 (description "Rouge is a code highlighter written in Ruby. It supports more
10808 than 100 languages and outputs HTML or ANSI 256-color text. Its HTML output
10809 is compatible with stylesheets designed for pygments.")
10810 (license (list
10811 ;; rouge is licensed under expat
10812 license:expat
10813 ;; pygments is licensed under bsd-2
10814 license:bsd-2))))
10815
10816 (define-public ruby-rouge-2
10817 (package
10818 (inherit ruby-rouge)
10819 (version "2.2.1")
10820 (source (origin
10821 (method url-fetch)
10822 (uri (rubygems-uri "rouge" version))
10823 (sha256
10824 (base32
10825 "02kpahk5nkc33yxnn75649kzxaz073wvazr2zyg491nndykgnvcs"))))))
10826
10827 (define-public ruby-hashie
10828 (package
10829 (name "ruby-hashie")
10830 (version "3.6.0")
10831 (source (origin
10832 (method url-fetch)
10833 (uri (rubygems-uri "hashie" version))
10834 (sha256
10835 (base32
10836 "13bdzfp25c8k51ayzxqkbzag3wj5gc1jd8h7d985nsq6pn57g5xh"))))
10837 (build-system ruby-build-system)
10838 (native-inputs
10839 `(("bundler" ,bundler)))
10840 (arguments `(#:tests? #f)); FIXME: Could not locate Gemfile or .bundle/ directory
10841 (home-page "https://github.com/intridea/hashie")
10842 (synopsis "Extensions to Ruby Hashes")
10843 (description "Hashie is a collection of classes and mixins that make Ruby
10844 hashes more powerful.")
10845 (license license:expat)))
10846
10847 (define-public ruby-heredoc-unindent
10848 (package
10849 (name "ruby-heredoc-unindent")
10850 (version "1.2.0")
10851 (source (origin
10852 (method url-fetch)
10853 (uri (rubygems-uri "heredoc_unindent" version))
10854 (sha256
10855 (base32
10856 "14ijr2fsjwhrkjkcaz81d5xnfa4vvgvcflrff83avqw9klm011yw"))))
10857 (build-system ruby-build-system)
10858 (native-inputs
10859 `(("ruby-hoe" ,ruby-hoe)))
10860 (home-page "https://github.com/adrianomitre/heredoc_unindent")
10861 (synopsis "Heredoc indentation cleaner")
10862 (description "This gem removes common margin from indented strings, such
10863 as the ones produced by indented heredocs. In other words, it strips out
10864 leading whitespace chars at the beginning of each line, but only as much as
10865 the line with the smallest margin.
10866
10867 It is acknowledged that many strings defined by heredocs are just code and
10868 fact is that most parsers are insensitive to indentation. If, however, the
10869 strings are to be used otherwise, be it for printing or testing, the extra
10870 indentation will probably be an issue and hence this gem.")
10871 (license license:expat)))
10872
10873 (define-public ruby-safe-yaml
10874 (package
10875 (name "ruby-safe-yaml")
10876 (version "1.0.5")
10877 (source
10878 (origin
10879 (method git-fetch)
10880 (uri (git-reference
10881 (url "https://github.com/dtao/safe_yaml")
10882 (commit version)))
10883 (file-name (git-file-name name version))
10884 (sha256
10885 (base32
10886 "1a0wh7y3va2m7bjza95na2snw0vrdh9syz40mpjvjphbc4ph3pzg"))))
10887 (build-system ruby-build-system)
10888 (native-inputs
10889 `(("ruby-rspec" ,ruby-rspec)
10890 ("ruby-hashie" ,ruby-hashie)
10891 ("ruby-heredoc-unindent" ,ruby-heredoc-unindent)))
10892 (arguments
10893 '(#:test-target "spec"
10894 #:phases
10895 (modify-phases %standard-phases
10896 (add-before 'check 'set-TZ
10897 (lambda _
10898 ;; This test is dependent on the timezone
10899 ;; spec/transform/to_date_spec.rb:35
10900 ;; # SafeYAML::Transform::ToDate converts times to the local
10901 ;; timezone
10902 (setenv "TZ" "UTC-11")
10903 #t)))))
10904 (home-page "https://github.com/dtao/safe_yaml")
10905 (synopsis "YAML parser")
10906 (description "The SafeYAML gem provides an alternative implementation of
10907 YAML.load suitable for accepting user input in Ruby applications.")
10908 (license license:expat)))
10909
10910 (define-public ruby-mercenary
10911 (package
10912 (name "ruby-mercenary")
10913 (version "0.3.6")
10914 (source (origin
10915 (method url-fetch)
10916 (uri (rubygems-uri "mercenary" version))
10917 (sha256
10918 (base32
10919 "10la0xw82dh5mqab8bl0dk21zld63cqxb1g16fk8cb39ylc4n21a"))))
10920 (build-system ruby-build-system)
10921 (arguments `(#:test-target "spec"))
10922 (native-inputs
10923 `(("bundler" ,bundler)))
10924 (home-page "https://github.com/jekyll/mercenary")
10925 (synopsis "Command-line apps library in Ruby")
10926 (description "Mercenary is a lightweight and flexible library for writing
10927 command-line apps in Ruby.")
10928 (license license:expat)))
10929
10930 (define-public ruby-liquid
10931 (package
10932 (name "ruby-liquid")
10933 (version "4.0.0")
10934 (source (origin
10935 (method url-fetch)
10936 (uri (rubygems-uri "liquid" version))
10937 (sha256
10938 (base32
10939 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))
10940 (build-system ruby-build-system)
10941 (arguments `(#:tests? #f)); No rakefile
10942 (home-page "https://shopify.github.io/liquid/")
10943 (synopsis "Template language")
10944 (description "Liquid is a template language written in Ruby. It is used
10945 to load dynamic content on storefronts.")
10946 (license license:expat)))
10947
10948 (define-public ruby-forwardable-extended
10949 (package
10950 (name "ruby-forwardable-extended")
10951 (version "2.6.0")
10952 (source (origin
10953 (method url-fetch)
10954 (uri (rubygems-uri "forwardable-extended" version))
10955 (sha256
10956 (base32
10957 "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"))))
10958 (build-system ruby-build-system)
10959 (arguments `(#:tests? #f)); Cyclic dependency on luna-rspec-formatters
10960 (home-page "https://github.com/envygeeks/forwardable-extended")
10961 (synopsis "Delegation to hashes and instance variables in Forwardable")
10962 (description "Forwardable Extended provides more @code{Forwardable}
10963 methods for your source as @code{Forwardable::Extended}.")
10964 (license license:expat)))
10965
10966 (define-public ruby-pathutil
10967 (package
10968 (name "ruby-pathutil")
10969 (version "0.16.2")
10970 (source (origin
10971 (method url-fetch)
10972 (uri (rubygems-uri "pathutil" version))
10973 (sha256
10974 (base32
10975 "12fm93ljw9fbxmv2krki5k5wkvr7560qy8p4spvb9jiiaqv78fz4"))))
10976 (build-system ruby-build-system)
10977 (propagated-inputs
10978 `(("ruby-forwardable-extended" ,ruby-forwardable-extended)))
10979 (native-inputs
10980 `(("bundler" ,bundler)
10981 ("ruby-rspec" ,ruby-rspec)))
10982 ;; Fails with: cannot load such file --
10983 ;; /tmp/guix-build-ruby-pathutil-0.16.0.drv-0/gem/benchmark/support/task
10984 (arguments `(#:tests? #f))
10985 (home-page "https://github.com/envygeeks/pathutil")
10986 (synopsis "Extended implementation of Pathname")
10987 (description "Pathutil tries to be a faster pure Ruby implementation of
10988 Pathname.")
10989 (license license:expat)))
10990
10991 (define-public jekyll
10992 (package
10993 (name "jekyll")
10994 (version "3.8.6")
10995 (source (origin
10996 (method url-fetch)
10997 (uri (rubygems-uri "jekyll" version))
10998 (sha256
10999 (base32
11000 "1ph1jjjl25vmzif7bvxzviq7azjm384pm7ba4k24cah94285bzhz"))))
11001 (build-system ruby-build-system)
11002 (arguments
11003 ;; No rakefile, but a test subdirectory.
11004 `(#:tests? #f
11005 #:phases
11006 (modify-phases %standard-phases
11007 (add-before 'build 'fix-i18n
11008 (lambda _
11009 (substitute* ".gemspec"
11010 (("~> 0.7") ">= 0.7")
11011 (("~> 1.14") ">= 1.14"))
11012 #t)))))
11013 (propagated-inputs
11014 `(("ruby-addressable" ,ruby-addressable)
11015 ("ruby-colorator" ,ruby-colorator)
11016 ("ruby-em-websocket" ,ruby-em-websocket)
11017 ("ruby-i18n" ,ruby-i18n)
11018 ("ruby-jekyll-sass-converter" ,ruby-jekyll-sass-converter)
11019 ("ruby-jekyll-watch" ,ruby-jekyll-watch)
11020 ("ruby-kramdown" ,ruby-kramdown-parser-gfm)
11021 ("ruby-liquid" ,ruby-liquid)
11022 ("ruby-mercenary" ,ruby-mercenary)
11023 ("ruby-pathutil" ,ruby-pathutil)
11024 ("ruby-rouge" ,ruby-rouge-2)
11025 ("ruby-safe-yaml" ,ruby-safe-yaml)))
11026 (home-page "https://jekyllrb.com/")
11027 (synopsis "Static site generator")
11028 (description "Jekyll is a simple, blog aware, static site generator.")
11029 (license license:expat)))
11030
11031 (define-public ruby-jekyll-paginate-v2
11032 (package
11033 (name "ruby-jekyll-paginate-v2")
11034 (version "3.0.0")
11035 (source (origin
11036 (method url-fetch)
11037 (uri (rubygems-uri "jekyll-paginate-v2" version))
11038 (sha256
11039 (base32
11040 "1qzlqhpiqz28624fp0ak76hfy7908w6kpx62v7z43aiwjv0yc6q0"))))
11041 (build-system ruby-build-system)
11042 (propagated-inputs
11043 `(("jekyll" ,jekyll)))
11044 (home-page "https://github.com/sverrirs/jekyll-paginate-v2")
11045 (synopsis "Pagination Generator for Jekyll 3")
11046 (description "The Pagination Generator forms the core of the pagination
11047 logic in Jekyll. It calculates and generates the pagination pages.")
11048 (license license:expat)))
11049
11050 (define-public ruby-faraday
11051 (package
11052 (name "ruby-faraday")
11053 (version "0.15.4")
11054 (source
11055 (origin
11056 (method url-fetch)
11057 (uri (rubygems-uri "faraday" version))
11058 (sha256
11059 (base32
11060 "0s72m05jvzc1pd6cw1i289chas399q0a14xrwg4rvkdwy7bgzrh0"))))
11061 (build-system ruby-build-system)
11062 (arguments
11063 '(#:tests? #f))
11064 (propagated-inputs
11065 `(("ruby-multipart-post" ,ruby-multipart-post)))
11066 (synopsis "Ruby HTTP/REST API client library")
11067 (description
11068 "Faraday is a HTTP/REST API client library which provides a common
11069 interface over different adapters.")
11070 (home-page "https://github.com/lostisland/faraday")
11071 (license license:expat)))
11072
11073 (define-public ruby-nio4r
11074 (package
11075 (name "ruby-nio4r")
11076 (version "2.5.2")
11077 (source
11078 (origin
11079 (method url-fetch)
11080 (uri (rubygems-uri "nio4r" version))
11081 (sha256
11082 (base32
11083 "0gnmvbryr521r135yz5bv8354m7xn6miiapfgpg1bnwsvxz8xj6c"))))
11084 (build-system ruby-build-system)
11085 (arguments
11086 '(#:phases
11087 (modify-phases %standard-phases
11088 (add-after 'unpack 'remove-unnecessary-dependencies
11089 (lambda _
11090 (substitute* "spec/spec_helper.rb"
11091 ;; Coveralls is for uploading test coverage information to an
11092 ;; online service, and thus unnecessary for building the Guix
11093 ;; package
11094 (("require \"coveralls\"") "")
11095 (("Coveralls\\.wear!") "")
11096 ;; Remove rspec/retry as we are not retrying the tests
11097 (("require \"rspec/retry\"") "")
11098 (("config\\.display_try_failure_messages = true") "")
11099 (("config\\.verbose_retry = true") ""))
11100 #t))
11101 (add-before 'check 'compile
11102 (lambda _
11103 (invoke "rake" "compile")
11104 #t))
11105 (replace 'check
11106 (lambda* (#:key tests? #:allow-other-keys)
11107 (when tests?
11108 (invoke "rspec"))
11109 #t)))))
11110 (native-inputs
11111 `(("bundler" ,bundler)
11112 ("ruby-rake-compiler" ,ruby-rake-compiler)
11113 ("ruby-rspec" ,ruby-rspec)
11114 ("ruby-rubocop" ,ruby-rubocop)))
11115 (synopsis "New I/O for Ruby")
11116 (description
11117 "@code{nio} provides cross-platform asynchronous I/O primitives in Ruby
11118 for scalable network clients and servers.")
11119 (home-page "https://github.com/socketry/nio4r")
11120 (license license:expat)))
11121
11122 (define-public ruby-globalid
11123 (package
11124 (name "ruby-globalid")
11125 (version "0.4.2")
11126 (source
11127 (origin
11128 (method url-fetch)
11129 (uri (rubygems-uri "globalid" version))
11130 (sha256
11131 (base32
11132 "1zkxndvck72bfw235bd9nl2ii0lvs5z88q14706cmn702ww2mxv1"))))
11133 (build-system ruby-build-system)
11134 (arguments
11135 '(;; No included tests
11136 #:tests? #f))
11137 (propagated-inputs
11138 `(("ruby-activesupport" ,ruby-activesupport)))
11139 (synopsis "Generate URIs idenfitying model instances in Ruby")
11140 (description
11141 "@code{GlobalID} provides a way to generate URIs from a model in Ruby that
11142 uniquely identify it.")
11143 (home-page "https://rubyonrails.org/")
11144 (license license:expat)))
11145
11146 (define-public ruby-sprockets
11147 (package
11148 (name "ruby-sprockets")
11149 (version "3.7.2")
11150 (source
11151 (origin
11152 (method url-fetch)
11153 (uri (rubygems-uri "sprockets" version))
11154 (sha256
11155 (base32
11156 "182jw5a0fbqah5w9jancvfmjbk88h8bxdbwnl4d3q809rpxdg8ay"))))
11157 (build-system ruby-build-system)
11158 (arguments
11159 '(;; No included tests
11160 #:tests? #f))
11161 (propagated-inputs
11162 `(("ruby-concurrent" ,ruby-concurrent)
11163 ("ruby-rack" ,ruby-rack)))
11164 (synopsis "Sprockets is a Rack-based asset packaging system")
11165 (description
11166 "Sprockets is a Rack-based asset packaging system that concatenates and
11167 serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.")
11168 (home-page "https://github.com/rails/sprockets")
11169 (license license:expat)))
11170
11171 (define-public ruby-mustache
11172 (package
11173 (name "ruby-mustache")
11174 (version "1.1.1")
11175 (source
11176 (origin
11177 (method url-fetch)
11178 (uri (rubygems-uri "mustache" version))
11179 (sha256
11180 (base32 "1l0p4wx15mi3wnamfv92ipkia4nsx8qi132c6g51jfdma3fiz2ch"))))
11181 (build-system ruby-build-system)
11182 (native-inputs
11183 `(("ruby-simplecov" ,ruby-simplecov)))
11184 (synopsis "framework-agnostic way to render logic-free views")
11185 (description
11186 "Mustache is a framework-agnostic way to render logic-free views.
11187 Think of Mustache as a replacement for your views. Instead of views
11188 consisting of ERB or HAML with random helpers and arbitrary logic,
11189 your views are broken into two parts: a Ruby class and an HTML
11190 template.")
11191 (home-page "https://github.com/mustache/mustache")
11192 (license license:expat)))
11193
11194 (define-public ruby-mustermann
11195 (package
11196 (name "ruby-mustermann")
11197 (version "1.0.3")
11198 (source
11199 (origin
11200 (method url-fetch)
11201 (uri (rubygems-uri "mustermann" version))
11202 (sha256
11203 (base32
11204 "0lycgkmnyy0bf29nnd2zql5a6pcf8sp69g9v4xw0gcfcxgpwp7i1"))))
11205 (build-system ruby-build-system)
11206 (arguments
11207 ;; No tests.
11208 '(#:tests? #f))
11209 (synopsis "Library implementing patterns that behave like regular expressions")
11210 (description "Given a string pattern, Mustermann will turn it into an
11211 object that behaves like a regular expression and has comparable performance
11212 characteristics.")
11213 (home-page "https://github.com/sinatra/mustermann")
11214 (license license:expat)))
11215
11216 (define-public ruby-htmlentities
11217 (package
11218 (name "ruby-htmlentities")
11219 (version "4.3.4")
11220 (source
11221 (origin
11222 (method url-fetch)
11223 (uri (rubygems-uri "htmlentities" version))
11224 (sha256
11225 (base32
11226 "1nkklqsn8ir8wizzlakncfv42i32wc0w9hxp00hvdlgjr7376nhj"))))
11227 (build-system ruby-build-system)
11228 (arguments
11229 `(#:phases
11230 (modify-phases %standard-phases
11231 (replace 'check
11232 (lambda _
11233 (map (lambda (file)
11234 (invoke "ruby" "-Itest" file))
11235 (find-files "./test" ".*_test\\.rb")))))))
11236 (synopsis "Encode and decode (X)HTML entities")
11237 (description
11238 "This package provides a module for encoding and decoding (X)HTML
11239 entities.")
11240 (home-page "https://github.com/threedaymonk/htmlentities")
11241 (license license:expat)))
11242
11243 (define-public ruby-sinatra
11244 (package
11245 (name "ruby-sinatra")
11246 (version "2.0.8.1")
11247 (source
11248 (origin
11249 (method url-fetch)
11250 (uri (rubygems-uri "sinatra" version))
11251 (sha256
11252 (base32
11253 "0riy3hwjab1mr73jcqx3brmbmwspnw3d193j06a5f0fy1w35z15q"))))
11254 (build-system ruby-build-system)
11255 (arguments
11256 `(#:phases
11257 (modify-phases %standard-phases
11258 ;; See: https://github.com/sinatra/sinatra/issues/1578.
11259 (add-after 'extract-gemspec 'fix-slow-doc-generation
11260 (lambda _
11261 (substitute* "sinatra.gemspec"
11262 (("\"README.rdoc\"\\.freeze," all)
11263 (string-append all " \"--exclude=.*\\.md\".freeze,")))
11264 #t)))))
11265 (propagated-inputs
11266 `(("ruby-mustermann" ,ruby-mustermann)
11267 ("ruby-rack" ,ruby-rack)
11268 ("ruby-rack-protection" ,ruby-rack-protection)
11269 ("ruby-tilt" ,ruby-tilt)))
11270 (synopsis "DSL for quick web applications creation in Ruby")
11271 (description
11272 "Sinatra is a DSL for quickly creating web applications in Ruby with
11273 minimal effort.")
11274 (home-page "http://sinatrarb.com/")
11275 (license license:expat)))
11276
11277 (define-public ruby-thin
11278 (package
11279 (name "ruby-thin")
11280 (version "1.7.2")
11281 (source
11282 (origin
11283 (method url-fetch)
11284 (uri (rubygems-uri "thin" version))
11285 (sha256
11286 (base32
11287 "0nagbf9pwy1vg09k6j4xqhbjjzrg5dwzvkn4ffvlj76fsn6vv61f"))))
11288 (build-system ruby-build-system)
11289 (arguments
11290 ;; No tests.
11291 '(#:tests? #f))
11292 (propagated-inputs
11293 `(("ruby-daemons" ,ruby-daemons)
11294 ("ruby-eventmachine" ,ruby-eventmachine)
11295 ("ruby-rack" ,ruby-rack)))
11296 (synopsis "Thin and fast web server for Ruby")
11297 (description "Thin is a Ruby web server that glues together 3 Ruby libraries:
11298 @itemize
11299 @item the Mongrel parser,
11300 @item Event Machine, a network I/O library with high scalability, performance
11301 and stability,
11302 @item Rack, a minimal interface between webservers and Ruby frameworks.
11303 @end itemize\n")
11304 (home-page "https://github.com/macournoyer/thin")
11305 (license license:ruby)))
11306
11307 (define-public ruby-skinny
11308 (package
11309 (name "ruby-skinny")
11310 (version "0.2.4")
11311 (source
11312 (origin
11313 (method url-fetch)
11314 (uri (rubygems-uri "skinny" version))
11315 (sha256
11316 (base32
11317 "1y3yvx88ylgz4d2s1wskjk5rkmrcr15q3ibzp1q88qwzr5y493a9"))))
11318 (build-system ruby-build-system)
11319 (arguments
11320 '(#:tests? #f ; No included tests
11321 #:phases
11322 (modify-phases %standard-phases
11323 (add-before 'build 'patch-gemspec
11324 (lambda _
11325 (substitute* ".gemspec"
11326 (("<eventmachine>.freeze, \\[\\\"~> 1.0.0\"")
11327 "<eventmachine>, [\">= 1.0.0\"")
11328 (("<thin>.freeze, \\[\\\"< 1.7\", ") "<thin>, ["))
11329 #t)))))
11330 (propagated-inputs
11331 `(("ruby-eventmachine" ,ruby-eventmachine)
11332 ("ruby-thin" ,ruby-thin)))
11333 (synopsis "Simple, upgradable WebSockets for Ruby Thin")
11334 (description "Skinny is a simple, upgradable WebSockets for Ruby, using
11335 the Thin library.")
11336 (home-page "https://github.com/sj26/skinny")
11337 (license license:expat)))
11338
11339 (define-public ruby-sys-filesystem
11340 (package
11341 (name "ruby-sys-filesystem")
11342 (version "1.3.4")
11343 (source (origin
11344 (method url-fetch)
11345 (uri (rubygems-uri "sys-filesystem" version))
11346 (sha256
11347 (base32
11348 "0mizqnsiagagmracadr16s5na2ks2j3ih1w0f3gp4ssrda6szl01"))))
11349 (build-system ruby-build-system)
11350 (arguments
11351 '(#:phases (modify-phases %standard-phases
11352 (add-before 'check 'set-HOME
11353 (lambda _
11354 ;; Some tests attempt to stat $HOME. Let them.
11355 (setenv "HOME" "/tmp")
11356 #t)))))
11357 (propagated-inputs
11358 `(("ruby-ffi" ,ruby-ffi)))
11359 (native-inputs
11360 `(("ruby-mkmf-lite" ,ruby-mkmf-lite)))
11361 (synopsis "Gather file system information")
11362 (description
11363 "The @code{sys-filesystem} library provides a cross-platform interface
11364 for gathering file system information, such as disk space and mount points.")
11365 (home-page "https://github.com/djberg96/sys-filesystem")
11366 (license license:asl2.0)))
11367
11368 (define-public mailcatcher
11369 (package
11370 (name "mailcatcher")
11371 (version "0.7.1")
11372 (source
11373 (origin
11374 (method url-fetch)
11375 (uri (rubygems-uri "mailcatcher" version))
11376 (sha256
11377 (base32
11378 "02w1ycyfv7x0sh9799lz7xa65p5qvl5z4pa8a7prb68h2zwkfq0n"))))
11379 (build-system ruby-build-system)
11380 (arguments
11381 ;; Tests require web/assets which is not included in the output. We
11382 ;; might be able to fix this by adding the Git repository to the GEM_PATH
11383 ;; of the tests. See ruby-mysql2.
11384 '(#:tests? #f
11385 #:phases
11386 (modify-phases %standard-phases
11387 (add-before 'build 'patch-gemspec
11388 (lambda _
11389 (substitute* ".gemspec"
11390 (("<eventmachine>.freeze, \\[\\\"= 1.0.9.1")
11391 "<eventmachine>, [\">= 1.0.9.1")
11392 (("<rack>.freeze, \\[\\\"~> 1.5") "<rack>, [\">= 1.5")
11393 (("<thin>.freeze, \\[\\\"~> 1.5.0") "<thin>, [\">= 1.5.0")
11394 (("<sinatra>.freeze, \\[\\\"~> 1.2") "<sinatra>, [\">= 1.2"))
11395 #t))
11396 (add-before 'build 'loosen-dependency-contraint
11397 (lambda _
11398 (substitute* "lib/mail_catcher.rb"
11399 (("\"eventmachine\", \"1.0.9.1\"") "\"eventmachine\", \">= 1.0.9.1\"")
11400 (("\"rack\", \"~> 1.5\"") "\"rack\", \">= 1.5\"")
11401 (("\"thin\", \"~> 1.5.0\"") "\"thin\", \">= 1.5.0\"")
11402 (("\"sinatra\", \"~> 1.2\"") "\"sinatra\", \">= 1.2\""))
11403 #t)))))
11404 (inputs
11405 `(("ruby-eventmachine" ,ruby-eventmachine)
11406 ("ruby-mail" ,ruby-mail)
11407 ("ruby-rack" ,ruby-rack)
11408 ("ruby-sinatra" ,ruby-sinatra)
11409 ("ruby-skinny" ,ruby-skinny)
11410 ("ruby-sqlite3" ,ruby-sqlite3)
11411 ("ruby-thin" ,ruby-thin)))
11412 (synopsis "SMTP server which catches messages to display them a browser")
11413 (description
11414 "MailCatcher runs a super simple SMTP server which catches any message
11415 sent to it to display in a web interface. Run mailcatcher, set your favourite
11416 app to deliver to smtp://127.0.0.1:1025 instead of your default SMTP server,
11417 then check out http://127.0.0.1:1080 to see the mail.")
11418 (home-page "https://mailcatcher.me")
11419 (license license:expat)))
11420
11421 (define-public ruby-backport
11422 (package
11423 (name "ruby-backport")
11424 (version "1.1.2")
11425 (source
11426 (origin
11427 ;; The gem does not include test code, so fetch from the Git repository.
11428 (method git-fetch)
11429 (uri (git-reference
11430 (url "https://github.com/castwide/backport")
11431 (commit (string-append "v" version))))
11432 (file-name (git-file-name name version))
11433 (sha256
11434 (base32 "18fpg1n7n2z02ykz9v1x1q0cqa2lvivf8ygka768s01q1r9wfwv2"))))
11435 (build-system ruby-build-system)
11436 (arguments
11437 `(#:test-target "spec"))
11438 (native-inputs
11439 `(("bundler" ,bundler)
11440 ("ruby-rspec" ,ruby-rspec)))
11441 (inputs
11442 `(("ruby-simplecov" ,ruby-simplecov)))
11443 (synopsis "Pure Ruby library for event-driven IO")
11444 (description
11445 "This package provides a pure Ruby library for event-driven IO.")
11446 (home-page "https://github.com/castwide/backport")
11447 (license license:expat)))
11448
11449 (define-public ruby-json-schema
11450 (package
11451 (name "ruby-json-schema")
11452 (version "2.8.1")
11453 (source
11454 (origin
11455 (method url-fetch)
11456 (uri (rubygems-uri "json-schema" version))
11457 (sha256
11458 (base32
11459 "1yv5lfmr2nzd14af498xqd5p89f3g080q8wk0klr3vxgypsikkb5"))))
11460 (build-system ruby-build-system)
11461 (arguments
11462 `(#:tests? #f ; no tests
11463 #:phases
11464 (modify-phases %standard-phases
11465 (replace 'build
11466 (lambda _
11467 (invoke "gem" "build" ".gemspec"))))))
11468 (propagated-inputs
11469 `(("ruby-addressable" ,ruby-addressable)))
11470 (synopsis "Ruby JSON Schema Validator")
11471 (description "This library provides Ruby with an interface for validating
11472 JSON objects against a JSON schema conforming to JSON Schema Draft 4. Legacy
11473 support for JSON Schema Draft 3, JSON Schema Draft 2, and JSON Schema Draft 1
11474 is also included.")
11475 (home-page "https://github.com/ruby-json-schema/json-schema")
11476 (license license:expat)))
11477
11478 (define-public swagger-diff
11479 (package
11480 (name "swagger-diff")
11481 (version "1.1.2")
11482 (source
11483 (origin
11484 (method url-fetch)
11485 (uri (rubygems-uri "swagger-diff" version))
11486 (sha256
11487 (base32
11488 "1hxx50nga1bqn254iqjcdwkc9c72364ks9lyjyw10ajz0l0ly7sn"))))
11489 (build-system ruby-build-system)
11490 (arguments
11491 `(#:test-target "spec"
11492 #:phases
11493 (modify-phases %standard-phases
11494 ;; Don't run or require rubocop, the code linting tool, as this is a
11495 ;; bit unnecessary.
11496 (add-after 'unpack 'dont-run-rubocop
11497 (lambda _
11498 (substitute* "Rakefile"
11499 ((".*rubocop.*") "")
11500 ((".*RuboCop.*") ""))
11501 #t)))))
11502 (propagated-inputs
11503 `(("ruby-json-schema" ,ruby-json-schema)))
11504 (native-inputs
11505 `(("bundler" ,bundler)
11506 ("ruby-rspec-core" ,ruby-rspec-core)
11507 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
11508 (synopsis
11509 "Compare Open API Initiative specification files")
11510 (description
11511 "Swagger::Diff is a utility for comparing two different Open API
11512 Initiative (OAI) specifications (formerly known as Swagger specifications).
11513 It is intended to determine whether a newer API specification is
11514 backwards-compatible with an older API specification.")
11515 (home-page "https://github.com/civisanalytics/swagger-diff")
11516 (license license:bsd-3)))
11517
11518 (define-public ruby-reverse-markdown
11519 (package
11520 (name "ruby-reverse-markdown")
11521 (version "1.1.0")
11522 (source
11523 (origin
11524 (method url-fetch)
11525 (uri (rubygems-uri "reverse_markdown" version))
11526 (sha256
11527 (base32
11528 "0w7y5n74daajvl9gixr91nh8670d7mkgspkk3ql71m8azq3nffbg"))))
11529 (build-system ruby-build-system)
11530 (propagated-inputs
11531 `(("ruby-nokogiri" ,ruby-nokogiri)))
11532 (native-inputs
11533 `(("bundler" ,bundler)
11534 ("ruby-rspec" ,ruby-rspec)
11535 ("ruby-kramdown" ,ruby-kramdown)
11536 ("ruby-simplecov" ,ruby-simplecov)))
11537 (arguments
11538 `(#:phases
11539 (modify-phases %standard-phases
11540 (replace 'check
11541 (lambda* (#:key tests? #:allow-other-keys)
11542 (when tests?
11543 (invoke "rspec"))
11544 #t)))))
11545 (synopsis "Convert HTML into Markdown")
11546 (description
11547 "This Ruby module allows you to map simple HTML back into
11548 Markdown---e.g., if you want to import existing HTML data in your
11549 application.")
11550 (home-page "https://github.com/xijo/reverse_markdown")
11551 (license license:wtfpl2)))
11552
11553 (define-public ruby-solargraph
11554 (package
11555 (name "ruby-solargraph")
11556 (version "0.36.0")
11557 (source
11558 (origin
11559 (method url-fetch)
11560 (uri (rubygems-uri "solargraph" version))
11561 (sha256
11562 (base32
11563 "0b93xzkgd1h06da9gdnwivj1mzbil8lc072y2838dy6i7bxgpy9i"))))
11564 (build-system ruby-build-system)
11565 (propagated-inputs
11566 `(("ruby-backport" ,ruby-backport)
11567 ("bundler" ,bundler)
11568 ("ruby-htmlentities" ,ruby-htmlentities)
11569 ("ruby-jaro-winkler" ,ruby-jaro-winkler)
11570 ("ruby-maruku" ,ruby-maruku)
11571 ("ruby-nokogiri" ,ruby-nokogiri)
11572 ("ruby-parser" ,ruby-parser)
11573 ("ruby-reverse-markdown" ,ruby-reverse-markdown)
11574 ("ruby-rubocop" ,ruby-rubocop)
11575 ("ruby-thor" ,ruby-thor)
11576 ("ruby-tilt" ,ruby-tilt)
11577 ("ruby-yard" ,ruby-yard)))
11578 (native-inputs
11579 `(("ruby-rspec" ,ruby-rspec)
11580 ("ruby-pry" ,ruby-pry)
11581 ("ruby-simplecov" ,ruby-simplecov)
11582 ("ruby-webmock" ,ruby-webmock-2)))
11583 ;; FIXME: can't figure out how to run the tests properly:
11584
11585 ;; An error occurred while loading spec_helper.
11586 ;; Failure/Error: return gem_original_require(path)
11587 ;; LoadError:
11588 ;; cannot load such file -- spec_helper
11589 (arguments
11590 '(#:tests? #f
11591 #:phases
11592 (modify-phases %standard-phases
11593 (replace 'check
11594 (lambda* (#:key tests? #:allow-other-keys)
11595 (when tests?
11596 (invoke "rspec"))
11597 #t)))))
11598 (synopsis
11599 "IDE tools for code completion, inline documentation, and static analysis")
11600 (description
11601 "Solargraph provides a comprehensive suite of tools for Ruby
11602 programming: intellisense, diagnostics, inline documentation, and type
11603 checking.")
11604 (home-page "https://solargraph.org/")
11605 (license license:expat)))
11606
11607 (define-public ruby-wayback-machine-downloader
11608 (package
11609 (name "ruby-wayback-machine-downloader")
11610 (version "2.2.1")
11611 (source
11612 (origin
11613 (method url-fetch)
11614 (uri (rubygems-uri
11615 "wayback_machine_downloader"
11616 version))
11617 (sha256
11618 (base32
11619 "12kb1qmvmmsaihqab1prn6cmynkn6cgb4vf41mgv22wkcgv5wgk2"))))
11620 (build-system ruby-build-system)
11621 (arguments
11622 '(#:tests? #f)) ; no tests
11623 (synopsis "Download archived websites from the Wayback Machine")
11624 (description
11625 "Wayback Machine Downloader is a command line tool for downloading
11626 websites from the Internet Archive's Wayback Machine (archive.org).
11627 It allows fine grained control over what to download by specifying
11628 which snapshots to consider and what files to include.")
11629 (home-page
11630 "https://github.com/hartator/wayback-machine-downloader")
11631 (license license:expat)))
11632
11633 (define-public ruby-wwtd
11634 (package
11635 (name "ruby-wwtd")
11636 (version "1.4.1")
11637 (home-page "https://github.com/grosser/wwtd")
11638 (source (origin
11639 (method git-fetch)
11640 (uri (git-reference
11641 (url home-page)
11642 (commit (string-append "v" version))))
11643 (file-name (git-file-name name version))
11644 (sha256
11645 (base32
11646 "0gw7vfnbb41cy67yw82zji3jkhfsgmzcgzaszm99ax77y18wclf2"))
11647 (modules '((guix build utils)))
11648 (snippet
11649 '(begin
11650 ;; Remove bundled library.
11651 (delete-file "spec/rake-12.3.0.gem")
11652 #t))))
11653 (build-system ruby-build-system)
11654 (arguments
11655 '(;; XXX: Tests need multiple versions of ruby, wants to run
11656 ;; `bundle install`, etc.
11657 #:tests? #f
11658 #:phases (modify-phases %standard-phases
11659 (replace 'replace-git-ls-files
11660 (lambda _
11661 (substitute* "wwtd.gemspec"
11662 (("git ls-files lib/ bin/`")
11663 "find lib/ bin/ -type f |sort`"))
11664 #t))
11665 (add-before 'check 'remove-version-constraints
11666 (lambda _
11667 (delete-file "Gemfile.lock")
11668 #t))
11669 (replace 'check
11670 (lambda* (#:key tests? #:allow-other-keys)
11671 (if tests?
11672 (invoke "rspec" "spec/")
11673 (format #t "test suite not run~%"))
11674 #t)))))
11675 (native-inputs
11676 `(("ruby-bump" ,ruby-bump)
11677 ("ruby-rspec" ,ruby-rspec)))
11678 (synopsis "Run @file{.travis.yml} files locally")
11679 (description
11680 "WWTD is a @dfn{Travis Simulator} that lets you run test matrices
11681 defined in @file{.travis.yml} on your local machine, using @code{rvm},
11682 @code{rbenv}, or @code{chruby} to test different versions of Ruby.")
11683 (license license:expat)))