gnu: hdf4: Provide an absolute reference to libjpeg.
[jackhill/guix/guix.git] / gnu / packages / ruby.scm
CommitLineData
6ef8c59a 1;;; GNU Guix --- Functional package management for GNU
37ab3aba 2;;; Copyright © 2014, 2015 Pjotr Prins <pjotr.guix@thebird.nl>
402b03e6 3;;; Copyright © 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
f586c877 4;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
37ab3aba 5;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org>
6742c6f6 6;;; Copyright © 2015, 2019 Ricardo Wurmus <rekado@elephly.net>
cba53c60 7;;; Copyright © 2015, 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
3c986a7d 8;;; Copyright © 2017 Nikita <nikita@n0.is>
3cc8e029 9;;; Copyright © 2017, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
b872b47b 10;;; Copyright © 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
a7b7817d 11;;; Copyright © 2017, 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
6a9d2266 12;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
433e3154 13;;; Copyright © 2017, 2018, 2019 Christopher Baines <mail@cbaines.net>
4db80f8b 14;;; Copyright © 2018 Vasile Dumitrascu <va511e@yahoo.com>
8ef06557 15;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
3355e49c 16;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz>
fc4f7c45 17;;; Copyright © 2019 Mikhail Kirillov <w96k.ru@gmail.com>
369faa59 18;;; Copyright © 2019 Jelle Licht <jlicht@fsfe.org>
9e065a8a 19;;; Copyright © 2019 Brian Leung <bkleung89@gmail.com>
9c4cb1ef 20;;; Copyright © 2019 Collin J. Doering <collin@rekahsoft.ca>
0c558aa9 21;;; Copyright © 2019 Diego N. Barbato <dnbarbato@posteo.de>
fd248cb8 22;;; Copyright © 2019 Brett Gilio <brettg@posteo.de>
6ef8c59a
PP
23;;;
24;;; This file is part of GNU Guix.
25;;;
26;;; GNU Guix is free software; you can redistribute it and/or modify it
27;;; under the terms of the GNU General Public License as published by
28;;; the Free Software Foundation; either version 3 of the License, or (at
29;;; your option) any later version.
30;;;
31;;; GNU Guix is distributed in the hope that it will be useful, but
32;;; WITHOUT ANY WARRANTY; without even the implied warranty of
33;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
34;;; GNU General Public License for more details.
35;;;
36;;; You should have received a copy of the GNU General Public License
37;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
38
39(define-module (gnu packages ruby)
40 #:use-module ((guix licenses) #:prefix license:)
41 #:use-module (gnu packages)
1db791d5 42 #:use-module (gnu packages base)
933dad91 43 #:use-module (gnu packages bison)
15b16c2c 44 #:use-module (gnu packages check)
6ef8c59a 45 #:use-module (gnu packages compression)
2a9ce5cb 46 #:use-module (gnu packages crypto)
4a9e0585 47 #:use-module (gnu packages databases)
255d1bbe 48 #:use-module (gnu packages dbm)
c41fba01 49 #:use-module (gnu packages rails)
6ef8c59a 50 #:use-module (gnu packages readline)
6ef8c59a 51 #:use-module (gnu packages autotools)
ad79eb55 52 #:use-module (gnu packages java)
6ef8c59a 53 #:use-module (gnu packages libffi)
f3d7bb93 54 #:use-module (gnu packages libidn)
c41fba01
CB
55 #:use-module (gnu packages linux)
56 #:use-module (gnu packages lsof)
34138e42 57 #:use-module (gnu packages maths)
0c8eedc1 58 #:use-module (gnu packages ncurses)
fe5dd5f4 59 #:use-module (gnu packages networking)
3ca43524 60 #:use-module (gnu packages node)
ac09beba 61 #:use-module (gnu packages python)
44d10b1f 62 #:use-module (gnu packages python-xyz)
763624f5 63 #:use-module (gnu packages ragel)
30f08487 64 #:use-module (gnu packages rsync)
cd0322a3 65 #:use-module (gnu packages sqlite)
cc2b77df 66 #:use-module (gnu packages tls)
66e20863 67 #:use-module (gnu packages version-control)
6ef8c59a
PP
68 #:use-module (guix packages)
69 #:use-module (guix download)
bda0c139 70 #:use-module (guix git-download)
6ef8c59a 71 #:use-module (guix utils)
acf735f2 72 #:use-module (guix build-system gnu)
e920bfca 73 #:use-module (gnu packages xml)
c2c4e5b2 74 #:use-module (gnu packages web)
15b16c2c
CB
75 #:use-module (guix build-system ruby)
76 #:use-module ((srfi srfi-1) #:select (alist-delete)))
6ef8c59a
PP
77
78(define-public ruby
79 (package
80 (name "ruby")
4914c157 81 (version "2.6.5")
6ef8c59a
PP
82 (source
83 (origin
84 (method url-fetch)
6becfdff
MW
85 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
86 (version-major+minor version)
12d39eb5 87 "/ruby-" version ".tar.xz"))
6ef8c59a
PP
88 (sha256
89 (base32
4914c157 90 "0qhsw2mr04f3lqinkh557msr35pb5rdaqy4vdxcj91flgxqxmmnm"))
65e84e31
BW
91 (modules '((guix build utils)))
92 (snippet `(begin
93 ;; Remove bundled libffi
c033c195 94 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
65e84e31 95 #t))))
6ef8c59a
PP
96 (build-system gnu-build-system)
97 (arguments
98 `(#:test-target "test"
fd248cb8 99 #:configure-flags '("--enable-shared") ; dynamic linking
6ef8c59a 100 #:phases
9656b8be 101 (modify-phases %standard-phases
65e84e31 102 (add-before 'configure 'replace-bin-sh-and-remove-libffi
9656b8be
BW
103 (lambda _
104 (substitute* '("Makefile.in"
105 "ext/pty/pty.c"
106 "io.c"
107 "lib/mkmf.rb"
108 "process.c"
109 "test/rubygems/test_gem_ext_configure_builder.rb"
110 "test/rdoc/test_rdoc_parser.rb"
111 "test/ruby/test_rubyoptions.rb"
112 "test/ruby/test_process.rb"
113 "test/ruby/test_system.rb"
114 "tool/rbinstall.rb")
115 (("/bin/sh") (which "sh")))
116 #t)))))
6ef8c59a
PP
117 (inputs
118 `(("readline" ,readline)
6ef8c59a
PP
119 ("openssl" ,openssl)
120 ("libffi" ,libffi)
4914c157
CB
121 ("gdbm" ,gdbm)))
122 (propagated-inputs
123 `(("zlib" ,zlib)))
6ef8c59a
PP
124 (native-search-paths
125 (list (search-path-specification
126 (variable "GEM_PATH")
3cb3fa67 127 (files (list (string-append "lib/ruby/vendor_ruby"))))))
6becfdff 128 (synopsis "Programming language interpreter")
6ef8c59a
PP
129 (description "Ruby is a dynamic object-oriented programming language with
130a focus on simplicity and productivity.")
bf3be6a5 131 (home-page "https://www.ruby-lang.org")
6ef8c59a
PP
132 (license license:ruby)))
133
1cc7d340
RP
134(define-public ruby-2.7
135 (package
136 (inherit ruby)
137 (version "2.7.1")
138 (source
139 (origin
140 (method url-fetch)
141 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
142 (version-major+minor version)
143 "/ruby-" version ".tar.gz"))
144 (sha256
145 (base32
146 "0674x98f542y02r7n2yv2qhmh97blqhi2mvh2dn5f000vlxlh66l"))
147 (modules '((guix build utils)))
148 (snippet `(begin
149 ;; Remove bundled libffi
150 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
151 #t))))
152 (arguments
153 `(#:test-target "test"
154 #:configure-flags '("--enable-shared") ; dynamic linking
155 #:phases
156 (modify-phases %standard-phases
157 (add-before 'configure 'replace-bin-sh-and-remove-libffi
158 (lambda _
159 (substitute* '("configure.ac"
160 "template/Makefile.in"
161 "lib/rubygems/installer.rb"
162 "ext/pty/pty.c"
163 "io.c"
164 "lib/mkmf.rb"
165 "process.c"
166 "test/rubygems/test_gem_ext_configure_builder.rb"
167 "test/rdoc/test_rdoc_parser.rb"
168 "test/ruby/test_rubyoptions.rb"
169 "test/ruby/test_process.rb"
170 "test/ruby/test_system.rb"
171 "tool/rbinstall.rb")
172 (("/bin/sh") (which "sh")))
173 #t)))))
174 (native-inputs
175 `(("autoconf" ,autoconf)))))
176
227fab3e
CB
177(define-public ruby-2.5
178 (package
179 (inherit ruby)
a09ff632 180 (version "2.5.8")
227fab3e
CB
181 (source
182 (origin
183 (method url-fetch)
184 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
185 (version-major+minor version)
186 "/ruby-" version ".tar.xz"))
187 (sha256
188 (base32
a09ff632 189 "0vad5ah1lrdhxsyqr5iqc8c7r7qczpmm76cz8rsf4crimpzv5483"))
227fab3e
CB
190 (modules '((guix build utils)))
191 (snippet `(begin
192 ;; Remove bundled libffi
193 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
194 #t))))))
195
93cae02f
CB
196(define-public ruby-2.4
197 (package
198 (inherit ruby)
dfe211f9 199 (version "2.4.10")
93cae02f
CB
200 (source
201 (origin
202 (method url-fetch)
203 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
204 (version-major+minor version)
205 "/ruby-" version ".tar.xz"))
206 (sha256
207 (base32
dfe211f9 208 "1prhqlgik1zmw9lakl6hkriqslspw48pvhxff17h7ns42p8qwrnm"))
93cae02f
CB
209 (modules '((guix build utils)))
210 (snippet `(begin
211 ;; Remove bundled libffi
212 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
213 #t))))))
214
933dad91
RW
215(define-public mruby
216 (package
217 (name "mruby")
218 (version "2.0.0")
219 (source
220 (origin
221 (method git-fetch)
222 (uri (git-reference
223 (url "https://github.com/mruby/mruby.git")
224 (commit version)))
225 (file-name (git-file-name name version))
226 (sha256
227 (base32
228 "1r6w1asjshff43ymdwa6xmrkggza99mi2kw88k7ic6ag2j81hcj5"))))
229 (build-system gnu-build-system)
230 (arguments
231 `(#:test-target "test"
232 #:phases
233 (modify-phases %standard-phases
234 (delete 'configure)
235 (add-after 'unpack 'enable-verbose-tests
236 (lambda _
237 (substitute* "Makefile"
238 (("ruby ./minirake" m)
239 (string-append m " --verbose")))
240 #t))
241 (add-after 'unpack 'disable-broken-tests
242 (lambda _
243 (substitute* "mrbgems/mruby-io/test/io.rb"
244 (("assert\\('IO.popen.+$" m)
245 (string-append m "skip \"Hangs in the Guix build environment\"\n"))
246 (("assert\\('IO#isatty.+$" m)
247 (string-append m "skip \"Disable for Guix; there is no /dev/tty\"\n"))
248 ;; This one is really weird. The *expected* output is all wrong.
249 (("assert\\('`cmd`.*" m)
250 (string-append m "skip \"Disable for Guix\"\n"))
251 (("echo foo")
252 (string-append (which "echo") " foo")))
253 #t))
254 ;; There is no install target
255 (replace 'install
256 (lambda* (#:key outputs #:allow-other-keys)
257 (let* ((out (assoc-ref outputs "out"))
258 (bin (string-append out "/bin"))
259 (lib (string-append out "/lib")))
260 (mkdir-p bin)
261 (copy-recursively "build/host/bin" bin)
262 (mkdir-p lib)
263 (copy-recursively "build/host/lib" lib))
264 #t)))))
265 (native-inputs
266 `(("ruby" ,ruby)
267 ("bison" ,bison)))
268 (home-page "https://github.com/mruby/mruby")
269 (synopsis "Lightweight Ruby")
270 (description "mruby is the lightweight implementation of the Ruby
271language. Its syntax is Ruby 1.9 compatible. mruby can be linked and
272embedded within your application.")
273 (license license:expat)))
274
34372d39
RW
275(define-public ruby-commander
276 (package
277 (name "ruby-commander")
278 (version "4.4.7")
279 (source
280 (origin
281 (method url-fetch)
282 (uri (rubygems-uri "commander" version))
283 (sha256
284 (base32
285 "1pxakz596fjqak3cdbha6iva1dlqis86i3kjrgg6lf3sp8i5vhwg"))))
286 (build-system ruby-build-system)
287 (arguments
288 `(#:test-target "spec"
289 #:phases
290 (modify-phases %standard-phases
291 ;; Don't run or require rubocop, the code linting tool, as this is a
292 ;; bit unnecessary.
293 (add-after 'unpack 'dont-run-rubocop
294 (lambda _
295 (substitute* "Rakefile"
296 ((".*rubocop.*") "")
297 ((".*RuboCop.*") ""))
298 #t)))))
299 (propagated-inputs
300 `(("ruby-highline" ,ruby-highline)))
301 (native-inputs
302 `(("bundler" ,bundler)
303 ("ruby-rspec-core" ,ruby-rspec-core)
304 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
305 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
306 ("ruby-simplecov" ,ruby-simplecov)))
307 (home-page "https://github.com/commander-rb/commander")
308 (synopsis "Library for building Ruby command-line executables")
309 (description
310 "Commander aims to be a complete solution for Ruby command-line
311executables. Commander bridges the gap between other terminal related
312libraries (OptionParser, HighLine), while providing many new features, and an
313elegant API.")
314 (license license:expat)))
315
823ed097
CB
316(define-public ruby-highline
317 (package
318 (name "ruby-highline")
6742c6f6 319 (version "2.0.1")
823ed097
CB
320 (source
321 (origin
322 (method url-fetch)
323 (uri (rubygems-uri "highline" version))
324 (sha256
325 (base32
6742c6f6 326 "0gr6pckj2jayxw1gdgh9193j5jag5zrrqqlrnl4jvcwpyd3sn2zc"))))
823ed097
CB
327 (build-system ruby-build-system)
328 (arguments
329 `(#:tests? #f)) ;; TODO: NameError: uninitialized constant SPEC
330 (native-inputs
331 `(("bundler" ,bundler)
332 ("ruby-code-statistics" ,ruby-code-statistics)))
333 (synopsis
334 "HighLine helps you build command-line interfaces")
335 (description
336 "HighLine provides a high-level IO library that provides validation,
337type conversion, and more for command-line interfaces. HighLine also includes
338a menu system for providing multiple options to the user.")
339 (home-page "https://github.com/JEG2/highline")
340 (license (list license:gpl2 license:ruby))))
341
bda0c139
DT
342(define-public ruby-hoe
343 (package
344 (name "ruby-hoe")
d0d2dd24 345 (version "3.21.0")
bda0c139 346 (source (origin
e83c6d00
DT
347 (method url-fetch)
348 (uri (rubygems-uri "hoe" version))
bda0c139
DT
349 (sha256
350 (base32
d0d2dd24 351 "0qid0n56mgsjvq5ksxajv0gb92akky8imwgvw22ajms5g4fd6nf4"))))
bda0c139 352 (build-system ruby-build-system)
d0d2dd24
CB
353 (arguments
354 '(#:phases
355 (modify-phases %standard-phases
356 ;; One of the tests fails if the SOURCE_DATE_EPOCH environment
357 ;; variable is set, so unset it for the duration of the tests.
358 ;;
359 ;; TestHoe#test_possibly_better
360 ;; [/tmp/guix-build-ruby-hoe-3.20.0.drv-0/gem/test/test_hoe.rb:250]:
361 ;; Expected: 2019-11-12 00:00:00 UTC
362 ;; Actual: 1970-01-01 00:00:00 UTC
363 (add-before 'check 'unset-SOURCE-DATE-EPOCH
364 (lambda _
365 (unsetenv "SOURCE_DATE_EPOCH")
366 #t))
367 (add-after 'check 'set-SOURCE-DATE-EPOCH-again
368 (lambda _
369 (setenv "SOURCE_DATE_EPOCH" "1")
370 #t)))))
bda0c139
DT
371 (synopsis "Ruby project management helper")
372 (description
373 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
374maintain, and release projects and includes a dynamic plug-in system allowing
375for easy extensibility. Hoe ships with plug-ins for all the usual project
376tasks including rdoc generation, testing, packaging, deployment, and
377announcement.")
2f3800e5 378 (home-page "https://www.zenspider.com/projects/hoe.html")
bda0c139
DT
379 (license license:expat)))
380
022170dc
PP
381(define-public ruby-rake-compiler
382 (package
383 (name "ruby-rake-compiler")
0cd7b816 384 (version "1.0.4")
022170dc
PP
385 (source (origin
386 (method url-fetch)
e83c6d00 387 (uri (rubygems-uri "rake-compiler" version))
022170dc
PP
388 (sha256
389 (base32
0cd7b816 390 "1xpdi4w8zaklk1i9ps8g3k0icw3v5fcks092l84w28rgrpx82qip"))))
022170dc
PP
391 (build-system ruby-build-system)
392 (arguments
e83c6d00 393 '(#:tests? #f)) ; needs cucumber
022170dc 394 (synopsis "Building and packaging helper for Ruby native extensions")
e881752c 395 (description "Rake-compiler provides a framework for building and
022170dc
PP
396packaging native C and Java extensions in Ruby.")
397 (home-page "https://github.com/rake-compiler/rake-compiler")
398 (license license:expat)))
399
30f08487
RW
400(define-public ruby-rsync
401 (package
402 (name "ruby-rsync")
403 (version "1.0.9")
404 (source
405 (origin
406 (method url-fetch)
407 (uri (rubygems-uri "rsync" version))
408 (sha256
409 (base32
410 "0p8b27q1gvxilqfq2528xpwglzcm2myikkjxpqk7mwbwg9r6knxv"))))
411 (build-system ruby-build-system)
412 (arguments
413 '(#:test-target "spec"
414 #:phases
415 (modify-phases %standard-phases
416 (add-after 'unpack 'remove-coveralls-requirement
417 (lambda _
418 (substitute* "spec/spec_helper.rb"
419 (("require 'coveralls'") "")
420 (("Coveralls.wear!") ""))
421 #t)))))
422 (native-inputs
423 `(("bundler" ,bundler)
424 ("rsync" ,rsync)
425 ("ruby-rspec-core" ,ruby-rspec-core)
426 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
427 ("ruby-rspec-mocks" ,ruby-rspec-mocks)))
428 (home-page "https://github.com/jbussdieker/ruby-rsync")
429 (synopsis "Ruby wrapper around rsync")
430 (description
431 "Ruby Rsync is a Ruby library that can synchronize files between remote
432hosts by wrapping the @file{rsync} binary.")
433 (license license:expat)))
434
acf735f2
DT
435(define-public ruby-i18n
436 (package
437 (name "ruby-i18n")
92dddf6b 438 (version "1.7.0")
acf735f2
DT
439 (source (origin
440 (method url-fetch)
e83c6d00 441 (uri (rubygems-uri "i18n" version))
acf735f2
DT
442 (sha256
443 (base32
92dddf6b 444 "0hmypvx9iyc0b4hski7aic2xzm09cg1c7q1qlpnk3k8s5acxzyhl"))))
acf735f2
DT
445 (build-system ruby-build-system)
446 (arguments
0bfdfd37 447 '(#:tests? #f)) ; no tests
cbb50182 448 (propagated-inputs `(("concurrent-ruby" ,ruby-concurrent)))
acf735f2
DT
449 (synopsis "Internationalization library for Ruby")
450 (description "Ruby i18n is an internationalization and localization
451solution for Ruby programs. It features translation and localization,
452interpolation of values to translations, pluralization, customizable
453transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
454translation data, custom key/scope separator, custom exception handlers, and
455an extensible architecture with a swappable backend.")
92dddf6b 456 (home-page "https://github.com/ruby-i18n/i18n")
acf735f2 457 (license license:expat)))
eb0c2dd6 458
62b138ca
CB
459(define-public ruby-iruby
460 (package
461 (name "ruby-iruby")
462 (version "0.3")
463 (source
464 (origin
465 (method url-fetch)
466 (uri (rubygems-uri "iruby" version))
467 (sha256
468 (base32
469 "1wdf2c0x8y6cya0n3y0p3p7b1sxkb2fdavdn2k58rf4rs37s7rzn"))))
470 (build-system ruby-build-system)
471 (arguments
472 ;; TODO: Tests currently fail.
473 ;;
474 ;; Finished in 1.764405s, 1.1335 runs/s, 5.1009 assertions/s.
475 ;;
476 ;; 1) Failure:
477 ;; IntegrationTest#test_interaction [/tmp/guix-build-ruby-iruby-0.3.drv-0/gem/test/integration_test.rb:25]:
478 ;; In [ expected
479 ;;
480 ;; 2 runs, 9 assertions, 1 failures, 0 errors, 0 skips
481 '(#:tests? #f
482 #:phases
483 (modify-phases %standard-phases
484 (add-after 'unpack 'patch-ipython
485 (lambda* (#:key inputs #:allow-other-keys)
486 (substitute* "lib/iruby/command.rb"
487 (("version = `")
488 (string-append
489 "version = `"
490 (assoc-ref inputs "python-ipython")
491 "/bin/"))
492 (("Kernel\\.exec\\('")
493 (string-append
494 "Kernel.exec('"
495 (assoc-ref inputs "python-ipython")
496 "/bin/")))
497 #t)))))
498 (inputs
499 `(("python-ipython" ,python-ipython)))
500 (propagated-inputs
501 `(("ruby-bond" ,ruby-bond)
502 ("ruby-data_uri" ,ruby-data_uri)
503 ("ruby-mimemagic" ,ruby-mimemagic)
504 ("ruby-multi-json" ,ruby-multi-json)
505 ("ruby-cztop" ,ruby-cztop)
506 ;; Optional inputs
507 ("ruby-pry" ,ruby-pry)))
508 (synopsis "Ruby kernel for Jupyter/IPython")
509 (description
510 "This package provides a Ruby kernel for Jupyter/IPython frontends (e.g.
511notebook).")
512 (home-page "https://github.com/SciRuby/iruby")
513 (license license:expat)))
514
eb0c2dd6
DT
515;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
516;; dependencies use RSpec for their test suites! To avoid these circular
517;; dependencies, we disable tests for all of the RSpec-related packages.
87688ff3 518(define-public ruby-rspec-support
eb0c2dd6
DT
519 (package
520 (name "ruby-rspec-support")
bee67d18 521 (version "3.8.0")
eb0c2dd6
DT
522 (source (origin
523 (method url-fetch)
e83c6d00 524 (uri (rubygems-uri "rspec-support" version))
eb0c2dd6
DT
525 (sha256
526 (base32
bee67d18 527 "0p3m7drixrlhvj2zpc38b11x145bvm311x6f33jjcxmvcm0wq609"))))
eb0c2dd6
DT
528 (build-system ruby-build-system)
529 (arguments
530 '(#:tests? #f)) ; avoid dependency cycles
531 (synopsis "RSpec support library")
532 (description "Support utilities for RSpec gems.")
533 (home-page "https://github.com/rspec/rspec-support")
534 (license license:expat)))
535
536(define-public ruby-rspec-core
537 (package
538 (name "ruby-rspec-core")
bee67d18 539 (version "3.8.0")
eb0c2dd6
DT
540 (source (origin
541 (method url-fetch)
e83c6d00 542 (uri (rubygems-uri "rspec-core" version))
eb0c2dd6
DT
543 (sha256
544 (base32
bee67d18 545 "1p1s5bnbqp3sxk67y0fh0x884jjym527r0vgmhbm81w7aq6b7l4p"))))
eb0c2dd6
DT
546 (build-system ruby-build-system)
547 (arguments
548 '(#:tests? #f)) ; avoid dependency cycles
549 (propagated-inputs
550 `(("ruby-rspec-support" ,ruby-rspec-support)))
551 (synopsis "RSpec core library")
552 (description "Rspec-core provides the RSpec test runner and example
553groups.")
554 (home-page "https://github.com/rspec/rspec-core")
555 (license license:expat)))
e6962009 556
64c318f2
BW
557(define-public ruby-rspec-core-2
558 (package (inherit ruby-rspec-core)
559 (version "2.14.8")
560 (source (origin
561 (method url-fetch)
562 (uri (rubygems-uri "rspec-core" version))
563 (sha256
564 (base32
565 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
566 (propagated-inputs `())))
567
20c05ea9 568(define-public ruby-diff-lcs
e6962009
DT
569 (package
570 (name "ruby-diff-lcs")
e2fcef39 571 (version "1.3")
e6962009
DT
572 (source (origin
573 (method url-fetch)
e83c6d00 574 (uri (rubygems-uri "diff-lcs" version))
e6962009
DT
575 (sha256
576 (base32
e2fcef39 577 "18w22bjz424gzafv6nzv98h0aqkwz3d9xhm7cbr1wfbyas8zayza"))))
e6962009
DT
578 (build-system ruby-build-system)
579 (arguments
580 '(#:tests? #f)) ; avoid dependency cycles
581 (synopsis "Compute the difference between two Enumerable sequences")
582 (description "Diff::LCS computes the difference between two Enumerable
583sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
584It includes utilities to create a simple HTML diff output format and a
585standard diff-like tool.")
586 (home-page "https://github.com/halostatue/diff-lcs")
587 (license license:expat)))
588
589(define-public ruby-rspec-expectations
590 (package
591 (name "ruby-rspec-expectations")
bee67d18 592 (version "3.8.2")
e6962009
DT
593 (source (origin
594 (method url-fetch)
e83c6d00 595 (uri (rubygems-uri "rspec-expectations" version))
e6962009
DT
596 (sha256
597 (base32
bee67d18 598 "18l21hy1zdc2pgc2yb17k3n2al1khpfr0z6pijlm852iz6vj0dkm"))))
e6962009
DT
599 (build-system ruby-build-system)
600 (arguments
601 '(#:tests? #f)) ; avoid dependency cycles
602 (propagated-inputs
603 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 604 ("ruby-diff-lcs" ,ruby-diff-lcs)))
e881752c 605 (synopsis "RSpec expectations library")
e6962009
DT
606 (description "Rspec-expectations provides a simple API to express expected
607outcomes of a code example.")
608 (home-page "https://github.com/rspec/rspec-expectations")
609 (license license:expat)))
4f2a0cac 610
fb157f25
BW
611(define-public ruby-rspec-expectations-2
612 (package (inherit ruby-rspec-expectations)
613 (version "2.14.5")
614 (source (origin
615 (method url-fetch)
616 (uri (rubygems-uri "rspec-expectations" version))
617 (sha256
618 (base32
619 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
620 (propagated-inputs
621 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
622
999ffb26
DM
623(define-public ruby-rspec-its
624 (package
625 (name "ruby-rspec-its")
b2244c68 626 (version "1.3.0")
999ffb26
DM
627 (source
628 (origin
3306f02a
CB
629 (method git-fetch)
630 (uri (git-reference
631 (url "https://github.com/rspec/rspec-its.git")
632 (commit (string-append "v" version))))
633 (file-name (git-file-name name version))
999ffb26
DM
634 (sha256
635 (base32
b2244c68 636 "02mlsc9d4d1cjj5vahi8v3q8hyn9fyiv8nnlidhgfh186qp20g1p"))))
999ffb26
DM
637 (build-system ruby-build-system)
638 (arguments
3306f02a
CB
639 `(#:test-target "spec"
640 #:phases
641 (modify-phases %standard-phases
642 (add-after 'unpack 'dont-install-gems-from-gemfile
643 (lambda _
644 (substitute* "Gemfile"
645 (("rspec rspec-core rspec-expectations rspec-mocks rspec-support")
646 ""))
647 #t))
b2244c68
BH
648 (add-before 'build 'update-ffi-in-gemfile
649 (lambda _
650 (substitute* "Gemfile"
651 ((" gem 'ffi', '~> 1.9.25'") " gem 'ffi', '~> 1.10.0'"))
652 #t))
3306f02a
CB
653 (add-before 'build 'remove-unnecessary-dependency-versions-from-gemfile
654 (lambda _
655 (substitute* "rspec-its.gemspec"
656 (("rake.*") "rake'\n")
b2244c68
BH
657 (("spec.add_development_dependency 'cucumber'.*")
658 "spec.add_development_dependency 'cucumber'\n")
3306f02a 659 (("bundler.*") "bundler'\n")
b2244c68 660 (("\"aruba.*") "'aruba'\n"))
3306f02a 661 #t)))))
999ffb26
DM
662 (propagated-inputs
663 `(("ruby-rspec-core" ,ruby-rspec-core)
664 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
3306f02a
CB
665 (native-inputs
666 `(("bundler" ,bundler)
667 ("ruby-cucumber" ,ruby-cucumber)
b2244c68 668 ("ruby-ffi" ,ruby-ffi)
3306f02a
CB
669 ("ruby-aruba" ,ruby-aruba)))
670 (synopsis "RSpec extension that provides the @code{its} method")
671 (description
672 "RSpec::Its provides the its method as a short-hand to specify the expected
673value of an attribute. For example, one can use @code{its(:size)\\{should
674eq(1)\\}}.")
999ffb26
DM
675 (home-page "https://github.com/rspec/rspec-its")
676 (license license:expat)))
677
4f2a0cac
DT
678(define-public ruby-rspec-mocks
679 (package
680 (name "ruby-rspec-mocks")
bee67d18 681 (version "3.8.0")
4f2a0cac
DT
682 (source (origin
683 (method url-fetch)
e83c6d00 684 (uri (rubygems-uri "rspec-mocks" version))
4f2a0cac
DT
685 (sha256
686 (base32
bee67d18 687 "06y508cjqycb4yfhxmb3nxn0v9xqf17qbd46l1dh4xhncinr4fyp"))))
4f2a0cac
DT
688 (build-system ruby-build-system)
689 (arguments
690 '(#:tests? #f)) ; avoid dependency cycles
691 (propagated-inputs
692 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 693 ("ruby-diff-lcs" ,ruby-diff-lcs)))
4f2a0cac
DT
694 (synopsis "RSpec stubbing and mocking library")
695 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
696support for stubbing and mocking.")
697 (home-page "https://github.com/rspec/rspec-mocks")
698 (license license:expat)))
d4fde1f2 699
6da9adeb
BW
700(define-public ruby-rspec-mocks-2
701 (package (inherit ruby-rspec-mocks)
702 (version "2.14.6")
703 (source (origin
704 (method url-fetch)
705 (uri (rubygems-uri "rspec-mocks" version))
706 (sha256
707 (base32
708 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
709 (propagated-inputs
710 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
711
198bc648
CB
712(define-public ruby-rspec-rerun
713 (package
714 (name "ruby-rspec-rerun")
715 (version "1.1.0")
716 (source
717 (origin
718 (method url-fetch)
719 (uri (rubygems-uri "rspec-rerun" version))
720 (sha256
721 (base32
722 "1gy7znkcaqhpccfnk2nvaqbsvgxy3q57cmjwkl9fi1zabaq5lbkj"))))
723 (build-system ruby-build-system)
724 (arguments
725 '(;; No included tests
726 #:tests? #f))
727 (propagated-inputs `(("ruby-rspec" ,ruby-rspec)))
728 (synopsis "Track failed RSpec tests to re-run them")
729 (description
730 "This package provides an automated way to track, and then re-run failed
731RSpec tests.")
732 (home-page "https://github.com/dblock/rspec-rerun")
733 (license license:expat)))
734
9c4cb1ef
CD
735(define-public ruby-rspec-wait
736 (package
737 (name "ruby-rspec-wait")
738 (version "0.0.9")
739 (source
740 (origin
741 (method url-fetch)
742 (uri (rubygems-uri "rspec-wait" version))
743 (sha256
744 (base32
745 "0gvj1bp5ccx001dyvcgk2j49s5sl6vs9fdaqqb08z3bd1554hsww"))))
746 (build-system ruby-build-system)
747 (arguments
748 '(#:phases
749 (modify-phases %standard-phases
750 (replace 'check
751 (lambda _
752 (invoke "rake" "spec"))))))
753 (native-inputs
754 `(("bundler" ,bundler)))
755 (propagated-inputs
756 `(("ruby-rspec" ,ruby-rspec)))
757 (home-page "https://github.com/laserlemon/rspec-wait")
758 (synopsis "Wait for conditions in RSpec")
759 (description
760 "RSpec::Wait strives to make it easier to test asynchronous or slow
761interactions.")
762 (license license:expat)))
763
d4fde1f2
DT
764(define-public ruby-rspec
765 (package
766 (name "ruby-rspec")
bee67d18 767 (version "3.8.0")
d4fde1f2
DT
768 (source (origin
769 (method url-fetch)
e83c6d00 770 (uri (rubygems-uri "rspec" version))
d4fde1f2
DT
771 (sha256
772 (base32
bee67d18 773 "15ppasvb9qrscwlyjz67ppw1lnxiqnkzx5vkx1bd8x5n3dhikxc3"))))
d4fde1f2
DT
774 (build-system ruby-build-system)
775 (arguments
776 '(#:tests? #f)) ; avoid dependency cycles
777 (propagated-inputs
778 `(("ruby-rspec-core" ,ruby-rspec-core)
779 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
780 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
781 (synopsis "Behavior-driven development framework for Ruby")
782 (description "RSpec is a behavior-driven development (BDD) framework for
783Ruby. This meta-package includes the RSpec test runner, along with the
784expectations and mocks frameworks.")
35739712 785 (home-page "https://rspec.info/")
d4fde1f2 786 (license license:expat)))
2cbc105b 787
5ac984b3
BW
788(define-public ruby-rspec-2
789 (package (inherit ruby-rspec)
790 (version "2.14.1")
791 (source (origin
792 (method url-fetch)
793 (uri (rubygems-uri "rspec" version))
794 (sha256
795 (base32
796 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
797 (propagated-inputs
798 `(("ruby-rspec-core" ,ruby-rspec-core-2)
799 ("ruby-rspec-mocks" ,ruby-rspec-mocks-2)
800 ("ruby-rspec-expectations" ,ruby-rspec-expectations-2)))))
801
2cbc105b
DT
802;; Bundler is yet another source of circular dependencies, so we must disable
803;; its test suite as well.
804(define-public bundler
805 (package
806 (name "bundler")
4fdd4d33 807 (version "1.17.3")
2cbc105b
DT
808 (source (origin
809 (method url-fetch)
e83c6d00 810 (uri (rubygems-uri "bundler" version))
2cbc105b
DT
811 (sha256
812 (base32
4fdd4d33 813 "0ln3gnk7cls81gwsbxvrmlidsfd78s6b2hzlm4d4a9wbaidzfjxw"))))
2cbc105b
DT
814 (build-system ruby-build-system)
815 (arguments
816 '(#:tests? #f)) ; avoid dependency cycles
817 (synopsis "Ruby gem bundler")
818 (description "Bundler automatically downloads and installs a list of gems
819specified in a \"Gemfile\", as well as their dependencies.")
2f3800e5 820 (home-page "https://bundler.io/")
2cbc105b 821 (license license:expat)))
98b87b82 822
cf36174f
RW
823(define-public ruby-builder
824 (package
825 (name "ruby-builder")
42b48db2 826 (version "3.2.3")
cf36174f
RW
827 (source (origin
828 (method url-fetch)
829 (uri (rubygems-uri "builder" version))
830 (sha256
831 (base32
42b48db2 832 "0qibi5s67lpdv1wgcj66wcymcr04q6j4mzws6a479n0mlrmh5wr1"))))
cf36174f
RW
833 (build-system ruby-build-system)
834 (arguments
835 `(#:phases
836 (modify-phases %standard-phases
837 (add-after 'unpack 'do-not-use-rvm
838 (lambda _
839 (substitute* "rakelib/tags.rake"
840 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
841 #t)))))
842 (synopsis "Ruby library to create structured data")
843 (description "Builder provides a number of builder objects that make it
844easy to create structured data. Currently the following builder objects are
845supported: XML Markup and XML Events.")
846 (home-page "https://github.com/jimweirich/builder")
847 (license license:expat)))
848
566f71f8
CB
849(define-public ruby-bump
850 (package
851 (name "ruby-bump")
852 (version "0.7.0")
853 (source
854 (origin
855 (method url-fetch)
856 (uri (rubygems-uri "bump" version))
857 (sha256
858 (base32
859 "1xinbr9rzh6cj75x24niwgqcnbhdxc68a8bc41lk8xv6fd906fym"))))
860 (build-system ruby-build-system)
861 (arguments
862 '(;; No included tests
863 #:tests? #f))
864 (synopsis "Tool for working with Rubygems")
865 (description
866 "Bump provides commands to manage Rubygem versioning, updating to the
867next patch version for example.")
868 (home-page "https://github.com/gregorym/bump")
869 (license license:expat)))
870
ad79eb55
RW
871(define-public ruby-rjb
872 (package
873 (name "ruby-rjb")
aeb4e61e 874 (version "1.5.5")
ad79eb55
RW
875 (source (origin
876 (method url-fetch)
877 (uri (rubygems-uri "rjb" version))
878 (sha256
879 (base32
aeb4e61e 880 "1ppj8rbicj3w0nhh7f73mflq19yd7pzdzkh2a91hcvphriy5b0ca"))))
ad79eb55
RW
881 (build-system ruby-build-system)
882 (arguments
883 `(#:tests? #f ; no rakefile
884 #:phases
885 (modify-phases %standard-phases
886 (add-before 'build 'set-java-home
887 (lambda* (#:key inputs #:allow-other-keys)
888 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
889 #t)))))
890 (native-inputs
d2540f80 891 `(("jdk" ,icedtea "jdk")))
ad79eb55
RW
892 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
893 (description "RJB is a bridge program that connects Ruby and Java via the
894Java Native Interface.")
2f3800e5 895 (home-page "https://www.artonx.org/collabo/backyard/?RubyJavaBridge")
ad79eb55
RW
896 (license license:lgpl2.1+)))
897
f9ae2c06
PP
898(define-public ruby-log4r
899 (package
900 (name "ruby-log4r")
901 (version "1.1.10")
902 (source
903 (origin
904 (method url-fetch)
905 (uri (rubygems-uri "log4r" version))
906 (sha256
907 (base32
908 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
909 (build-system ruby-build-system)
910 (arguments
911 '(#:tests? #f)) ; no Rakefile in gem
912 (synopsis "Flexible logging library for Ruby")
913 (description "Comprehensive and flexible logging library written
914in Ruby for use in Ruby programs. It features a hierarchical logging
915system of any number of levels, custom level names, logger
916inheritance, multiple output destinations per log event, execution
917tracing, custom formatting, thread safteyness, XML and YAML
918configuration, and more.")
919 (home-page "http://log4r.rubyforge.org/")
920 (license license:bsd-3)))
921
71a03c29
RW
922(define-public ruby-atoulme-antwrap
923 (package
924 (name "ruby-atoulme-antwrap")
925 (version "0.7.5")
926 (source (origin
927 (method url-fetch)
928 (uri (rubygems-uri "atoulme-Antwrap" version))
929 (sha256
930 (base32
931 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
932 (build-system ruby-build-system)
933 ;; Test data required for most of the tests are not included.
934 (arguments `(#:tests? #f))
935 (native-inputs
936 `(("ruby-hoe" ,ruby-hoe)))
937 (inputs
938 `(("ruby-rjb" ,ruby-rjb)))
939 (synopsis "Ruby wrapper for the Ant build tool")
940 (description "Antwrap is a Ruby module that wraps the Apache Ant build
941tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
942script.")
943 (home-page "http://rubyforge.org/projects/antwrap/")
944 (license license:expat)))
945
fe1ddad5
RW
946(define-public ruby-atoulme-saikuro
947 (package
948 (name "ruby-atoulme-saikuro")
949 (version "1.2.1")
950 (source (origin
951 (method url-fetch)
952 (uri (rubygems-uri "atoulme-Saikuro" version))
953 (sha256
954 (base32
955 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
956 (build-system ruby-build-system)
957 ;; FIXME: There are no unit tests. The tests are demonstrations of the
958 ;; "saikuro" tool.
959 (arguments `(#:tests? #f))
960 (synopsis "Cyclomatic complexity analyzer")
961 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
962given Ruby source code Saikuro will generate a report listing the cyclomatic
963complexity of each method found. In addition, Saikuro counts the number of
964lines per method and can generate a listing of the number of tokens on each
965line of code.")
966 (home-page "http://www.github.com/atoulme/Saikuro")
967 ;; File headers contain the BSD-3 license and the README.rdoc says that
968 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
969 ;; of the Expat license.
970 (license license:bsd-3)))
971
34138e42
BW
972(define-public ruby-asciidoctor
973 (package
974 (name "ruby-asciidoctor")
9933a8e7 975 (version "1.5.7.1")
34138e42
BW
976 (source
977 (origin
978 (method url-fetch)
979 (uri (rubygems-uri "asciidoctor" version))
980 (sha256
981 (base32
9933a8e7 982 "0v52bzc72cvg7zfgq27pa4mgyf29dx9m20fghrw1xmvwgd519n1w"))))
34138e42
BW
983 (build-system ruby-build-system)
984 (arguments
985 `(#:test-target "test:all"
986 #:phases
987 (modify-phases %standard-phases
988 (add-before 'check 'remove-circular-tests
989 (lambda _
990 ;; Remove tests that require circular dependencies to load or pass.
991 (delete-file "test/invoker_test.rb")
992 (delete-file "test/converter_test.rb")
993 (delete-file "test/options_test.rb")
994 #t)))))
995 (native-inputs
996 `(("ruby-minitest" ,ruby-minitest)
997 ("ruby-nokogiri" ,ruby-nokogiri)
998 ("ruby-asciimath" ,ruby-asciimath)
999 ("ruby-coderay" ,ruby-coderay)))
1000 (synopsis "Converter from AsciiDoc content to other formats")
1001 (description
1002 "Asciidoctor is a text processor and publishing toolchain for converting
20860819 1003AsciiDoc content to HTML5, DocBook 5 (or 4.5), PDF, and other formats.")
bba082a1 1004 (home-page "https://asciidoctor.org")
34138e42
BW
1005 (license license:expat)))
1006
d5840f77
CB
1007(define-public ruby-ast
1008 (package
1009 (name "ruby-ast")
1010 (version "2.4.0")
1011 (source
1012 (origin
1013 (method url-fetch)
1014 (uri (rubygems-uri "ast" version))
1015 (sha256
1016 (base32
1017 "184ssy3w93nkajlz2c70ifm79jp3j737294kbc5fjw69v1w0n9x7"))))
1018 (build-system ruby-build-system)
1019 (arguments
1020 '(#:phases
1021 (modify-phases %standard-phases
1022 (add-after 'unpack 'remove-coveralls-requirement
1023 (lambda _
1024 (substitute* "test/helper.rb"
1025 (("require 'coveralls'") "")
1026 (("Coveralls::SimpleCov::Formatter") ""))
1027 #t))
1028 (add-after 'extract-gemspec 'remove-unnecessary-requirements
1029 (lambda _
1030 (substitute* "ast.gemspec"
1031 ((".*coveralls.*") "\n")
1032 (("%q<rest-client>.*") "%q<rest-client>.freeze, [\">= 0\"])\n")
1033 (("%q<mime-types>.*") "%q<mime-types>.freeze, [\">= 0\"])\n")
1034 (("%q<rake>.*") "%q<rake>.freeze, [\">= 0\"])\n"))
1035 #t)))))
1036 (native-inputs
1037 `(("bundler" ,bundler)
1038 ("ruby-simplecov" ,ruby-simplecov)
1039 ("ruby-json-pure" ,ruby-json-pure)
1040 ("ruby-mime-times" ,ruby-mime-types)
1041 ("ruby-yard" ,ruby-yard)
1042 ("ruby-kramdown" ,ruby-kramdown)
1043 ("ruby-rest-client" ,ruby-rest-client)
1044 ("ruby-bacon" ,ruby-bacon)
1045 ("ruby-bacon-colored-output" ,ruby-bacon-colored-output)
1046 ("ruby-racc" ,ruby-racc)))
1047 (synopsis "Library for working with Abstract Syntax Trees")
1048 (description
1049 "@code{ast} is a Ruby library for working with Abstract Syntax Trees.
1050It does this through immutable data structures.")
1051 (home-page "https://whitequark.github.io/ast/")
1052 (license license:expat)))
1053
b88502c9
BW
1054(define-public ruby-sporkmonger-rack-mount
1055 ;; Testing the addressable gem requires a newer commit than that released, so
1056 ;; use an up to date version.
1057 (let ((revision "1")
1058 (commit "076aa2c47d9a4c081f1e9bcb56a826a9e72bd5c3"))
1059 (package
1060 (name "ruby-sporkmonger-rack-mount")
1061 (version (git-version "0.8.3" revision commit))
1062 (source (origin
1063 (method git-fetch)
1064 (uri (git-reference
1065 (url "https://github.com/sporkmonger/rack-mount.git")
1066 (commit commit)))
1067 (file-name (git-file-name name version))
1068 (sha256
1069 (base32
1070 "1scx273g3xd93424x9lxc4zyvcp2niknbw5mkz6wkivpf7xsyxdq"))))
1071 (build-system ruby-build-system)
1072 (arguments
1073 ;; Tests currently fail so disable them.
1074 ;; https://github.com/sporkmonger/rack-mount/pull/1
1075 `(#:tests? #f))
1076 (propagated-inputs `(("ruby-rack" ,ruby-rack)))
1077 (synopsis "Stackable dynamic tree based Rack router")
1078 (description
1079 "@code{Rack::Mount} supports Rack's @code{X-Cascade} convention to
1080continue trying routes if the response returns pass. This allows multiple
1081routes to be nested or stacked on top of each other.")
1082 (home-page "https://github.com/sporkmonger/rack-mount")
1083 (license license:expat))))
1084
2f9e0b68
RW
1085(define-public ruby-ci-reporter
1086 (package
1087 (name "ruby-ci-reporter")
1088 (version "2.0.0")
1089 (source (origin
1090 (method url-fetch)
1091 (uri (rubygems-uri "ci_reporter" version))
1092 (sha256
1093 (base32
1094 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
1095 (build-system ruby-build-system)
1096 (arguments
1097 `(#:test-target "rspec"))
1098 (propagated-inputs
1099 `(("ruby-builder" ,ruby-builder)))
1100 (native-inputs
1101 `(("bundler" ,bundler)
1102 ("ruby-rspec" ,ruby-rspec)))
1103 (synopsis "Generate XML reports of runs test")
1104 (description
1105 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
1106you to generate XML reports of your test runs. The resulting files can be
1107read by a continuous integration system that understands Ant's JUnit report
1108format.")
1109 (home-page "https://github.com/nicksieger/ci_reporter")
1110 (license license:expat)))
1111
2ed201c1
CB
1112(define-public ruby-contracts
1113 (package
1114 (name "ruby-contracts")
1115 (version "0.16.0")
1116 (source
1117 (origin
1118 (method url-fetch)
1119 (uri (rubygems-uri "contracts" version))
1120 (sha256
1121 (base32
1122 "119f5p1n6r5svbx8h09za6a4vrsnj5i1pzr9cqdn9hj3wrxvyl3a"))))
1123 (build-system ruby-build-system)
1124 (arguments
1125 '(#:test-target "spec"
1126 #:phases
1127 (modify-phases %standard-phases
1128 ;; Don't run or require rubocop, the code linting tool, as this is a
1129 ;; bit unnecessary.
1130 (add-after 'unpack 'dont-run-rubocop
1131 (lambda _
1132 (substitute* "Rakefile"
1133 ((".*rubocop.*") "")
1134 ((".*RuboCop.*") ""))
1135 #t)))))
1136 (native-inputs
1137 `(("ruby-rspec" ,ruby-rspec)))
1138 (synopsis "Method contracts for Ruby")
1139 (description
1140 "This library provides contracts for Ruby. A contract describes the
1141correct inputs and output for a method, and will raise an error if a incorrect
1142value is found.")
1143 (home-page "https://github.com/egonSchiele/contracts.ruby")
1144 (license license:bsd-2)))
1145
6f8bf0eb
CB
1146(define-public ruby-crack
1147 (package
1148 (name "ruby-crack")
1149 (version "0.4.3")
1150 (source
1151 (origin
1152 (method url-fetch)
1153 (uri (rubygems-uri "crack" version))
1154 (sha256
1155 (base32
1156 "0abb0fvgw00akyik1zxnq7yv391va148151qxdghnzngv66bl62k"))))
1157 (build-system ruby-build-system)
1158 (arguments
1159 `(#:phases
1160 (modify-phases %standard-phases
1161 (replace 'check
1162 (lambda* (#:key tests? #:allow-other-keys)
1163 (when tests?
1164 (for-each (lambda (file)
1165 (display file)(display "\n")
1166 (invoke "ruby" "-Ilib" "-Itest" "-rrubygems" file))
1167 (find-files "test" ".*rb$")))
1168 #t)))))
1169 (propagated-inputs
1170 `(("ruby-safe-yaml" ,ruby-safe-yaml)))
1171 (synopsis "Simple JSON and XML parsing for Ruby")
1172 (description
1173 "@code{crack} provides really simple JSON and XML parsing, extracted from
1174code in Merb and Rails.")
1175 (home-page "https://github.com/jnunemaker/crack")
1176 (license license:expat)))
1177
bef3506e
CB
1178(define-public ruby-cliver
1179 (package
1180 (name "ruby-cliver")
1181 (version "0.3.2")
1182 (source
1183 (origin
1184 (method url-fetch)
1185 (uri (rubygems-uri "cliver" version))
1186 (sha256
1187 (base32
1188 "096f4rj7virwvqxhkavy0v55rax10r4jqf8cymbvn4n631948xc7"))))
1189 (build-system ruby-build-system)
1190 (arguments
1191 '(#:phases
1192 (modify-phases %standard-phases
1193 ;; Avoid a incompatibility between rspec@2 and rake. Using rspec@3
1194 ;; would be nice, but the tests look to be incompatible:
1195 ;;
1196 ;; NoMethodError: undefined method `last_comment'
1197 (replace 'check
1198 (lambda* (#:key tests? #:allow-other-keys)
1199 (when tests?
1200 (invoke "rspec"))
1201 #t)))))
1202 (native-inputs
1203 `(("bundler" ,bundler)
1204 ("ruby-rspec" ,ruby-rspec-2)))
1205 (synopsis "Assertions for command-line dependencies in Ruby")
1206 (description
1207 "@code{cliver} provides a way to detect missing command-line
1208dependencies, including versions.")
1209 (home-page "https://github.com/yaauie/cliver")
1210 (license license:expat)))
1211
fe5dd5f4
CB
1212(define-public ruby-czmq-ffi-gen
1213 (package
1214 (name "ruby-czmq-ffi-gen")
1215 (version "0.13.0")
1216 (source
1217 (origin
1218 (method url-fetch)
1219 (uri (rubygems-uri "czmq-ffi-gen" version))
1220 (sha256
1221 (base32
1222 "1yf719dmf4mwks1hqdsy6i5kzfvlsha69sfnhb2fr2cgk2snbys3"))))
1223 (build-system ruby-build-system)
1224 (arguments
1225 '(#:tests? #f ;; Tests are not included in the release on rubygems.org
1226 #:phases
1227 (modify-phases %standard-phases
1228 (add-after 'unpack 'patch-lib_dirs
1229 (lambda* (#:key inputs #:allow-other-keys)
1230 (substitute* "lib/czmq-ffi-gen/czmq/ffi.rb"
1231 (("lib\\_dirs = \\[.*\\]")
1232 (string-append "lib_dirs = ['"
1233 (assoc-ref inputs "czmq") "/lib"
1234 "']")))
1235 (substitute* "lib/czmq-ffi-gen/libzmq.rb"
1236 (("lib\\_dirs = \\[.*\\]")
1237 (string-append "lib_dirs = ['"
1238 (assoc-ref inputs "zeromq") "/lib"
1239 "']"))))))))
1240 (inputs
1241 `(("zeromq" ,zeromq)
1242 ("czmq" ,czmq)))
1243 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
1244 (synopsis "Low-level Ruby bindings for CZMQ (generated using zproject)")
1245 (description
1246 "These Ruby bindings are not intended to be directly used, but rather
1247used by higher level bindings like those provided by CZTop.")
1248 (home-page
1249 "https://github.com/paddor/czmq-ffi-gen")
1250 (license license:isc)))
1251
d0afff26
CB
1252(define-public ruby-cztop
1253 (package
1254 (name "ruby-cztop")
1255 (version "0.12.2")
1256 (source
1257 (origin
1258 (method url-fetch)
1259 (uri (rubygems-uri "cztop" version))
1260 (sha256
1261 (base32
1262 "0yqbpaiw5d7f271d73lyrsh8xpx6n4zi6xqwfgi00dacxrq3s3fa"))))
1263 (build-system ruby-build-system)
1264 (arguments
1265 '(#:test-target "spec"
1266 #:phases
1267 (modify-phases %standard-phases
1268 (add-after 'unpack 'patch-lib_paths
1269 (lambda* (#:key inputs #:allow-other-keys)
1270 (substitute* "lib/cztop/poller/zmq.rb"
1271 (("lib\\_paths = \\[.*\\]")
1272 (string-append "lib_paths = ['"
1273 (assoc-ref inputs "zeromq") "/lib"
1274 "']"))))))))
1275 (native-inputs
1276 `(("bundler" ,bundler)
1277 ("ruby-rspec" ,ruby-rspec)))
1278 (inputs
1279 `(("zeromq" ,zeromq)))
1280 (propagated-inputs
1281 `(("ruby-czmq-ffi-gen" ,ruby-czmq-ffi-gen)))
1282 (synopsis "CZMQ Ruby bindings")
1283 (description
1284 "CZMQ Ruby bindings, based on the generated low-level FFI bindings of
1285CZMQ. The focus of of CZTop is on being easy to use and providing first class
1286support for security mechanisms.")
1287 (home-page "https://github.com/paddor/cztop")
1288 (license license:isc)))
1289
b004fb6a
RW
1290(define-public ruby-saikuro-treemap
1291 (package
1292 (name "ruby-saikuro-treemap")
1293 (version "0.2.0")
1294 (source (origin
1295 (method url-fetch)
1296 (uri (rubygems-uri "saikuro_treemap" version))
1297 (sha256
1298 (base32
1299 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
1300 (build-system ruby-build-system)
1301 ;; Some of the tests fail because the generated JSON has keys in a
1302 ;; different order. This is a problem with the test suite rather than any
1303 ;; of the involved libraries.
1304 (arguments `(#:tests? #f))
1305 (propagated-inputs
1306 `(("ruby-json-pure" ,ruby-json-pure)
1307 ("ruby-atoulme-saikuro" ,ruby-atoulme-saikuro)))
1308 (synopsis "Generate complexity treemap based on saikuro analysis")
1309 (description
1310 "This gem generates a treemap showing the complexity of Ruby code on
1311which it is run. It uses Saikuro under the covers to analyze Ruby code
1312complexity.")
7bf837fd 1313 (home-page "https://github.com/ThoughtWorksStudios/saikuro_treemap")
b004fb6a
RW
1314 (license license:expat)))
1315
92b37500
CB
1316(define-public ruby-oauth2
1317 (package
1318 (name "ruby-oauth2")
5dd10be5 1319 (version "1.4.2")
92b37500
CB
1320 (source
1321 (origin
1322 (method url-fetch)
1323 (uri (rubygems-uri "oauth2" version))
1324 (sha256
5dd10be5 1325 (base32 "15i9z4j5pcjkr30lkcd79xzbr4kpmy0bqgwa436fqyqk646fv036"))))
92b37500
CB
1326 (build-system ruby-build-system)
1327 (arguments
5dd10be5 1328 '(#:tests? #f)) ; no included tests
92b37500
CB
1329 (propagated-inputs
1330 `(("ruby-faraday" ,ruby-faraday)
1331 ("ruby-jwt" ,ruby-jwt)
1332 ("ruby-multi-json" ,ruby-multi-json)
1333 ("ruby-multi-xml" ,ruby-multi-xml)
1334 ("ruby-rack" ,ruby-rack)))
1335 (synopsis "Ruby wrapper for the OAuth 2.0")
1336 (description
1337 "This package provides a Ruby wrapper for the OAuth 2.0 protocol built
1338with a similar style to the original OAuth spec.")
1339 (home-page "https://github.com/oauth-xx/oauth2")
1340 (license license:expat)))
1341
29dc4823
CB
1342(define-public ruby-omniauth
1343 (package
1344 (name "ruby-omniauth")
a7b7817d 1345 (version "1.9.1")
29dc4823
CB
1346 (source
1347 (origin
1348 (method url-fetch)
1349 (uri (rubygems-uri "omniauth" version))
1350 (sha256
a7b7817d 1351 (base32 "002vi9gwamkmhf0dsj2im1d47xw2n1jfhnzl18shxf3ampkqfmyz"))))
29dc4823
CB
1352 (build-system ruby-build-system)
1353 (arguments
1354 '(#:tests? #f)) ; No included tests
1355 (propagated-inputs
1356 `(("ruby-hashie" ,ruby-hashie)
1357 ("ruby-rack" ,ruby-rack)))
1358 (synopsis "Generalized Rack framework for multiple-provider authentication")
1359 (description
1360 "This package provides a generalized Rack framework for multiple-provider
1361authentication.")
1362 (home-page "https://github.com/omniauth/omniauth")
1363 (license license:expat)))
1364
d6084cdb
CB
1365(define-public ruby-omniauth-oauth2
1366 (package
1367 (name "ruby-omniauth-oauth2")
1368 (version "1.6.0")
1369 (source
1370 (origin
1371 (method url-fetch)
1372 (uri (rubygems-uri "omniauth-oauth2" version))
1373 (sha256
1374 (base32
1375 "11mi36l9d97r77q99jnafdc1yaa0a9wahhpp7dj7ank8q52g7g79"))))
1376 (build-system ruby-build-system)
1377 (arguments
1378 '(#:phases
1379 (modify-phases %standard-phases
1380 (add-after 'unpack 'remove-unnecessary-dependencies
1381 (lambda _
1382 ;; The coveralls gem submits coverage information to an online
1383 ;; service, and is unnecessary when running the tests
1384 (substitute* "Gemfile"
1385 ((".*coveralls\"") ""))
1386 (substitute* "spec/helper.rb"
1387 (("require \"coveralls\"") "")
1388 (("Coveralls::SimpleCov::Formatter") ""))
1389 #t)))))
1390 (propagated-inputs
1391 `(("ruby-oauth2" ,ruby-oauth2)
1392 ("ruby-omniauth" ,ruby-omniauth)))
1393 (native-inputs
1394 `(("bundler" ,bundler)
1395 ("ruby-rspec" ,ruby-rspec)
1396 ("ruby-simplecov" ,ruby-simplecov)
1397 ("ruby-rack-test" ,ruby-rack-test)
1398 ("ruby-webmock" ,ruby-webmock-2)))
1399 (synopsis "Abstract OAuth2 strategy for OmniAuth")
1400 (description
1401 "This library provides a generic OAuth2 strategy for OmniAuth. It
1402doesn't provide a way to gather user information, so should be used as a
1403building block for authentication strategies.")
1404 (home-page "https://github.com/omniauth/omniauth-oauth2")
1405 (license license:expat)))
1406
433e3154
CB
1407(define-public ruby-open4
1408 (package
1409 (name "ruby-open4")
1410 (version "1.3.4")
1411 (source
1412 (origin
1413 (method url-fetch)
1414 (uri (rubygems-uri "open4" version))
1415 (sha256
1416 (base32
1417 "1cgls3f9dlrpil846q0w7h66vsc33jqn84nql4gcqkk221rh7px1"))))
1418 (build-system ruby-build-system)
1419 (arguments
1420 '(#:phases
1421 (modify-phases %standard-phases
1422 (add-after 'unpack 'patch
1423 (lambda _
1424 (substitute* "rakefile"
1425 ;; Update the Rakefile so it works
1426 (("-rubygems") "-rrubygems")
1427 (("Config") "RbConfig"))
1428 #t))
1429 (add-before 'check 'set-LIB
1430 (lambda _
1431 ;; This is used in the rakefile when running the tests
1432 (setenv "LIB" "open4")
1433 #t)))))
1434 (synopsis "Open child processes from Ruby and manage them easily")
1435 (description
1436 "@code{Open4} is a Ruby library to run child processes and manage their
1437input and output.")
1438 (home-page "https://github.com/ahoward/open4")
1439 (license license:ruby)))
1440
cef87ed6
CB
1441(define-public ruby-options
1442 (package
1443 (name "ruby-options")
1444 (version "2.3.2")
1445 (source
1446 (origin
1447 (method url-fetch)
1448 (uri (rubygems-uri "options" version))
1449 (sha256
1450 (base32
1451 "1s650nwnabx66w584m1cyw82icyym6hv5kzfsbp38cinkr5klh9j"))))
1452 (build-system ruby-build-system)
1453 (arguments
1454 '(#:tests? #f ;; TODO: NameError: uninitialized constant Config
1455 #:phases
1456 (modify-phases %standard-phases
1457 (add-before 'check 'set-LIB
1458 (lambda _
1459 ;; This is used in the Rakefile, and setting it avoids an issue
1460 ;; with running the tests.
fe27238c
CB
1461 (setenv "LIB" "options")
1462 #t)))))
cef87ed6
CB
1463 (synopsis "Ruby library to parse options from *args cleanly")
1464 (description
1465 "The @code{options} library helps with parsing keyword options in Ruby
1466functions.")
1467 (home-page "https://github.com/ahoward/options")
1468 (license license:ruby)))
1469
d15dbe83
CB
1470(define-public ruby-erubi
1471 (package
1472 (name "ruby-erubi")
1473 (version "1.8.0")
1474 (source
1475 (origin
1476 (method url-fetch)
1477 (uri (rubygems-uri "erubi" version))
1478 (sha256
1479 (base32
1480 "1kagnf6ziahj0d781s6ryy6fwqwa3ad4xbzzj84p9m4nv4c2jir1"))))
1481 (build-system ruby-build-system)
1482 (synopsis "ERB template engine for Ruby")
1483 (description
1484 "Erubi is a ERB template engine for Ruby. It is a simplified fork of
1485Erubis")
1486 (home-page "https://github.com/jeremyevans/erubi")
1487 (license license:expat)))
1488
d64ebebd
BW
1489(define-public ruby-erubis
1490 (package
1491 (name "ruby-erubis")
1492 (version "2.7.0")
1493 (source
1494 (origin
1495 (method url-fetch)
1496 (uri (rubygems-uri "erubis" version))
1497 (sha256
1498 (base32
1499 "1fj827xqjs91yqsydf0zmfyw9p4l2jz5yikg3mppz6d7fi8kyrb3"))))
1500 (build-system ruby-build-system)
1501 (arguments
1502 '(#:tests? #f)) ; tests do not run properly with Ruby 2.0
1503 (synopsis "Implementation of embedded Ruby (eRuby)")
1504 (description
1505 "Erubis is a fast implementation of embedded Ruby (eRuby) with several
1506features such as multi-language support, auto escaping, auto trimming spaces
1507around @code{<% %>}, a changeable embedded pattern, and Ruby on Rails
1508support.")
1509 (home-page "http://www.kuwata-lab.com/erubis/")
1510 (license license:expat)))
1511
3ca43524
CB
1512(define-public ruby-execjs
1513 (package
1514 (name "ruby-execjs")
1515 (version "2.7.0")
1516 (source
1517 (origin
1518 ;; fetch from github as the gem does not contain testing code
1519 (method git-fetch)
1520 (uri (git-reference
1521 (url "https://github.com/rails/execjs.git")
1522 (commit (string-append "v" version))))
1523 (file-name (git-file-name name version))
1524 (sha256
1525 (base32
1526 "0c0vd2mmqq3ar4plbwi2wsbr31vn4h45i19r5km66skydnnbp1y6"))))
1527 (build-system ruby-build-system)
1528 (native-inputs
1529 `(("bundler" ,bundler)
1530 ;; The test suite tests all the available backends. Currenly, this just
1531 ;; means the node backend.
1532 ;;
1533 ;; PASSED: test:node
1534 ;; SKIPPED: test:duktape, ;; test:javascriptcore, test:jscript,
1535 ;; test:miniracer, test:rubyracer, ;; test:rubyrhino, test:v8
1536 ("node" ,node)))
1537 (synopsis "Run JavaScript code from Ruby")
1538 (description
1539 "ExecJS lets you run JavaScript code from Ruby. It automatically picks a
1540runtime to evaluate your JavaScript program, then returns the result to you as
1541a Ruby object.")
1542 (home-page "https://github.com/rails/execjs")
1543 (license license:expat)))
1544
6623a151
MB
1545(define-public ruby-fakefs
1546 (package
1547 (name "ruby-fakefs")
1548 (version "1.2.2")
1549 (home-page "https://github.com/fakefs/fakefs")
1550 (source (origin
1551 ;; The Rubygems release does not contain tests.
1552 (method git-fetch)
1553 (uri (git-reference
1554 (url home-page)
1555 (commit (string-append "v" version))))
1556 (file-name (git-file-name name version))
1557 (sha256
1558 (base32
1559 "008dq9knyip2bfbl0mrk8b8r7bv0k3bf128wcfqsgy1rqal4mgwk"))))
1560 (build-system ruby-build-system)
1561 (arguments
1562 '(#:phases (modify-phases %standard-phases
1563 (replace 'replace-git-ls-files
1564 (lambda _
1565 (substitute* "fakefs.gemspec"
1566 (("`git ls-files lib README.md LICENSE`")
1567 "`find lib README.md LICENSE -type f | sort`"))
1568 #t))
1569 (add-before 'check 'remove-version-constraints
1570 (lambda _
1571 ;; Drop hard version requirements for test dependencies.
1572 (substitute* "fakefs.gemspec"
1573 (("(.*add_development_dependency .*), .*" _ dep)
1574 (string-append dep "\n")))
a011f67b 1575 #t)))))
6623a151
MB
1576 (native-inputs
1577 `(("ruby-bump" ,ruby-bump)
1578 ("ruby-maxitest" ,ruby-maxitest)
1579 ("ruby-rubocop" ,ruby-rubocop)
1580 ("ruby-rspec" ,ruby-rspec)))
1581 (synopsis "Fake file system for Ruby")
1582 (description
1583 "This package provides a fake file system for use in test suites. It
1584avoids the need for manually creating temporary directories, or dealing
1585with platform intricacies in @code{File} and @code{FileUtils}.")
1586 (license license:expat)))
1587
cc53e630
RW
1588(define-public ruby-orderedhash
1589 (package
1590 (name "ruby-orderedhash")
1591 (version "0.0.6")
1592 (source (origin
1593 (method url-fetch)
1594 (uri (rubygems-uri "orderedhash" version))
1595 (sha256
1596 (base32
1597 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
1598 (build-system ruby-build-system)
1599 (arguments
1600 '(#:tests? #f)) ; no test suite
1601 (synopsis "Ruby library providing an order-preserving hash")
1602 (description "Orderedhash is a Ruby library providing a hash
1603implementation that preserves the order of items and features some array-like
1604extensions.")
1605 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
1606 (license license:public-domain)))
1607
28c5d42d
PP
1608(define-public ruby-libxml
1609 (package
1610 (name "ruby-libxml")
acbc5062 1611 (version "3.0.0")
28c5d42d
PP
1612 (source
1613 (origin
1614 (method url-fetch)
1615 (uri (rubygems-uri "libxml-ruby" version))
1616 (sha256
1617 (base32
acbc5062 1618 "0xy8wmjwjcnv36zi042678ncjzpxvy351ccbv7mzkns2n3kxfp54"))))
28c5d42d
PP
1619 (build-system ruby-build-system)
1620 (inputs
1621 `(("zlib" ,zlib)
1622 ("libxml2" ,libxml2)))
1623 (arguments
1624 '(#:tests? #f ; test suite hangs for unknown reason
1625 #:gem-flags
1626 (list "--"
1627 (string-append "--with-xml2-include="
1628 (assoc-ref %build-inputs "libxml2")
1629 "/include/libxml2" ))))
1630 (synopsis "Ruby bindings for GNOME Libxml2")
1631 (description "The Libxml-Ruby project provides Ruby language bindings for
1632the GNOME Libxml2 XML toolkit.")
2f3800e5 1633 (home-page "https://xml4r.github.com/libxml-ruby")
28c5d42d
PP
1634 (license license:expat)))
1635
b3222518
CB
1636(define-public ruby-lino
1637 (package
1638 (name "ruby-lino")
1639 (version "1.1.0")
1640 (source
1641 (origin
1642 (method url-fetch)
1643 (uri (rubygems-uri "lino" version))
1644 (sha256
1645 (base32
1646 "11d29g0fk372b9fcpyr0k6hxm2b4j4igpysmi542hgbbgqgp9cd3"))))
1647 (build-system ruby-build-system)
1648 (arguments
1649 '(#:tests? #f)) ; No included tests
1650 (propagated-inputs
1651 `(("ruby-hamster" ,ruby-hamster)
1652 ("ruby-open4" ,ruby-open4)))
1653 (synopsis "Build and execute commands in Ruby")
1654 (description
1655 "@code{Lino} provides an interface to run external commands. It provides
1656an interface to add options as well as managing the standard input, output and
1657error streams.")
1658 (home-page "https://github.com/tobyclemson/lino")
1659 (license license:expat)))
1660
8b9bde07
RW
1661(define-public ruby-xml-simple
1662 (package
1663 (name "ruby-xml-simple")
1664 (version "1.1.5")
1665 (source (origin
1666 (method url-fetch)
1667 (uri (rubygems-uri "xml-simple" version))
1668 (sha256
1669 (base32
1670 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
1671 (build-system ruby-build-system)
1672 (arguments
1673 '(#:tests? #f)) ; no test suite
1674 (synopsis "Simple Ruby library for XML processing")
1675 (description "This library provides a simple API for XML processing in
1676Ruby.")
1677 (home-page "https://github.com/maik/xml-simple")
1678 (license license:ruby)))
1679
2cb3ab48
RW
1680(define-public ruby-thor
1681 (package
1682 (name "ruby-thor")
2e8cd862 1683 (version "0.19.4")
2cb3ab48
RW
1684 (source (origin
1685 (method url-fetch)
1686 (uri (rubygems-uri "thor" version))
1687 (sha256
1688 (base32
2e8cd862 1689 "01n5dv9kql60m6a00zc0r66jvaxx98qhdny3klyj0p3w34pad2ns"))))
2cb3ab48
RW
1690 (build-system ruby-build-system)
1691 (arguments
1692 '(#:tests? #f)) ; no test suite
1693 (native-inputs
1694 `(("bundler" ,bundler)))
1695 (synopsis "Ruby toolkit for building command-line interfaces")
1696 (description "Thor is a toolkit for building powerful command-line
1697interfaces.")
1698 (home-page "http://whatisthor.com/")
1699 (license license:expat)))
1700
ec79018e
RW
1701(define-public ruby-lumberjack
1702 (package
1703 (name "ruby-lumberjack")
41700efa 1704 (version "1.0.13")
ec79018e
RW
1705 (source (origin
1706 (method url-fetch)
1707 (uri (rubygems-uri "lumberjack" version))
1708 (sha256
1709 (base32
41700efa 1710 "06im7gcg42x77yhz2w5da2ly9xz0n0c36y5ks7xs53v0l9g0vf5n"))))
ec79018e
RW
1711 (build-system ruby-build-system)
1712 (native-inputs
8be62d3f
BW
1713 `(("ruby-rspec" ,ruby-rspec)
1714 ("ruby-timecop" ,ruby-timecop)))
ec79018e
RW
1715 (synopsis "Logging utility library for Ruby")
1716 (description "Lumberjack is a simple logging utility that can be a drop in
1717replacement for Logger or ActiveSupport::BufferedLogger. It provides support
1718for automatically rolling log files even with multiple processes writing the
1719same log file.")
7bf837fd 1720 (home-page "https://github.com/bdurand/lumberjack")
ec79018e
RW
1721 (license license:expat)))
1722
2a9ce5cb
CB
1723(define-public ruby-rbnacl
1724 (package
1725 (name "ruby-rbnacl")
1726 (version "6.0.1")
1727 (source
1728 (origin
1729 (method url-fetch)
1730 (uri (rubygems-uri "rbnacl" version))
1731 (sha256
1732 (base32
1733 "0ajxy5kj2jw09wdsla3jmha8w07vj5l14288xr9djpl327g3lzhn"))))
1734 (build-system ruby-build-system)
1735 (arguments
1736 `(#:phases
1737 (modify-phases %standard-phases
1738 (add-after 'unpack 'remove-unnecessary-dependencies
1739 (lambda _
1740 ;; Coveralls relates to a network service, and Rubocop to code
1741 ;; linting and both are unnecessary to run the tests
1742 (substitute* "Gemfile"
1743 ((".*rubocop.*") "\n")
1744 ((".*guard-rspec.*") "\n")
1745 ((".*coveralls.*") "\n"))
1746 (substitute* "spec/spec_helper.rb"
1747 (("require \"coveralls\"") "")
1748 (("Coveralls.wear!") ""))
1749 #t))
1750 (add-after 'unpack 'use-libsodium-from-store
1751 (lambda* (#:key inputs #:allow-other-keys)
1752 (substitute* '("lib/rbnacl/init.rb"
1753 "lib/rbnacl/sodium.rb")
1754 (("ffi_lib \\[.+\\]")
1755 (string-append "ffi_lib [\""
1756 (assoc-ref inputs "libsodium") "/lib/libsodium.so"
1757 "\"]")))
1758 #t))
1759 ;; Run Rspec directly to avoid the Rubocop dependency in the Rakefile
1760 (replace 'check
1761 (lambda* (#:key tests? #:allow-other-keys)
1762 (when tests?
1763 (invoke "rspec"))
1764 #t)))))
1765 (propagated-inputs
1766 `(("ruby-ffi" ,ruby-ffi)))
1767 (inputs
1768 `(("libsodium" ,libsodium)))
1769 (native-inputs
1770 `(("bundler" ,bundler)
1771 ("ruby-rspec" ,ruby-rspec)))
1772 (synopsis "Ruby FFI binding to libsodium")
1773 (description
1774 "This package provides Ruby FFI bindings to the Networking and
1775Cryptography (NaCl) library, also known as libsodium. This provides a
1776high-level toolkit for building cryptographic systems and protocols.")
1777 (home-page "https://github.com/crypto-rb/rbnacl")
1778 (license license:expat)))
1779
70b4cf38
RW
1780(define-public ruby-nenv
1781 (package
1782 (name "ruby-nenv")
12313cd0 1783 (version "0.3.0")
70b4cf38
RW
1784 (source (origin
1785 (method url-fetch)
1786 (uri (rubygems-uri "nenv" version))
1787 (sha256
1788 (base32
12313cd0 1789 "0r97jzknll9bhd8yyg2bngnnkj8rjhal667n7d32h8h7ny7nvpnr"))))
70b4cf38
RW
1790 (build-system ruby-build-system)
1791 (arguments
1792 `(#:tests? #f)) ; no tests included
1793 (native-inputs
1794 `(("ruby-rspec" ,ruby-rspec)
1795 ("bundler" ,bundler)))
1796 (synopsis "Ruby interface for modifying the environment")
1797 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
1798and inspect the environment.")
1799 (home-page "https://github.com/e2/nenv")
1800 (license license:expat)))
1801
8d9e9f28
RW
1802(define-public ruby-permutation
1803 (package
1804 (name "ruby-permutation")
1805 (version "0.1.8")
1806 (source (origin
1807 (method url-fetch)
1808 (uri (rubygems-uri "permutation" version))
1809 (sha256
1810 (base32
1811 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
1812 (build-system ruby-build-system)
1813 (arguments
1814 `(#:phases
1815 (modify-phases %standard-phases
1816 (add-after 'unpack 'fix-rakefile
1817 (lambda _
1818 (substitute* "Rakefile"
1819 (("require 'rake/gempackagetask'")
1820 "require 'rubygems/package_task'")
1821 (("include Config") ""))
1822 #t))
1823 (replace 'check
1824 (lambda _
9923d5a4 1825 (invoke "ruby" "-Ilib" "test/test.rb"))))))
8d9e9f28
RW
1826 (synopsis "Library to perform operations with sequence permutations")
1827 (description "This package provides a Ruby library to perform different
1828operations with permutations of sequences, such as strings and arrays.")
2f3800e5 1829 (home-page "https://flori.github.io/permutation")
8d9e9f28
RW
1830 (license license:gpl2))) ; GPL 2 only
1831
c5d14d42
RW
1832(define-public ruby-shellany
1833 (package
1834 (name "ruby-shellany")
1835 (version "0.0.1")
1836 (source (origin
1837 (method url-fetch)
1838 (uri (rubygems-uri "shellany" version))
1839 (sha256
1840 (base32
1841 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
1842 (build-system ruby-build-system)
1843 (arguments
1844 `(#:test-target "default"
1845 #:phases
1846 (modify-phases %standard-phases
1847 (add-after 'unpack 'fix-version-test
1848 (lambda _
1849 (substitute* "spec/shellany_spec.rb"
1850 (("^RSpec") "require \"shellany\"\nRSpec"))
1851 #t)))))
1852 (native-inputs
1853 `(("ruby-rspec" ,ruby-rspec)
1854 ("ruby-nenv" ,ruby-nenv)
1855 ("bundler" ,bundler)))
1856 (synopsis "Capture command output")
1857 (description "Shellany is a Ruby library providing functions to capture
1858the output produced by running shell commands.")
1859 (home-page "https://rubygems.org/gems/shellany")
1860 (license license:expat)))
1861
d152162f
RW
1862(define-public ruby-notiffany
1863 (package
1864 (name "ruby-notiffany")
8c1e4a4f 1865 (version "0.1.3")
d152162f
RW
1866 (source (origin
1867 (method url-fetch)
1868 (uri (rubygems-uri "notiffany" version))
1869 (sha256
1870 (base32
8c1e4a4f 1871 "0f47h3bmg1apr4x51szqfv3rh2vq58z3grh4w02cp3bzbdh6jxnk"))))
d152162f
RW
1872 (build-system ruby-build-system)
1873 ;; Tests are not included in the gem.
1874 (arguments `(#:tests? #f))
1875 (propagated-inputs
1876 `(("ruby-shellany" ,ruby-shellany)
1877 ("ruby-nenv" ,ruby-nenv)))
1878 (native-inputs
1879 `(("bundler" ,bundler)))
01eb17de
VC
1880 (synopsis "Wrapper library for notification libraries")
1881 (description "Notiffany is a Ruby wrapper library for notification
d152162f
RW
1882libraries such as Libnotify.")
1883 (home-page "https://github.com/guard/notiffany")
1884 (license license:expat)))
1885
96bf7521
MB
1886(define-public ruby-forking-test-runner
1887 (package
1888 (name "ruby-forking-test-runner")
1889 (version "1.6.0")
1890 (home-page "https://github.com/grosser/forking_test_runner")
1891 (source (origin
1892 (method git-fetch)
1893 (uri (git-reference (url home-page)
1894 (commit (string-append "v" version))))
1895 (file-name (git-file-name name version))
1896 (sha256
1897 (base32
1898 "1mrglzkj2nrgisccf2f30zbfmcs0awv1g3lw994b2az90fl39x8m"))))
1899 (build-system ruby-build-system)
1900 (arguments
1901 '(#:test-target "spec"
1902 ;; FIXME: ActiveRecord depends on sqlite3 1.3.6, but Guix has
1903 ;; 1.4.1, which in turn breaks the tests that use ActiveRecord.
1904 #:tests? #f
1905 #:phases (modify-phases %standard-phases
1906 (replace 'replace-git-ls-files
1907 (lambda _
1908 (substitute* "forking_test_runner.gemspec"
1909 (("`git ls-files lib/ bin/ MIT-LICENSE`")
1910 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
1911 #t))
1912 (add-before 'check 'remove-version-constraints
1913 (lambda _
1914 ;; Ignore hard coded version constraints for the tests.
1915 (delete-file "Gemfile.lock")
1916 #t))
1917 (add-before 'check 'set-HOME
1918 (lambda _
1919 ;; Many tests invoke Bundler, and fails when Bundler
1920 ;; warns that /homeless-shelter does not exist.
1921 (setenv "HOME" "/tmp")
1922 #t)))))
1923 (native-inputs
1924 `(("ruby-activerecord" ,ruby-activerecord)
1925 ("ruby-bump" ,ruby-bump)
1926 ("ruby-rspec" ,ruby-rspec)
1927 ("ruby-sqlite3" ,ruby-sqlite3)
1928 ("ruby-wwtd" ,ruby-wwtd)))
1929 (propagated-inputs
1930 `(("ruby-parallel-tests" ,ruby-parallel-tests)))
1931 (synopsis "Run every test in a fork")
1932 (description
1933 "This package is a wrapper around @code{parallel_tests} that runs every
1934test in a fork to avoid pollution and get clean output per test.")
1935 (license license:expat)))
1936
8528365b
RW
1937(define-public ruby-formatador
1938 (package
1939 (name "ruby-formatador")
1940 (version "0.2.5")
1941 (source (origin
1942 (method url-fetch)
1943 (uri (rubygems-uri "formatador" version))
1944 (sha256
1945 (base32
1946 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
1947 (build-system ruby-build-system)
1948 ;; Circular dependency: Tests require ruby-shindo, which requires
1949 ;; ruby-formatador at runtime.
1950 (arguments `(#:tests? #f))
1951 (synopsis "Ruby library to format text on stdout")
1952 (description "Formatador is a Ruby library to format text printed to the
1953standard output stream.")
7bf837fd 1954 (home-page "https://github.com/geemus/formatador")
8528365b
RW
1955 (license license:expat)))
1956
5437c741
CB
1957(define-public ruby-fuubar
1958 (package
1959 (name "ruby-fuubar")
1960 (version "2.3.2")
1961 (source
1962 (origin
1963 ;; Fetch from the git repository, as the gem package doesn't include
1964 ;; the tests.
1965 (method git-fetch)
1966 (uri (git-reference
1967 (url "https://github.com/thekompanee/fuubar.git")
1968 (commit (string-append "releases/v" version))))
1969 (file-name (git-file-name name version))
1970 (sha256
1971 (base32
1972 "0jm1x2xp13csbnadixaikj7mlkp5yk4byx51npm56zi13izp7259"))))
1973 (build-system ruby-build-system)
1974 (arguments
1975 '(;; TODO: Some tests fail, unsure why.
1976 ;; 21 examples, 7 failures
1977 #:tests? #f
1978 #:phases
1979 (modify-phases %standard-phases
1980 (add-before 'build 'delete-certificate
1981 (lambda _
1982 ;; Remove 's.cert_chain' as we do not build with a private key
1983 (substitute* "fuubar.gemspec"
1984 ((".*cert_chain.*") "")
1985 ((".*signing_key.*") ""))
1986 #t))
1987 (replace 'check
1988 (lambda* (#:key tests? #:allow-other-keys)
1989 (when tests?
1990 (invoke "rspec"))
1991 #t)))))
1992 (native-inputs
1993 `(("bundler" ,bundler)))
1994 (propagated-inputs
1995 `(("ruby-rspec-core" ,ruby-rspec-core)
1996 ("ruby-progressbar" ,ruby-progressbar)))
1997 (synopsis "Fuubar is an RSpec formatter that uses a progress bar")
1998 (description
1999 "Fuubar is an RSpec formatter that uses a progress bar instead of a
2000string of letters and dots as feedback. It also stops on the first test
2001failure.")
2002 (home-page "https://github.com/thekompanee/fuubar")
2003 (license license:expat)))
2004
8ea991e3
CB
2005(define-public ruby-haml
2006 (package
2007 (name "ruby-haml")
2008 (version "5.0.4")
2009 (source
2010 (origin
2011 (method url-fetch)
2012 (uri (rubygems-uri "haml" version))
2013 (sha256
2014 (base32
2015 "1q0a9fvqh8kn6wm97fcks6qzbjd400bv8bx748w8v87m7p4klhac"))))
2016 (build-system ruby-build-system)
2017 (arguments
2018 '(#:tests? #f)) ; No included tests
2019 (propagated-inputs
2020 `(("ruby-tilt" ,ruby-tilt)
2021 ("ruby-temple" ,ruby-temple)))
2022 (synopsis "Haml is a Ruby library to generate HTML documents")
2023 (description
2024 "@acronym{Haml, HTML Abstraction Markup Language} is a layer on top of
2025HTML or XML that is designed to express the structure of documents using
2026indentation rather than closing tags. It was originally envisioned as a
2027plugin for Ruby on Rails, but it can function as a stand-alone templating
2028engine.")
2029 (home-page "http://haml.info/")
2030 (license license:expat)))
2031
353b7eb8
CB
2032(define-public ruby-hamster
2033 (package
2034 (name "ruby-hamster")
2035 (version "3.0.0")
2036 (source
2037 (origin
2038 (method url-fetch)
2039 (uri (rubygems-uri "hamster" version))
2040 (sha256
2041 (base32
2042 "1n1lsh96vnyc1pnzyd30f9prcsclmvmkdb3nm5aahnyizyiy6lar"))))
2043 (build-system ruby-build-system)
2044 (arguments
2045 '(#:phases
2046 (modify-phases %standard-phases
2047 (add-after 'unpack 'remove-unnecessary-dependencies
2048 (lambda _
2049 ;; pry is a debugging tool, and is unnecessary when running the
2050 ;; tests
2051 (substitute* "spec/lib/hamster/vector/insert_spec.rb"
2052 (("require 'pry'") ""))
2053 (substitute* "spec/spec_helper.rb"
2054 (("require \"pry\"") "")
2055 ;; CodeClimate is an online service, and is unnecessary for
2056 ;; running the tests
2057 (("require \"codeclimate-test-reporter\"") "")
2058 (("CodeClimate.*\n") ""))
2059 #t))
2060 ;; No Rakefile is included, so run rspec directly.
2061 (replace 'check
2062 (lambda* (#:key tests? #:allow-other-keys)
2063 (when tests?
2064 (invoke "rspec"))
2065 #t)))))
2066 (propagated-inputs
2067 `(("ruby-concurrent" ,ruby-concurrent)))
2068 (native-inputs
2069 `(("ruby-rspec" ,ruby-rspec)))
2070 (synopsis "Efficient, immutable, thread-safe collection classes for Ruby")
2071 (description
2072 "Hamster provides 6 persistent data structures: @code{Hash}, @code{Vector},
2073@code{Set}, @code{SortedSet}, @code{List}, and @code{Deque} (which works as an
2074immutable queue or stack).")
2075 (home-page "https://github.com/hamstergem/hamster")
2076 (license license:expat)))
2077
21781436
CB
2078(define-public ruby-hashdiff
2079 (package
2080 (name "ruby-hashdiff")
2081 (version "0.3.8")
2082 (source
2083 (origin
2084 (method url-fetch)
2085 (uri (rubygems-uri "hashdiff" version))
2086 (sha256
2087 (base32
2088 "19ykg5pax8798nh1yv71adkx0zzs7gn2rxjj86v7nsw0jba5lask"))))
2089 (build-system ruby-build-system)
2090 (arguments
2091 '(#:phases
2092 (modify-phases %standard-phases
2093 ;; Run tests directly via rspec to avoid Rake issue:
2094 ;; NoMethodError: undefined method `last_comment'
2095 (replace 'check
2096 (lambda* (#:key tests? #:allow-other-keys)
2097 (when tests?
2098 (invoke "rspec"))
2099 #t)))))
2100 (native-inputs
2101 `(("bundler" ,bundler)
2102 ("ruby-rspec" ,ruby-rspec-2)))
2103 (synopsis "HashDiff computes the smallest difference between two hashes")
2104 (description
2105 "HashDiff is a Ruby library to compute the smallest difference between
2106two hashes.")
2107 (home-page "https://github.com/liufengyun/hashdiff")
2108 (license license:expat)))
2109
3cc8e029
MB
2110(define-public ruby-hydra
2111 ;; No releases yet.
2112 (let ((commit "5abfa378743756ae4d9306cc134bcc482f5c9525")
2113 (revision "0"))
2114 (package
2115 (name "ruby-hydra")
2116 (version (git-version "0.0" revision commit))
2117 (home-page "https://github.com/hyphenation/hydra")
2118 (source (origin
2119 (method git-fetch)
2120 (uri (git-reference (url home-page) (commit commit)))
2121 (file-name (git-file-name name version))
2122 (sha256
2123 (base32
2124 "1cik398l2765y3d9sdhjzki3303hkry58ac6jlkiy7iy62nm529f"))))
2125 (build-system ruby-build-system)
2126 (arguments
2127 '(#:phases (modify-phases %standard-phases
2128 (add-after 'unpack 'make-files-writable
2129 (lambda _
2130 (for-each make-file-writable (find-files "."))
2131 #t))
2132 (replace 'check
2133 (lambda _
2134 (invoke "rspec"))))))
2135 (native-inputs
2136 `(("ruby-rspec" ,ruby-rspec)))
2137 (propagated-inputs
2138 `(("ruby-byebug" ,ruby-byebug)))
2139 (synopsis "Ruby hyphenation patterns")
2140 (description
2141 "ruby-hydra is a Ruby library for working with hyphenation patterns.")
2142 (license license:expat))))
2143
7ac4610f
RW
2144(define-public ruby-shindo
2145 (package
2146 (name "ruby-shindo")
2147 (version "0.3.8")
2148 (source (origin
2149 (method url-fetch)
2150 (uri (rubygems-uri "shindo" version))
2151 (sha256
2152 (base32
2153 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
2154 (build-system ruby-build-system)
2155 (arguments
2156 `(#:test-target "shindo_tests"
2157 #:phases
2158 (modify-phases %standard-phases
2159 (add-after 'unpack 'fix-tests
0b060e34
CB
2160 (lambda _
2161 (substitute* "tests/tests_helper.rb"
2162 (("-rubygems") ""))
2163 (substitute* "Rakefile"
2164 (("system \"shindo") "system \"./bin/shindo")
2165 ;; This test doesn't work, so we disable it.
2166 (("fail \"The build_error test should fail") "#")
2167 ((" -rubygems") ""))
2168 #t)))))
7ac4610f
RW
2169 (propagated-inputs
2170 `(("ruby-formatador" ,ruby-formatador)))
2171 (synopsis "Simple depth first Ruby testing")
2172 (description "Shindo is a simple depth first testing library for Ruby.")
2173 (home-page "https://github.com/geemus/shindo")
2174 (license license:expat)))
2175
f13636f2
RW
2176(define-public ruby-rubygems-tasks
2177 (package
2178 (name "ruby-rubygems-tasks")
2179 (version "0.2.4")
2180 (source (origin
2181 (method url-fetch)
2182 (uri (rubygems-uri "rubygems-tasks" version))
2183 (sha256
2184 (base32
2185 "16cp45qlbcglnqdm4f1vj3diywdz4v024saqpgrz6palf0wmgz2j"))))
2186 (build-system ruby-build-system)
2187 ;; Tests need Internet access.
2188 (arguments `(#:tests? #f))
2189 (native-inputs
2190 `(("ruby-rspec" ,ruby-rspec)
2191 ("ruby-yard" ,ruby-yard)))
2192 (synopsis "Rake tasks for managing and releasing Ruby Gems")
2193 (description "Rubygems-task provides Rake tasks for managing and releasing
2194Ruby Gems.")
2195 (home-page "https://github.com/postmodern/rubygems-tasks")
2196 (license license:expat)))
2197
cb6bc5df
CB
2198(define-public ruby-rubyzip
2199 (package
2200 (name "ruby-rubyzip")
2201 (version "1.2.1")
2202 (source
2203 (origin
2204 (method url-fetch)
2205 (uri (rubygems-uri "rubyzip" version))
2206 (sha256
2207 (base32
2208 "06js4gznzgh8ac2ldvmjcmg9v1vg9llm357yckkpylaj6z456zqz"))))
2209 (build-system ruby-build-system)
2210 (arguments
2211 '(#:phases
2212 (modify-phases %standard-phases
2213 (add-before 'check 'patch-tests
2214 (lambda* (#:key inputs #:allow-other-keys)
2215 (substitute* "test/gentestfiles.rb"
2216 (("/usr/bin/zip")
2217 (string-append
2218 (assoc-ref inputs "zip") "/bin/zip")))
2219 (substitute* "test/input_stream_test.rb"
2220 (("/usr/bin/env ruby") (which "ruby")))
2221 #t)))))
2222 (native-inputs
2223 `(("bundler" ,bundler)
2224 ("ruby-simplecov" ,ruby-simplecov)
2225 ("zip" ,zip)
2226 ("unzip" ,unzip)))
2227 (synopsis "Ruby module is for reading and writing zip files")
2228 (description
2229 "The rubyzip module provides ways to read from and create zip files.")
2230 (home-page "http://github.com/rubyzip/rubyzip")
2231 (license license:bsd-2)))
2232
58b59742
RW
2233(define-public ruby-simplecov-html
2234 (package
2235 (name "ruby-simplecov-html")
53fd476f 2236 (version "0.10.2")
58b59742
RW
2237 (source (origin
2238 (method url-fetch)
2239 (uri (rubygems-uri "simplecov-html" version))
2240 (sha256
2241 (base32
53fd476f 2242 "1lihraa4rgxk8wbfl77fy9sf0ypk31iivly8vl3w04srd7i0clzn"))))
58b59742 2243 (build-system ruby-build-system)
8b749cf3 2244 (arguments `(#:tests? #f)) ; there are no tests
58b59742
RW
2245 (native-inputs
2246 `(("bundler" ,bundler)))
2247 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
2248 (description "This package provides the default HTML formatter for
2249the SimpleCov code coverage tool for Ruby version 1.9 and above.")
2250 (home-page "https://github.com/colszowka/simplecov-html")
2251 (license license:expat)))
2252
a84fa2ad
RW
2253(define-public ruby-simplecov
2254 (package
2255 (name "ruby-simplecov")
d432682b 2256 (version "0.17.1")
a84fa2ad
RW
2257 (source (origin
2258 (method url-fetch)
2259 (uri (rubygems-uri "simplecov" version))
2260 (sha256
2261 (base32
d432682b 2262 "1135k46nik05sdab30yxb8264lqiz01c8v000g16cl9pjc4mxrdw"))))
a84fa2ad
RW
2263 (build-system ruby-build-system)
2264 ;; Simplecov depends on rubocop for code style checking at build time.
2265 ;; Rubocop needs simplecov at build time.
2266 (arguments `(#:tests? #f))
2267 (propagated-inputs
2268 `(("ruby-json" ,ruby-json)
2269 ("ruby-docile" ,ruby-docile)
2270 ("ruby-simplecov-html" ,ruby-simplecov-html)))
2271 (native-inputs
2272 `(("bundler" ,bundler)))
2273 (synopsis "Code coverage framework for Ruby")
2274 (description "SimpleCov is a code coverage framework for Ruby with a
2275powerful configuration library and automatic merging of coverage across test
2276suites.")
7bf837fd 2277 (home-page "https://github.com/colszowka/simplecov")
a84fa2ad
RW
2278 (license license:expat)))
2279
98b87b82
DT
2280(define-public ruby-useragent
2281 (package
2282 (name "ruby-useragent")
959d908d 2283 (version "0.16.10")
98b87b82
DT
2284 (source (origin
2285 (method url-fetch)
e83c6d00 2286 (uri (rubygems-uri "useragent" version))
98b87b82
DT
2287 (sha256
2288 (base32
959d908d 2289 "1fv5kvq494swy0p17h9qya9r50w15xsi9zmvhzb8gh55kq6ki50p"))))
98b87b82
DT
2290 (build-system ruby-build-system)
2291 (arguments
e83c6d00 2292 '(#:tests? #f)) ; no test suite
98b87b82
DT
2293 (synopsis "HTTP user agent parser for Ruby")
2294 (description "UserAgent is a Ruby library that parses and compares HTTP
2295User Agents.")
2296 (home-page "https://github.com/gshutler/useragent")
2297 (license license:expat)))
96086cc5 2298
f7e9b2f3
CB
2299(define-public ruby-backports
2300 (package
2301 (name "ruby-backports")
2302 (version "3.11.4")
2303 (source
2304 (origin
2305 (method url-fetch)
2306 (uri (rubygems-uri "backports" version))
2307 (sha256
2308 (base32
2309 "1hshjxww2h7s0dk57njrygq4zpp0nlqrjfya7zwm27iq3rhc3y8g"))))
2310 (build-system ruby-build-system)
2311 (arguments
2312 '(;; TODO: This should be default, but there is one test failure
2313 #:test-target "all_spec"))
2314 (native-inputs
2315 `(("ruby-mspec" ,ruby-mspec)
2316 ("ruby-activesupport" ,ruby-activesupport)))
2317 (synopsis "Backports of the features in newer Ruby versions")
2318 (description
2319 "Backports enables more compatibility across Ruby versions by providing
2320backports of some features.")
2321 (home-page "https://github.com/marcandre/backports")
2322 (license license:expat)))
2323
96086cc5
DT
2324(define-public ruby-bacon
2325 (package
2326 (name "ruby-bacon")
e83c6d00 2327 (version "1.2.0")
96086cc5
DT
2328 (source (origin
2329 (method url-fetch)
e83c6d00 2330 (uri (rubygems-uri "bacon" version))
96086cc5
DT
2331 (sha256
2332 (base32
e83c6d00 2333 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
96086cc5 2334 (build-system ruby-build-system)
96086cc5
DT
2335 (synopsis "Small RSpec clone")
2336 (description "Bacon is a small RSpec clone providing all essential
2337features.")
2338 (home-page "https://github.com/chneukirchen/bacon")
2339 (license license:expat)))
de59d316 2340
a8d2bf3c
CB
2341(define-public ruby-bacon-bits
2342 (package
2343 (name "ruby-bacon-bits")
2344 (version "0.1.0")
2345 (source
2346 (origin
2347 (method url-fetch)
2348 (uri (rubygems-uri "bacon-bits" version))
2349 (sha256
2350 (base32
2351 "1ghpj8ja94lhi8rgi872hqk4fd2amz2k7g9znd64z5dj7v6l0dmx"))))
2352 (build-system ruby-build-system)
2353 (arguments
2354 ;; No tests
2355 '(#:tests? #f))
2356 (propagated-inputs `(("ruby-bacon" ,ruby-bacon)))
2357 (synopsis "Extensions to Bacon, for disabling tests, before and after
2358blocks and more")
2359 (description
2360 "This extends the bacon testing framework with useful extensions to
2361disable tests, have before and after blocks that run once and more.")
2362 (home-page "https://github.com/cldwalker/bacon-bits")
2363 (license license:expat)))
2364
65f65889
CB
2365(define-public ruby-bacon-colored-output
2366 (package
2367 (name "ruby-bacon-colored-output")
2368 (version "1.1.1")
2369 (source
2370 (origin
2371 (method url-fetch)
2372 (uri (rubygems-uri "bacon-colored_output" version))
2373 (sha256
2374 (base32
2375 "1znyh3vkfdlmf19p3k4zip88ibym41dn5g4p4n5hmks2iznb7qpx"))))
2376 (build-system ruby-build-system)
2377 (arguments
2378 '(;; No included tests
2379 #:tests? #f))
2380 (propagated-inputs
2381 `(("ruby-bacon" ,ruby-bacon)))
2382 (synopsis "Colored output for Bacon test framework")
2383 (description
2384 "This package adds color through ANSI escape codes to Bacon test
2385output.")
2386 (home-page "https://github.com/whitequark/bacon-colored_output")
2387 (license license:expat)))
2388
e259bdf0
DT
2389(define-public ruby-connection-pool
2390 (package
2391 (name "ruby-connection-pool")
58021db4 2392 (version "2.2.2")
e259bdf0
DT
2393 (source (origin
2394 (method url-fetch)
e83c6d00 2395 (uri (rubygems-uri "connection_pool" version))
e259bdf0
DT
2396 (sha256
2397 (base32
58021db4 2398 "0lflx29mlznf1hn0nihkgllzbj8xp5qasn8j7h838465pi399k68"))))
e259bdf0
DT
2399 (build-system ruby-build-system)
2400 (native-inputs
2401 `(("bundler" ,bundler)))
2402 (synopsis "Generic connection pool for Ruby")
2403 (description "Connection_pool provides a generic connection pooling
2404interface for Ruby programs.")
2405 (home-page "https://github.com/mperham/connection_pool")
2406 (license license:expat)))
4c0aeb44 2407
4a98314d
MB
2408(define-public ruby-fast-gettext
2409 (package
2410 (name "ruby-fast-gettext")
2411 (version "2.0.2")
2412 (home-page "https://github.com/grosser/fast_gettext")
2413 (source (origin
2414 (method git-fetch)
2415 (uri (git-reference (url home-page)
2416 (commit (string-append "v" version))))
2417 (file-name (git-file-name name version))
2418 (sha256
2419 (base32
2420 "1rd48fp89k1sclgn2v26br2glwl3iv7z72mizzzmkdmqalqfn1sa"))))
2421 (build-system ruby-build-system)
2422 (arguments
2423 '(#:test-target "spec"
2424 #:phases (modify-phases %standard-phases
2425 (add-before 'check 'remove-version-constraints
2426 (lambda _
2427 (delete-file "Gemfile.lock")
2428 #t))
2429 (add-before 'check 'remove-activerecord-test
2430 (lambda _
2431 ;; FIXME: This test fails because ActiveRecord depends on
2432 ;; a different version of ruby-sqlite than the currently
2433 ;; available one.
2434 (delete-file
2435 "spec/fast_gettext/translation_repository/db_spec.rb")
2436 #t))
2437 (add-before 'check 'disable-i18n-test
2438 (lambda _
2439 ;; XXX: This test checks i18n intricasies with Rails 3 and
2440 ;; automatically disables itself for Rails 4.0, but does
2441 ;; not know about newer versions as it has not been updated
2442 ;; since 2014. Disable for later versions of Rails too.
2443 (substitute* "spec/fast_gettext/vendor/string_spec.rb"
2444 (((string-append "ActiveRecord::VERSION::MAJOR == 4 and "
2445 "ActiveRecord::VERSION::MINOR == 0"))
2446 "ActiveRecord::VERSION::MAJOR >= 4"))
2447 #t)))))
2448 (native-inputs
2449 `(;; For tests.
2450 ("ruby-activerecord" ,ruby-activerecord)
2451 ("ruby-activesupport" ,ruby-activesupport)
2452 ("ruby-bump" ,ruby-bump)
2453 ("ruby-forking-test-runner" ,ruby-forking-test-runner)
2454 ("ruby-i18n" ,ruby-i18n)
2455 ("ruby-rubocop" ,ruby-rubocop)
2456 ("ruby-rspec" ,ruby-rspec)
2457 ("ruby-single-cov" ,ruby-single-cov)
2458 ("ruby-sqlite3" ,ruby-sqlite3)
2459 ("ruby-wwtd" ,ruby-wwtd)))
2460 (synopsis "Fast implementation of @code{GetText}")
2461 (description
2462 "This package provides an alternative implementation of the Ruby
2463@code{GetText} library that is approximately 12x faster yet thread safe.")
2464 ;; Some parts are covered by the Ruby license, see file headers.
2465 (license (list license:expat license:ruby))))
2466
4c0aeb44
DT
2467(define-public ruby-net-http-persistent
2468 (package
2469 (name "ruby-net-http-persistent")
185ea446 2470 (version "3.0.0")
4c0aeb44
DT
2471 (source (origin
2472 (method url-fetch)
e83c6d00 2473 (uri (rubygems-uri "net-http-persistent" version))
4c0aeb44
DT
2474 (sha256
2475 (base32
185ea446 2476 "156rv95bgxfz6qw5y1r7c7bswr77918hygl8dyl14qzbqc5vyp18"))))
4c0aeb44 2477 (build-system ruby-build-system)
4c0aeb44
DT
2478 (native-inputs
2479 `(("ruby-connection-pool" ,ruby-connection-pool)
2480 ("ruby-hoe" ,ruby-hoe)))
2481 (synopsis "Persistent HTTP connection manager")
2482 (description "Net::HTTP::Persistent manages persistent HTTP connections
2483using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
2484 (home-page "https://github.com/drbrain/net-http-persistent")
2485 (license license:expat)))
afbbdf77 2486
f88bacaf
RW
2487(define-public ruby-power-assert
2488 (package
2489 (name "ruby-power-assert")
6754323b 2490 (version "1.1.5")
f88bacaf
RW
2491 (source (origin
2492 (method url-fetch)
2493 (uri (rubygems-uri "power_assert" version))
2494 (sha256
2495 (base32
6754323b 2496 "1dii0wkfa0jm8sk9b20zl1z4980dmrjh0zqnii058485pp3ws10s"))))
f88bacaf 2497 (build-system ruby-build-system)
6754323b
CB
2498 (arguments
2499 '(#:tests? #f)) ; No included tests
f88bacaf
RW
2500 (native-inputs
2501 `(("bundler" ,bundler)))
2502 (synopsis "Assert library with descriptive assertion messages")
2503 (description "Power-assert is an assertion library providing descriptive
2504assertion messages for tests.")
2505 (home-page "https://github.com/k-tsj/power_assert")
2506 (license (list license:bsd-2 license:ruby))))
2507
e42e3bfa
CB
2508(define-public ruby-powerpack
2509 (package
2510 (name "ruby-powerpack")
2511 (version "0.1.2")
2512 (source
2513 (origin
2514 (method url-fetch)
2515 (uri (rubygems-uri "powerpack" version))
2516 (sha256
2517 (base32
2518 "1r51d67wd467rpdfl6x43y84vwm8f5ql9l9m85ak1s2sp3nc5hyv"))))
2519 (build-system ruby-build-system)
2520 (arguments
2521 '(#:test-target "spec"))
2522 (native-inputs
2523 `(("bundler" ,bundler)
2524 ("ruby-rspec" ,ruby-rspec)
2525 ("ruby-yard" ,ruby-yard)))
2526 (synopsis "Useful extensions to core Ruby classes")
2527 (description
2528 "This package provides a few useful extensions to core Ruby classes,
2529including @code{Array}, @code{Enumerable}, @code{Hash}, @code{Numeric}, and
2530@code{String}.")
2531 (home-page "https://github.com/bbatsov/powerpack")
2532 (license license:expat)))
2533
347eb21e
RW
2534(define-public ruby-locale
2535 (package
2536 (name "ruby-locale")
2537 (version "2.1.2")
2538 (source (origin
2539 (method url-fetch)
2540 (uri (rubygems-uri "locale" version))
2541 (sha256
2542 (base32
2543 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
2544 (build-system ruby-build-system)
2545 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
2546 ;; which needs ruby-gettext, which needs ruby-locale. To break the
2547 ;; dependency cycle we disable tests.
2548 (arguments `(#:tests? #f))
2549 (native-inputs
2550 `(("bundler" ,bundler)
2551 ("ruby-yard" ,ruby-yard)))
2552 (synopsis "Ruby library providing basic localization APIs")
2553 (description
2554 "Ruby-Locale is the pure ruby library which provides basic APIs for
2555localization.")
2556 (home-page "https://github.com/ruby-gettext/locale")
2557 (license (list license:lgpl3+ license:ruby))))
2558
09e2b0af
CB
2559(define-public ruby-temple
2560 (package
2561 (name "ruby-temple")
2562 (version "0.8.1")
2563 (source
2564 (origin
2565 (method url-fetch)
2566 (uri (rubygems-uri "temple" version))
2567 (sha256
2568 (base32
2569 "158d7ygbwcifqnvrph219p7m78yjdjazhykv5darbkms7bxm5y09"))))
2570 (build-system ruby-build-system)
2571 (native-inputs
2572 `(("ruby-tilt" ,ruby-tilt)
2573 ("ruby-bacon" ,ruby-bacon)
2574 ("ruby-erubis" ,ruby-erubis)))
2575 (synopsis "Template compilation framework in Ruby")
2576 (description
2577 "Temple is an abstraction and framework for compiling templates to pure
2578Ruby.")
2579 (home-page "https://github.com/judofyr/temple")
2580 (license license:expat)))
2581
e2333ea3
RW
2582(define-public ruby-text
2583 (package
2584 (name "ruby-text")
2585 (version "1.3.1")
2586 (source (origin
2587 (method url-fetch)
2588 (uri (rubygems-uri "text" version))
2589 (sha256
2590 (base32
2591 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
2592 (build-system ruby-build-system)
2593 (synopsis "Collection of text algorithms for Ruby")
2594 (description
2595 "This package provides a collection of text algorithms: Levenshtein,
2596Soundex, Metaphone, Double Metaphone, Porter Stemming.")
7bf837fd 2597 (home-page "https://github.com/threedaymonk/text")
e2333ea3
RW
2598 (license license:expat)))
2599
c1f52261
RW
2600(define-public ruby-gettext
2601 (package
2602 (name "ruby-gettext")
2603 (version "3.1.7")
2604 (source (origin
2605 (method url-fetch)
2606 (uri (rubygems-uri "gettext" version))
2607 (sha256
2608 (base32
2609 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
2610 (build-system ruby-build-system)
2611 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
2612 ;; which needs ruby-gettext. To break the dependency cycle we disable
2613 ;; tests.
2614 (arguments `(#:tests? #f))
2615 (propagated-inputs
2616 `(("ruby-locale" ,ruby-locale)
2617 ("ruby-text" ,ruby-text)))
2618 (native-inputs
2619 `(("bundler" ,bundler)
2620 ("ruby-yard" ,ruby-yard)))
2621 (synopsis "GNU gettext-like program for Ruby")
2622 (description
2623 "Gettext is a GNU gettext-like program for Ruby. The catalog
2624file (po-file) used is the same as that used by GNU gettext, allowing you to
2625use GNU gettext tools for maintenance.")
2f3800e5 2626 (home-page "https://ruby-gettext.github.com/")
c1f52261
RW
2627 (license (list license:lgpl3+ license:ruby))))
2628
cc5aeb8c
RW
2629(define-public ruby-packnga
2630 (package
2631 (name "ruby-packnga")
1d60c436 2632 (version "1.0.4")
cc5aeb8c
RW
2633 (source (origin
2634 (method url-fetch)
2635 (uri (rubygems-uri "packnga" version))
2636 (sha256
2637 (base32
1d60c436 2638 "1vv2j0i43s4xid2km5hgrrxqlqpwgq8nlm8kaxfg2531c1vwfsd4"))))
cc5aeb8c
RW
2639 (build-system ruby-build-system)
2640 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
2641 ;; To break the dependency cycle we disable tests.
2642 (arguments `(#:tests? #f))
2643 (propagated-inputs
2644 `(("ruby-gettext" ,ruby-gettext)
2645 ("ruby-yard" ,ruby-yard)))
2646 (native-inputs
2647 `(("bundler" ,bundler)))
2648 (synopsis "Utility library to package internationalized libraries")
2649 (description
2650 "Packnga is a library to translate to many languages using YARD.")
2651 (home-page "http://ranguba.org/packnga/")
2652 (license license:lgpl2.0+)))
2653
93dc8684
CB
2654(define-public ruby-test-construct
2655 (package
2656 (name "ruby-test-construct")
2657 (version "2.0.1")
2658 (source
2659 (origin
2660 (method url-fetch)
2661 (uri (rubygems-uri "test_construct" version))
2662 (sha256
2663 (base32
2664 "1a2ym3l068d0pxzzr95kvqx87zpdsarxslz9ygd4qfm9frrz0kgj"))))
2665 (build-system ruby-build-system)
2666 (native-inputs
2667 `(("bundler" ,bundler)
2668 ("ruby-mocha" ,ruby-mocha)
2669 ("ruby-rspec" ,ruby-rspec)))
2670 (synopsis "Creates temporary files and directories for testing")
2671 (description
2672 "TestConstruct is a @acronym{DSL, Domain Specific Language} for creating
2673temporary files and directories during tests.")
2674 (home-page "https://github.com/bhb/test_construct")
2675 (license license:expat)))
2676
3383f5bd
RW
2677(define-public ruby-test-unit
2678 (package
2679 (name "ruby-test-unit")
d74d96e4 2680 (version "3.2.5")
3383f5bd
RW
2681 (source (origin
2682 (method url-fetch)
2683 (uri (rubygems-uri "test-unit" version))
2684 (sha256
2685 (base32
d74d96e4 2686 "05bx36fw01iqz0xqhvjfrwjgnj1zx3b2vn6w1fzp19rchd7zqc52"))))
3383f5bd
RW
2687 (build-system ruby-build-system)
2688 (propagated-inputs
2689 `(("ruby-power-assert" ,ruby-power-assert)))
2690 (native-inputs
2691 `(("bundler" ,bundler)
2692 ("ruby-packnga" ,ruby-packnga)
2693 ("ruby-yard" ,ruby-yard)))
2694 (synopsis "Unit testing framework for Ruby")
2695 (description "@code{Test::Unit} is unit testing framework for Ruby, based
2696on xUnit principles. These were originally designed by Kent Beck, creator of
2697extreme programming software development methodology, for Smalltalk's SUnit.
2698It allows writing tests, checking results and automated testing in Ruby.")
2f3800e5 2699 (home-page "https://test-unit.github.io/")
3383f5bd
RW
2700 (license (list license:psfl license:ruby))))
2701
76b732fb
CB
2702(define-public ruby-markaby
2703 (package
2704 (name "ruby-markaby")
2705 (version "0.9.0")
2706 (source
2707 (origin
2708 (method url-fetch)
2709 (uri (rubygems-uri "markaby" version))
2710 (sha256
2711 (base32
2712 "1j4jc31ycydbkh5h3q6zwidzpavg3g5mbb5lqyaczd3jrq78rd7i"))))
2713 (build-system ruby-build-system)
2714 (arguments
2715 '(#:phases
2716 (modify-phases %standard-phases
2717 ;; Run rspec manually without using the Rakefile, as the versions of
2718 ;; Rake and RSpec 2 are incompatible:
2719 ;;
2720 ;; NoMethodError: undefined method `last_comment'
2721 (replace 'check
2722 (lambda* (#:key tests? #:allow-other-keys)
2723 (when tests?
2724 (invoke "rspec"))
2725 #t)))))
2726 (propagated-inputs
2727 `(("ruby-builder" ,ruby-builder)))
2728 (native-inputs
2729 `(("bundler" ,bundler)
2730 ("ruby-rspec" ,ruby-rspec-2)))
2731 (synopsis "Write HTML pages in pure Ruby")
2732 (description
2733 "Markaby allows writing HTML packages in pure Ruby. This is similar to
e54af322 2734the functionality provided by @acronym{ERB, Embedded Ruby}, but without the
76b732fb 2735mixture of HTML and additional ERB syntax.")
41181b76 2736 (home-page "https://markaby.github.io/")
76b732fb
CB
2737 (license license:expat)))
2738
b9511aa9
CB
2739(define-public ruby-maruku
2740 (package
2741 (name "ruby-maruku")
2742 (version "0.7.3")
2743 (source
2744 (origin
2745 (method url-fetch)
2746 (uri (rubygems-uri "maruku" version))
2747 (sha256
2748 (base32
2749 "1r7bxpgnx2hp3g12bjrmdrpv663dfqxsdp0af69kjhxmaxpia56x"))))
2750 (build-system ruby-build-system)
2751 (arguments
2752 '(;; TODO: 3 tests seem to fail due to HTML encoding issues
2753 #:tests? #f
2754 #:phases
2755 (modify-phases %standard-phases
2756 (replace 'check
2757 (lambda* (#:key tests? #:allow-other-keys)
2758 (when tests?
2759 (invoke "rspec"))
2760 #t)))))
2761 (native-inputs
2762 `(("ruby-rspec" ,ruby-rspec)
2763 ("ruby-simplecov" ,ruby-simplecov)
2764 ("ruby-nokogiri-diff" ,ruby-nokogiri-diff)))
2765 (synopsis "Markdown interpreter in Ruby")
2766 (description
2767 "Maruku is a Markdown interpreter in Ruby. It can export Markdown to
2768HTML, and PDF through LaTeX.")
2769 (home-page "https://github.com/bhollis/maruku")
2770 (license license:expat)))
2771
25d6d49b
RW
2772(define-public ruby-metaclass
2773 (package
2774 (name "ruby-metaclass")
2775 (version "0.0.4")
2776 (source (origin
2777 (method url-fetch)
2778 (uri (rubygems-uri "metaclass" version))
2779 (sha256
2780 (base32
2781 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
2782 (build-system ruby-build-system)
2783 (arguments
2784 `(#:phases
2785 (modify-phases %standard-phases
2786 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 2787 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 2788 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
2789 (substitute* "Rakefile"
2790 (("t\\.libs << \"test\"" line)
2791 (string-append line "; t.libs << \""
3cb3fa67 2792 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
2793 "/gems/test-unit-"
2794 ,(package-version ruby-test-unit)
2795 "/lib\""))))
2796 #t)))))
25d6d49b
RW
2797 (native-inputs
2798 `(("bundler" ,bundler)
2799 ("ruby-test-unit" ,ruby-test-unit)))
2800 (synopsis "Ruby library adding metaclass method to all objects")
2801 (description
2802 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
2803objects.")
7bf837fd 2804 (home-page "https://github.com/floehopper/metaclass")
25d6d49b
RW
2805 (license license:expat)))
2806
1d1d20b0
CB
2807(define-public ruby-mspec
2808 (package
2809 (name "ruby-mspec")
2810 (version "1.9.1")
2811 (source
2812 (origin
2813 (method url-fetch)
2814 (uri (rubygems-uri "mspec" version))
2815 (sha256
2816 (base32
2817 "0wmyh2n40m4srwdx9z6h6g6p46k02pzyhcsja3hqcw5h5b0hfmhd"))))
2818 (build-system ruby-build-system)
2819 (arguments
2820 '(;; TODO: 3 test failures
2821 ;; ./spec/mocks/mock_spec.rb:82
2822 ;; ./spec/utils/name_map_spec.rb:151
2823 ;; ./spec/utils/name_map_spec.rb:155
2824 #:tests? #f
2825 #:phases
2826 (modify-phases %standard-phases
2827 (add-after 'extract-gemspec 'change-dependency-constraints
2828 (lambda _
2829 (substitute* "mspec.gemspec"
2830 (("rake.*") "rake>)\n")
2831 (("rspec.*") "rspec>)\n"))
2832 #t))
2833 (replace 'check
2834 (lambda* (#:key tests? #:allow-other-keys)
2835 (when tests?
2836 (invoke "rspec" "spec"))
2837 #t)))))
2838 (native-inputs
2839 `(("bundler" ,bundler)
2840 ("ruby-rake" ,ruby-rake)
2841 ("ruby-rspec" ,ruby-rspec)))
2842 (synopsis "MSpec is a specialized framework for RubySpec")
2843 (description
2844 "MSpec is a specialized framework that is syntax-compatible with RSpec 2
2845for basic features. MSpec contains additional features that assist in writing
2846specs for Ruby implementations in ruby/spec.")
2847 (home-page "http://rubyspec.org")
2848 (license license:expat)))
2849
b8aecc31
CB
2850(define-public ruby-mysql2
2851 (package
2852 (name "ruby-mysql2")
2853 (version "0.5.2")
2854 (source
2855 (origin
2856 (method git-fetch)
2857 (uri (git-reference
2858 (url "https://github.com/brianmario/mysql2.git")
2859 (commit version)))
2860 (file-name (git-file-name name version))
2861 (sha256
2862 (base32
2863 "11lvfgc2rmvkm52jp0nbi6pvhk06klznghr7llldfw8basl9n5wv"))))
2864 (build-system ruby-build-system)
2865 (arguments
2866 '(;; TODO: Tests require a running MySQL/MariaDB service
2867 #:tests? #f
2868 #:phases
2869 (modify-phases %standard-phases
2870 (replace 'replace-git-ls-files
2871 (lambda _
2872 (substitute* "mysql2.gemspec"
2873 (("git ls-files .*`") "find . -type f |sort`"))
2874 #t))
2875 (add-before 'install 'set-MAKEFLAGS
2876 (lambda* (#:key outputs #:allow-other-keys)
2877 (setenv "MAKEFLAGS"
2878 (string-append
2879 "V=1 "
2880 "prefix=" (assoc-ref outputs "out")))
2881 #t))
2882 ;; Move the 'check phase to after 'install, as then you can test
2883 ;; using the installed mysql2 gem in the store.
2884 (delete 'check)
2885 (add-after 'install 'check
2886 (lambda* (#:key outputs tests? #:allow-other-keys)
2887 (setenv "GEM_PATH"
2888 (string-append
2889 (getenv "GEM_PATH")
2890 ":"
2891 (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))
2892 (when tests?
2893 (invoke "rspec"))
2894 #t)))))
2895 (inputs
2b8491fb
JL
2896 `(("mariadb" ,mariadb "lib")
2897 ("mariadb-dev" ,mariadb "dev")
b8aecc31
CB
2898 ("zlib" ,zlib)))
2899 (native-inputs
2900 `(("ruby-rspec" ,ruby-rspec)
2901 ("ruby-rake-compiler" ,ruby-rake-compiler)))
2902 (synopsis "MySQL library for Ruby, binding to libmysql")
2903 (description
2904 "This package provides a simple, fast MySQL library for Ruby, binding to
2905libmysql.")
2906 (home-page "https://github.com/brianmario/mysql2")
2907 (license license:expat)))
2908
21f7b7bd
RW
2909(define-public ruby-blankslate
2910 (package
2911 (name "ruby-blankslate")
2912 (version "3.1.3")
2913 (source (origin
2914 (method url-fetch)
2915 (uri (rubygems-uri "blankslate" version))
2916 (sha256
2917 (base32
2918 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
2919 (build-system ruby-build-system)
2920 (arguments
2921 `(#:phases
2922 (modify-phases %standard-phases
2923 (replace 'check
9923d5a4 2924 (lambda _ (invoke "rspec" "spec/"))))))
21f7b7bd
RW
2925 (native-inputs
2926 `(("bundler" ,bundler)
2927 ("ruby-rspec" ,ruby-rspec)))
2928 (synopsis "Abstract base class with no predefined methods")
2929 (description
2930 "BlankSlate provides an abstract base class with no predefined
2931methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
2932as a base class when writing classes that depend upon
2933@code{method_missing} (e.g. dynamic proxies).")
7bf837fd 2934 (home-page "https://github.com/masover/blankslate")
21f7b7bd
RW
2935 (license license:expat)))
2936
afdb437c
CB
2937(define-public ruby-bond
2938 (package
2939 (name "ruby-bond")
2940 (version "0.5.1")
2941 (source
2942 (origin
2943 (method url-fetch)
2944 (uri (rubygems-uri "bond" version))
2945 (sha256
2946 (base32
2947 "1r19ifc4skyl2gxnifrxa5jvbbay9fb2in79ppgv02b6n4bhsw90"))))
2948 (build-system ruby-build-system)
2949 (native-inputs
2950 `(("ruby-bacon" ,ruby-bacon)
2951 ("ruby-bacon-bits" ,ruby-bacon-bits)
2952 ("ruby-mocha-on-bacon" ,ruby-mocha-on-bacon)))
2953 (synopsis "Bond can provide custom autocompletion for arguments, methods
2954and more")
2955 (description
2956 "Bond can autocomplete argument(s) to methods, uniquely completing per
2957module, per method and per argument. Bond provides a configuration system and
2958a DSL for creating custom completions and completion rules. Bond can also
2959load completions that ship with gems. Bond is able to offer more than irb's
2960completion since it uses the full line of input when completing as opposed to
2961irb's last-word approach.")
2962 (home-page "http://tagaholic.me/bond/")
2963 (license license:expat)))
2964
f3d7bb93
CB
2965(define-public ruby-idn-ruby
2966 (package
2967 (name "ruby-idn-ruby")
2968 (version "0.1.0")
2969 (source
2970 (origin
2971 (method url-fetch)
2972 (uri (rubygems-uri "idn-ruby" version))
2973 (sha256
2974 (base32
2975 "07vblcyk3g72sbq12xz7xj28snpxnh3sbcnxy8bglqbfqqhvmawr"))))
2976 (build-system ruby-build-system)
2977 (arguments
2978 '(#:phases
2979 (modify-phases %standard-phases
2980 (delete 'check)
2981 (add-after 'install 'check
2982 (lambda* (#:key tests? outputs #:allow-other-keys)
2983 (when tests?
2984 (let* ((gem-file (cadr (find-files "." "\\.gem")))
2985 (name-and-version (basename gem-file ".gem")))
2986 (apply invoke
2987 "ruby" "--verbose"
2988 (string-append "-I"
2989 (assoc-ref outputs "out")
2990 "/lib/ruby/vendor_ruby/gems/"
2991 name-and-version
2992 "/lib")
2993 (find-files "./test" ".*\\.rb"))))
2994 #t)))))
2995 (inputs
2996 `(("libidn" ,libidn)))
2997 (synopsis "Ruby Bindings for the GNU LibIDN library")
2998 (description
2999 "Ruby Bindings for the GNU LibIDN library, an implementation of the
3000Stringprep, Punycode and IDNA specifications. These are used to encode and
3001decode internationalized domain + names according to the IDNA2003
3002specifications.
3003
3004Included are the most important parts of the Stringprep, Punycode and IDNA
3005APIs like performing Stringprep processings, encoding to and decoding from
3006Punycode strings and converting entire domain names to and from the ACE
3007encoded form.")
3008 (home-page "https://github.com/deepfryed/idn-ruby")
3009 (license license:asl2.0)))
3010
4016ba3f
RW
3011(define-public ruby-instantiator
3012 (package
3013 (name "ruby-instantiator")
688c9076 3014 (version "0.0.7")
4016ba3f
RW
3015 (source (origin
3016 (method url-fetch)
3017 (uri (rubygems-uri "instantiator" version))
3018 (sha256
3019 (base32
688c9076 3020 "0w07w3gkyqr7m0vz5h13vm8b411660qywjm2xxxgdjv4wb3fazbr"))))
4016ba3f
RW
3021 (build-system ruby-build-system)
3022 (arguments
3023 `(#:phases
3024 (modify-phases %standard-phases
3025 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 3026 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3027 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
3028 (substitute* "Rakefile"
3029 (("t\\.libs << \"test\"" line)
3030 (string-append line "; t.libs << \""
3cb3fa67 3031 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
3032 "/gems/test-unit-"
3033 ,(package-version ruby-test-unit)
3034 "/lib\""))))
3035 #t)))))
4016ba3f
RW
3036 (propagated-inputs
3037 `(("ruby-blankslate" ,ruby-blankslate)))
3038 (native-inputs
3039 `(("bundler" ,bundler)
3040 ("ruby-test-unit" ,ruby-test-unit)))
3041 (synopsis "Instantiate an arbitrary Ruby class")
3042 (description
3043 "Instantiator lets you instantiate an arbitrary Ruby class without
3044knowing anything about the constructor.")
3045 (home-page "https://github.com/floehopper/instantiator")
3046 (license license:expat)))
3047
97aee8d3
RW
3048(define-public ruby-introspection
3049 (package
3050 (name "ruby-introspection")
98ff58a5 3051 (version "0.0.4")
97aee8d3
RW
3052 (source (origin
3053 (method url-fetch)
3054 (uri (rubygems-uri "introspection" version))
3055 (sha256
3056 (base32
98ff58a5 3057 "1y2nbijkc0zlfmn9ss6588ilarq2kbn2i7w7pwwsli66dj84zgca"))))
97aee8d3
RW
3058 (build-system ruby-build-system)
3059 (arguments
3060 `(#:phases
3061 (modify-phases %standard-phases
3062 (add-after 'unpack 'add-test-unit-to-search-path
3063 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3064 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
3065 (substitute* "Rakefile"
3066 (("t\\.libs << \"test\"" line)
3067 (string-append line "; t.libs << \""
3cb3fa67 3068 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
3069 "/gems/test-unit-"
3070 ,(package-version ruby-test-unit)
3071 "/lib\""))))
97aee8d3
RW
3072 #t)))))
3073 (propagated-inputs
3074 `(("ruby-instantiator" ,ruby-instantiator)
3075 ("ruby-metaclass" ,ruby-metaclass)))
3076 (native-inputs
3077 `(("bundler" ,bundler)
3078 ("ruby-blankslate" ,ruby-blankslate)
3079 ("ruby-test-unit" ,ruby-test-unit)))
3080 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
3081 (description
3082 "Introspection provides tools to inspect the hierarchy of method
3083definitions on a Ruby object.")
3084 (home-page "https://github.com/floehopper/introspection")
3085 (license license:expat)))
3086
d93062fd
RW
3087(define-public ruby-redcarpet
3088 (package
3089 (name "ruby-redcarpet")
ba4084bb 3090 (version "3.5.0")
d93062fd
RW
3091 (source (origin
3092 (method url-fetch)
3093 (uri (rubygems-uri "redcarpet" version))
3094 (sha256
3095 (base32
ba4084bb 3096 "0skcyx1h8b5ms0rp2zm3ql6g322b8c1adnkwkqyv7z3kypb4bm7k"))))
d93062fd
RW
3097 (build-system ruby-build-system)
3098 (arguments
3099 `(#:phases
3100 (modify-phases %standard-phases
3101 ;; The gem archive does not include the conformance tests.
3102 (add-after 'unpack 'disable-conformance-tests
3103 (lambda _
3104 (substitute* "Rakefile"
3105 (("task :test => %w\\[test:unit test:conformance\\]")
3106 "task :test => %w[test:unit]"))
3107 #t)))))
3108 (native-inputs
3109 `(("bundler" ,bundler)
3110 ("ruby-test-unit" ,ruby-test-unit)
3111 ("ruby-rake-compiler" ,ruby-rake-compiler)))
3112 (synopsis "Extensible Markdown to (X)HTML converter")
3113 (description
3114 "Redcarpet is an extensible Ruby library for Markdown processing and
3115conversion to (X)HTML.")
7bf837fd 3116 (home-page "https://github.com/vmg/redcarpet")
d93062fd
RW
3117 (license license:expat)))
3118
09924294
CB
3119(define-public ruby-rerun
3120 (package
3121 (name "ruby-rerun")
3122 (version "0.13.0")
3123 (source
3124 (origin
3125 (method url-fetch)
3126 (uri (rubygems-uri "rerun" version))
3127 (sha256
3128 (base32
3129 "1cskvxk8z8vmfail8na7hj91hs0qnvds9nydj04zi3dbddgnbmvz"))))
3130 (build-system ruby-build-system)
3131 (arguments
3132 '(#:tests? #f)) ; No included tests
3133 (propagated-inputs
3134 `(("ruby-listen" ,ruby-listen)))
3135 (synopsis "Run a process, and restart when some monitored files change")
3136 (description
52beae7b 3137 "Rerun is a tool to launch programs, then monitor the file system, and
09924294
CB
3138restart the program when any of the monitored files change. It's written in
3139Ruby, but can be used for all programs.")
3140 (home-page "https://github.com/alexch/rerun/")
3141 (license license:expat)))
3142
8d85543b
MB
3143(define-public ruby-maxitest
3144 (package
3145 (name "ruby-maxitest")
3146 (version "3.6.0")
3147 (home-page "https://github.com/grosser/maxitest")
3148 (source (origin
3149 ;; Pull from git because the gem does not contain tests.
3150 (method git-fetch)
3151 (uri (git-reference
3152 (url home-page)
3153 (commit (string-append "v" version))))
3154 (file-name (git-file-name name version))
3155 (sha256
3156 (base32
3157 "07b3j0bv3dx5j42jlvpvl07aaxplyi6wq688y3jl8y528ww2hjz8"))))
3158 (build-system ruby-build-system)
3159 (arguments
3160 '(#:test-target "default"
3161 #:phases (modify-phases %standard-phases
3162 (replace 'replace-git-ls-files
3163 (lambda _
3164 (substitute* "maxitest.gemspec"
3165 (("`git ls-files lib/ bin/ MIT-LICENSE Readme.md`")
3166 "`find lib/ bin/ MIT-LICENSE Readme.md -type f | sort`"))
3167 #t))
3168 (add-before 'check 'remove-version-constraints
3169 (lambda _
3170 ;; Don't use specific versions of dependencies, instead
3171 ;; take whatever is available in Guix.
3172 (delete-file "Gemfile.lock")
3173 #t))
3174 (add-before 'check 'add-mtest-on-PATH
3175 (lambda _
3176 ;; Tests use 'mtest' which is not automatically added on
3177 ;; PATH.
3178 (setenv "PATH" (string-append (getcwd) "/bin:"
3179 (getenv "PATH")))
3180 #t)))))
3181 (native-inputs
3182 `(("ps" ,procps)
3183 ("ruby-bump" ,ruby-bump)
3184 ("ruby-byebug" ,ruby-byebug)
3185 ("ruby-rspec" ,ruby-rspec)
3186 ("ruby-wwtd" ,ruby-wwtd)))
3187 (propagated-inputs
3188 `(("ruby-minitest" ,ruby-minitest)))
3189 (synopsis "Minitest with extra features")
3190 (description
3191 "Maxitest is a wrapper around Minitest with extra functionality such
3192as timeouts, an @command{mtest} executable that can run tests by line
3193number, support for interrupted tests, better backtraces, and more.")
3194 (license license:expat)))
3195
4f2a52ae
RW
3196(define-public ruby-mocha
3197 (package
3198 (name "ruby-mocha")
2fc3cc24 3199 (version "1.11.2")
4f2a52ae
RW
3200 (source (origin
3201 (method url-fetch)
3202 (uri (rubygems-uri "mocha" version))
3203 (sha256
3204 (base32
2fc3cc24 3205 "0hxmkm8qxd04vwj8mqnpyrf2dwy7g1k9zipdfhl4y71cw7ijm9n4"))))
4f2a52ae
RW
3206 (build-system ruby-build-system)
3207 (arguments
3208 `(#:phases
3209 (modify-phases %standard-phases
2fc3cc24
MB
3210 (add-before 'check 'remove-rubocop-dependency
3211 (lambda _
3212 ;; Disable dependency on Rubocop, which is just a linter,
3213 ;; and would introduce a circular dependency.
3214 (substitute* "mocha.gemspec"
3215 ((".*rubocop.*")
3216 "true\n"))
3217 #t)))))
4f2a52ae 3218 (native-inputs
2fc3cc24 3219 `(("ruby-introspection" ,ruby-introspection)))
4f2a52ae
RW
3220 (synopsis "Mocking and stubbing library for Ruby")
3221 (description
3222 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
3223allows mocking and stubbing of methods on real (non-mock) classes.")
3224 (home-page "http://gofreerange.com/mocha/docs")
e3febab5
MB
3225 ;; Mocha can be used with either license at the users choice.
3226 (license (list license:expat license:ruby))))
4f2a52ae 3227
cf646acf
CB
3228(define-public ruby-mocha-on-bacon
3229 (package
3230 (name "ruby-mocha-on-bacon")
3231 (version "0.2.3")
3232 (source
3233 (origin
3234 (method url-fetch)
3235 (uri (rubygems-uri "mocha-on-bacon" version))
3236 (sha256
3237 (base32
3238 "1h49b33rq889hn8x3wp9byczl91va16jh1w4d2wyy4yj23icdrcp"))))
3239 (build-system ruby-build-system)
3240 (arguments
3241 ;; rubygems.org release missing tests
3242 '(#:tests? #f))
3243 (propagated-inputs `(("ruby-mocha" ,ruby-mocha)))
3244 (synopsis "Mocha adapter for Bacon")
3245 (description
3246 "This package provides a Mocha adapter for Bacon, allowing you to use the
3247Mocha stubbing and mocking library with Bacon, a small RSpec clone.")
3248 (home-page
3249 "https://github.com/alloy/mocha-on-bacon")
3250 (license license:expat)))
3251
2c84ba7e
RW
3252(define-public ruby-net-ssh
3253 (package
3254 (name "ruby-net-ssh")
5803f872 3255 (version "4.2.0")
2c84ba7e
RW
3256 (source (origin
3257 (method url-fetch)
3258 (uri (rubygems-uri "net-ssh" version))
3259 (sha256
3260 (base32
5803f872 3261 "07c4v97zl1daabmri9zlbzs6yvkl56z1q14bw74d53jdj0c17nhx"))))
2c84ba7e
RW
3262 (build-system ruby-build-system)
3263 (native-inputs
a7938625
MB
3264 `(("bundler" ,bundler)
3265 ("ruby-mocha" ,ruby-mocha)
2c84ba7e
RW
3266 ("ruby-test-unit" ,ruby-test-unit)))
3267 (synopsis "Ruby implementation of the SSH2 client protocol")
3268 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
3269client protocol. It allows you to write programs that invoke and interact
3270with processes on remote servers, via SSH2.")
3271 (home-page "https://github.com/net-ssh/net-ssh")
3272 (license license:expat)))
3273
d38755cb
DM
3274(define-public ruby-net-scp
3275 (package
3276 (name "ruby-net-scp")
3277 ;; The 1.2.1 release would be incompatible with ruby-net-ssh >= 4.
3278 (version "1.2.2.rc2")
3279 (source
3280 (origin
e405f996
TGR
3281 (method git-fetch)
3282 (uri (git-reference
3283 (url "https://github.com/net-ssh/net-scp.git")
3284 (commit (string-append "v" version))))
3285 (file-name (git-file-name name version))
d38755cb 3286 (sha256
e405f996 3287 (base32 "1nyn17sy71fn7zs3y6wbgcn35318c10flqgc0582409095x4h0sx"))))
d38755cb
DM
3288 (build-system ruby-build-system)
3289 (native-inputs
3290 `(("bundler" ,bundler)
3291 ("ruby-test-unit" ,ruby-test-unit)
3292 ("ruby-mocha" ,ruby-mocha)))
3293 (propagated-inputs
3294 `(("ruby-net-ssh" ,ruby-net-ssh)))
3295 (synopsis "Pure-Ruby SCP client library")
3296 (description "@code{Net::SCP} is a pure-Ruby implementation of the SCP
3297client protocol.")
3298 (home-page "https://github.com/net-ssh/net-scp")
3299 (license license:expat)))
3300
2206e948
DT
3301(define-public ruby-minitest
3302 (package
3303 (name "ruby-minitest")
88a105c1 3304 (version "5.11.3")
2206e948 3305 (source (origin
e83c6d00
DT
3306 (method url-fetch)
3307 (uri (rubygems-uri "minitest" version))
2206e948
DT
3308 (sha256
3309 (base32
88a105c1 3310 "0icglrhghgwdlnzzp4jf76b0mbc71s80njn5afyfjn4wqji8mqbq"))))
2206e948 3311 (build-system ruby-build-system)
2206e948
DT
3312 (native-inputs
3313 `(("ruby-hoe" ,ruby-hoe)))
3314 (synopsis "Small test suite library for Ruby")
3315 (description "Minitest provides a complete suite of Ruby testing
3316facilities supporting TDD, BDD, mocking, and benchmarking.")
3317 (home-page "https://github.com/seattlerb/minitest")
3318 (license license:expat)))
3319
1db6e09f
RW
3320;; This is the last release of Minitest 4, which is used by some packages.
3321(define-public ruby-minitest-4
3322 (package (inherit ruby-minitest)
3323 (version "4.7.5")
3324 (source (origin
3325 (method url-fetch)
3326 (uri (rubygems-uri "minitest" version))
3327 (sha256
3328 (base32
3329 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
3330 (arguments
3331 `(#:phases
3332 (modify-phases %standard-phases
3333 (add-after 'unpack 'remove-unsupported-method
3334 (lambda _
3335 (substitute* "Rakefile"
3336 (("self\\.rubyforge_name = .*") ""))
9a7017eb
BW
3337 #t))
3338 (add-after 'build 'exclude-failing-tests
3339 (lambda _
3340 ;; Some tests are failing on Ruby 2.4 due to the deprecation of
3341 ;; Fixnum.
3342 (delete-file "test/minitest/test_minitest_spec.rb")
3343 #t)))))))
1db6e09f 3344
450a3f7f
CB
3345(define-public ruby-minitest-around
3346 (package
3347 (name "ruby-minitest-around")
3348 (version "0.5.0")
3349 (source
3350 (origin
3351 (method url-fetch)
3352 (uri (rubygems-uri "minitest-around" version))
3353 (sha256
3354 (base32
3355 "15ywnqx0719jl9c25yqfshmwcir57i5f4hr1ra9v9vay9ylcwndr"))))
3356 (build-system ruby-build-system)
3357 (arguments
3358 '(#:phases
3359 (modify-phases %standard-phases
3360 (add-after 'extract-gemspec 'remove-unnecessary-dependency-versions
3361 (lambda _
3362 (substitute* "minitest-around.gemspec"
3363 (("%q<cucumber>.*") "%q<cucumber>, [\">= 0\"])\n"))
3364 #t)))))
3365 (propagated-inputs
3366 `(("ruby-minitest" ,ruby-minitest)))
3367 (native-inputs
3368 `(("bundler" ,bundler)
3369 ("ruby-cucumber" ,ruby-cucumber)
3370 ("ruby-bump" ,ruby-bump)
3371 ("ruby-test-construct" ,ruby-test-construct)))
3372 (synopsis "Run code around tests in Minitest")
3373 (description
3374 "This library provides a way to run code around tests in Minitest,
3375written using either the unit test or spec style.")
3376 (home-page "https://github.com/splattael/minitest-around")
3377 (license license:expat)))
3378
35130835
DT
3379(define-public ruby-minitest-sprint
3380 (package
3381 (name "ruby-minitest-sprint")
3382 (version "1.1.0")
3383 (source (origin
e83c6d00
DT
3384 (method url-fetch)
3385 (uri (rubygems-uri "minitest-sprint" version))
35130835
DT
3386 (sha256
3387 (base32
e83c6d00 3388 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
35130835 3389 (build-system ruby-build-system)
35130835
DT
3390 (native-inputs
3391 `(("ruby-hoe" ,ruby-hoe)
3392 ("ruby-minitest" ,ruby-minitest)))
3393 (synopsis "Fast test suite runner for minitest")
3394 (description "Minitest-sprint is a test runner for minitest that makes it
3395easier to re-run individual failing tests.")
3396 (home-page "https://github.com/seattlerb/minitest-sprint")
3397 (license license:expat)))
3398
0808e361
DT
3399(define-public ruby-minitest-bacon
3400 (package
3401 (name "ruby-minitest-bacon")
6f9652b0 3402 (version "1.0.3")
0808e361 3403 (source (origin
e83c6d00
DT
3404 (method url-fetch)
3405 (uri (rubygems-uri "minitest-bacon" version))
0808e361
DT
3406 (sha256
3407 (base32
6f9652b0 3408 "0zhdwcl6bgha61qiyfvr7zs7ywaxc33wmj9xhxl8jdmpdvifvfaj"))))
0808e361 3409 (build-system ruby-build-system)
0808e361
DT
3410 (native-inputs
3411 `(("ruby-hoe" ,ruby-hoe)))
3412 (inputs
3413 `(("ruby-minitest" ,ruby-minitest)))
3414 (synopsis "Bacon compatibility library for minitest")
3415 (description "Minitest-bacon extends minitest with bacon-like
3416functionality, making it easier to migrate test suites from bacon to minitest.")
3417 (home-page "https://github.com/seattlerb/minitest-bacon")
3418 (license license:expat)))
3419
39dc0eb5
BW
3420(define-public ruby-minitest-focus
3421 (package
3422 (name "ruby-minitest-focus")
3423 (version "1.1.2")
3424 (source
3425 (origin
3426 (method url-fetch)
3427 (uri (rubygems-uri "minitest-focus" version))
3428 (sha256
3429 (base32
3430 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
3431 (build-system ruby-build-system)
3432 (propagated-inputs
3433 `(("ruby-minitest" ,ruby-minitest)))
3434 (native-inputs
3435 `(("ruby-hoe" ,ruby-hoe)))
3436 (synopsis "Allows a few specific tests to be focused on")
3437 (description
3438 "@code{minitest-focus} gives the ability focus on a few tests with ease
3439without having to use command-line arguments. It introduces a @code{focus}
3440class method for use in testing classes, specifying that the next defined test
3441is to be run.")
3442 (home-page "https://github.com/seattlerb/minitest-focus")
3443 (license license:expat)))
3444
99fc5cd5
BW
3445(define-public ruby-minitest-pretty-diff
3446 ;; Use git reference because gem is out of date and does not contain testing
3447 ;; script. There are no releases on GitHub.
3448 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
3449 (package
3450 (name "ruby-minitest-pretty-diff")
3451 (version (string-append "0.1-1." (string-take commit 8)))
3452 (source (origin
3453 (method git-fetch)
3454 (uri (git-reference
3455 (url "https://github.com/adammck/minitest-pretty_diff.git")
3456 (commit commit)))
3457 (file-name (string-append name "-" version "-checkout"))
3458 (sha256
3459 (base32
3460 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
3461 (build-system ruby-build-system)
3462 (arguments
3463 `(#:phases
3464 (modify-phases %standard-phases
3465 (replace 'check
3466 (lambda _
9923d5a4 3467 (invoke "script/test"))))))
99fc5cd5
BW
3468 (native-inputs
3469 `(("bundler" ,bundler)
3470 ("ruby-turn" ,ruby-turn)))
3471 (synopsis "Pretty-print hashes and arrays in MiniTest")
3472 (description
3473 "@code{minitest-pretty_diff} monkey-patches
3474@code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
3475diffing them. This makes it easier to spot differences between nested
3476structures when tests fail.")
3477 (home-page "https://github.com/adammck/minitest-pretty_diff")
3478 (license license:expat))))
3479
685d0d2f
BW
3480(define-public ruby-minitest-moar
3481 (package
3482 (name "ruby-minitest-moar")
3483 (version "0.0.4")
3484 (source
3485 (origin
3486 (method url-fetch)
3487 (uri (rubygems-uri "minitest-moar" version))
3488 (sha256
3489 (base32
3490 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
3491 (build-system ruby-build-system)
3492 (arguments
3493 `(#:phases
3494 (modify-phases %standard-phases
3495 (add-before 'check 'clean-dependencies
3496 (lambda _
3497 ;; Remove all gems defined in the Gemfile because these are not
3498 ;; truly needed.
3499 (substitute* "Gemfile"
3500 (("gem .*") ""))
3501 ;; Remove byebug as not needed to run tests.
3502 (substitute* "test/test_helper.rb"
3503 (("require 'byebug'") ""))
3504 #t)))))
3505 (native-inputs
3506 `(("bundler" ,bundler)
3507 ("ruby-minitest" ,ruby-minitest)))
3508 (synopsis "Extra features and changes to MiniTest")
3509 (description "@code{MiniTest Moar} add some additional features and
3510changes some default behaviours in MiniTest. For instance, Moar replaces the
3511MiniTest @code{Object#stub} with a global @code{stub} method.")
3512 (home-page "https://github.com/dockyard/minitest-moar")
3513 (license license:expat)))
3514
e07ef1d6
BW
3515(define-public ruby-minitest-bonus-assertions
3516 (package
3517 (name "ruby-minitest-bonus-assertions")
c9e261b7 3518 (version "3.0")
e07ef1d6
BW
3519 (source
3520 (origin
3521 (method url-fetch)
3522 (uri (rubygems-uri "minitest-bonus-assertions" version))
3523 (sha256
3524 (base32
c9e261b7 3525 "1hbq9jk904xkz868yha1bqcm6azm7kmjsll2k4pn2nrcib508h2a"))))
e07ef1d6
BW
3526 (build-system ruby-build-system)
3527 (arguments
3528 `(#:phases
3529 (modify-phases %standard-phases
3530 (add-before 'check 'clean-dependencies
3531 (lambda _
3532 ;; Remove unneeded require statement that would entail another
3533 ;; dependency.
3534 (substitute* "test/minitest_config.rb"
3535 (("require 'minitest/bisect'") ""))
3536 #t)))))
3537 (native-inputs
3538 `(("ruby-hoe" ,ruby-hoe)
3539 ("ruby-minitest-pretty-diff" ,ruby-minitest-pretty-diff)
3540 ("ruby-minitest-focus" ,ruby-minitest-focus)
3541 ("ruby-minitest-moar" ,ruby-minitest-moar)))
3542 (synopsis "Bonus assertions for @code{Minitest}")
3543 (description
3544 "Minitest bonus assertions provides extra MiniTest assertions. For
3545instance, it provides @code{assert_true}, @code{assert_false} and
3546@code{assert_set_equal}.")
3547 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
3548 (license license:expat)))
3549
e2c9a9cc
CB
3550(define-public ruby-minitest-reporters
3551 (package
3552 (name "ruby-minitest-reporters")
3553 (version "1.3.6")
3554 (source
3555 (origin
3556 (method url-fetch)
3557 (uri (rubygems-uri "minitest-reporters" version))
3558 (sha256
3559 (base32
3560 "1a3das80rwgys5rj48i5ly144nvszyqyi748bk9bss74jblcf5ay"))))
3561 (build-system ruby-build-system)
3562 (arguments
3563 '(#:phases
3564 (modify-phases %standard-phases
3565 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
3566 ;; including it as an input can lead to circular dependencies.
3567 (add-after 'unpack 'remove-rubocop-from-Rakefile
3568 (lambda _
3569 (substitute* "Rakefile"
3570 (("require 'rubocop/rake\\_task'") "")
3571 (("RuboCop::RakeTask\\.new\\(:rubocop\\)") "[].each"))
3572 #t))
3573 (add-after 'extract-gemspec 'remove-rubocop-from-gemspec
3574 (lambda _
3575 (substitute* "minitest-reporters.gemspec"
3576 ((".*%q<rubocop>.*") "\n"))
3577 #t)))))
3578 (propagated-inputs
3579 `(("ruby-ansi" ,ruby-ansi)
3580 ("ruby-builder" ,ruby-builder)
3581 ("ruby-minitest" ,ruby-minitest)
3582 ("ruby-progressbar" ,ruby-progressbar)))
3583 (native-inputs
3584 `(("bundler" ,bundler)
3585 ("ruby-maruku" ,ruby-maruku)))
3586 (synopsis "Enhanced reporting for Minitest tests")
3587 (description
3588 "@code{minitest/reporters} provides a custom Minitest runner to improve
3589how the test state is reported. A number of different reporters are
3590available, including a spec reporter, progress bar reporter, a HTML
3591reporter.")
3592 (home-page "https://github.com/kern/minitest-reporters")
3593 (license license:expat)))
3594
e582fa93
BW
3595(define-public ruby-minitest-rg
3596 (package
3597 (name "ruby-minitest-rg")
3598 (version "5.2.0")
3599 (source
3600 (origin
3601 (method url-fetch)
3602 (uri (rubygems-uri "minitest-rg" version))
3603 (sha256
3604 (base32
3605 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
3606 (build-system ruby-build-system)
3607 (arguments
3608 ;; Some tests fail even outside Guix, so disable tests.
3609 ;; https://github.com/blowmage/minitest-rg/issues/12
3610 ;; https://github.com/blowmage/minitest-rg/pull/13
3611 `(#:tests? #f))
3612 (propagated-inputs
3613 `(("ruby-minitest" ,ruby-minitest)))
3614 (synopsis "Coloured output for Minitest")
3615 (description
3616 "@code{minitest-rg} changes the colour of the output from Minitest.")
8e486e80 3617 (home-page "https://blowmage.com/minitest-rg/")
e582fa93
BW
3618 (license license:expat)))
3619
2a96dbe6
BW
3620(define-public ruby-minitest-hooks
3621 (package
3622 (name "ruby-minitest-hooks")
eaaf8b12 3623 (version "1.4.2")
2a96dbe6
BW
3624 (source
3625 (origin
3626 (method url-fetch)
3627 (uri (rubygems-uri "minitest-hooks" version))
3628 (sha256
3629 (base32
eaaf8b12 3630 "0lnpvzijbjrvxjc43d155jnbk2mkfshrz22an711wh004scavlzc"))))
2a96dbe6
BW
3631 (build-system ruby-build-system)
3632 (arguments
3633 '(#:test-target "spec"))
3634 (native-inputs
3635 `(("ruby-sequel" ,ruby-sequel)
3636 ("ruby-sqlite3" ,ruby-sqlite3)))
3637 (synopsis "Hooks for the minitest framework")
3638 (description
3639 "Minitest-hooks adds @code{around}, @code{before_all}, @code{after_all},
3640@code{around_all} hooks for Minitest. This allows, for instance, running each
3641suite of specs inside a database transaction, running each spec inside its own
3642savepoint inside that transaction. This can significantly speed up testing
3643for specs that share expensive database setup code.")
7bf837fd 3644 (home-page "https://github.com/jeremyevans/minitest-hooks")
2a96dbe6
BW
3645 (license license:expat)))
3646
afbbdf77
DT
3647(define-public ruby-daemons
3648 (package
3649 (name "ruby-daemons")
f03153db 3650 (version "1.2.5")
afbbdf77
DT
3651 (source (origin
3652 (method url-fetch)
e83c6d00 3653 (uri (rubygems-uri "daemons" version))
afbbdf77
DT
3654 (sha256
3655 (base32
f03153db 3656 "15smbsg0gxb7nf0nrlnplc68y0cdy13dm6fviavpmw7c630sring"))))
afbbdf77
DT
3657 (build-system ruby-build-system)
3658 (arguments
3659 `(#:tests? #f)) ; no test suite
3660 (synopsis "Daemonize Ruby programs")
3661 (description "Daemons provides a way to wrap existing Ruby scripts to be
3662run as a daemon and to be controlled by simple start/stop/restart commands.")
3663 (home-page "https://github.com/thuehlinger/daemons")
3664 (license license:expat)))
b03eb6ac
CB
3665
3666(define-public ruby-data_uri
3667 (package
3668 (name "ruby-data_uri")
3669 (version "0.1.0")
3670 (source
3671 (origin
3672 (method url-fetch)
3673 (uri (rubygems-uri "data_uri" version))
3674 (sha256
3675 (base32
3676 "0fzkxgdxrlbfl4537y3n9mjxbm28kir639gcw3x47ffchwsgdcky"))))
3677 (build-system ruby-build-system)
3678 (synopsis "URI class for parsing data URIs")
3679 (description
3680 "Data @acronym{URI, universal resource idenfitier}s allow resources to be
3681embedded inside a URI. The URI::Data class provides support for parsing these
3682URIs using the normal URI.parse method.")
3683 (home-page "https://github.com/dball/data_uri")
3684 (license license:expat)))
66e20863 3685
72c785f9
MB
3686(define-public ruby-deep-merge
3687 (package
3688 (name "ruby-deep-merge")
3689 (version "1.2.1")
3690 (home-page "https://github.com/danielsdeleo/deep_merge")
3691 ;; The Rubygem source does not contain the gemspec required for tests.
3692 (source (origin
3693 (method git-fetch)
3694 (uri (git-reference (url home-page) (commit version)))
3695 (file-name (git-file-name name version))
3696 (sha256
3697 (base32
3698 "0c9rk23ilhc0n4489y6lda2wzphpzh6ish6fahlbpjhxn82wb931"))))
3699 (build-system ruby-build-system)
3700 (native-inputs
3701 `(("ruby-minitest" ,ruby-minitest)))
3702 (synopsis "Recursively merge hashes")
3703 (description
3704 "Deep Merge is a set of utility functions for @code{Hash}. It permits
3705you to merge elements inside a hash together recursively.")
3706 (license license:expat)))
3707
66e20863
DT
3708(define-public ruby-git
3709 (package
3710 (name "ruby-git")
ceaff59e 3711 (version "1.3.0")
66e20863
DT
3712 (source (origin
3713 (method url-fetch)
e83c6d00 3714 (uri (rubygems-uri "git" version))
66e20863
DT
3715 (sha256
3716 (base32
ceaff59e 3717 "1waikaggw7a1d24nw0sh8fd419gbf7awh000qhsf411valycj6q3"))))
66e20863
DT
3718 (build-system ruby-build-system)
3719 (arguments
e83c6d00
DT
3720 `(#:tests? #f ; no tests
3721 #:phases (modify-phases %standard-phases
3722 (add-after 'install 'patch-git-binary
3723 (lambda* (#:key inputs outputs #:allow-other-keys)
66e20863
DT
3724 ;; Make the default git binary an absolute path to the
3725 ;; store.
e83c6d00
DT
3726 (let ((git (string-append (assoc-ref inputs "git")
3727 "/bin/git"))
3cb3fa67
CB
3728 (config (string-append
3729 (assoc-ref outputs "out")
3730 "/lib/ruby/vendor_ruby/gems/git-"
3731 ,version "/lib/git/config.rb")))
e83c6d00 3732 (substitute* (list config)
66e20863
DT
3733 (("'git'")
3734 (string-append "'" git "'")))
e83c6d00 3735 #t))))))
66e20863
DT
3736 (inputs
3737 `(("git" ,git)))
3738 (synopsis "Ruby wrappers for Git")
3739 (description "Ruby/Git is a Ruby library that can be used to create, read
3740and manipulate Git repositories by wrapping system calls to the git binary.")
3741 (home-page "https://github.com/schacon/ruby-git")
3742 (license license:expat)))
71d3e2c2 3743
95598153
MB
3744(define-public ruby-hocon
3745 (package
3746 (name "ruby-hocon")
3747 (version "1.3.0")
3748 (home-page "https://github.com/puppetlabs/ruby-hocon")
3749 (source (origin
3750 (method git-fetch)
3751 (uri (git-reference (url home-page) (commit version)))
3752 (file-name (git-file-name name version))
3753 (sha256
3754 (base32
3755 "1wz4cswjg3gs1y1bar7j4j88wjimfa9zhvy51jyi177i5dzax416"))))
3756 (build-system ruby-build-system)
3757 (arguments
3758 '(#:phases (modify-phases %standard-phases
3759 (replace 'check
3760 (lambda* (#:key tests? #:allow-other-keys)
3761 (if tests?
3762 (invoke "rspec")
3763 (format #t "test suite not run~%"))
3764 #t)))))
3765 (native-inputs
3766 `(("bundler" ,bundler)
3767 ("ruby-rspec" ,ruby-rspec)))
3768 (synopsis "HOCON config library")
3769 (description
3770 "This package provides Ruby support for the @acronym{HOCON,
3771Human-Optimized Config Object Notation} configuration file format. It
3772supports parsing and modifying HOCON and JSON files, and rendering parsed
3773objects back to a @code{String}.")
3774 (license license:asl2.0)))
3775
71d3e2c2
DT
3776(define-public ruby-slop
3777 (package
3778 (name "ruby-slop")
d14e5eaa 3779 (version "4.5.0")
71d3e2c2
DT
3780 (source (origin
3781 (method url-fetch)
e83c6d00 3782 (uri (rubygems-uri "slop" version))
71d3e2c2
DT
3783 (sha256
3784 (base32
d14e5eaa 3785 "0bfm8535g0rkn9cbjndkckf0f7a3wj0rg4rqhrpsgxnbfdf2lm0p"))))
71d3e2c2
DT
3786 (build-system ruby-build-system)
3787 (native-inputs
3788 `(("ruby-minitest" ,ruby-minitest)))
3789 (synopsis "Ruby command line option parser")
3790 (description "Slop provides a Ruby domain specific language for gathering
3791options and parsing command line flags.")
3792 (home-page "https://github.com/leejarvis/slop")
3793 (license license:expat)))
e778a549 3794
5337f8b9
DT
3795(define-public ruby-slop-3
3796 (package (inherit ruby-slop)
3797 (version "3.6.0")
3798 (source (origin
3799 (method url-fetch)
3800 (uri (rubygems-uri "slop" version))
3801 (sha256
3802 (base32
3803 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
3804
ca914b5b
CB
3805(define-public ruby-multi-xml
3806 (package
3807 (name "ruby-multi-xml")
3808 (version "0.6.0")
3809 (source
3810 (origin
3811 (method url-fetch)
3812 (uri (rubygems-uri "multi_xml" version))
3813 (sha256
3814 (base32
3815 "0lmd4f401mvravi1i1yq7b2qjjli0yq7dfc4p1nj5nwajp7r6hyj"))))
3816 (build-system ruby-build-system)
3817 (arguments
3818 '(#:tests? #f)) ; No included tests
3819 (synopsis "Swappable XML backends for Ruby")
3820 (description
3821 "@code{MultiXml} provides swappable XML backends utilizing either LibXML,
3822Nokogiri, Ox, or REXML.")
3823 (home-page "https://github.com/sferik/multi_xml")
3824 (license license:expat)))
3825
e778a549
DT
3826(define-public ruby-multipart-post
3827 (package
3828 (name "ruby-multipart-post")
3829 (version "2.0.0")
3830 (source (origin
3831 (method url-fetch)
e83c6d00 3832 (uri (rubygems-uri "multipart-post" version))
e778a549
DT
3833 (sha256
3834 (base32
e83c6d00 3835 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
e778a549
DT
3836 (build-system ruby-build-system)
3837 (native-inputs
3838 `(("bundler" ,bundler)))
3839 (synopsis "Multipart POST library for Ruby")
3840 (description "Multipart-Post Adds multipart POST capability to Ruby's
3841net/http library.")
3842 (home-page "https://github.com/nicksieger/multipart-post")
3843 (license license:expat)))
f8da3af0 3844
9a97e7ce
CB
3845(define-public ruby-multi-json
3846 (package
3847 (name "ruby-multi-json")
1b6f5475 3848 (version "1.13.1")
9a97e7ce
CB
3849 (source
3850 (origin
b872b47b 3851 (method git-fetch)
1b6f5475
BW
3852 ;; Tests are not distributed at rubygems.org so download from GitHub
3853 ;; instead.
b872b47b
EF
3854 (uri (git-reference
3855 (url "https://github.com/intridea/multi_json")
3856 (commit (string-append "v" version))))
3857 (file-name (git-file-name name version))
9a97e7ce
CB
3858 (sha256
3859 (base32
b872b47b 3860 "18wpb6p01rrkl4v33byh70vxj2a5jxkfxzv3pz8z6pssy4ymwkm4"))))
9a97e7ce
CB
3861 (build-system ruby-build-system)
3862 (arguments
1b6f5475
BW
3863 `(#:phases
3864 (modify-phases %standard-phases
3865 (add-after 'unpack 'remove-signing-key-reference
3866 (lambda _
3867 (substitute* "multi_json.gemspec"
3868 ((".*spec.signing_key.*") ""))
3869 #t)))))
3870 (native-inputs
3871 `(("bundler" ,bundler)
3872 ("ruby-rspec" ,ruby-rspec)
3873 ("ruby-yard" ,ruby-yard)
3874 ("ruby-json-pure" ,ruby-json-pure)
3875 ("ruby-oj" ,ruby-oj)
3876 ("ruby-yajl-ruby" ,ruby-yajl-ruby)))
9a97e7ce
CB
3877 (synopsis "Common interface to multiple JSON libraries for Ruby")
3878 (description
3879 "This package provides a common interface to multiple JSON libraries,
3880including Oj, Yajl, the JSON gem (with C-extensions), the pure-Ruby JSON gem,
3881NSJSONSerialization, gson.rb, JrJackson, and OkJson.")
1b6f5475 3882 (home-page "https://github.com/intridea/multi_json")
9a97e7ce
CB
3883 (license license:expat)))
3884
5edef88b
BW
3885(define-public ruby-multi-test
3886 (package
3887 (name "ruby-multi-test")
3888 (version "0.1.2")
3889 (source
3890 (origin
3891 (method url-fetch)
3892 (uri (rubygems-uri "multi_test" version))
3893 (sha256
3894 (base32
3895 "1sx356q81plr67hg16jfwz9hcqvnk03bd9n75pmdw8pfxjfy1yxd"))))
3896 (build-system ruby-build-system)
3897 (arguments
3898 '(;; Tests require different sets of specific gem versions to be available,
3899 ;; and there is no gemfile that specifies the newest versions of
3900 ;; dependencies to be tested.
3901 #:tests? #f))
3902 (synopsis
3903 "Interface to testing libraries loaded into a running Ruby process")
3904 (description
3905 "@code{multi_test} provides a uniform interface onto whatever testing
3906libraries that have been loaded into a running Ruby process to help control
3907rogue test/unit/autorun requires.")
3908 (home-page "https://github.com/cucumber/multi_test")
9a97e7ce
CB
3909 (license license:expat)))
3910
f8da3af0
DT
3911(define-public ruby-arel
3912 (package
3913 (name "ruby-arel")
aecd533d 3914 (version "9.0.0")
f8da3af0
DT
3915 (source (origin
3916 (method url-fetch)
3917 (uri (rubygems-uri "arel" version))
3918 (sha256
3919 (base32
aecd533d 3920 "1jk7wlmkr61f6g36w9s2sn46nmdg6wn2jfssrhbhirv5x9n95nk0"))))
f8da3af0
DT
3921 (build-system ruby-build-system)
3922 (arguments '(#:tests? #f)) ; no tests
3923 (home-page "https://github.com/rails/arel")
3924 (synopsis "SQL AST manager for Ruby")
6f23e2fb
TGR
3925 (description "Arel is an SQL @dfn{Abstract Syntax Tree} (AST) manager for
3926Ruby. It simplifies the generation of complex SQL queries and adapts to
3927various relational database implementations.")
f8da3af0 3928 (license license:expat)))
616eaead 3929
554bf4f6
CB
3930(define-public ruby-marcel
3931 (package
3932 (name "ruby-marcel")
3933 (version "0.3.3")
3934 (source
3935 (origin
3936 (method url-fetch)
3937 (uri (rubygems-uri "marcel" version))
3938 (sha256
3939 (base32
3940 "1nxbjmcyg8vlw6zwagf17l9y2mwkagmmkg95xybpn4bmf3rfnksx"))))
3941 (build-system ruby-build-system)
3942 (arguments
3943 '(;; No included tests
3944 #:tests? #f))
3945 (propagated-inputs
3946 `(("ruby-mimemagic" ,ruby-mimemagic)))
3947 (synopsis "MIME type detection using magic numbers, filenames and extensions")
3948 (description
3949 "@code{marcel} provides @acronym{MIME, Multipurpose Internet Mail
3950Extensions} type detection using magic numbers, filenames, and extensions")
3951 (home-page "https://github.com/basecamp/marcel")
3952 (license license:expat)))
3953
616eaead 3954(define-public ruby-minitar
bfaf8efd
BW
3955 ;; We package from the GitHub source to fix the security issue reported at
3956 ;; https://github.com/halostatue/minitar/issues/16.
3957 (let ((commit "e25205ecbb6277ae8a3df1e6a306d7ed4458b6e4"))
3958 (package
3959 (name "ruby-minitar")
3960 (version (string-append "0.5.4-1." (string-take commit 8)))
3961 (source
3962 (origin
3963 (method git-fetch)
3964 (uri (git-reference
3965 (url "https://github.com/halostatue/minitar.git")
3966 (commit commit)))
3967 (file-name (string-append name "-" version "-checkout"))
3968 (sha256
3969 (base32
3970 "1iywfx07jgjqcmixzkxk9zdwfmij1fyg1z2jlwzj15cj7s99qlfv"))))
3971 (build-system ruby-build-system)
3972 (arguments
3973 '(#:tests? #f)) ; missing a gemspec
3974 (synopsis "Ruby library and utility for handling tar archives")
3975 (description
3976 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
616eaead 3977that provides the ability to deal with POSIX tar archive files.")
bfaf8efd
BW
3978 (home-page "http://www.github.com/atoulme/minitar")
3979 (license (list license:gpl2+ license:ruby)))))
bea1c0e2
DT
3980
3981(define-public ruby-mini-portile
3982 (package
3983 (name "ruby-mini-portile")
3984 (version "0.6.2")
3985 (source
3986 (origin
3987 (method url-fetch)
3988 (uri (rubygems-uri "mini_portile" version))
3989 (sha256
3990 (base32
3991 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
3992 (build-system ruby-build-system)
3993 (arguments
3994 '(#:tests? #f)) ; tests require network access
3995 (synopsis "Ports system for Ruby developers")
3996 (description "Mini-portile is a port/recipe system for Ruby developers.
3997It provides a standard way to compile against specific versions of libraries
3998to reproduce user environments.")
7bf837fd 3999 (home-page "https://github.com/flavorjones/mini_portile")
bea1c0e2 4000 (license license:expat)))
e920bfca 4001
d000fc92
BW
4002(define-public ruby-mini-portile-2
4003 (package (inherit ruby-mini-portile)
a88ac044 4004 (version "2.4.0")
d000fc92
BW
4005 (source (origin
4006 (method url-fetch)
4007 (uri (rubygems-uri "mini_portile2" version))
4008 (sha256
4009 (base32
a88ac044 4010 "15zplpfw3knqifj9bpf604rb3wc1vhq6363pd6lvhayng8wql5vy"))))))
d000fc92 4011
e920bfca
DT
4012(define-public ruby-nokogiri
4013 (package
4014 (name "ruby-nokogiri")
36ccf59e 4015 (version "1.10.5")
e920bfca
DT
4016 (source (origin
4017 (method url-fetch)
4018 (uri (rubygems-uri "nokogiri" version))
4019 (sha256
4020 (base32
36ccf59e 4021 "185g3dwba73jqxjr94bd2zk6fil6n9hmcfnfyzh3p1w47vm296r7"))))
e920bfca
DT
4022 (build-system ruby-build-system)
4023 (arguments
4024 ;; Tests fail because Nokogiri can only test with an installed extension,
4025 ;; and also because many test framework dependencies are missing.
7b01f250 4026 `(#:tests? #f
e920bfca
DT
4027 #:gem-flags (list "--" "--use-system-libraries"
4028 (string-append "--with-xml2-include="
4029 (assoc-ref %build-inputs "libxml2")
5e7f1b0b
BW
4030 "/include/libxml2" ))
4031 #:phases
4032 (modify-phases %standard-phases
7b01f250
BW
4033 (add-before 'build 'patch-extconf
4034 ;; 'pkg-config' is not included in the GEM_PATH during
4035 ;; installation, so we add it directly to the load path.
4036 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 4037 (let* ((pkg-config (assoc-ref inputs "ruby-pkg-config")))
7b01f250
BW
4038 (substitute* "ext/nokogiri/extconf.rb"
4039 (("gem 'pkg-config'.*")
4040 (string-append "$:.unshift '"
3cb3fa67 4041 pkg-config "/lib/ruby/vendor_ruby"
7b01f250
BW
4042 "/gems/pkg-config-"
4043 ,(package-version ruby-pkg-config)
4044 "/lib'\n"))))
5e7f1b0b 4045 #t)))))
e920bfca 4046 (native-inputs
7b01f250 4047 `(("ruby-hoe" ,ruby-hoe)))
e920bfca
DT
4048 (inputs
4049 `(("zlib" ,zlib)
4050 ("libxml2" ,libxml2)
4051 ("libxslt" ,libxslt)))
4052 (propagated-inputs
7b01f250
BW
4053 `(("ruby-mini-portile" ,ruby-mini-portile-2)
4054 ("ruby-pkg-config" ,ruby-pkg-config)))
e920bfca
DT
4055 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
4056 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
4057both CSS3 selector and XPath 1.0 support.")
4058 (home-page "http://www.nokogiri.org/")
4059 (license license:expat)))
30b0b725
DT
4060
4061(define-public ruby-method-source
4062 (package
4063 (name "ruby-method-source")
c8355037 4064 (version "0.9.0")
30b0b725
DT
4065 (source
4066 (origin
4067 (method url-fetch)
4068 (uri (rubygems-uri "method_source" version))
4069 (sha256
4070 (base32
c8355037 4071 "0xqj21j3vfq4ldia6i2akhn2qd84m0iqcnsl49kfpq3xk6x0dzgn"))))
30b0b725 4072 (build-system ruby-build-system)
c8355037
BW
4073 (arguments
4074 `(#:test-target "spec"))
30b0b725 4075 (native-inputs
c8355037 4076 `(("ruby-rspec" ,ruby-rspec)
30b0b725
DT
4077 ("git" ,git)))
4078 (synopsis "Retrieve the source code for Ruby methods")
4079 (description "Method_source retrieves the source code for Ruby methods.
4080Additionally, it can extract source code from Proc and Lambda objects or just
4081extract comments.")
4082 (home-page "https://github.com/banister/method_source")
4083 (license license:expat)))
2e3fdea4
DT
4084
4085(define-public ruby-coderay
4086 (package
4087 (name "ruby-coderay")
5cf0997a 4088 (version "1.1.2")
2e3fdea4
DT
4089 (source
4090 (origin
4091 (method url-fetch)
4092 (uri (rubygems-uri "coderay" version))
4093 (sha256
4094 (base32
5cf0997a 4095 "15vav4bhcc2x3jmi3izb11l4d9f3xv8hp2fszb7iqmpsccv1pz4y"))))
2e3fdea4
DT
4096 (build-system ruby-build-system)
4097 (arguments
4098 '(#:tests? #f)) ; missing test files
4099 (synopsis "Ruby syntax highlighting library")
4100 (description "Coderay is a Ruby library that provides syntax highlighting
4101for select languages.")
4102 (home-page "http://coderay.rubychan.de")
4103 (license license:expat)))
96e76083 4104
2156cc9c
MB
4105(define-public ruby-parallel-tests
4106 (package
4107 (name "ruby-parallel-tests")
4108 (version "2.32.0")
4109 (home-page "https://github.com/grosser/parallel_tests")
4110 (source (origin
4111 (method git-fetch)
4112 (uri (git-reference
4113 (url home-page)
4114 (commit (string-append "v" version))))
4115 (file-name (string-append name version))
4116 (sha256
4117 (base32
4118 "0l2rjz9fnxv7hvz679v7a75mghsh9x9qpvbyapiavqsx21v42l7m"))))
4119 (build-system ruby-build-system)
4120 (arguments
4121 '(#:test-target "default"
4122 #:phases (modify-phases %standard-phases
4123 (add-after 'patch-source-shebangs 'patch-shell-invokations
4124 (lambda _
4125 (substitute* '("lib/parallel_tests/tasks.rb"
4126 "spec/parallel_tests/tasks_spec.rb")
4127 (("/bin/sh") (which "sh"))
4128 (("/bin/bash") (which "bash")))
4129 #t))
4130 (add-before 'check 'remove-version-constraints
4131 (lambda _
4132 ;; Remove hard coded version constraints, instead just
4133 ;; use whatever versions are available in Guix.
4134 (delete-file "Gemfile.lock")
4135 (substitute* "Gemfile"
4136 (("'minitest',.*")
4137 "'minitest'\n")
4138 (("'cucumber',.*")
4139 "'cucumber'\n"))
4140 #t))
4141 (add-before 'check 'disable-rails-test
4142 (lambda _
4143 ;; XXX: This test attempts to download and run the test
4144 ;; suites of multiple Rails versions(!) directly.
4145 (delete-file "spec/rails_spec.rb")
4146 #t))
4147 (add-before 'check 'set-HOME
4148 (lambda _
4149 ;; Some tests check the output of Bundler, and fail when
4150 ;; Bundler warns that /homeless-shelter does not exist.
4151 (setenv "HOME" "/tmp")
4152 #t)))))
4153 (native-inputs
4154 `(("ruby-bump" ,ruby-bump)
4155 ("ruby-cucumber" ,ruby-cucumber)
4156 ("ruby-minitest" ,ruby-minitest)
4157 ("ruby-rake" ,ruby-rake)
4158 ("ruby-rspec" ,ruby-rspec)
4159 ("ruby-spinach" ,ruby-spinach)))
4160 (propagated-inputs
4161 `(("ruby-parallel" ,ruby-parallel)))
4162 (synopsis "Run tests in parallel")
4163 (description
4164 "This package can speed up @code{Test::Unit}, @code{RSpec},
4165@code{Cucumber}, and @code{Spinach} tests by running them concurrently
4166across multiple CPU cores.")
4167 (license license:expat)))
4168
54993457
CB
4169(define-public ruby-parser
4170 (package
4171 (name "ruby-parser")
4172 (version "2.6.0.0")
4173 (source
4174 (origin
4175 (method url-fetch)
4176 (uri (rubygems-uri "parser" version))
4177 (sha256
4178 (base32
4179 "1hhz2k5417vr2k1llwqgjdnmyrhlpqicy0y2arr6r1gp04fg9wlm"))))
4180 (build-system ruby-build-system)
4181 (native-inputs
4182 `(("bundler" ,bundler)
4183 ("ruby-cliver" ,ruby-cliver)
4184 ("ruby-simplecov" ,ruby-simplecov)
4185 ("ruby-racc" ,ruby-racc)))
4186 (inputs
4187 `(("ragel" ,ragel)))
4188 (propagated-inputs
4189 `(("ruby-ast" ,ruby-ast)))
4190 (synopsis "Ruby parser written in pure Ruby")
4191 (description
4192 "This package provides a Ruby parser written in pure Ruby.")
4193 (home-page "https://github.com/whitequark/parser")
4194 (license license:expat)))
4195
16f423cb
CB
4196(define-public ruby-prawn-manual-builder
4197 (package
4198 (name "ruby-prawn-manual-builder")
1d4f0019 4199 (version "0.3.1")
16f423cb
CB
4200 (source
4201 (origin
4202 (method url-fetch)
4203 (uri (rubygems-uri "prawn-manual_builder" version))
4204 (sha256
1d4f0019 4205 (base32 "1vlg5w7wq43g2hgpgra2nrcxj1kb4ayqliz4gmja2rhs037j2vzs"))))
16f423cb
CB
4206 (build-system ruby-build-system)
4207 (arguments
1d4f0019 4208 '(#:tests? #f ; no included tests
16f423cb
CB
4209 #:phases
4210 (modify-phases %standard-phases
4211 (add-after 'extract-gemspec 'patch-gemspec
4212 (lambda _
4213 (substitute* ".gemspec"
4214 ;; Loosen the requirement for pdf-inspector
4215 (("~> 1\\.0\\.7") ">= 0")))))))
4216 (propagated-inputs
4217 `(("ruby-coderay" ,ruby-coderay)))
4218 (synopsis "Tool for writing manuals for Prawn and Prawn accessories")
4219 (description
4220 "This package provides a tool for writing manuals for Prawn and Prawn
4221accessories")
4222 (home-page "https://github.com/prawnpdf/prawn-manual_builder")
4223 (license (list
4224 ;; GPLv2 or GPLv3 or custom license described in LICENSE file
4225 license:gpl2
4226 license:gpl3))))
4227
268643b9
CB
4228(define-public ruby-progress_bar
4229 (package
4230 (name "ruby-progress_bar")
4231 (version "1.1.0")
4232 (source
4233 (origin
4234 (method url-fetch)
4235 (uri (rubygems-uri "progress_bar" version))
4236 (sha256
4237 (base32
4238 "1qc40mr6p1z9a3vlpnsg1zfgk1qswviql2a31y63wpv3vr6b5f48"))))
4239 (build-system ruby-build-system)
4240 (arguments
4241 '(#:test-target "spec"))
4242 (propagated-inputs
4243 `(("ruby-highline" ,ruby-highline)
4244 ("ruby-options" ,ruby-options)))
4245 (native-inputs
4246 `(("bundler" ,bundler)
4247 ("ruby-rspec" ,ruby-rspec)
4248 ("ruby-timecop" ,ruby-timecop)))
4249 (synopsis
4250 "Ruby library for displaying progress bars")
4251 (description
4252 "ProgressBar is a simple library for displaying progress bars. The
4253maximum value is configurable, and additional information can be displayed
4254like the percentage completion, estimated time remaining, elapsed time and
4255rate.")
4256 (home-page "https://github.com/paul/progress_bar")
4257 (license license:wtfpl2)))
4258
95f85d44
CB
4259(define-public ruby-dep
4260 (package
4261 (name "ruby-dep")
4262 (version "1.5.0")
4263 (source
4264 (origin
4265 (method url-fetch)
4266 (uri (rubygems-uri "ruby_dep" version))
4267 (sha256
4268 (base32
4269 "1c1bkl97i9mkcvkn1jks346ksnvnnp84cs22gwl0vd7radybrgy5"))))
4270 (build-system ruby-build-system)
4271 (arguments
4272 '(#:tests? #f)) ; No included tests
4273 (synopsis "Creates a version constraint of supported Rubies")
4274 (description
4275 "This package helps create a version constraint of supported Rubies,
4276suitable for a gemspec file.")
4277 (home-page "https://github.com/e2/ruby_dep")
4278 (license license:expat)))
4279
158a9253
CB
4280(define-public ruby-progressbar
4281 (package
4282 (name "ruby-progressbar")
2d2a2363 4283 (version "1.10.1")
158a9253
CB
4284 (source
4285 (origin
4286 (method url-fetch)
4287 (uri (rubygems-uri "ruby-progressbar" version))
4288 (sha256
2d2a2363 4289 (base32 "1k77i0d4wsn23ggdd2msrcwfy0i376cglfqypkk2q77r2l3408zf"))))
158a9253
CB
4290 (build-system ruby-build-system)
4291 (arguments
4292 '(;; TODO: There looks to be a circular dependency with ruby-fuubar.
4293 #:tests? #f))
4294 (synopsis "Text progress bar library for Ruby")
4295 (description
4296 "Ruby/ProgressBar is an flexible text progress bar library for Ruby.
4297The output can be customized with a formatting system.")
4298 (home-page "https://github.com/jfelchner/ruby-progressbar")
4299 (license license:expat)))
4300
96e76083
DT
4301(define-public ruby-pry
4302 (package
4303 (name "ruby-pry")
1bf02b20 4304 (version "0.11.3")
96e76083
DT
4305 (source
4306 (origin
4307 (method url-fetch)
4308 (uri (rubygems-uri "pry" version))
4309 (sha256
4310 (base32
1bf02b20 4311 "1mh312k3y94sj0pi160wpia0ps8f4kmzvm505i6bvwynfdh7v30g"))))
96e76083
DT
4312 (build-system ruby-build-system)
4313 (arguments
4314 '(#:tests? #f)) ; no tests
4315 (propagated-inputs
4316 `(("ruby-coderay" ,ruby-coderay)
1960d4fd 4317 ("ruby-method-source" ,ruby-method-source)))
96e76083
DT
4318 (synopsis "Ruby REPL")
4319 (description "Pry is an IRB alternative and runtime developer console for
4320Ruby. It features syntax highlighting, a plugin architecture, runtime
4321invocation, and source and documentation browsing.")
2f3800e5 4322 (home-page "https://pryrepl.org")
96e76083 4323 (license license:expat)))
1415792a 4324
def7908a
MB
4325(define-public ruby-single-cov
4326 (package
4327 (name "ruby-single-cov")
4328 (version "1.3.2")
4329 (home-page "https://github.com/grosser/single_cov")
4330 (source (origin
4331 (method git-fetch)
4332 (uri (git-reference (url home-page)
4333 (commit (string-append "v" version))))
4334 (file-name (git-file-name name version))
4335 (sha256
4336 (base32
4337 "05qdzpcai1p23a120gb9bxkfl4y73k9hicx34ch2lsk31lgi9bl7"))))
4338 (build-system ruby-build-system)
4339 (arguments
4340 '(#:test-target "default"
4341 #:phases (modify-phases %standard-phases
4342 (replace 'replace-git-ls-files
4343 (lambda _
4344 (substitute* "single_cov.gemspec"
4345 (("`git ls-files lib/ bin/ MIT-LICENSE`")
4346 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
4347 #t))
4348 (add-before 'check 'remove-version-constraints
4349 (lambda _
4350 (delete-file "Gemfile.lock")
4351 #t))
4352 (add-before 'check 'make-files-writable
4353 (lambda _
4354 ;; Tests need to create local directories and open files
4355 ;; with write permissions.
4356 (for-each make-file-writable
4357 (find-files "specs" #:directories? #t))
4358 #t))
4359 (add-before 'check 'disable-failing-test
4360 (lambda _
4361 ;; XXX: This test copies assets from minitest, but can
4362 ;; not cope with the files being read-only. Just skip
4363 ;; it for now.
4364 (substitute* "specs/single_cov_spec.rb"
4365 (("it \"complains when coverage is bad\"")
4366 "xit \"complains when coverage is bad\""))
4367 #t)))))
4368 (native-inputs
4369 `(("ruby-bump" ,ruby-bump)
4370 ("ruby-minitest" ,ruby-minitest)
4371 ("ruby-rspec" ,ruby-rspec)
4372 ("ruby-simplecov" ,ruby-simplecov)))
4373 (synopsis "Code coverage reporting tool")
4374 (description
4375 "This package provides actionable code coverage reports for Ruby
4376projects. It has very little overhead and can be easily integrated with
4377development tools to catch coverage problems early.")
4378 (license license:expat)))
4379
051deeb7
RW
4380(define-public ruby-guard
4381 (package
4382 (name "ruby-guard")
4383 (version "2.13.0")
4384 (source (origin
3c6128f6 4385 (method git-fetch)
051deeb7
RW
4386 ;; The gem does not include a Rakefile, nor does it contain a
4387 ;; gemspec file, nor does it come with the tests. This is why
4388 ;; we fetch the tarball from Github.
3c6128f6
EF
4389 (uri (git-reference
4390 (url "https://github.com/guard/guard")
4391 (commit (string-append "v" version))))
4392 (file-name (git-file-name name version))
051deeb7
RW
4393 (sha256
4394 (base32
3c6128f6 4395 "16pxcszr0g2jnl3090didxh1d8z5m2mly14m3w4rspb8fmclsnjs"))))
051deeb7
RW
4396 (build-system ruby-build-system)
4397 (arguments
4398 `(#:tests? #f ; tests require cucumber
4399 #:phases
4400 (modify-phases %standard-phases
4401 (add-after 'unpack 'remove-git-ls-files
4402 (lambda* (#:key outputs #:allow-other-keys)
4403 (substitute* "guard.gemspec"
4404 (("git ls-files -z") "find . -type f -print0"))
4405 #t))
4406 (replace 'build
4407 (lambda _
9923d5a4 4408 (invoke "gem" "build" "guard.gemspec"))))))
051deeb7
RW
4409 (propagated-inputs
4410 `(("ruby-formatador" ,ruby-formatador)
4411 ("ruby-listen" ,ruby-listen)
4412 ("ruby-lumberjack" ,ruby-lumberjack)
4413 ("ruby-nenv" ,ruby-nenv)
4414 ("ruby-notiffany" ,ruby-notiffany)
4415 ("ruby-pry" ,ruby-pry)
4416 ("ruby-shellany" ,ruby-shellany)
4417 ("ruby-thor" ,ruby-thor)))
4418 (native-inputs
4419 `(("bundler" ,bundler)
4420 ("ruby-rspec" ,ruby-rspec)))
4421 (synopsis "Tool to handle events on file system modifications")
4422 (description
4423 "Guard is a command line tool to easily handle events on file system
4424modifications. Guard automates various tasks by running custom rules whenever
4425file or directories are modified.")
3c6128f6 4426 (home-page "https://guardgem.org/")
051deeb7
RW
4427 (license license:expat)))
4428
c09bc60d
MB
4429(define-public ruby-spinach
4430 (package
4431 (name "ruby-spinach")
4432 (version "0.11.0")
4433 (home-page "http://github.com/codegram/spinach")
4434 (source (origin
4435 (method url-fetch)
4436 (uri (rubygems-uri "spinach" version))
4437 (sha256
4438 (base32
4439 "1mv053mqz9c8ngqa6wp1ymk2fax6j0yqzax6918akrdr7c3fx3c6"))))
4440 (build-system ruby-build-system)
4441 (arguments
4442 ;; FIXME: Disable tests altogether because they depend on 'capybara'
4443 ;; which in turn depends on many other unpackaged gems. Enable once
4444 ;; capybara is available.
4445 '(#:tests? #f))
4446 (propagated-inputs
4447 `(("ruby-colorize" ,ruby-colorize)
4448 ("ruby-gherkin-ruby" ,ruby-gherkin-ruby)
4449 ("ruby-json" ,ruby-json)))
4450 (synopsis "Gherkin-based BDD framework")
4451 (description
4452 "Spinach is a high-level @acronym{BDD, Behavior-driven development}
4453framework that leverages the expressive @code{Gherkin} language to help you
4454define executable specifications of your code.")
4455 (license license:expat)))
4456
bcbb3cc9
CB
4457(define-public ruby-tilt
4458 (package
4459 (name "ruby-tilt")
4460 (version "2.0.9")
4461 (source
4462 (origin
4463 (method url-fetch)
4464 (uri (rubygems-uri "tilt" version))
4465 (sha256
4466 (base32
4467 "0ca4k0clwf0rkvy7726x4nxpjxkpv67w043i39saxgldxd97zmwz"))))
4468 (build-system ruby-build-system)
4469 (arguments
4470 '(#:phases
4471 (modify-phases %standard-phases
4472 (add-after 'unpack 'remove-some-dependencies
4473 (lambda _
4474 (substitute* "Gemfile"
4475 ;; TODO ronn is used for generating the manual
4476 (("gem 'ronn'.*") "\n")
4477 ;; ruby-haml has a runtime dependency on ruby-tilt, so don't
4478 ;; pass it in as a native-input
4479 (("gem 'haml'.*") "\n")
4480 ;; TODO Not all of these gems are packaged for Guix yet:
4481 ;; less, coffee-script, livescript, babel-transpiler,
4482 ;; typescript-node
4483 (("if can_execjs") "if false")
4484 ;; Disable the secondary group to reduce the number of
4485 ;; dependencies. None of the normal approaches work, so patch
4486 ;; the Gemfile instead.
4487 (("group :secondary") "[].each"))
4488 #t)))))
4489 (native-inputs
4490 `(("bundler" ,bundler)
4491 ("ruby-yard" ,ruby-yard)
4492 ("ruby-builder" ,ruby-builder)
4493 ("ruby-erubis" ,ruby-erubis)
4494 ("ruby-markaby" ,ruby-markaby)
4495 ("ruby-sassc" ,ruby-sassc)))
4496 (synopsis "Generic interface to multiple Ruby template engines")
4497 (description
4498 "Tilt is a thin interface over a number of different Ruby template
4499engines in an attempt to make their usage as generic as possible.")
4500 (home-page "https://github.com/rtomayko/tilt/")
4501 (license license:expat)))
4502
1415792a
DT
4503(define-public ruby-thread-safe
4504 (package
4505 (name "ruby-thread-safe")
313dd5dd 4506 (version "0.3.6")
1415792a
DT
4507 (source
4508 (origin
4509 (method url-fetch)
4510 (uri (rubygems-uri "thread_safe" version))
4511 (sha256
4512 (base32
313dd5dd 4513 "0nmhcgq6cgz44srylra07bmaw99f5271l0dpsvl5f75m44l0gmwy"))))
1415792a
DT
4514 (build-system ruby-build-system)
4515 (arguments
4516 '(#:tests? #f)) ; needs simplecov, among others
4517 (synopsis "Thread-safe utilities for Ruby")
4518 (description "The thread_safe library provides thread-safe collections and
4519utilities for Ruby.")
4520 (home-page "https://github.com/ruby-concurrency/thread_safe")
4521 (license license:asl2.0)))
08a1b701
DT
4522
4523(define-public ruby-tzinfo
4524 (package
4525 (name "ruby-tzinfo")
4237af85 4526 (version "1.2.4")
08a1b701
DT
4527 (source
4528 (origin
4529 (method url-fetch)
4530 (uri (rubygems-uri "tzinfo" version))
4531 (sha256
4532 (base32
4237af85 4533 "09dpbrih054mn42flbbcdpzk2727mzfvjrgqb12zdafhx7p9rrzp"))))
08a1b701 4534 (build-system ruby-build-system)
740fea08
CB
4535 (arguments
4536 '(#:phases
4537 (modify-phases %standard-phases
4538 (add-after 'unpack 'skip-safe-tests
4539 (lambda _
4540 (substitute* "test/test_utils.rb"
4541 (("def safe_test\\(options = \\{\\}\\)")
4542 "def safe_test(options = {})
4543 skip('The Guix build environment has an unsafe load path')"))
4544 #t)))))
08a1b701
DT
4545 (propagated-inputs
4546 `(("ruby-thread-safe" ,ruby-thread-safe)))
4547 (synopsis "Time zone library for Ruby")
4548 (description "TZInfo is a Ruby library that provides daylight savings
4549aware transformations between times in different time zones.")
2f3800e5 4550 (home-page "https://tzinfo.github.io")
1e12924a
BW
4551 (license license:expat)))
4552
4553(define-public ruby-tzinfo-data
4554 (package
4555 (name "ruby-tzinfo-data")
92513191 4556 (version "1.2017.3")
1e12924a
BW
4557 (source
4558 (origin
bb1e7ed0 4559 (method git-fetch)
1e12924a
BW
4560 ;; Download from GitHub because the rubygems version does not contain
4561 ;; Rakefile or tests.
bb1e7ed0
EF
4562 (uri (git-reference
4563 (url "https://github.com/tzinfo/tzinfo-data")
4564 (commit (string-append "v" version))))
4565 (file-name (git-file-name name version))
1e12924a
BW
4566 (sha256
4567 (base32
bb1e7ed0 4568 "0v3phl5l3jrm6waxcszqmj2dkjhqawxfsxb6mss7vkp1hlckqcdp"))
1e12924a
BW
4569 ;; Remove the known test failure.
4570 ;; https://github.com/tzinfo/tzinfo-data/issues/10
4571 ;; https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1587128
4572 (patches (search-patches
4573 "ruby-tzinfo-data-ignore-broken-test.patch"))))
4574 (build-system ruby-build-system)
4575 (propagated-inputs
4576 `(("ruby-tzinfo" ,ruby-tzinfo)))
4577 (synopsis "Data from the IANA Time Zone database")
4578 (description
4579 "This library provides @code{TZInfo::Data}, which contains data from the
4580IANA Time Zone database packaged as Ruby modules for use with @code{TZInfo}.")
2f3800e5 4581 (home-page "https://tzinfo.github.io")
08a1b701 4582 (license license:expat)))
c99e2247 4583
48e6851f
RW
4584(define-public ruby-rb-inotify
4585 (package
4586 (name "ruby-rb-inotify")
32bbfea8 4587 (version "0.9.10")
48e6851f
RW
4588 (source
4589 (origin
4590 (method url-fetch)
4591 (uri (rubygems-uri "rb-inotify" version))
4592 (sha256
4593 (base32
32bbfea8 4594 "0yfsgw5n7pkpyky6a9wkf1g9jafxb0ja7gz0qw0y14fd2jnzfh71"))))
48e6851f
RW
4595 (build-system ruby-build-system)
4596 (arguments
4597 '(#:tests? #f ; there are no tests
4598 #:phases
4599 (modify-phases %standard-phases
4600 ;; Building the gemspec with rake is not working here since it is
4601 ;; generated with Jeweler. It is also unnecessary because the
4602 ;; existing gemspec does not use any development tools to generate a
4603 ;; list of files.
4604 (replace 'build
4605 (lambda _
9923d5a4 4606 (invoke "gem" "build" "rb-inotify.gemspec"))))))
48e6851f
RW
4607 (propagated-inputs
4608 `(("ruby-ffi" ,ruby-ffi)))
4609 (native-inputs
4610 `(("ruby-yard" ,ruby-yard)))
4611 (synopsis "Ruby wrapper for Linux's inotify")
4612 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
4613kernel subsystem for monitoring changes to files and directories.")
4614 (home-page "https://github.com/nex3/rb-inotify")
4615 (license license:expat)))
4616
a75bdfce
RW
4617(define-public ruby-pry-editline
4618 (package
4619 (name "ruby-pry-editline")
4620 (version "1.1.2")
4621 (source (origin
4622 (method url-fetch)
4623 (uri (rubygems-uri "pry-editline" version))
4624 (sha256
4625 (base32
4626 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
4627 (build-system ruby-build-system)
4628 (arguments `(#:tests? #f)) ; no tests included
4629 (native-inputs
4630 `(("bundler" ,bundler)))
4631 (synopsis "Open the current REPL line in an editor")
4632 (description
4633 "This gem provides a plugin for the Ruby REPL to enable opening the
4634current line in an external editor.")
4635 (home-page "https://github.com/tpope/pry-editline")
4636 (license license:expat)))
4637
d3b20a02
RW
4638(define-public ruby-sdoc
4639 (package
4640 (name "ruby-sdoc")
fdf3a68d 4641 (version "0.4.2")
d3b20a02
RW
4642 (source (origin
4643 (method url-fetch)
4644 (uri (rubygems-uri "sdoc" version))
4645 (sha256
4646 (base32
fdf3a68d 4647 "0qhvy10vnmrqcgh8494m13kd5ag9c3sczzhfasv8j0294ylk679n"))))
d3b20a02
RW
4648 (build-system ruby-build-system)
4649 (arguments
4650 `(#:phases
4651 (modify-phases %standard-phases
fc29d5e6 4652 (add-before 'check 'set-rubylib-and-patch-gemfile
d3b20a02 4653 (lambda _
fdf3a68d 4654 (setenv "RUBYLIB" "lib")
fc29d5e6
BW
4655 (substitute* "sdoc.gemspec"
4656 (("s.add_runtime_dependency.*") "\n")
4657 (("s.add_dependency.*") "\n"))
4658 (substitute* "Gemfile"
4659 (("gem \"rake\".*")
4660 "gem 'rake'\ngem 'rdoc'\ngem 'json'\n"))
d3b20a02
RW
4661 #t)))))
4662 (propagated-inputs
4663 `(("ruby-json" ,ruby-json)))
4664 (native-inputs
4665 `(("bundler" ,bundler)
fdf3a68d
BW
4666 ("ruby-minitest" ,ruby-minitest)
4667 ("ruby-hoe" ,ruby-hoe)))
d3b20a02
RW
4668 (synopsis "Generate searchable RDoc documentation")
4669 (description
4670 "SDoc is an RDoc documentation generator to build searchable HTML
4671documentation for Ruby code.")
7bf837fd 4672 (home-page "https://github.com/voloko/sdoc")
d3b20a02
RW
4673 (license license:expat)))
4674
70b002aa
RW
4675(define-public ruby-tins
4676 (package
4677 (name "ruby-tins")
fbefd6ff 4678 (version "1.15.0")
70b002aa
RW
4679 (source (origin
4680 (method url-fetch)
4681 (uri (rubygems-uri "tins" version))
4682 (sha256
4683 (base32
fbefd6ff 4684 "09whix5a7ics6787zrkwjmp16kqyh6560p9f317syks785805f7s"))))
70b002aa
RW
4685 (build-system ruby-build-system)
4686 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
4687 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
4688 ;; the gemspec.
4689 (arguments
4690 `(#:tests? #f ; there are no tests
4691 #:phases
4692 (modify-phases %standard-phases
4693 (replace 'build
4694 (lambda _
4695 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
4696 ;; causes an error.
4697 (substitute* "tins.gemspec"
4698 (("\"lib/spruz\", ") ""))
9923d5a4 4699 (invoke "gem" "build" "tins.gemspec"))))))
70b002aa
RW
4700 (synopsis "Assorted tools for Ruby")
4701 (description "Tins is a Ruby library providing assorted tools.")
4702 (home-page "https://github.com/flori/tins")
4703 (license license:expat)))
4704
bc8277e4
RW
4705(define-public ruby-gem-hadar
4706 (package
4707 (name "ruby-gem-hadar")
3fd577e3 4708 (version "1.9.1")
bc8277e4
RW
4709 (source (origin
4710 (method url-fetch)
4711 (uri (rubygems-uri "gem_hadar" version))
4712 (sha256
4713 (base32
3fd577e3 4714 "1zxvd9l95rbks7x3cxn396w0sn7nha5542bf97v8akkn4vm7nby9"))))
bc8277e4
RW
4715 (build-system ruby-build-system)
4716 ;; This gem needs itself at development time. We disable rebuilding of the
4717 ;; gemspec to avoid this loop.
4718 (arguments
4719 `(#:tests? #f ; there are no tests
4720 #:phases
4721 (modify-phases %standard-phases
4722 (replace 'build
4723 (lambda _
9923d5a4 4724 (invoke "gem" "build" "gem_hadar.gemspec"))))))
bc8277e4
RW
4725 (propagated-inputs
4726 `(("git" ,git)
4727 ("ruby-tins" ,ruby-tins)
3fd577e3 4728 ("ruby-yard" ,ruby-yard)))
bc8277e4
RW
4729 (synopsis "Library for the development of Ruby gems")
4730 (description
4731 "This library contains some useful functionality to support the
4732development of Ruby gems.")
4733 (home-page "https://github.com/flori/gem_hadar")
4734 (license license:expat)))
4735
d8cafe29
RW
4736(define-public ruby-minitest-tu-shim
4737 (package
4738 (name "ruby-minitest-tu-shim")
4739 (version "1.3.3")
4740 (source (origin
4741 (method url-fetch)
4742 (uri (rubygems-uri "minitest_tu_shim" version))
4743 (sha256
4744 (base32
4745 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
4746 (build-system ruby-build-system)
4747 (arguments
4748 `(#:phases
4749 (modify-phases %standard-phases
4750 (add-after 'unpack 'fix-test-include-path
4751 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 4752 (let* ((minitest (assoc-ref inputs "ruby-minitest-4")))
761e7042
BW
4753 (substitute* "Rakefile"
4754 (("Hoe\\.add_include_dirs .*")
4755 (string-append "Hoe.add_include_dirs \""
3cb3fa67 4756 minitest "/lib/ruby/vendor_ruby"
761e7042
BW
4757 "/gems/minitest-"
4758 ,(package-version ruby-minitest-4)
4759 "/lib" "\""))))
4760 #t))
d8cafe29
RW
4761 (add-before 'check 'fix-test-assumptions
4762 (lambda _
4763 ;; The test output includes the file name, so a couple of tests
4764 ;; fail. Changing the regular expressions slightly fixes this
4765 ;; problem.
4766 (substitute* "test/test_mini_test.rb"
4767 (("output.sub!\\(.*, 'FILE:LINE'\\)")
4768 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
4769 (("gsub\\(/.*, 'FILE:LINE'\\)")
4770 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
4771 #t)))))
4772 (propagated-inputs
4773 `(("ruby-minitest-4" ,ruby-minitest-4)))
4774 (native-inputs
4775 `(("ruby-hoe" ,ruby-hoe)))
4776 (synopsis "Adapter library between minitest and test/unit")
4777 (description
4778 "This library bridges the gap between the small and fast minitest and
4779Ruby's large and slower test/unit.")
4780 (home-page "https://rubygems.org/gems/minitest_tu_shim")
4781 (license license:expat)))
4782
fd83a212
RW
4783(define-public ruby-term-ansicolor
4784 (package
4785 (name "ruby-term-ansicolor")
f3a6311a 4786 (version "1.6.0")
fd83a212
RW
4787 (source (origin
4788 (method url-fetch)
4789 (uri (rubygems-uri "term-ansicolor" version))
4790 (sha256
4791 (base32
f3a6311a 4792 "1b1wq9ljh7v3qyxkk8vik2fqx2qzwh5lval5f92llmldkw7r7k7b"))))
fd83a212
RW
4793 (build-system ruby-build-system)
4794 ;; Rebuilding the gemspec seems to require git, even though this is not a
4795 ;; git repository, so we just build the gem from the existing gemspec.
4796 (arguments
4797 `(#:phases
4798 (modify-phases %standard-phases
39ecb977
CB
4799 (add-after 'unpack 'fix-test
4800 (lambda -
4801 (substitute* "tests/hsl_triple_test.rb"
4802 (("0\\\\\\.0%")
4803 "0\\.?0?%"))))
fd83a212
RW
4804 (replace 'build
4805 (lambda _
9923d5a4 4806 (invoke "gem" "build" "term-ansicolor.gemspec"))))))
fd83a212
RW
4807 (propagated-inputs
4808 `(("ruby-tins" ,ruby-tins)))
4809 (native-inputs
4810 `(("ruby-gem-hadar" ,ruby-gem-hadar)
4811 ("ruby-minitest-tu-shim" ,ruby-minitest-tu-shim)))
4812 (synopsis "Ruby library to control the attributes of terminal output")
4813 (description
4814 "This Ruby library uses ANSI escape sequences to control the attributes
4815of terminal output.")
2f3800e5 4816 (home-page "https://flori.github.io/term-ansicolor/")
fd83a212
RW
4817 ;; There is no mention of the "or later" clause.
4818 (license license:gpl2)))
4819
a714c30f
CB
4820(define-public ruby-terraform
4821 (package
4822 (name "ruby-terraform")
4823 (version "0.22.0")
4824 (source
4825 (origin
4826 (method url-fetch)
4827 (uri (rubygems-uri "ruby-terraform" version))
4828 (sha256
4829 (base32
4830 "13zjkp71cd19j2ds2h9rqwcfr1zdg5nsh63p89l6qcsc9z39z324"))))
4831 (build-system ruby-build-system)
4832 (arguments
4833 '(#:tests? #f)) ; No included tests
4834 (propagated-inputs
4835 `(("ruby-lino" ,ruby-lino)))
4836 (synopsis "Ruby wrapper around the Terraform command line interface")
4837 (description
4838 "This package provides a Ruby wrapper around the Terraform command line
4839interface so that Terraform can be more easily invoked from Ruby code.")
4840 (home-page "https://github.com/infrablocks/ruby_terraform")
4841 (license license:expat)))
4842
6e376ca4
RW
4843(define-public ruby-pstree
4844 (package
4845 (name "ruby-pstree")
4846 (version "0.1.0")
4847 (source (origin
4848 (method url-fetch)
4849 (uri (rubygems-uri "pstree" version))
4850 (sha256
4851 (base32
4852 "1mig1sv5qx1cdyhjaipy8jlh9j8pnja04vprrzihyfr54x0215p1"))))
4853 (build-system ruby-build-system)
4854 (native-inputs
4855 `(("ruby-gem-hadar" ,ruby-gem-hadar)
4856 ("bundler" ,bundler)))
4857 (synopsis "Create a process tree data structure")
4858 (description
4859 "This library uses the output of the @code{ps} command to create a
4860process tree data structure for the current host.")
2f3800e5 4861 (home-page "https://github.com/flori/pstree")
6e376ca4
RW
4862 ;; There is no mention of the "or later" clause.
4863 (license license:gpl2)))
4864
53239b5f
RW
4865(define-public ruby-utils
4866 (package
4867 (name "ruby-utils")
cd698b6e 4868 (version "0.9.0")
53239b5f
RW
4869 (source (origin
4870 (method url-fetch)
4871 (uri (rubygems-uri "utils" version))
4872 (sha256
4873 (base32
cd698b6e 4874 "196zhgcygrnx09bb9mh22qas03rl9avzx8qs0wnxznpin4pffwcl"))))
53239b5f
RW
4875 (build-system ruby-build-system)
4876 (propagated-inputs
4877 `(("ruby-tins" ,ruby-tins)
4878 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
4879 ("ruby-pstree" ,ruby-pstree)
4880 ("ruby-pry-editline" ,ruby-pry-editline)))
4881 (native-inputs
4882 `(("ruby-gem-hadar" ,ruby-gem-hadar)
4883 ("bundler" ,bundler)))
4884 (synopsis "Command line tools for working with Ruby")
4885 (description
4886 "This package provides assorted command line tools that may be useful
4887when working with Ruby code.")
4888 (home-page "https://github.com/flori/utils")
4889 ;; There is no mention of the "or later" clause.
4890 (license license:gpl2)))
4891
433f10b5
CB
4892(define-public ruby-jaro-winkler
4893 (package
4894 (name "ruby-jaro-winkler")
37b23e44 4895 (version "1.5.4")
433f10b5
CB
4896 (source
4897 (origin
4898 (method url-fetch)
4899 (uri (rubygems-uri "jaro_winkler" version))
4900 (sha256
37b23e44 4901 (base32 "1y8l6k34svmdyqxya3iahpwbpvmn3fswhwsvrz0nk1wyb8yfihsh"))))
433f10b5
CB
4902 (build-system ruby-build-system)
4903 (arguments
37b23e44 4904 '(#:tests? #f)) ; no included tests
433f10b5
CB
4905 (synopsis "Ruby implementation of Jaro-Winkler distance algorithm")
4906 (description
4907 "@code{jaro_winkler} is an implementation of Jaro-Winkler distance
4908algorithm. It is written as a C extension and will fallback to a pure Ruby
4909implementation on platforms where this is unsupported.")
4910 (home-page "https://github.com/tonytonyjan/jaro_winkler")
4911 (license license:expat)))
4912
c99e2247
DT
4913(define-public ruby-json
4914 (package
4915 (name "ruby-json")
a281acce 4916 (version "2.1.0")
c99e2247
DT
4917 (source
4918 (origin
4919 (method url-fetch)
4920 (uri (rubygems-uri "json" version))
4921 (sha256
4922 (base32
a281acce 4923 "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp"))))
c99e2247
DT
4924 (build-system ruby-build-system)
4925 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
4926 (synopsis "JSON library for Ruby")
4927 (description "This Ruby library provides a JSON implementation written as
4928a native C extension.")
4929 (home-page "http://json-jruby.rubyforge.org/")
4930 (license (list license:ruby license:gpl2)))) ; GPL2 only
5ff89a1b 4931
763624f5
RW
4932(define-public ruby-json-pure
4933 (package
4934 (name "ruby-json-pure")
1c65d99f 4935 (version "2.2.0")
763624f5
RW
4936 (source (origin
4937 (method url-fetch)
4938 (uri (rubygems-uri "json_pure" version))
4939 (sha256
4940 (base32
1c65d99f 4941 "0m0j1mfwv0mvw72kzqisb26xjl236ivqypw1741dkis7s63b8439"))))
763624f5
RW
4942 (build-system ruby-build-system)
4943 (arguments
ac01cb07 4944 `(#:phases
763624f5 4945 (modify-phases %standard-phases
ac01cb07 4946 (add-after 'unpack 'fix-rakefile
763624f5 4947 (lambda _
ac01cb07
BW
4948 (substitute* "Rakefile"
4949 ;; Since this is not a git repository, do not call 'git'.
4950 (("`git ls-files`") "`find . -type f |sort`")
4951 ;; Loosen dependency constraint.
4952 (("'test-unit', '~> 2.0'") "'test-unit', '>= 2.0'"))
4953 #t))
4954 (add-after 'replace-git-ls-files 'regenerate-gemspec
4955 (lambda _
4956 ;; Regenerate gemspec so loosened dependency constraints are
4957 ;; propagated.
17cfb7ae
CB
4958 (invoke "rake" "gemspec")))
4959 (add-after 'regenerate-gemspec 'fix-json-java.gemspec
4960 (lambda _
4961 ;; This gemspec doesn't look to be generated by the above
4962 ;; command, so patch it separately.
4963 (substitute* "json-java.gemspec"
4964 (("%q<test-unit>\\.freeze, \\[\"~> 2\\.0\"\\]")
4965 "%q<test-unit>.freeze, [\">= 2.0\"]"))
4966 #t)))))
763624f5 4967 (native-inputs
ac01cb07 4968 `(("bundler" ,bundler)
0c9f73cd
TGR
4969 ("ragel" ,ragel)
4970 ("ruby-simplecov" ,ruby-simplecov)
4971 ("ruby-test-unit" ,ruby-test-unit)))
763624f5
RW
4972 (synopsis "JSON implementation in pure Ruby")
4973 (description
4974 "This package provides a JSON implementation written in pure Ruby.")
1c65d99f 4975 (home-page "https://flori.github.com/json/")
763624f5
RW
4976 (license license:ruby)))
4977
2a8581ac
CB
4978(define-public ruby-jwt
4979 (package
4980 (name "ruby-jwt")
4981 (version "2.1.0")
4982 (source
4983 (origin
4984 (method url-fetch)
4985 (uri (rubygems-uri "jwt" version))
4986 (sha256
4987 (base32
4988 "1w0kaqrbl71cq9sbnixc20x5lqah3hs2i93xmhlfdg2y3by7yzky"))))
4989 (build-system ruby-build-system)
4990 (arguments
4991 '(#:test-target "test"
4992 #:phases
4993 (modify-phases %standard-phases
4994 (add-after 'unpack 'remove-unnecessary-dependencies
4995 (lambda _
4996 (substitute* "spec/spec_helper.rb"
4997 (("require 'simplecov.*") "\n")
4998 ;; Use [].each to disable running the SimpleCov configuration
4999 ;; block
5000 (("SimpleCov\\.configure") "[].each")
5001 (("require 'codeclimate-test-reporter'") "")
5002 (("require 'codacy-coverage'") "")
5003 (("Codacy::Reporter\\.start") ""))
5004 #t)))))
5005 (native-inputs
5006 `(("bundler" ,bundler)
5007 ("ruby-rspec" ,ruby-rspec)
5008 ("ruby-rbnacl" ,ruby-rbnacl)))
5009 (synopsis "Ruby implementation of the JSON Web Token standard")
5010 (description
5011 "This package provides a pure Ruby implementation of the RFC 7519 OAuth
5012@acronym{JWT, JSON Web Token} standard.")
5013 (home-page "https://github.com/jwt/ruby-jwt")
5014 (license license:expat)))
5015
16b324cd
RW
5016;; Even though this package only provides bindings for a Mac OSX API it is
5017;; required by "ruby-listen" at runtime.
5018(define-public ruby-rb-fsevent
5019 (package
5020 (name "ruby-rb-fsevent")
b0ef15ed 5021 (version "0.10.3")
16b324cd
RW
5022 (source (origin
5023 (method url-fetch)
5024 (uri (rubygems-uri "rb-fsevent" version))
5025 (sha256
5026 (base32
b0ef15ed 5027 "1lm1k7wpz69jx7jrc92w3ggczkjyjbfziq5mg62vjnxmzs383xx8"))))
16b324cd
RW
5028 (build-system ruby-build-system)
5029 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
5030 ;; "listen", which needs "rb-fsevent" at runtime.
5031 (arguments `(#:tests? #f))
5032 (synopsis "FSEvents API with signals catching")
5033 (description
5034 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
5035 (home-page "https://rubygems.org/gems/rb-fsevent")
5036 (license license:expat)))
5037
b86be2ad
RW
5038(define-public ruby-listen
5039 (package
5040 (name "ruby-listen")
12341d34 5041 (version "3.2.0")
b86be2ad
RW
5042 (source
5043 (origin
35602819
CB
5044 ;; The gem does not include a Rakefile, so fetch from the Git
5045 ;; repository.
5046 (method git-fetch)
5047 (uri (git-reference
5048 (url "https://github.com/guard/listen.git")
5049 (commit (string-append "v" version))))
5050 (file-name (git-file-name name version))
b86be2ad
RW
5051 (sha256
5052 (base32
12341d34 5053 "1hkp1g6hk5clsmbd001gkc12ma6s459x820piajyasv61m87if24"))))
b86be2ad 5054 (build-system ruby-build-system)
35602819
CB
5055 (arguments
5056 `(#:test-target "spec"
5057 #:phases
5058 (modify-phases %standard-phases
5059 (add-after 'unpack 'fix-files-in-gemspec
5060 (lambda _
5061 (substitute* "listen.gemspec"
5062 (("`git ls-files -z`") "`find . -type f -printf '%P\\\\0' |sort -z`"))
5063 #t))
5064 (add-before 'check 'remove-unnecessary-dependencies'
5065 (lambda _
5066 (substitute* "Rakefile"
5067 ;; Rubocop is for code linting, and is unnecessary for running
5068 ;; the tests.
5069 ((".*rubocop.*") ""))
5070 #t)))))
5071 (native-inputs
5072 `(("bundler" ,bundler)
5073 ("ruby-rspec" ,ruby-rspec)))
5074 (inputs
5075 `(;; ruby-thor is used for the command line interface, and is referenced
5076 ;; in the wrapper, and therefore just needs to be an input.
5077 ("ruby-thor" ,ruby-thor)))
b86be2ad 5078 (propagated-inputs
35602819
CB
5079 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
5080 ("ruby-rb-inotify" ,ruby-rb-inotify)
5081 ("ruby-dep" ,ruby-dep)))
b86be2ad
RW
5082 (synopsis "Listen to file modifications")
5083 (description "The Listen gem listens to file modifications and notifies
5084you about the changes.")
5085 (home-page "https://github.com/guard/listen")
5086 (license license:expat)))
5087
8d3c5ff6
CB
5088(define-public ruby-loofah
5089 (package
5090 (name "ruby-loofah")
5091 (version "2.2.3")
5092 (source
5093 (origin
5094 (method url-fetch)
5095 (uri (rubygems-uri "loofah" version))
5096 (sha256
5097 (base32
5098 "1ccsid33xjajd0im2xv941aywi58z7ihwkvaf1w2bv89vn5bhsjg"))))
5099 (build-system ruby-build-system)
5100 (arguments
5101 '(#:phases
5102 (modify-phases %standard-phases
5103 (add-after 'unpack 'remove-unnecessary-dependencies
5104 (lambda _
5105 ;; concourse is a development tool which is unused, so remove it
5106 ;; so it's not required.
5107 (substitute* "Gemfile"
5108 ((".*\"concourse\".*") "\n"))
5109 (substitute* "Rakefile"
5110 (("require 'concourse'") "")
5111 (("Concourse\\.new.*") "\n"))
5112 #t)))))
5113 (native-inputs
5114 `(("ruby-hoe" ,ruby-hoe)
5115 ("ruby-rr" ,ruby-rr)))
5116 (propagated-inputs
5117 `(("ruby-nokogiri" ,ruby-nokogiri)
5118 ("ruby-crass" ,ruby-crass)))
5119 (synopsis "Ruby library for manipulating and transforming HTML/XML")
5120 (description
5121 "Loofah is a general library for manipulating and transforming HTML/XML
5122documents and fragments. It's built on top of Nokogiri and libxml2.")
5123 (home-page "https://github.com/flavorjones/loofah")
5124 (license license:expat)))
5125
5ff89a1b
DT
5126(define-public ruby-activesupport
5127 (package
5128 (name "ruby-activesupport")
bcf1fe5b 5129 (version "5.2.2.1")
5ff89a1b
DT
5130 (source
5131 (origin
5132 (method url-fetch)
5133 (uri (rubygems-uri "activesupport" version))
5134 (sha256
5135 (base32
bcf1fe5b 5136 "161bp4p01v1a1lvszrhd1a02zf9x1p1l1yhw79a3rix1kvzkkdqb"))))
5ff89a1b
DT
5137 (build-system ruby-build-system)
5138 (arguments
2af45e50
BW
5139 `(#:phases
5140 (modify-phases %standard-phases
5141 (replace 'check
5142 (lambda _
9923d5a4
TGR
5143 ;; There are no tests, instead attempt to load the library.
5144 (invoke "ruby" "-Ilib" "-r" "active_support"))))))
5ff89a1b 5145 (propagated-inputs
2af45e50
BW
5146 `(("ruby-concurrent" ,ruby-concurrent)
5147 ("ruby-i18n" ,ruby-i18n)
5ff89a1b 5148 ("ruby-minitest" ,ruby-minitest)
606ee9a1
BW
5149 ("ruby-tzinfo" ,ruby-tzinfo)
5150 ("ruby-tzinfo-data" ,ruby-tzinfo-data)))
5ff89a1b
DT
5151 (synopsis "Ruby on Rails utility library")
5152 (description "ActiveSupport is a toolkit of support libraries and Ruby
5153core extensions extracted from the Rails framework. It includes support for
5154multibyte strings, internationalization, time zones, and testing.")
5155 (home-page "http://www.rubyonrails.org")
5156 (license license:expat)))
f847ad7b 5157
3996f0aa
RW
5158(define-public ruby-crass
5159 (package
5160 (name "ruby-crass")
a0e0f9d7 5161 (version "1.0.4")
3996f0aa
RW
5162 (source (origin
5163 (method url-fetch)
5164 (uri (rubygems-uri "crass" version))
5165 (sha256
5166 (base32
a0e0f9d7 5167 "0bpxzy6gjw9ggjynlxschbfsgmx8lv3zw1azkjvnb8b9i895dqfi"))))
3996f0aa
RW
5168 (build-system ruby-build-system)
5169 (native-inputs
5170 `(("bundler" ,bundler)
5171 ("ruby-minitest" ,ruby-minitest)))
5172 (synopsis "Pure Ruby CSS parser")
5173 (description
5174 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
5175 (home-page "https://github.com/rgrove/crass/")
5176 (license license:expat)))
5177
c2c4e5b2 5178(define-public ruby-nokogumbo
f1ae7c62
BW
5179 (let ((commit "fb51ff299a1c34346837580b6d1d9a60fadf5dbd"))
5180 (package
5181 (name "ruby-nokogumbo")
5182 (version (string-append "1.4.7-1." (string-take commit 8)))
5183 (source (origin
5184 ;; We use the git reference, because there's no Rakefile in the
5185 ;; published gem and the tarball on Github is outdated.
5186 (method git-fetch)
5187 (uri (git-reference
5188 (url "https://github.com/rubys/nokogumbo.git")
5189 (commit "d56f954d20a")))
5190 (file-name (string-append name "-" version "-checkout"))
5191 (sha256
5192 (base32
5193 "0bnppjy96xiadrsrc9dp8y6wvdwnkfa930n7acrp0mqm4qywl2wl"))))
5194 (build-system ruby-build-system)
5195 (arguments
5196 `(#:modules ((guix build ruby-build-system)
5197 (guix build utils)
5198 (ice-9 rdelim))
5199 #:phases
5200 (modify-phases %standard-phases
5c31e981 5201 (add-after 'unpack 'build-gemspec
f1ae7c62
BW
5202 (lambda _
5203 (substitute* "Rakefile"
5204 ;; Build Makefile even without a copy of gumbo-parser sources
5205 (("'gumbo-parser/src',") "")
5206 ;; We don't bundle gumbo-parser sources
5207 (("'gumbo-parser/src/\\*',") "")
5208 (("'gumbo-parser/visualc/include/\\*',") "")
5209 ;; The definition of SOURCES will be cut in gemspec, and
5210 ;; "FileList" will be undefined.
5211 (("SOURCES \\+ FileList\\[")
5212 "['ext/nokogumboc/extconf.rb', 'ext/nokogumboc/nokogumbo.c', "))
5213
5214 ;; Copy the Rakefile and cut out the gemspec.
5215 (copy-file "Rakefile" ".gemspec")
5216 (with-atomic-file-replacement ".gemspec"
5217 (lambda (in out)
5218 (let loop ((line (read-line in 'concat))
5219 (skipping? #t))
5220 (if (eof-object? line)
5221 #t
5222 (let ((skip-next? (if skipping?
5223 (not (string-prefix? "SPEC =" line))
5224 (string-prefix? "end" line))))
5225 (when (or (not skipping?)
5226 (and skipping? (not skip-next?)))
5227 (format #t "~a" line)
5228 (display line out))
5229 (loop (read-line in 'concat) skip-next?))))))
5230 #t)))))
5231 (inputs
5232 `(("gumbo-parser" ,gumbo-parser)))
5233 (propagated-inputs
5234 `(("ruby-nokogiri" ,ruby-nokogiri)))
5235 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
5236 (description
5237 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
c2c4e5b2 5238access the result as a Nokogiri parsed document.")
f1ae7c62
BW
5239 (home-page "https://github.com/rubys/nokogumbo/")
5240 (license license:asl2.0))))
c2c4e5b2 5241
d56ff88b
RW
5242(define-public ruby-sanitize
5243 (package
5244 (name "ruby-sanitize")
f812145e 5245 (version "4.6.3")
d56ff88b
RW
5246 (source (origin
5247 (method url-fetch)
5248 ;; The gem does not include the Rakefile, so we download the
5249 ;; release tarball from Github.
5250 (uri (string-append "https://github.com/rgrove/"
5251 "sanitize/archive/v" version ".tar.gz"))
5252 (file-name (string-append name "-" version ".tar.gz"))
5253 (sha256
5254 (base32
f812145e 5255 "1fmqppwif3cm8h79006jfzkdnlxxzlry9kzk03psk0d5xpg55ycc"))))
d56ff88b
RW
5256 (build-system ruby-build-system)
5257 (propagated-inputs
5258 `(("ruby-crass" ,ruby-crass)
5259 ("ruby-nokogiri" ,ruby-nokogiri)
5260 ("ruby-nokogumbo" ,ruby-nokogumbo)))
5261 (native-inputs
5262 `(("bundler" ,bundler)
5263 ("ruby-minitest" ,ruby-minitest)
5264 ("ruby-redcarpet" ,ruby-redcarpet)
5265 ("ruby-yard" ,ruby-yard)))
5266 (synopsis "Whitelist-based HTML and CSS sanitizer")
5267 (description
5268 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
5269acceptable elements, attributes, and CSS properties, Sanitize will remove all
5270unacceptable HTML and/or CSS from a string.")
5271 (home-page "https://github.com/rgrove/sanitize/")
5272 (license license:expat)))
5273
ed4b6b18
BW
5274(define-public ruby-oj
5275 (package
5276 (name "ruby-oj")
93dfdec5 5277 (version "3.10.1")
ed4b6b18
BW
5278 (source
5279 (origin
b09ef660 5280 (method git-fetch)
ed4b6b18
BW
5281 ;; Version on rubygems.org does not contain Rakefile, so download from
5282 ;; GitHub instead.
b09ef660
EF
5283 (uri (git-reference
5284 (url "https://github.com/ohler55/oj")
5285 (commit (string-append "v" version))))
5286 (file-name (git-file-name name version))
ed4b6b18
BW
5287 (sha256
5288 (base32
93dfdec5 5289 "0i5xjx4sh816zx2c1a4d1q67k7vllg5jnnc4jy6zhbmwi1dvp5vw"))))
ed4b6b18
BW
5290 (build-system ruby-build-system)
5291 (arguments
5292 '(#:test-target "test_all"
5293 #:phases
5294 (modify-phases %standard-phases
5295 (add-before 'check 'disable-bundler
5296 (lambda _
5297 (substitute* "Rakefile"
5298 (("Bundler\\.with_clean_env") "1.times")
5299 (("bundle exec ") "")))))))
5300 (native-inputs
5301 `(("bundler" ,bundler)
5302 ("ruby-rspec" ,ruby-rspec)
5303 ("ruby-rake-compiler" ,ruby-rake-compiler)))
5304 (synopsis "JSON parser for Ruby optimized for speed")
5305 (description
5306 "Oj is a JSON parser and generator for Ruby, where the encoding and
5307decoding of JSON is implemented as a C extension to Ruby.")
b09ef660 5308 (home-page "http://www.ohler.com/oj/")
ed4b6b18
BW
5309 (license (list license:expat ; Ruby code
5310 license:bsd-3)))) ; extension code
5311
f847ad7b
DT
5312(define-public ruby-ox
5313 (package
5314 (name "ruby-ox")
263c0dbf 5315 (version "2.6.0")
f847ad7b
DT
5316 (source
5317 (origin
5318 (method url-fetch)
5319 (uri (rubygems-uri "ox" version))
5320 (sha256
5321 (base32
263c0dbf 5322 "0fmk62b1h2i79dfzjj8wmf8qid1rv5nhwfc17l489ywnga91xl83"))))
f847ad7b
DT
5323 (build-system ruby-build-system)
5324 (arguments
5325 '(#:tests? #f)) ; no tests
5326 (synopsis "Optimized XML library for Ruby")
5327 (description
5328 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
5329written as a native C extension. It was designed to be an alternative to
5330Nokogiri and other Ruby XML parsers for generic XML parsing and as an
5331alternative to Marshal for Object serialization. ")
5332 (home-page "http://www.ohler.com/ox")
5333 (license license:expat)))
4a9e0585 5334
0c4e7625
RW
5335(define-public ruby-redcloth
5336 (package
5337 (name "ruby-redcloth")
2a91494e 5338 (version "4.3.2")
0c4e7625
RW
5339 (source (origin
5340 (method url-fetch)
5341 (uri (rubygems-uri "RedCloth" version))
5342 (sha256
5343 (base32
2a91494e 5344 "0m9dv7ya9q93r8x1pg2gi15rxlbck8m178j1fz7r5v6wr1avrrqy"))))
0c4e7625
RW
5345 (build-system ruby-build-system)
5346 (arguments
5347 `(#:tests? #f ; no tests
5348 #:phases
5349 (modify-phases %standard-phases
5350 ;; Redcloth has complicated rake tasks to build various versions for
5351 ;; multiple targets using RVM. We don't want this so we just use the
5352 ;; existing gemspec.
5353 (replace 'build
5354 (lambda _
9923d5a4 5355 (invoke "gem" "build" "redcloth.gemspec"))))))
0c4e7625
RW
5356 (native-inputs
5357 `(("bundler" ,bundler)
5358 ("ruby-diff-lcs" ,ruby-diff-lcs)
5359 ("ruby-rspec-2" ,ruby-rspec-2)))
5360 (synopsis "Textile markup language parser for Ruby")
5361 (description
5362 "RedCloth is a Ruby parser for the Textile markup language.")
5363 (home-page "http://redcloth.org")
5364 (license license:expat)))
5365
4a9e0585
DT
5366(define-public ruby-pg
5367 (package
5368 (name "ruby-pg")
ffc4869e 5369 (version "1.1.4")
4a9e0585
DT
5370 (source
5371 (origin
5372 (method url-fetch)
5373 (uri (rubygems-uri "pg" version))
5374 (sha256
5375 (base32
ffc4869e 5376 "0fmnyxcyrvgdbgq7m09whgn9i8rwfybk0w8aii1nc4g5kqw0k2jy"))))
4a9e0585
DT
5377 (build-system ruby-build-system)
5378 (arguments
5379 '(#:test-target "spec"))
5380 (native-inputs
5381 `(("ruby-rake-compiler" ,ruby-rake-compiler)
5382 ("ruby-hoe" ,ruby-hoe)
5383 ("ruby-rspec" ,ruby-rspec)))
5384 (inputs
ffc4869e 5385 `(("postgresql" ,postgresql)))
4a9e0585
DT
5386 (synopsis "Ruby interface to PostgreSQL")
5387 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
4db80f8b 5388with PostgreSQL 9.0 and later.")
4a9e0585
DT
5389 (home-page "https://bitbucket.org/ged/ruby-pg")
5390 (license license:ruby)))
468e5657
DT
5391
5392(define-public ruby-byebug
5393 (package
5394 (name "ruby-byebug")
d5489a61 5395 (version "9.0.6")
468e5657
DT
5396 (source
5397 (origin
5398 (method url-fetch)
5399 (uri (rubygems-uri "byebug" version))
5400 (sha256
5401 (base32
d5489a61 5402 "1kbfcn65rgdhi72n8x9l393b89rvi5z542459k7d1ggchpb0idb0"))))
468e5657
DT
5403 (build-system ruby-build-system)
5404 (arguments
5405 '(#:tests? #f)) ; no tests
5406 (synopsis "Debugger for Ruby 2")
5407 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
5408TracePoint C API for execution control and the Debug Inspector C API for call
5409stack navigation. The core component provides support that front-ends can
5410build on. It provides breakpoint handling and bindings for stack frames among
5411other things and it comes with a command line interface.")
7bf837fd 5412 (home-page "https://github.com/deivid-rodriguez/byebug")
468e5657 5413 (license license:bsd-2)))
64b6ccc3 5414
5799bc2b
RW
5415(define-public ruby-netrc
5416 (package
5417 (name "ruby-netrc")
5418 (version "0.11.0")
5419 (source (origin
5420 (method url-fetch)
5421 (uri (rubygems-uri "netrc" version))
5422 (sha256
5423 (base32
5424 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
5425 (build-system ruby-build-system)
5426 (arguments
5427 `(#:phases
5428 (modify-phases %standard-phases
5429 (replace 'check
5430 ;; There is no Rakefile and minitest can only run one file at once,
5431 ;; so we have to iterate over all test files.
5432 (lambda _
9923d5a4
TGR
5433 (map (lambda (file)
5434 (invoke "ruby" "-Itest" file))
5435 (find-files "./test" "test_.*\\.rb")))))))
5799bc2b
RW
5436 (native-inputs
5437 `(("ruby-minitest" ,ruby-minitest)))
5438 (synopsis "Library to read and update netrc files")
5439 (description
5440 "This library can read and update netrc files, preserving formatting
5441including comments and whitespace.")
5442 (home-page "https://github.com/geemus/netrc")
5443 (license license:expat)))
5444
3a6989ce
RW
5445(define-public ruby-unf-ext
5446 (package
5447 (name "ruby-unf-ext")
14db8f19 5448 (version "0.0.7.6")
3a6989ce
RW
5449 (source (origin
5450 (method url-fetch)
5451 (uri (rubygems-uri "unf_ext" version))
5452 (sha256
5453 (base32
14db8f19 5454 "1ll6w64ibh81qwvjx19h8nj7mngxgffg7aigjx11klvf5k2g4nxf"))))
3a6989ce 5455 (build-system ruby-build-system)
b809cc9a
RW
5456 (arguments
5457 `(#:phases
5458 (modify-phases %standard-phases
5459 (add-after 'build 'build-ext
14db8f19
MB
5460 (lambda _ (invoke "rake" "compile:unf_ext")))
5461 (add-before 'check 'lose-rake-compiler-dock-dependency
5462 (lambda _
5463 ;; rake-compiler-dock is listed in the gemspec, but only
5464 ;; required when cross-compiling.
5465 (substitute* "unf_ext.gemspec"
5466 ((".*rake-compiler-dock.*") ""))
5467 #t)))))
3a6989ce
RW
5468 (native-inputs
5469 `(("bundler" ,bundler)
5470 ("ruby-rake-compiler" ,ruby-rake-compiler)
5471 ("ruby-test-unit" ,ruby-test-unit)))
5472 (synopsis "Unicode normalization form support library")
5473 (description
5474 "This package provides unicode normalization form support for Ruby.")
5475 (home-page "https://github.com/knu/ruby-unf_ext")
5476 (license license:expat)))
5477
2632a067 5478(define-public ruby-tdiff
5071f17b
BW
5479 ;; Use a newer than released snapshot so that rspec-2 is not required.
5480 (let ((commit "b662a6048f08abc45c1a834e5f34dd1c662935e2"))
5481 (package
5482 (name "ruby-tdiff")
5483 (version (string-append "0.3.3-1." (string-take commit 8)))
5484 (source (origin
5485 (method git-fetch)
5486 (uri (git-reference
5487 (url "https://github.com/postmodern/tdiff.git")
5488 (commit commit)))
5489 (file-name (string-append name "-" version "-checkout"))
5490 (sha256
5491 (base32
5492 "0n3gq8rx49f7ln6zqlshqfg2mgqyy30rsdjlnki5mv307ykc7ad4"))))
5493 (build-system ruby-build-system)
5494 (native-inputs
5495 `(("ruby-rspec" ,ruby-rspec)
5496 ("ruby-yard" ,ruby-yard)
5497 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
5498 (synopsis "Calculate the differences between two tree-like structures")
5499 (description
5500 "This library provides functions to calculate the differences between two
2632a067 5501tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
5071f17b
BW
5502 (home-page "https://github.com/postmodern/tdiff")
5503 (license license:expat))))
2632a067 5504
f60f5002 5505(define-public ruby-nokogiri-diff
5b0c223a
BW
5506 ;; Use a newer than released snapshot so that rspec-2 is not required.
5507 (let ((commit "a38491e4d8709b7406f2cae11a50226d927d06f5"))
5508 (package
5509 (name "ruby-nokogiri-diff")
5510 (version (string-append "0.2.0-1." (string-take commit 8)))
5511 (source (origin
5512 (method git-fetch)
5513 (uri (git-reference
5514 (url "https://github.com/postmodern/nokogiri-diff.git")
5515 (commit commit)))
5516 (file-name (string-append name "-" version "-checkout"))
5517 (sha256
5518 (base32
5519 "1ah2sfjh9n1p0ln2wkqzfl448ml7j4zfy6dhp1qgzq2m41php6rf"))))
5520 (build-system ruby-build-system)
5521 (propagated-inputs
5522 `(("ruby-tdiff" ,ruby-tdiff)
5523 ("ruby-nokogiri" ,ruby-nokogiri)))
5524 (native-inputs
5525 `(("ruby-rspec" ,ruby-rspec)
5526 ("ruby-yard" ,ruby-yard)
5527 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
5528 (synopsis "Calculate the differences between two XML/HTML documents")
5529 (description
5530 "@code{Nokogiri::Diff} adds the ability to calculate the
f60f5002 5531differences (added or removed nodes) between two XML/HTML documents.")
5b0c223a
BW
5532 (home-page "https://github.com/postmodern/nokogiri-diff")
5533 (license license:expat))))
f60f5002 5534
6dc21310
CB
5535(define-public ruby-racc
5536 (package
5537 (name "ruby-racc")
5538 (version "1.4.14")
5539 (source
5540 (origin
5541 (method url-fetch)
5542 (uri (rubygems-uri "racc" version))
5543 (sha256
5544 (base32
5545 "00yhs2ag7yy5v83mqvkbnhk9bvsh6mx3808k53n61ddzx446v1zl"))))
5546 (build-system ruby-build-system)
5547 (native-inputs
5548 `(("ruby-hoe" ,ruby-hoe)
5549 ("ruby-rake-compiler" ,ruby-rake-compiler)))
5550 (synopsis "LALR(1) parser generator for Ruby")
5551 (description
5552 "Racc is a LALR(1) parser generator. It is written in Ruby itself, and
5553generates Ruby program.")
5554 (home-page "http://i.loveruby.net/en/projects/racc/")
5555 (license (list
5556 ;; Generally licensed under the LGPL2.1, and some files also
5557 ;; available under the same license as Ruby.
5558 license:lgpl2.1
5559 license:ruby))))
5560
64b6ccc3
DT
5561(define-public ruby-rack
5562 (package
5563 (name "ruby-rack")
288d2480 5564 (version "2.0.6")
64b6ccc3
DT
5565 (source
5566 (origin
83870c32 5567 (method git-fetch)
1db791d5 5568 ;; Download from GitHub so that the patch can be applied.
83870c32
EF
5569 (uri (git-reference
5570 (url "https://github.com/rack/rack")
5571 (commit version)))
5572 (file-name (git-file-name name version))
64b6ccc3
DT
5573 (sha256
5574 (base32
83870c32 5575 "1n7z4g1x6yxip096cdc04wq7yk7ywpinq28g2xjb46r4nlv5h0j6"))
1db791d5
BW
5576 ;; Ignore test which fails inside the build environment but works
5577 ;; outside.
5578 (patches (search-patches "ruby-rack-ignore-failing-test.patch"))))
64b6ccc3
DT
5579 (build-system ruby-build-system)
5580 (arguments
5581 '(#:phases
5582 (modify-phases %standard-phases
5583 (add-before 'check 'fix-tests
5584 (lambda _
5585 ;; A few of the tests use the length of a file on disk for
5586 ;; Content-Length and Content-Range headers. However, this file
5587 ;; has a shebang in it which an earlier phase patches, growing
5588 ;; the file size from 193 to 239 bytes when the store prefix is
5589 ;; "/gnu/store".
5590 (let ((size-diff (- (string-length (which "ruby"))
5591 (string-length "/usr/bin/env ruby"))))
5592 (substitute* '("test/spec_file.rb")
5593 (("193")
5594 (number->string (+ 193 size-diff)))
5595 (("bytes(.)22-33" all delimiter)
5596 (string-append "bytes"
5597 delimiter
5598 (number->string (+ 22 size-diff))
5599 "-"
5600 (number->string (+ 33 size-diff))))))
83870c32
EF
5601 #t))
5602 (add-before 'reset-gzip-timestamps 'make-files-writable
5603 (lambda* (#:key outputs #:allow-other-keys)
5604 ;; Make sure .gz files are writable so that the
5605 ;; 'reset-gzip-timestamps' phase can do its work.
5606 (let ((out (assoc-ref outputs "out")))
5607 (for-each make-file-writable
5608 (find-files out "\\.gz$"))
5609 #t))))))
64b6ccc3 5610 (native-inputs
1db791d5
BW
5611 `(("ruby-minitest" ,ruby-minitest)
5612 ("ruby-minitest-sprint" ,ruby-minitest-sprint)
5613 ("which" ,which)))
5614 (propagated-inputs
5615 `(("ruby-concurrent" ,ruby-concurrent)))
64b6ccc3
DT
5616 (synopsis "Unified web application interface for Ruby")
5617 (description "Rack provides a minimal, modular and adaptable interface for
5618developing web applications in Ruby. By wrapping HTTP requests and responses,
5619it unifies the API for web servers, web frameworks, and software in between
5620into a single method call.")
2f3800e5 5621 (home-page "https://rack.github.io/")
64b6ccc3 5622 (license license:expat)))
62e4cc5a 5623
20a0f804
BW
5624(define-public ruby-rack-test
5625 (package
5626 (name "ruby-rack-test")
5627 (version "0.8.3")
5628 (source
5629 (origin
5630 (method url-fetch)
5631 (uri (rubygems-uri "rack-test" version))
5632 (sha256
5633 (base32
5634 "14ij39zywvr1i9f6jsixfg4zxi2q1m1n1nydvf47f0b6sfc9mv1g"))))
5635 (build-system ruby-build-system)
5636 (arguments
5637 ;; Disable tests because of circular dependencies: requires sinatra,
5638 ;; which requires rack-protection, which requires rack-test. Instead
5639 ;; simply require the library.
5640 `(#:phases
5641 (modify-phases %standard-phases
5642 (replace 'check
5643 (lambda _
5644 (invoke "ruby" "-Ilib" "-r" "rack/test"))))))
5645 (propagated-inputs
5646 `(("ruby-rack" ,ruby-rack)))
5647 (synopsis "Testing API for Rack applications")
5648 (description
5649 "Rack::Test is a small, simple testing API for Rack applications. It can
5650be used on its own or as a reusable starting point for Web frameworks and
5651testing libraries to build on.")
5652 (home-page "https://github.com/rack-test/rack-test")
5653 (license license:expat)))
5654
a0a7e690
BW
5655(define-public ruby-rack-protection
5656 (package
5657 (name "ruby-rack-protection")
3355e49c 5658 (version "2.0.5")
a0a7e690
BW
5659 (source
5660 (origin
5661 (method url-fetch)
5662 (uri (rubygems-uri "rack-protection" version))
5663 (sha256
5664 (base32
3355e49c 5665 "15167q25rmxipqwi6hjqj3i1byi9iwl3xq9b7mdar7qiz39pmjsk"))))
a0a7e690
BW
5666 (build-system ruby-build-system)
5667 (arguments
fafeeaa2 5668 '(;; Tests missing from the gem.
a0a7e690
BW
5669 #:tests? #f))
5670 (propagated-inputs
5671 `(("ruby-rack" ,ruby-rack)))
5672 (native-inputs
5673 `(("bundler" ,bundler)
5674 ("ruby-rspec" ,ruby-rspec-2)
5675 ("ruby-rack-test" ,ruby-rack-test)))
5676 (synopsis "Rack middleware that protects against typical web attacks")
5677 (description "Rack middleware that can be used to protect against typical
5678web attacks. It can protect all Rack apps, including Rails. For instance, it
5679protects against cross site request forgery, cross site scripting,
5680clickjacking, directory traversal, session hijacking and IP spoofing.")
5681 (home-page "https://github.com/sinatra/sinatra/tree/master/rack-protection")
5682 (license license:expat)))
5683
6edabcb2
CB
5684(define-public ruby-rainbow
5685 (package
5686 (name "ruby-rainbow")
5687 (version "3.0.0")
5688 (source
5689 (origin
5690 (method url-fetch)
5691 (uri (rubygems-uri "rainbow" version))
5692 (sha256
5693 (base32
5694 "0bb2fpjspydr6x0s8pn1pqkzmxszvkfapv0p4627mywl7ky4zkhk"))))
5695 (build-system ruby-build-system)
5696 (arguments
5697 '(#:phases
5698 (modify-phases %standard-phases
5699 ;; Run rspec directly, to avoid requiring Rubocop which is used from
5700 ;; the Rakefile.
5701 (replace 'check
5702 (lambda* (#:key tests? #:allow-other-keys)
5703 (when tests?
5704 (invoke "rspec"))
5705 #t)))))
5706 (native-inputs
5707 `(("bundler" ,bundler)
5708 ("ruby-rspec" ,ruby-rspec)))
5709 (synopsis "Colorize printed text on ANSI terminals")
5710 (description
5711 "@code{rainbow} provides a string presenter object to colorize strings by
5712wrapping them in ANSI escape codes.")
5713 (home-page "https://github.com/sickill/rainbow")
79193b20
CB
5714 (license license:expat)))
5715
6188d643
CB
5716(define-public ruby-rr
5717 (package
5718 (name "ruby-rr")
5719 (version "1.2.1")
5720 (source
5721 (origin
5722 (method url-fetch)
5723 (uri (rubygems-uri "rr" version))
5724 (sha256
5725 (base32
5726 "1n9g78ba4c2zzmz8cdb97c38h1xm0clircag00vbcxwqs4dq0ymp"))))
5727 (build-system ruby-build-system)
5728 (arguments
5729 '(#:tests? #f)) ; test files not included
5730 (native-inputs
5731 `(("bundler" ,bundler)
5732 ("ruby-rspec" ,ruby-rspec)))
5733 (synopsis "Ruby test double framework")
5734 (description
5735 "RR is a test double framework that features a rich selection of double
5736techniques and a terse syntax.")
5737 (home-page "https://rr.github.io/rr/")
5738 (license license:expat)))
5739
79193b20
CB
5740(define-public ruby-rest-client
5741 (package
5742 (name "ruby-rest-client")
5743 (version "2.0.2")
5744 (source
5745 (origin
5746 (method url-fetch)
5747 (uri (rubygems-uri "rest-client" version))
5748 (sha256
5749 (base32
5750 "1hzcs2r7b5bjkf2x2z3n8z6082maz0j8vqjiciwgg3hzb63f958j"))))
5751 (build-system ruby-build-system)
5752 (arguments
5753 '(#:phases
5754 (modify-phases %standard-phases
5755 (add-before 'check 'remove-unnecessary-development-dependencies
5756 (lambda _
5757 (substitute* "rest-client.gemspec"
5758 ;; Remove rubocop as it's unused. Rubocop also indirectly
5759 ;; depends on this package through ruby-parser and ruby-ast so
5760 ;; this avoids a dependency loop.
5761 ((".*rubocop.*") "\n")
5762 ;; Remove pry as it's unused, it's a debugging tool
5763 ((".*pry.*") "\n")
5764 ;; Remove an unnecessarily strict rdoc dependency
5765 ((".*rdoc.*") "\n"))
5766 #t))
5767 (add-before 'check 'delete-network-dependent-tests
5768 (lambda _
5769 (delete-file "spec/integration/request_spec.rb")
5770 (delete-file "spec/integration/httpbin_spec.rb")
5771 #t)))))
5772 (propagated-inputs
5773 `(("ruby-http-cookie" ,ruby-http-cookie)
5774 ("ruby-mime-types" ,ruby-mime-types)
5775 ("ruby-netrc" ,ruby-netrc)))
5776 (native-inputs
5777 `(("bundler" ,bundler)
eea094cc
TGR
5778 ("ruby-webmock" ,ruby-webmock-2)
5779 ("ruby-rspec" ,ruby-rspec)))
79193b20
CB
5780 (synopsis "Simple HTTP and REST client for Ruby")
5781 (description
5782 "@code{rest-client} provides a simple HTTP and REST client for Ruby,
5783inspired by the Sinatra microframework style of specifying actions:
5784@code{get}, @code{put}, @code{post}, @code{delete}.")
5785 (home-page "https://github.com/rest-client/rest-client")
6edabcb2
CB
5786 (license license:expat)))
5787
5d8fe6de
CB
5788(define-public ruby-rubocop
5789 (package
5790 (name "ruby-rubocop")
865ba3f4 5791 (version "0.77.0")
5d8fe6de
CB
5792 (source
5793 (origin
5794 (method url-fetch)
5795 (uri (rubygems-uri "rubocop" version))
5796 (sha256
5797 (base32
865ba3f4 5798 "0m88b1bgbhmmbdnz2xv6n0il0j4q5qm9jbc0vf1zsaxmxqp06nx9"))))
5d8fe6de
CB
5799 (build-system ruby-build-system)
5800 (arguments
5801 '(;; No included tests
5802 #:tests? #f))
5803 (propagated-inputs
5804 `(("ruby-parser" ,ruby-parser)
5805 ("ruby-powerpack" ,ruby-powerpack)
5806 ("ruby-rainbow" ,ruby-rainbow)
5807 ("ruby-progressbar" ,ruby-progressbar)
5808 ("ruby-parallel" ,ruby-parallel)
5809 ("ruby-jaro-winkler" ,ruby-jaro-winkler)
5810 ("ruby-unicode-display-width" ,ruby-unicode-display-width)))
5811 (synopsis "Ruby code style checking tool")
5812 (description
5813 "@code{rubocop} is a Ruby code style checking tool. It aims to enforce
5814the community-driven Ruby Style Guide.")
5815 (home-page "https://github.com/rubocop-hq/rubocop")
5816 (license license:expat)))
5817
6ef85256
BW
5818(define-public ruby-contest
5819 (package
5820 (name "ruby-contest")
5821 (version "0.1.3")
5822 (source
5823 (origin
5824 (method url-fetch)
5825 (uri (rubygems-uri "contest" version))
5826 (sha256
5827 (base32
5828 "1p9f2292b7b0fbrcjswvj9v01z7ig5ig52328wyqcabgb553qsdf"))))
5829 (build-system ruby-build-system)
5830 (synopsis "Write declarative tests using nested contexts")
5831 (description
5832 "Contest allows writing declarative @code{Test::Unit} tests using nested
5833contexts without performance penalties.")
5834 (home-page "https://github.com/citrusbyte/contest")
5835 (license license:expat)))
5836
c4550f75
BW
5837(define-public ruby-creole
5838 (package
5839 (name "ruby-creole")
5840 (version "0.5.0")
5841 (source
5842 (origin
5843 (method url-fetch)
5844 (uri (rubygems-uri "creole" version))
5845 (sha256
5846 (base32
5847 "00rcscz16idp6dx0dk5yi5i0fz593i3r6anbn5bg2q07v3i025wm"))))
5848 (build-system ruby-build-system)
5849 (native-inputs
5850 `(("ruby-bacon" ,ruby-bacon)))
5851 (synopsis "Creole markup language converter")
5852 (description
5853 "Creole is a lightweight markup language and this library for converting
5854creole to @code{HTML}.")
5855 (home-page "https://github.com/minad/creole")
5856 (license license:ruby)))
5857
6aaa815e
PP
5858(define-public ruby-docile
5859 (package
5860 (name "ruby-docile")
5861 (version "1.1.5")
5862 (source
5863 (origin
5864 (method url-fetch)
5865 (uri (rubygems-uri "docile" version))
5866 (sha256
5867 (base32
5868 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
5869 (build-system ruby-build-system)
5870 (arguments
5871 '(#:tests? #f)) ; needs github-markup, among others
5872 (synopsis "Ruby EDSL helper library")
5873 (description "Docile is a Ruby library that provides an interface for
5874creating embedded domain specific languages (EDSLs) that manipulate existing
5875Ruby classes.")
5876 (home-page "https://ms-ati.github.io/docile/")
5877 (license license:expat)))
5878
44514637 5879(define-public ruby-gherkin
62e4cc5a 5880 (package
44514637 5881 (name "ruby-gherkin")
aada5f6f 5882 (version "5.1.0")
62e4cc5a
PP
5883 (source
5884 (origin
5885 (method url-fetch)
44514637 5886 (uri (rubygems-uri "gherkin" version))
62e4cc5a
PP
5887 (sha256
5888 (base32
aada5f6f 5889 "1cgcdchwwdm10rsk44frjwqd4ihprhxjbm799nscqy2q1raqfj5s"))))
62e4cc5a
PP
5890 (build-system ruby-build-system)
5891 (native-inputs
5892 `(("bundler" ,bundler)))
5893 (arguments
5894 '(#:tests? #f)) ; needs simplecov, among others
5895 (synopsis "Gherkin parser for Ruby")
44514637 5896 (description "Gherkin is a parser and compiler for the Gherkin language.
aada5f6f
CB
5897It is intended be used by all Cucumber implementations to parse
5898@file{.feature} files.")
5899 (home-page "https://github.com/cucumber-attic/gherkin")
62e4cc5a 5900 (license license:expat)))
cd89fecb 5901
8f85018d
MB
5902(define-public ruby-gherkin-ruby
5903 (package
5904 (name "ruby-gherkin-ruby")
5905 (version "0.3.2")
5906 (home-page "http://github.com/codegram/gherkin-ruby")
5907 (source (origin
5908 (method url-fetch)
5909 (uri (rubygems-uri "gherkin-ruby" version))
5910 (sha256
5911 (base32
5912 "18ay7yiibf4sl9n94k7mbi4k5zj2igl4j71qcmkswv69znyx0sn1"))))
5913 (build-system ruby-build-system)
5914 (synopsis "Pure Ruby Gherkin parser")
5915 (description
5916 "Gherkin-ruby is a Gherkin parser written in pure Ruby and less than
5917200 lines of code.")
5918 ;; XXX: No license information anywhere but Readme.md.
5919 (license license:expat)))
5920
15b16c2c
CB
5921(define-public ruby-aruba
5922 (package
5923 (name "ruby-aruba")
cf7201c4 5924 (version "0.14.14")
15b16c2c
CB
5925 (source
5926 (origin
5927 (method url-fetch)
5928 (uri (rubygems-uri "aruba" version))
5929 (sha256
5930 (base32
cf7201c4 5931 "0l2mfpdxc03gdrbwc2hv4vdhjhqhfcdp6d02j05j64ncpi9srlqn"))))
15b16c2c
CB
5932 (build-system ruby-build-system)
5933 (arguments
5934 '(#:test-target "spec"
5935 #:phases
5936 (modify-phases %standard-phases
5937 (add-after 'unpack 'patch
5938 (lambda _
5939 (substitute* "spec/aruba/api_spec.rb"
5940 ;; This resolves some errors in the specs
5941 ;;
5942 ;; undefined method `parse' for Time:Class
5943 (("require 'spec_helper'")
5944 "require 'spec_helper'\nrequire 'time'"))
5945 ;; Avoid shebang issues in this spec file
5946 (substitute* "spec/aruba/matchers/command_spec.rb"
5947 (("/usr/bin/env bash")
5948 (which "bash")))
5949 #t))
5950 (add-before 'check 'remove-unnecessary-dependencies
5951 (lambda _
5952 (substitute* "Gemfile"
5953 ((".*byebug.*") "\n")
5954 ((".*pry.*") "\n")
5955 ((".*yaml.*") "\n")
5956 ((".*bcat.*") "\n")
5957 ((".*kramdown.*") "\n")
5958 ((".*rubocop.*") "\n")
5959 ((".*cucumber-pro.*") "\n")
5960 ((".*cucumber.*") "\n")
5961 ((".*license_finder.*") "\n")
5962 ((".*rake.*") "gem 'rake'\n")
15b16c2c 5963 ((".*relish.*") "\n"))
15b16c2c
CB
5964 (substitute* "aruba.gemspec"
5965 (("spec\\.add\\_runtime\\_dependency 'cucumber'.*")
5966 "spec.add_runtime_dependency 'cucumber'"))
5967 #t))
5968 (add-before 'check 'set-home
5969 (lambda _ (setenv "HOME" "/tmp") #t)))))
5970 (native-inputs
5971 `(("bundler" ,bundler)
5972 ("ruby-rspec" ,ruby-rspec)
cf7201c4
CB
5973 ("ruby-fuubar" ,ruby-fuubar)
5974 ("ruby-simplecov" ,ruby-simplecov)))
15b16c2c
CB
5975 (propagated-inputs
5976 `(("ruby-childprocess" ,ruby-childprocess)
5977 ("ruby-contracts" ,ruby-contracts)
5978 ("ruby-cucumber" ,ruby-cucumber)
5979 ("ruby-ffi" ,ruby-ffi)
5980 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
5981 ("ruby-thor" ,ruby-thor)
5982 ("ruby-yard" ,ruby-yard)))
5983 (synopsis "Test command-line applications with Cucumber, RSpec or Minitest")
5984 (description
5985 "Aruba is an extension for Cucumber, RSpec and Minitest for testing
5986command-line applications. It supports applications written in any
5987language.")
5988 (home-page "https://github.com/cucumber/aruba")
5989 (license license:expat)))
5990
5991;; A version of ruby-aruba without tests run so that circular dependencies can
5992;; be avoided.
5993(define ruby-aruba-without-tests
5994 (package
5995 (inherit ruby-aruba)
5996 (arguments '(#:tests? #f))
5997 (propagated-inputs
5998 `(("ruby-cucumber" ,ruby-cucumber-without-tests)
5999 ,@(alist-delete "ruby-cucumber"
6000 (package-propagated-inputs ruby-aruba))))
6001 (native-inputs '())))
6002
6003(define-public ruby-cucumber
6004 (package
6005 (name "ruby-cucumber")
6006 (version "3.1.2")
6007 (source
6008 (origin
6009 (method git-fetch)
6010 (uri (git-reference
6011 (url "https://github.com/cucumber/cucumber-ruby.git")
6012 (commit (string-append "v" version))))
6013 (file-name (git-file-name name version))
6014 (sha256
6015 (base32
6016 "0764wp2cjg60qa3l69q1dxda5g06a01n5w92szqbf89d2hgl47n3"))))
6017 (build-system ruby-build-system)
6018 (arguments
6019 '(#:test-target "spec"
6020 #:phases
6021 (modify-phases %standard-phases
6022 ;; Don't run or require rubocop, the code linting tool, as this is a
6023 ;; bit unnecessary.
6024 (add-after 'unpack 'dont-run-rubocop
6025 (lambda _
6026 (substitute* "Rakefile"
6027 ((".*rubocop/rake\\_task.*") "")
6028 ((".*RuboCop.*") ""))
6029 #t)))))
6030 (propagated-inputs
6031 `(("ruby-builder" ,ruby-builder)
6032 ("ruby-cucumber-core" ,ruby-cucumber-core)
6033 ("ruby-cucumber-wire" ,ruby-cucumber-wire)
6034 ("ruby-cucumber-expressions" ,ruby-cucumber-expressions)
6035 ("ruby-diff-lcs" ,ruby-diff-lcs)
6036 ("ruby-gherkin" ,ruby-gherkin)
6037 ("ruby-multi-json" ,ruby-multi-json)
6038 ("ruby-multi-test" ,ruby-multi-test)))
6039 (native-inputs
6040 `(("bundler" ,bundler)
6041 ;; Use a untested version of aruba, to avoid a circular dependency, as
6042 ;; ruby-aruba depends on ruby-cucumber.
6043 ("ruby-aruba", ruby-aruba-without-tests)
6044 ("ruby-rspec" ,ruby-rspec)
6045 ("ruby-pry" ,ruby-pry)
6046 ("ruby-nokogiri" ,ruby-nokogiri)))
6047 (synopsis "Describe automated tests in plain language")
6048 (description
6049 "Cucumber is a tool for running automated tests written in plain
6050language. It's designed to support a Behaviour Driven Development (BDD)
6051software development workflow.")
6052 (home-page "https://cucumber.io/")
6053 (license license:expat)))
6054
6055(define ruby-cucumber-without-tests
6056 (package (inherit ruby-cucumber)
6057 (arguments
6058 '(#:tests? #f))
6059 (native-inputs
6060 '())))
6061
cd89fecb
PP
6062(define-public ruby-cucumber-core
6063 (package
6064 (name "ruby-cucumber-core")
5cd047e8
CB
6065 ;; Stick to major version 3, until version 4 of Cucumber is released.
6066 (version "3.2.1")
cd89fecb
PP
6067 (source
6068 (origin
6069 (method url-fetch)
6070 (uri (rubygems-uri "cucumber-core" version))
6071 (sha256
6072 (base32
5cd047e8 6073 "1iavlh8hqj9lwljbpkw06259gdicbr1bdb6pbj5yy3n8szgr8k3c"))))
cd89fecb
PP
6074 (build-system ruby-build-system)
6075 (propagated-inputs
5cd047e8
CB
6076 `(("ruby-backports" ,ruby-backports)
6077 ("ruby-gherkin" ,ruby-gherkin)
6078 ("ruby-cucumber-tag-expressions" ,ruby-cucumber-tag-expressions)))
cd89fecb
PP
6079 (native-inputs
6080 `(("bundler" ,bundler)))
6081 (arguments
6082 '(#:tests? #f)) ; needs simplecov, among others
6083 (synopsis "Core library for the Cucumber BDD app")
6084 (description "Cucumber is a tool for running automated tests
6085written in plain language. Because they're written in plain language,
6086they can be read by anyone on your team. Because they can be read by
6087anyone, you can use them to help improve communication, collaboration
6088and trust on your team.")
6089 (home-page "https://cucumber.io/")
6090 (license license:expat)))
212d563d 6091
fb1a8954
CB
6092(define-public ruby-cucumber-expressions
6093 (package
6094 (name "ruby-cucumber-expressions")
6095 (version "6.0.1")
6096 (source
6097 (origin
6098 (method url-fetch)
6099 (uri (rubygems-uri "cucumber-expressions" version))
6100 (sha256
6101 (base32
6102 "0zwmv6hznyz9vk81f5dhwcr9jhxx2vmbk8yyazayvllvhy0fkpdw"))))
6103 (build-system ruby-build-system)
6104 (arguments
6105 '(#:test-target "spec"))
6106 (native-inputs
6107 `(("bundler" ,bundler)
6108 ("ruby-rspec" ,ruby-rspec)
6109 ("ruby-simplecov" ,ruby-simplecov)))
6110 (synopsis "Simpler alternative to Regular Expressions")
6111 (description "Cucumber Expressions offer similar functionality to Regular
6112Expressions, with a syntax that is easier to read and write. Cucumber
6113Expressions are extensible with parameter types.")
6114 (home-page "https://github.com/cucumber/cucumber-expressions-ruby")
6115 (license license:expat)))
6116
ce872770
CB
6117(define-public ruby-cucumber-wire
6118 (package
6119 (name "ruby-cucumber-wire")
6120 ;; Package version 0.0.1 initially, as this is what's needed by Cucumber
6121 ;; 3, and Cucumber 4 hasn't been released yet.
6122 (version "0.0.1")
6123 (source
6124 (origin
6125 (method url-fetch)
6126 (uri (rubygems-uri "cucumber-wire" version))
6127 (sha256
6128 (base32
6129 "09ymvqb0sbw2if1nxg8rcj33sf0va88ancq5nmp8g01dfwzwma2f"))))
6130 (build-system ruby-build-system)
6131 (arguments
6132 '(;; TODO: Currently, the tests can't be run as cucumber is required,
6133 ;; which would lead to a circular dependency.
6134 #:tests? #f
6135 #:test-target "default"
6136 #:phases
6137 (modify-phases %standard-phases
6138 (add-before 'check 'set-CUCUMBER_USE_RELEASED_GEMS
6139 (lambda _
6140 (setenv "CUCUMBER_USE_RELEASED_GEMS" "true")
6141 #t)))))
6142 (native-inputs
6143 `(("bundler" ,bundler)
6144 ("ruby-rspec" ,ruby-rspec)))
6145 (synopsis "Cucumber wire protocol plugin")
6146 (description
6147 "Cucumber's wire protocol allows step definitions to be implemented and
6148invoked on any platform.")
6149 (home-page "https://github.com/cucumber/cucumber-ruby-wire")
6150 (license license:expat)))
6151
0ce8f344
CB
6152(define-public ruby-cucumber-tag-expressions
6153 (package
6154 (name "ruby-cucumber-tag-expressions")
6155 (version "1.1.1")
6156 (source
6157 (origin
6158 (method url-fetch)
6159 (uri (rubygems-uri "cucumber-tag_expressions" version))
6160 (sha256
6161 (base32
6162 "0cvmbljybws0qzjs1l67fvr9gqr005l8jk1ni5gcsis9pfmqh3vc"))))
6163 (build-system ruby-build-system)
6164 (arguments
6165 '(#:phases
6166 (modify-phases %standard-phases
6167 (replace 'check
6168 (lambda _
6169 (invoke "rspec")
6170 #t)))))
6171 (native-inputs
6172 `(("ruby-rspec" ,ruby-rspec)))
6173 (synopsis "Cucumber tag expressions for Ruby")
6174 (description
6175 "Cucumber tag expression parser for Ruby. A tag expression is an infix
6176boolean expression used by Cucumber.")
6177 (home-page "https://github.com/cucumber/tag-expressions-ruby")
6178 (license license:expat)))
6179
73a5aff7
CB
6180(define-public ruby-bindex
6181 (package
6182 (name "ruby-bindex")
6183 (version "0.5.0")
6184 (source
6185 (origin
6186 (method url-fetch)
6187 (uri (rubygems-uri "bindex" version))
6188 (sha256
6189 (base32
6190 "1wvhf4v8sk5x8li03pcc0v0wglmyv7ikvvg05bnms83dfy7s4k8i"))))
6191 (build-system ruby-build-system)
6192 (arguments
6193 '(#:test-target "default"))
6194 (native-inputs
6195 `(("bundler" ,bundler)
6196 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6197 (synopsis "Provides access for bindings relating to Ruby exceptions")
6198 (description
6199 "@code{bindex} provides a way to access the bindings that relate to
6200exceptions in Ruby, providing more information about the context in which the
6201exception occurred.")
6202 (home-page "https://github.com/gsamokovarov/bindex")
6203 (license license:expat)))
6204
212d563d
PP
6205(define-public ruby-bio-logger
6206 (package
6207 (name "ruby-bio-logger")
6208 (version "1.0.1")
6209 (source
6210 (origin
6211 (method url-fetch)
6212 (uri (rubygems-uri "bio-logger" version))
6213 (sha256
6214 (base32
6215 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
6216 (build-system ruby-build-system)
6217 (arguments
6218 `(#:tests? #f)) ; rake errors, missing shoulda
6219 (propagated-inputs
6220 `(("ruby-log4r" ,ruby-log4r)))
6221 (synopsis "Log4r wrapper for Ruby")
6222 (description "Bio-logger is a wrapper around Log4r adding extra logging
6223features such as filtering and fine grained logging.")
6224 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
6225 (license license:expat)))
07f61cb2 6226
2db0f9c8
BW
6227(define-public ruby-yajl-ruby
6228 (package
6229 (name "ruby-yajl-ruby")
6230 (version "1.4.1")
6231 (source
6232 (origin
6233 (method url-fetch)
6234 (uri (rubygems-uri "yajl-ruby" version))
6235 (sha256
6236 (base32
6237 "16v0w5749qjp13xhjgr2gcsvjv6mf35br7iqwycix1n2h7kfcckf"))))
6238 (build-system ruby-build-system)
6239 (arguments
6240 '(#:test-target "spec"
6241 #:phases
6242 (modify-phases %standard-phases
6243 (add-before 'check 'patch-test-to-update-load-path
6244 (lambda _
6245 (substitute* "spec/parsing/large_number_spec.rb"
6246 (("require \"yajl\"")
6247 "$LOAD_PATH << 'lib'; require 'yajl'"))
6248 #t)))))
6249 (native-inputs
6250 `(("ruby-rake-compiler" ,ruby-rake-compiler)
6251 ("ruby-rspec" ,ruby-rspec)))
6252 (synopsis "Streaming JSON parsing and encoding library for Ruby")
6253 (description
6254 "Ruby C bindings to the Yajl JSON stream-based parser library. The API
6255is compatible with the JSON gem, so yajl-ruby can act as a drop in
6256replacement.
6257
6258A modified copy of yajl is used, and included in the package.")
6259 (home-page "https://github.com/brianmario/yajl-ruby")
6260 (license (list license:expat ; Ruby code, yajl_ext.c and yajl_ext.h
6261 license:bsd-3)))) ; Included, modified copy of yajl
6262
07f61cb2 6263(define-public ruby-yard
6499893e
BW
6264 (package
6265 (name "ruby-yard")
f321380f 6266 (version "0.9.20")
6499893e
BW
6267 (source
6268 (origin
f3fd70c0 6269 (method git-fetch)
6499893e 6270 ;; Tests do not pass if we build from the distributed gem.
f3fd70c0
EF
6271 (uri (git-reference
6272 (url "https://github.com/lsegal/yard")
6273 (commit (string-append "v" version))))
6274 (file-name (git-file-name name version))
6499893e
BW
6275 (sha256
6276 (base32
f321380f 6277 "1v48zz8hzazrg79jksj9siys21d2axvzijvkxw2j42zh86syi1wi"))))
6499893e
BW
6278 (build-system ruby-build-system)
6279 (arguments
6280 `(#:phases
6281 (modify-phases %standard-phases
6282 (replace 'check
6283 (lambda _
f321380f
CB
6284 ;; Delete the Gemfile to avoid errors relating to it
6285 (delete-file "Gemfile")
6499893e
BW
6286 ;; $HOME needs to be set to somewhere writeable for tests to run
6287 (setenv "HOME" "/tmp")
6288 ;; Run tests without using 'rake' to avoid dependencies.
9923d5a4 6289 (invoke "rspec"))))))
6499893e
BW
6290 (native-inputs
6291 `(("ruby-rspec" ,ruby-rspec)
f321380f
CB
6292 ("ruby-rack" ,ruby-rack)
6293 ("ruby-redcloth" ,ruby-redcloth)
6294 ("ruby-asciidoc" ,ruby-asciidoctor)))
6499893e
BW
6295 (synopsis "Documentation generation tool for Ruby")
6296 (description
6297 "YARD is a documentation generation tool for the Ruby programming
07f61cb2
BW
6298language. It enables the user to generate consistent, usable documentation
6299that can be exported to a number of formats very easily, and also supports
6300extending for custom Ruby constructs such as custom class level definitions.")
2f3800e5 6301 (home-page "https://yardoc.org")
6499893e 6302 (license license:expat)))
2cbcd23a 6303
ad686ef3
RW
6304(define-public ruby-clap
6305 (package
6306 (name "ruby-clap")
6307 (version "1.0.0")
6308 (source (origin
6309 (method url-fetch)
6310 (uri (rubygems-uri "clap" version))
6311 (sha256
6312 (base32
6313 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
6314 (build-system ruby-build-system)
6315 ;; Clap needs cutest for running tests, but cutest needs clap.
6316 (arguments `(#:tests? #f))
6317 (synopsis "Command line argument parsing for simple applications")
6318 (description
6319 "Clap provides command line argument parsing features. It covers the
6320simple case of executing code based on the flags or parameters passed.")
6321 (home-page "https://github.com/djanowski/cutest")
0c80451e
RW
6322 (license license:expat)))
6323
6324(define-public ruby-cutest
6325 (package
6326 (name "ruby-cutest")
6327 (version "1.2.2")
6328 (source (origin
6329 (method url-fetch)
6330 (uri (rubygems-uri "cutest" version))
6331 (sha256
6332 (base32
6333 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
6334 (build-system ruby-build-system)
6335 (propagated-inputs
6336 `(("ruby-clap" ,ruby-clap)))
6337 (synopsis "Run tests in separate processes")
6338 (description
6339 "Cutest runs tests in separate processes to avoid shared state.")
6340 (home-page "https://github.com/djanowski/cutest")
ad686ef3
RW
6341 (license license:expat)))
6342
ac09beba
RW
6343(define-public ruby-pygmentize
6344 (package
6345 (name "ruby-pygmentize")
6346 (version "0.0.3")
6347 (source (origin
6348 (method url-fetch)
6349 (uri (rubygems-uri "pygmentize" version))
6350 (sha256
6351 (base32
6352 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
6353 (build-system ruby-build-system)
6354 (arguments
6355 `(#:phases
6356 (modify-phases %standard-phases
6357 (add-after 'unpack 'fix-pygmentize-path
6358 (lambda _
6359 (substitute* "lib/pygmentize.rb"
6360 (("\"/usr/bin/env python.*")
6361 (string-append "\"" (which "pygmentize") "\"\n")))
6362 #t))
6363 (add-after 'build 'do-not-use-vendor-directory
6364 (lambda _
6365 ;; Remove bundled pygments sources
6366 ;; FIXME: ruby-build-system does not support snippets.
6367 (delete-file-recursively "vendor")
6368 (substitute* "pygmentize.gemspec"
6369 (("\"vendor/\\*\\*/\\*\",") ""))
6370 #t)))))
6371 (inputs
6372 `(("pygments" ,python-pygments)))
6373 (native-inputs
6374 `(("ruby-cutest" ,ruby-cutest)
6375 ("ruby-nokogiri" ,ruby-nokogiri)))
6376 (synopsis "Thin Ruby wrapper around pygmentize")
6377 (description
6378 "Pygmentize provides a simple way to call pygmentize from within a Ruby
6379application.")
6380 (home-page "https://github.com/djanowski/pygmentize")
6381 (license license:expat)))
6382
2cbcd23a
DT
6383(define-public ruby-eventmachine
6384 (package
6385 (name "ruby-eventmachine")
c207fa5e 6386 (version "1.2.7")
2cbcd23a
DT
6387 (source
6388 (origin
6389 (method url-fetch)
6390 (uri (rubygems-uri "eventmachine" version))
6391 (sha256
6392 (base32
c207fa5e 6393 "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"))))
2cbcd23a
DT
6394 (build-system ruby-build-system)
6395 (arguments
c5d269fb 6396 '(#:tests? #f)) ; test suite tries to connect to google.com
2cbcd23a
DT
6397 (native-inputs
6398 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
6399 (synopsis "Single-threaded network event framework for Ruby")
6400 (description
6401 "EventMachine implements a single-threaded engine for arbitrary network
6402communications. EventMachine wraps all interactions with sockets, allowing
6403programs to concentrate on the implementation of network protocols. It can be
6404used to create both network servers and clients.")
24a26227
TGR
6405 ;; The ‘official’ rubyeventmachine.com domain is now registrar-squatted.
6406 (home-page "https://github.com/eventmachine/eventmachine")
2cbcd23a 6407 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
7d3a1a2d 6408
e218b0c8
BW
6409(define-public ruby-ruby-engine
6410 (package
6411 (name "ruby-ruby-engine")
6412 (version "1.0.1")
6413 (source
6414 (origin
6415 (method url-fetch)
6416 (uri (rubygems-uri "ruby_engine" version))
6417 (sha256
6418 (base32
6419 "1d0sd4q50zkcqhr395wj1wpn2ql52r0fpwhzjfvi1bljml7k546v"))))
6420 (build-system ruby-build-system)
6421 (arguments
6422 `(#:phases
6423 (modify-phases %standard-phases
6424 (add-before 'check 'clean-up
6425 (lambda _
6426 (delete-file "Gemfile.lock")
6427 (substitute* "ruby_engine.gemspec"
6428 ;; Remove unnecessary imports that would entail further
6429 ;; dependencies.
6430 ((".*<rdoc.*") "")
6431 ((".*<rubygems-tasks.*") "")
6432 ;; Remove extraneous .gem file
6433 (("\\\"pkg/ruby_engine-1.0.0.gem\\\",") "")
6434 ;; Soften rake dependency
6435 (("%q<rake>.freeze, \\[\\\"~> 10.0\\\"\\]")
6436 "%q<rake>.freeze, [\">= 10.0\"]")
6437 ;; Soften the rspec dependency
6438 (("%q<rspec>.freeze, \\[\\\"~> 2.4\\\"\\]")
6439 "%q<rspec>.freeze, [\">= 2.4\"]"))
6440 (substitute* "Rakefile"
6441 (("require 'rubygems/tasks'") "")
6442 (("Gem::Tasks.new") ""))
6443 ;; Remove extraneous .gem file that otherwise gets installed.
6444 (delete-file "pkg/ruby_engine-1.0.0.gem")
6445 #t)))))
6446 (native-inputs
6447 `(("bundler" ,bundler)
6448 ("ruby-rake" ,ruby-rake)
6449 ("ruby-rspec" ,ruby-rspec)))
6450 (synopsis "Simplifies checking for Ruby implementation")
6451 (description
6452 "@code{ruby_engine} provides an RubyEngine class that can be used to
6453check which implementation of Ruby is in use. It can provide the interpreter
6454name and provides query methods such as @{RubyEngine.mri?}.")
6455 (home-page "https://github.com/janlelis/ruby_engine")
6456 (license license:expat)))
6457
8092e333
BW
6458(define-public ruby-turn
6459 (package
6460 (name "ruby-turn")
6461 (version "0.9.7")
6462 (source
6463 (origin
6464 (method url-fetch)
6465 (uri (rubygems-uri "turn" version))
6466 (sha256
6467 (base32
6468 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
6469 (build-system ruby-build-system)
6470 (arguments
6471 `(#:phases
6472 (modify-phases %standard-phases
6473 ;; Tests fail because turn changes its environment so can no longer
6474 ;; find test/unit. Instead simply test if the executable runs
6475 ;; without issue.
6476 (replace 'check
6477 (lambda _
9923d5a4 6478 (invoke "ruby" "-Ilib" "bin/turn" "-h"))))))
8092e333
BW
6479 (propagated-inputs
6480 `(("ruby-ansi" ,ruby-ansi)
6481 ("ruby-minitest" ,ruby-minitest-4)))
6482 (synopsis "Alternate set of alternative runners for MiniTest")
6483 (description
6484 "TURN provides a set of alternative runners for MiniTest which are both
6485colorful and informative. TURN displays each test on a separate line with
6486failures being displayed immediately instead of at the end of the tests. Note
6487that TURN is no longer being maintained.")
f433b662 6488 (home-page "https://rubygems.org/gems/turn")
8092e333
BW
6489 (license license:expat)))
6490
8279b1d3
CB
6491(define-public ruby-mimemagic
6492 (package
6493 (name "ruby-mimemagic")
60bc8952 6494 (version "0.3.3")
8279b1d3
CB
6495 (source
6496 (origin
6497 (method url-fetch)
6498 (uri (rubygems-uri "mimemagic" version))
6499 (sha256
60bc8952 6500 (base32 "04cp5sfbh1qx82yqxn0q75c7hlcx8y1dr5g3kyzwm4mx6wi2gifw"))))
8279b1d3
CB
6501 (build-system ruby-build-system)
6502 (arguments
6503 '(#:phases
6504 (modify-phases %standard-phases
6505 ;; This phase breaks the tests, as it patches some of the test data.
6506 (delete 'patch-source-shebangs))))
6507 (native-inputs
6508 `(("ruby-bacon" ,ruby-bacon)))
6509 (synopsis "Ruby library for MIME detection by extension or content")
6510 (description
6511 "@acronym{MIME, Multipurpose Internet Mail Extensions} detection by
6512extension or content, using the freedesktop.org.xml shared-mime-info
6513database.")
6514 (home-page "https://github.com/minad/mimemagic")
6515 (license license:expat)))
6516
32d1c06f
BW
6517(define-public ruby-mime-types-data
6518 (package
6519 (name "ruby-mime-types-data")
f49511db 6520 (version "3.2016.0521")
32d1c06f
BW
6521 (source
6522 (origin
6523 (method url-fetch)
6524 (uri (rubygems-uri "mime-types-data" version))
6525 (sha256
6526 (base32
f49511db 6527 "04my3746hwa4yvbx1ranhfaqkgf6vavi1kyijjnw8w3dy37vqhkm"))))
32d1c06f
BW
6528 (build-system ruby-build-system)
6529 (native-inputs
6530 `(("ruby-hoe" ,ruby-hoe)))
6531 (synopsis "Registry for information about MIME media type definitions")
6532 (description
6533 "@code{mime-types-data} provides a registry for information about
6534Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
6535be used with the Ruby mime-types library or other software to determine
6536defined filename extensions for MIME types, or to use filename extensions to
6537look up the likely MIME type definitions.")
6538 (home-page "https://github.com/mime-types/mime-types-data/")
6539 (license license:expat)))
6540
d39b606c
BW
6541(define-public ruby-mime-types
6542 (package
6543 (name "ruby-mime-types")
803bcc81 6544 (version "3.1")
d39b606c
BW
6545 (source
6546 (origin
6547 (method url-fetch)
6548 (uri (rubygems-uri "mime-types" version))
6549 (sha256
6550 (base32
803bcc81 6551 "0087z9kbnlqhci7fxh9f6il63hj1k02icq2rs0c6cppmqchr753m"))))
d39b606c
BW
6552 (build-system ruby-build-system)
6553 (propagated-inputs
6554 `(("ruby-mime-types-data" ,ruby-mime-types-data)))
6555 (native-inputs
6556 `(("ruby-hoe" ,ruby-hoe)
6557 ("ruby-fivemat" ,ruby-fivemat)
6558 ("ruby-minitest-focus" ,ruby-minitest-focus)
6559 ("ruby-minitest-rg" ,ruby-minitest-rg)
803bcc81
BW
6560 ("ruby-minitest-bonus-assertions" ,ruby-minitest-bonus-assertions)
6561 ("ruby-minitest-hooks" ,ruby-minitest-hooks)))
d39b606c
BW
6562 (synopsis "Library and registry for MIME content type definitions")
6563 (description "The mime-types library provides a library and registry for
6564information about Multipurpose Internet Mail Extensions (MIME) content type
6565definitions. It can be used to determine defined filename extensions for MIME
6566types, or to use filename extensions to look up the likely MIME type
6567definitions.")
6568 (home-page "https://github.com/mime-types/ruby-mime-types")
6569 (license license:expat)))
6570
eb5e0bd9
BW
6571(define-public ruby-fivemat
6572 (package
6573 (name "ruby-fivemat")
c664ebcc 6574 (version "1.3.7")
eb5e0bd9
BW
6575 (source
6576 (origin
6577 (method url-fetch)
6578 (uri (rubygems-uri "fivemat" version))
6579 (sha256
6580 (base32
c664ebcc 6581 "0pzlycasvwmg4bbx7plllpqnhd9zlmmff8l2w3yii86nrm2nvf9n"))))
eb5e0bd9
BW
6582 (build-system ruby-build-system)
6583 (arguments
6584 `(#:tests? #f)) ; no tests
6585 (synopsis "Each test file given its own line of dots")
6586 (description
6587 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
6588its own line of dots during testing. It aims to provide test output that is
6589neither too verbose nor too minimal.")
6590 (home-page "https://github.com/tpope/fivemat")
6591 (license license:expat)))
6592
4fea500b
BW
6593(define-public ruby-sqlite3
6594 (package
6595 (name "ruby-sqlite3")
e7cdba61 6596 (version "1.4.2")
4fea500b
BW
6597 (source
6598 (origin
6599 (method url-fetch)
6600 (uri (rubygems-uri "sqlite3" version))
6601 (sha256
6602 (base32
e7cdba61 6603 "0lja01cp9xd5m6vmx99zwn4r7s97r1w5cb76gqd8xhbm1wxyzf78"))))
4fea500b
BW
6604 (build-system ruby-build-system)
6605 (arguments
6606 `(#:phases
6607 (modify-phases %standard-phases
6608 (add-before 'check 'add-gemtest-file
6609 ;; This file exists in the repository but is not distributed.
9923d5a4 6610 (lambda _ (invoke "touch" ".gemtest"))))))
4fea500b
BW
6611 (inputs
6612 `(("sqlite" ,sqlite)))
6613 (native-inputs
6614 `(("ruby-hoe" ,ruby-hoe)
6615 ("ruby-rake-compiler" ,ruby-rake-compiler)
6616 ("ruby-mini-portile" ,ruby-mini-portile)))
6617 (synopsis "Interface with SQLite3 databases")
6618 (description
6619 "This module allows Ruby programs to interface with the SQLite3 database
6620engine.")
6621 (home-page
6622 "https://github.com/sparklemotion/sqlite3-ruby")
6623 (license license:bsd-3)))
6624
4dfa39cc
BW
6625(define-public ruby-shoulda-context
6626 (package
6627 (name "ruby-shoulda-context")
e7d1d472 6628 (version "1.2.2")
4dfa39cc
BW
6629 (source
6630 (origin
6631 (method url-fetch)
6632 (uri (rubygems-uri "shoulda-context" version))
6633 (sha256
6634 (base32
e7d1d472 6635 "1l0ncsxycb4s8n47dml97kdnixw4mizljbkwqc3rh05r70csq9bc"))))
4dfa39cc
BW
6636 (build-system ruby-build-system)
6637 (arguments
6638 `(#:phases
6639 (modify-phases %standard-phases
6640 (replace 'check
6641 (lambda _
6642 ;; Do not run tests to avoid circular dependence with rails.
6643 ;; Instead just import the library to test.
9923d5a4 6644 (invoke "ruby" "-Ilib" "-r" "shoulda-context"))))))
4dfa39cc
BW
6645 (synopsis "Test::Unit context framework extracted from Shoulda")
6646 (description
6647 "@code{shoulda-context} is the context framework extracted from Shoulda.
6648Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
6649context, setup, and should blocks combine to produce natural test method
6650names.")
6651 (home-page "https://github.com/thoughtbot/shoulda-context")
6652 (license license:expat)))
6653
e4fea008
BW
6654(define-public ruby-shoulda-matchers
6655 (package
6656 (name "ruby-shoulda-matchers")
d1c1f368 6657 (version "3.1.2")
e4fea008
BW
6658 (source
6659 (origin
6660 (method url-fetch)
6661 (uri (rubygems-uri "shoulda-matchers" version))
6662 (sha256
6663 (base32
d1c1f368 6664 "1zvv94pqk5b5my3w1shdz7h34xf2ldhg5k4qfdpbwi2iy0j9zw2a"))))
e4fea008
BW
6665 (build-system ruby-build-system)
6666 (arguments
6667 `(#:phases
6668 (modify-phases %standard-phases
e4fea008
BW
6669 (replace 'check
6670 (lambda _
6671 ;; Do not run tests to avoid circular dependence with rails. Instead
6672 ;; just import the library to test.
9923d5a4 6673 (invoke "ruby" "-Ilib" "-r" "shoulda-matchers"))))))
e4fea008
BW
6674 (propagated-inputs
6675 `(("ruby-activesupport" ,ruby-activesupport)))
6676 (synopsis "Collection of testing matchers extracted from Shoulda")
6677 (description
6678 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
6679test common Rails functionality. These tests would otherwise be much longer,
6680more complex, and error-prone.")
6681 (home-page "https://github.com/thoughtbot/shoulda-matchers")
6682 (license license:expat)))
6683
3885c58b
BW
6684(define-public ruby-shoulda-matchers-2
6685 (package
6686 (inherit ruby-shoulda-matchers)
6687 (version "2.8.0")
6688 (source (origin
6689 (method url-fetch)
6690 (uri (rubygems-uri "shoulda-matchers" version))
6691 (sha256
6692 (base32
6693 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
6694
6f390716
BW
6695(define-public ruby-shoulda
6696 (package
6697 (name "ruby-shoulda")
6698 (version "3.5.0")
6699 (source
6700 (origin
6701 (method url-fetch)
6702 (uri (rubygems-uri "shoulda" version))
6703 (sha256
6704 (base32
6705 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
6706 (build-system ruby-build-system)
6707 (arguments
6708 `(#:phases
6709 (modify-phases %standard-phases
6710 (replace 'check
6711 ;; Don't run tests to avoid circular dependence with rails. Instead
6712 ;; just import the library to test.
9923d5a4 6713 (lambda _ (invoke "ruby" "-Ilib" "-r" "shoulda"))))))
6f390716
BW
6714 (propagated-inputs
6715 `(("ruby-shoulda-context" ,ruby-shoulda-context)
6716 ("ruby-shoulda-matchers" ,ruby-shoulda-matchers-2)))
6717 (synopsis "Context framework and matchers for testing")
6718 (description
6719 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
6720@code{shoulda-matchers} providing tools for writing tests.")
6721 (home-page "https://github.com/thoughtbot/shoulda")
6722 (license license:expat)))
6723
3b44bcdf
BW
6724(define-public ruby-unf
6725 (package
6726 (name "ruby-unf")
6727 (version "0.1.4")
6728 (source
6729 (origin
6730 (method url-fetch)
6731 (uri (rubygems-uri "unf" version))
6732 (sha256
6733 (base32
6734 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
6735 (build-system ruby-build-system)
6736 (arguments
6737 `(#:phases
6738 (modify-phases %standard-phases
6739 (add-before 'check 'add-dependency-to-bundler
6740 (lambda _
6741 ;; test-unit is required but not provided by the bundler
6742 ;; environment. This is fixed in the upstream repository but fix
6743 ;; has not been released.
6744 (substitute* "Gemfile"
6745 (("^gemspec") "gem 'test-unit'\ngemspec"))
6746 #t)))))
6747 (propagated-inputs
6748 `(("ruby-unf-ext" ,ruby-unf-ext)))
6749 (native-inputs
6750 `(("ruby-shoulda" ,ruby-shoulda)
6751 ("bundler" ,bundler)
6752 ("ruby-test-unit" ,ruby-test-unit)))
6753 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
6754 (description
6755 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
6756support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
6757@code{java.text.Normalizer} on JRuby.")
6758 (home-page "https://github.com/knu/ruby-unf")
6759 (license license:bsd-2)))
6760
e32c99d2
CB
6761(define-public ruby-warden
6762 (package
6763 (name "ruby-warden")
6764 (version "1.2.8")
6765 (source
6766 (origin
6767 (method url-fetch)
6768 (uri (rubygems-uri "warden" version))
6769 (sha256
6770 (base32
6771 "1fr9n9i9r82xb6i61fdw4xgc7zjv7fsdrr4k0njchy87iw9fl454"))))
6772 (build-system ruby-build-system)
6773 (arguments
6774 '(#:tests? #f)) ; No included tests
6775 (propagated-inputs
6776 `(("ruby-rack" ,ruby-rack)))
6777 (synopsis "Rack middleware providing authentication")
6778 (description
6779 "Warden is a Rack-based middleware that provides a mechanism for
6780authentication in Ruby web applications.")
6781 (home-page "https://github.com/wardencommunity/warden")
6782 (license license:expat)))
6783
e42eecdb
CB
6784(define-public ruby-warden-oauth2
6785 (package
6786 (name "ruby-warden-oauth2")
6787 (version "0.0.1")
6788 (source
6789 (origin
6790 (method url-fetch)
6791 (uri (rubygems-uri "warden-oauth2" version))
6792 (sha256
6793 (base32
6794 "1z9154lvzrnnfjbjkmirh4n811nygp6pm2fa6ikr7y1ysa4zv3cz"))))
6795 (build-system ruby-build-system)
6796 (arguments
6797 '(#:test-target "spec"
6798 #:phases
6799 (modify-phases %standard-phases
6800 (add-after 'unpack 'remove-unnecessary-dependencies
6801 (lambda _
6802 (substitute* "Gemfile"
6803 ;; All of these gems relate to development, and are unnecessary
6804 ;; when running the tests
6805 (("gem 'guard-bundler'") "")
6806 (("gem 'guard'") "")
6807 (("gem 'guard-rspec'") "")
6808 (("gem 'rb-fsevent'") "")
6809 (("gem 'pry'") "")
6810 (("gem 'growl'") ""))
6811 #t))
6812 ;; The test suite doesn't work with rspec@2, and this is incompatible
6813 ;; with the current version of Rake, so invoke Rspec directly
6814 (replace 'check
6815 (lambda* (#:key tests? #:allow-other-keys)
6816 (when tests?
6817 (invoke "bundle" "exec" "rspec"))
6818 #t)))))
6819 (propagated-inputs
6820 `(("ruby-warden" ,ruby-warden)))
6821 (native-inputs
6822 `(("bundler" ,bundler)
6823 ("ruby-rspec" ,ruby-rspec-2)
6824 ("ruby-rack-test" ,ruby-rack-test)))
6825 (synopsis "OAuth 2.0 strategies for Warden")
6826 (description
6827 "This library extends Warden to support OAuth 2.0 authorized API
6828requests.")
6829 (home-page "https://github.com/opperator/warden-oauth2")
6830 (license license:expat)))
6831
8c7ae384
CB
6832(define-public ruby-webmock-2
6833 (package
6834 (name "ruby-webmock")
6835 (version "2.3.2")
6836 (source
6837 (origin
6838 (method url-fetch)
6839 (uri (rubygems-uri "webmock" version))
6840 (sha256
6841 (base32
6842 "04hkcqsmbfnp8g237pisnc834vpgildklicbjbyikqg0bg1rwcy5"))))
6843 (build-system ruby-build-system)
6844 (native-inputs
6845 `(("bundler" ,bundler)
6846 ("ruby-rspec" ,ruby-rspec)))
6847 (propagated-inputs
6848 `(("ruby-addressable" ,ruby-addressable)
6849 ("ruby-crack" ,ruby-crack)
6850 ("ruby-hashdiff" ,ruby-hashdiff)))
6851 (synopsis "Allows stubbing and setting expectations on HTTP requests")
6852 (description
6853 "WebMock allows stubbing HTTP requests and setting expectations on HTTP
6854requests. This is useful when testing software.")
6855 (home-page "https://github.com/bblimke/webmock")
6856 (license license:expat)))
6857
d8c189ed
CB
6858(define-public ruby-unicode-display-width
6859 (package
6860 (name "ruby-unicode-display-width")
216ccced 6861 (version "1.6.0")
d8c189ed
CB
6862 (source
6863 (origin
6864 (method url-fetch)
6865 (uri (rubygems-uri "unicode-display_width" version))
6866 (sha256
6867 (base32
216ccced 6868 "08kfiniak1pvg3gn5k6snpigzvhvhyg7slmm0s2qx5zkj62c1z2w"))))
d8c189ed
CB
6869 (build-system ruby-build-system)
6870 (arguments
6871 '(;; Test data not included.
6872 #:tests? #f))
6873 (synopsis "Determine the monospace display width of Ruby strings")
6874 (description
6875 "@code{Unicode::DisplayWidth} is a Ruby library which can determine the
6876display width of strings in Ruby.")
6877 (home-page "https://github.com/janlelis/unicode-display_width")
6878 (license license:expat)))
6879
6120589f
CB
6880;; There is another gem called 'ruby-version' so we use an underscore in this
6881;; name
6882(define-public ruby_version
6883 (package
6884 (name "ruby_version")
6885 (version "1.0.1")
6886 (source
6887 (origin
6888 (method url-fetch)
6889 (uri (rubygems-uri "ruby_version" version))
6890 (sha256
6891 (base32
6892 "0854i1bjy56176anr05l5m0vc81nl53c7fyfg7sljj62m1d64dgj"))))
6893 (build-system ruby-build-system)
6894 (arguments
6895 '(#:phases
6896 (modify-phases %standard-phases
6897 (add-before 'check 'fix-dependencies
6898 (lambda _
6899 ;; Remove the Gemfile.lock, as we want to use Guix packages at
6900 ;; whatever versions.
6901 (delete-file "Gemfile.lock")
6902 ;; Remove the incldued gem file as it's unnecessary.
6903 (delete-file "pkg/ruby_version-1.0.0.gem")
6904 (substitute* "ruby_version.gemspec"
6905 ;; Don't require rdoc and rubygems-tasks as they're unnecessary
6906 ((".*rdoc.*") "\n")
6907 ((".*rubygems-tasks.*") "\n")
6908 ;; Accept any version of rake and rspec
6909 (("%q<rake.*") "%q<rake>)\n")
6910 (("%q<rspec.*") "%q<rspec>)\n"))
6911 ;; Remove the use of rubygems-tasks from the Rakefile, as it's
6912 ;; unnecessary.
6913 (substitute* "Rakefile"
6914 (("^require 'rubygems/tasks'") "")
6915 (("Gem::Tasks.new") ""))
6916 #t)))))
6917 (native-inputs
6918 `(("bundler" ,bundler)
6919 ("ruby-rspec" ,ruby-rspec)))
6920 (synopsis "Ruby library to help check the Ruby version")
6921 (description
6922 "@code{ruby_version} provides a @code{RubyVersion} module to simplify
6923checking for the right Ruby version in software.")
6924 (home-page "https://github.com/janlelis/ruby_version")
6925 (license license:expat)))
6926
a229acff
CB
6927(define-public ruby-websocket-driver
6928 (package
6929 (name "ruby-websocket-driver")
9d1cf6d4 6930 (version "0.7.1")
a229acff
CB
6931 (source
6932 (origin
6933 (method url-fetch)
6934 (uri (rubygems-uri "websocket-driver" version))
6935 (sha256
9d1cf6d4 6936 (base32 "1bxamwqldmy98hxs5pqby3andws14hl36ch78g0s81gaz9b91nj2"))))
a229acff
CB
6937 (build-system ruby-build-system)
6938 (arguments
9d1cf6d4 6939 '(#:tests? #f)) ; no included tests
a229acff
CB
6940 (propagated-inputs
6941 `(("ruby-websocket-extensions" ,ruby-websocket-extensions)))
6942 (synopsis "WebSocket protocol handler with pluggable I/O")
6943 (description
6944 "@code{websocket-driver} provides a complete implementation of the
6945WebSocket protocols that can be hooked up to any TCP library")
6946 (home-page "https://github.com/faye/websocket-driver-ruby")
6947 (license license:expat)))
6948
52b015a9
CB
6949(define-public ruby-websocket-extensions
6950 (package
6951 (name "ruby-websocket-extensions")
6952 (version "0.1.3")
6953 (source
6954 (origin
6955 (method url-fetch)
6956 (uri (rubygems-uri "websocket-extensions" version))
6957 (sha256
6958 (base32
6959 "034sdr7fd34yag5l6y156rkbhiqgmy395m231dwhlpcswhs6d270"))))
6960 (build-system ruby-build-system)
6961 (arguments
6962 '(;; No included tests
6963 #:tests? #f))
6964 (synopsis "Generic extension manager for WebSocket connections")
6965 (description
6966 "@code{websocket-extensions} provides a container for registering
6967extension plugins.")
6968 (home-page "https://github.com/faye/websocket-extensions-ruby")
6969 (license license:expat)))
6970
5799aadd
BW
6971(define-public ruby-domain-name
6972 (package
6973 (name "ruby-domain-name")
222999c9 6974 (version "0.5.20180417")
5799aadd
BW
6975 (source
6976 (origin
6977 (method url-fetch)
6978 (uri (rubygems-uri "domain_name" version))
6979 (sha256
6980 (base32
222999c9 6981 "0abdlwb64ns7ssmiqhdwgl27ly40x2l27l8hs8hn0z4kb3zd2x3v"))))
5799aadd
BW
6982 (build-system ruby-build-system)
6983 (arguments
6984 `(#:phases
6985 (modify-phases %standard-phases
6986 (add-before 'check 'fix-versions
6987 (lambda _
6988 ;; Fix NameError that appears to already be fixed upstream.
6989 (substitute* "Rakefile"
6990 (("DomainName::VERSION")
6991 "Bundler::GemHelper.gemspec.version"))
6992 ;; Loosen unnecessarily strict test-unit version specification.
6993 (substitute* "domain_name.gemspec"
71596c3c 6994 (("<test-unit>.freeze, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
5799aadd
BW
6995 #t)))))
6996 (propagated-inputs
6997 `(("ruby-unf" ,ruby-unf)))
6998 (native-inputs
6999 `(("ruby-shoulda" ,ruby-shoulda)
7000 ("bundler" ,bundler)
7001 ("ruby-test-unit" ,ruby-test-unit)))
7002 (synopsis "Domain name manipulation library")
7003 (description
7004 "@code{domain_name} is a Domain name manipulation library. It parses a
7005domain name ready for extracting the registered domain and TLD (Top Level
7006Domain). It can also be used for cookie domain validation based on the Public
7007Suffix List.")
7008 (home-page "https://github.com/knu/ruby-domain_name")
7009 (license license:bsd-2)))
7010
d114ceeb
BW
7011(define-public ruby-http-cookie
7012 (package
7013 (name "ruby-http-cookie")
2a2eb07d 7014 (version "1.0.3")
d114ceeb
BW
7015 (source
7016 (origin
7017 (method url-fetch)
7018 (uri (rubygems-uri "http-cookie" version))
7019 (sha256
7020 (base32
2a2eb07d 7021 "004cgs4xg5n6byjs7qld0xhsjq3n6ydfh897myr2mibvh6fjc49g"))))
d114ceeb
BW
7022 (build-system ruby-build-system)
7023 (arguments
7024 `(#:phases
7025 (modify-phases %standard-phases
7026 (add-before 'check 'add-dependency-to-bundler
7027 (lambda _
7028 ;; Fix NameError
7029 (substitute* "Rakefile"
7030 (("HTTP::Cookie::VERSION")
7031 "Bundler::GemHelper.gemspec.version"))
7032 #t)))))
7033 (propagated-inputs
7034 `(("ruby-domain-name" ,ruby-domain-name)))
7035 (native-inputs
7036 `(("rubysimplecov" ,ruby-simplecov)
7037 ("bundler" ,bundler)
7038 ("ruby-sqlite3" ,ruby-sqlite3)
7039 ("ruby-test-unit" ,ruby-test-unit)))
7040 (synopsis "Handle HTTP Cookies based on RFC 6265")
7041 (description
7042 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
7043RFC 6265. It has been designed with security, standards compliance and
7044compatibility in mind, to behave just the same as today's major web browsers.
7045It has built-in support for the legacy @code{cookies.txt} and
7046@code{cookies.sqlite} formats of Mozilla Firefox.")
7047 (home-page "https://github.com/sparklemotion/http-cookie")
7048 (license license:expat)))
7049
1c8e6fd3
CB
7050(define-public ruby-httpclient
7051 (package
7052 (name "ruby-httpclient")
7053 (version "2.8.3")
7054 (source
7055 (origin
7056 (method url-fetch)
7057 (uri (rubygems-uri "httpclient" version))
7058 (sha256
7059 (base32
7060 "19mxmvghp7ki3klsxwrlwr431li7hm1lczhhj8z4qihl2acy8l99"))))
7061 (build-system ruby-build-system)
7062 (arguments
7063 '(;; TODO: Some tests currently fail
7064 ;; ------
7065 ;; 211 tests, 729 assertions, 13 failures, 4 errors, 0 pendings,
7066 ;; 2 omissions, 0 notifications
7067 ;; 91.866% passed
7068 ;; ------
7069 ;; 6.49 tests/s, 22.41 assertions/s
7070 #:tests? #f
7071 #:phases
7072 (modify-phases %standard-phases
7073 (replace 'check
7074 (lambda* (#:key tests? #:allow-other-keys)
7075 (if tests?
9923d5a4
TGR
7076 (invoke "ruby"
7077 "-Ilib"
7078 "test/runner.rb")
0076f5a9 7079 #t))))))
1c8e6fd3
CB
7080 (native-inputs
7081 `(("ruby-rack" ,ruby-rack)))
7082 (synopsis
7083 "Make HTTP requests with support for HTTPS, Cookies, authentication and more")
7084 (description
7085 "The @code{httpclient} ruby library provides functionality related to
7086HTTP. Compared to the @code{net/http} library, @{httpclient} also provides
7087Cookie, multithreading and authentication (digest, NTLM) support.
7088
7089Also provided is a @command{httpclient} command, which can perform HTTP
7090requests either using arguments or with an interactive prompt.")
7091 (home-page "https://github.com/nahi/httpclient")
7092 (license license:ruby)))
7093
7d3a1a2d
BW
7094(define-public ruby-ansi
7095 (package
7096 (name "ruby-ansi")
7097 (version "1.5.0")
7098 (source
7099 (origin
3d30c332 7100 (method git-fetch)
7d3a1a2d 7101 ;; Fetch from GitHub as the gem does not contain testing code.
3d30c332
EF
7102 (uri (git-reference
7103 (url "https://github.com/rubyworks/ansi")
7104 (commit version)))
7105 (file-name (git-file-name name version))
7d3a1a2d
BW
7106 (sha256
7107 (base32
3d30c332 7108 "1wsz7xxwl3vkh277jb7fd7akqnqqgbvalxzpjwniiqk8ghfprbi5"))))
7d3a1a2d
BW
7109 (build-system ruby-build-system)
7110 (arguments
7111 `(#:phases
7112 (modify-phases %standard-phases
7113 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
7114 ;; cycle ansi, qed, ansi. Instead simply test that the library can
7115 ;; be require'd.
7116 (replace 'check
7117 (lambda _
9923d5a4 7118 (invoke "ruby" "-Ilib" "-r" "ansi")))
0899352f
MB
7119 (add-before 'validate-runpath 'replace-broken-symlink
7120 (lambda* (#:key outputs #:allow-other-keys)
7121 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
7122 (file (string-append
7123 out "/lib/ruby/vendor_ruby/gems/ansi-"
7124 ,version "/lib/ansi.yml")))
0899352f
MB
7125 ;; XXX: This symlink is broken since ruby 2.4.
7126 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
7127 (delete-file file)
7128 (symlink "../.index" file)
7129 #t))))))
7d3a1a2d
BW
7130 (synopsis "ANSI escape code related libraries")
7131 (description
7132 "This package is a collection of ANSI escape code related libraries
7133enabling ANSI colorization and stylization of console output. Included in the
7134library are the @code{Code} module, which defines ANSI codes as constants and
7135methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
7136@code{ProgressBar}, and a @code{String} subclass. The library also includes a
7137@code{Terminal} module which provides information about the current output
7138device.")
3d30c332 7139 (home-page "https://rubyworks.github.io/ansi/")
7d3a1a2d 7140 (license license:bsd-2)))
7c033c46
BW
7141
7142(define-public ruby-systemu
7143 (package
7144 (name "ruby-systemu")
7145 (version "2.6.5")
7146 (source
7147 (origin
7148 (method url-fetch)
7149 (uri (rubygems-uri "systemu" version))
7150 (sha256
7151 (base32
7152 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
7153 (build-system ruby-build-system)
7154 (arguments
7155 `(#:phases
7156 (modify-phases %standard-phases
7157 (add-before 'check 'set-version
7158 (lambda _
7159 (setenv "VERSION" ,version)
7160 #t)))))
7161 (synopsis "Capture of stdout/stderr and handling of child processes")
7162 (description
7163 "Systemu can be used on any platform to return status, stdout, and stderr
7164of any command. Unlike other methods like @code{open3} and @code{popen4}
7165there is no danger of full pipes or threading issues hanging your process or
7166subprocess.")
7167 (home-page "https://github.com/ahoward/systemu")
7168 (license license:ruby)))
3d84a99e
BW
7169
7170(define-public ruby-bio-commandeer
7171 (package
7172 (name "ruby-bio-commandeer")
37b08547 7173 (version "0.4.0")
3d84a99e
BW
7174 (source
7175 (origin
7176 (method url-fetch)
7177 (uri (rubygems-uri "bio-commandeer" version))
7178 (sha256
7179 (base32
37b08547 7180 "0khpfw1yl5l3d2m8nxpkk32ybc4c3pa5hic3agd160jdfjjjnlni"))))
3d84a99e
BW
7181 (build-system ruby-build-system)
7182 (arguments
7183 `(#:phases
7184 (modify-phases %standard-phases
7185 (replace 'check
7186 ;; Run test without calling 'rake' so that jeweler is
7187 ;; not required as an input.
7188 (lambda _
9923d5a4 7189 (invoke "rspec" "spec/bio-commandeer_spec.rb"))))))
3d84a99e
BW
7190 (propagated-inputs
7191 `(("ruby-bio-logger" ,ruby-bio-logger)
7192 ("ruby-systemu" ,ruby-systemu)))
7193 (native-inputs
7194 `(("bundler" ,bundler)
7195 ("ruby-rspec" ,ruby-rspec)))
7196 (synopsis "Simplified running of shell commands from within Ruby")
7197 (description
7198 "Bio-commandeer provides an opinionated method of running shell commands
7199from within Ruby. The advantage of bio-commandeer over other methods of
7200running external commands is that when something goes wrong, messages printed
7201to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
7202detail to ease debugging.")
7bf837fd 7203 (home-page "https://github.com/wwood/bioruby-commandeer")
3d84a99e 7204 (license license:expat)))
7c8131c7
BW
7205
7206(define-public ruby-rubytest
7207 (package
7208 (name "ruby-rubytest")
7209 (version "0.8.1")
7210 (source
7211 (origin
7212 (method url-fetch)
7213 (uri (rubygems-uri "rubytest" version))
7214 (sha256
7215 (base32
7216 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
7217 (build-system ruby-build-system)
7218 (arguments
7219 ;; Disable regular testing to break the cycle rubytest, qed, brass,
7220 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
7221 ;; simply test that the library can be require'd.
7222 `(#:phases
7223 (modify-phases %standard-phases
7224 (replace 'check
7225 (lambda _
9923d5a4 7226 (invoke "ruby" "-Ilib" "-r" "rubytest"))))))
7c8131c7
BW
7227 (propagated-inputs
7228 `(("ruby-ansi" ,ruby-ansi)))
7229 (synopsis "Universal test harness for Ruby")
7230 (description
7231 "Rubytest is a testing meta-framework for Ruby. It can handle any
7232compliant test framework and can run tests from multiple frameworks in a
7233single pass.")
2f3800e5 7234 (home-page "https://rubyworks.github.io/rubytest")
7c8131c7 7235 (license license:bsd-2)))
90fcedf2
BW
7236
7237(define-public ruby-brass
7238 (package
7239 (name "ruby-brass")
7240 (version "1.2.1")
7241 (source
7242 (origin
7243 (method url-fetch)
7244 (uri (rubygems-uri "brass" version))
7245 (sha256
7246 (base32
7247 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
7248 (build-system ruby-build-system)
7249 (arguments
7250 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
7251 ;; Instead simply test that the library can be require'd.
7252 `(#:phases
7253 (modify-phases %standard-phases
7254 (replace 'check
7255 (lambda _
9923d5a4 7256 (invoke "ruby" "-Ilib" "-r" "brass"))))))
90fcedf2
BW
7257 (synopsis "Basic foundational assertions framework")
7258 (description
7259 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
7260foundational assertions framework for other assertion and test frameworks to
7261make use of.")
2f3800e5 7262 (home-page "https://rubyworks.github.io/brass")
90fcedf2 7263 (license license:bsd-2)))
120fc74b
BW
7264
7265(define-public ruby-qed
7266 (package
7267 (name "ruby-qed")
7268 (version "2.9.2")
7269 (source
7270 (origin
7271 (method url-fetch)
7272 (uri (rubygems-uri "qed" version))
7273 (sha256
7274 (base32
7275 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
7276 (build-system ruby-build-system)
7277 (arguments
7278 ;; Disable testing to break the cycle qed, ansi, qed, among others.
7279 ;; Instead simply test that the executable runs using --copyright.
7280 `(#:phases
7281 (modify-phases %standard-phases
7282 (replace 'check
7283 (lambda _
9923d5a4 7284 (invoke "ruby" "-Ilib" "bin/qed" "--copyright"))))))
120fc74b
BW
7285 (propagated-inputs
7286 `(("ruby-ansi" ,ruby-ansi)
7287 ("ruby-brass" ,ruby-brass)))
7288 (synopsis "Test framework utilizing literate programming techniques")
7289 (description
7290 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
7291@dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
7292Development} (BDD) utilizing Literate Programming techniques. QED sits
7293somewhere between lower-level testing tools like @code{Test::Unit} and
7294requirement specifications systems like Cucumber.")
2f3800e5 7295 (home-page "https://rubyworks.github.io/qed")
120fc74b 7296 (license license:bsd-2)))
9273ee8f 7297
dbbe88d3
CB
7298(define-public ruby-que
7299 (package
7300 (name "ruby-que")
7301 (version "1.0.0.beta3")
7302 (source
7303 (origin
7304 (method url-fetch)
7305 (uri (rubygems-uri "que" version))
7306 (sha256
7307 (base32
7308 "0gr9pb814d4qj3ds98g6cjrdk7wv0yg8aqbm7c1lmgl87jkg8q04"))))
7309 (build-system ruby-build-system)
7310 (arguments
7311 '(#:tests? #f)) ; No included tests
7312 (synopsis "Job queue using PostgreSQL written in Ruby")
7313 (description
7314 "This package provides a job queue that uses PostgreSQL for storing jobs
7315and locking between worker processes.")
7316 (home-page "https://github.com/chanks/que")
7317 (license license:expat)))
7318
9273ee8f
BW
7319(define-public ruby-ae
7320 (package
7321 (name "ruby-ae")
7322 (version "1.8.2")
7323 (source
7324 (origin
11d1b318 7325 (method git-fetch)
9273ee8f 7326 ;; Fetch from github so tests are included.
11d1b318
EF
7327 (uri (git-reference
7328 (url "https://github.com/rubyworks/ae")
7329 (commit version)))
7330 (file-name (git-file-name name version))
9273ee8f
BW
7331 (sha256
7332 (base32
11d1b318 7333 "11299jj5ma8mi7b4majkyjy70y6zlqpgl8aql1c5lvfjavlpwmlp"))))
9273ee8f
BW
7334 (build-system ruby-build-system)
7335 (arguments
7336 `(#:phases
7337 (modify-phases %standard-phases
7338 (replace 'check
9923d5a4 7339 (lambda _ (invoke "qed")))
de6f6efd
MB
7340 (add-before 'validate-runpath 'replace-broken-symlink
7341 (lambda* (#:key outputs #:allow-other-keys)
7342 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
7343 (file (string-append
7344 out "/lib/ruby/vendor_ruby/gems/ae-"
7345 ,version "/lib/ae.yml")))
de6f6efd
MB
7346 ;; XXX: This symlink is broken since ruby 2.4.
7347 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
7348 (delete-file file)
7349 (symlink "../.index" file)
7350 #t))))))
9273ee8f
BW
7351 (propagated-inputs
7352 `(("ruby-ansi" ,ruby-ansi)))
7353 (native-inputs
7354 `(("ruby-qed" ,ruby-qed)))
7355 (synopsis "Assertions library")
7356 (description
7357 "Assertive Expressive (AE) is an assertions library specifically designed
7358for reuse by other test frameworks.")
11d1b318 7359 (home-page "https://rubyworks.github.io/ae/")
9273ee8f 7360 (license license:bsd-2)))
78bb471f
BW
7361
7362(define-public ruby-lemon
7363 (package
7364 (name "ruby-lemon")
7365 (version "0.9.1")
7366 (source
7367 (origin
7368 (method url-fetch)
7369 (uri (rubygems-uri "lemon" version))
7370 (sha256
7371 (base32
7372 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
7373 (build-system ruby-build-system)
7374 (arguments
7375 `(#:phases
7376 (modify-phases %standard-phases
9923d5a4 7377 (replace 'check (lambda _ (invoke "qed"))))))
78bb471f
BW
7378 (propagated-inputs
7379 `(("ruby-ae" ,ruby-ae)
7380 ("ruby-ansi" ,ruby-ansi)
7381 ("ruby-rubytest" ,ruby-rubytest)))
7382 (native-inputs
7383 `(("ruby-qed" ,ruby-qed)))
7384 (synopsis "Test framework correlating code structure and test unit")
7385 (description
7386 "Lemon is a unit testing framework that enforces highly formal
7387case-to-class and unit-to-method test construction. This enforcement can help
7388focus concern on individual units of behavior.")
2f3800e5 7389 (home-page "https://rubyworks.github.io/lemon")
78bb471f 7390 (license license:bsd-2)))
0832804e
BW
7391
7392(define-public ruby-rubytest-cli
7393 (package
7394 (name "ruby-rubytest-cli")
7395 (version "0.2.0")
7396 (source
7397 (origin
7398 (method url-fetch)
7399 (uri (rubygems-uri "rubytest-cli" version))
7400 (sha256
7401 (base32
7402 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
7403 (build-system ruby-build-system)
7404 (arguments
7405 `(#:tests? #f)) ; no tests
7406 (propagated-inputs
7407 `(("ruby-ansi" ,ruby-ansi)
7408 ("ruby-rubytest" ,ruby-rubytest)))
7409 (synopsis "Command-line interface for rubytest")
7410 (description
7411 "Rubytest CLI is a command-line interface for running tests for
7412Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
2f3800e5 7413 (home-page "https://rubyworks.github.io/rubytest-cli")
0832804e 7414 (license license:bsd-2)))
72ccbfe3
BW
7415
7416(define-public ruby-hashery
7417 (package
7418 (name "ruby-hashery")
cba96208 7419 (version "2.1.2")
72ccbfe3
BW
7420 (source
7421 (origin
7422 (method url-fetch)
7423 (uri (rubygems-uri "hashery" version))
7424 (sha256
7425 (base32
cba96208 7426 "0qj8815bf7q6q7llm5rzdz279gzmpqmqqicxnzv066a020iwqffj"))))
72ccbfe3
BW
7427 (build-system ruby-build-system)
7428 (arguments
7429 `(#:phases
7430 (modify-phases %standard-phases
7431 (replace 'check
7432 (lambda _
9923d5a4
TGR
7433 (invoke "qed")
7434 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
72ccbfe3
BW
7435 (native-inputs
7436 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
7437 ("ruby-qed" ,ruby-qed)
7438 ("ruby-lemon" ,ruby-lemon)))
7439 (synopsis "Hash-like classes with extra features")
7440 (description
7441 "The Hashery is a tight collection of @code{Hash}-like classes.
7442Included are the auto-sorting @code{Dictionary} class, the efficient
7443@code{LRUHash}, the flexible @code{OpenHash} and the convenient
7444@code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
7445defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
7446standard @code{Hash} making it possible to subclass and augment to fit any
7447specific use case.")
2f3800e5 7448 (home-page "https://rubyworks.github.io/hashery")
72ccbfe3 7449 (license license:bsd-2)))
1f1d71e0
BW
7450
7451(define-public ruby-rc4
7452 (package
7453 (name "ruby-rc4")
7454 (version "0.1.5")
7455 (source
7456 (origin
7457 (method url-fetch)
7458 (uri (rubygems-uri "ruby-rc4" version))
7459 (sha256
7460 (base32
7461 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
7462 (build-system ruby-build-system)
7463 (arguments
7464 `(#:phases
7465 (modify-phases %standard-phases
7466 (replace 'check
7467 (lambda _
9923d5a4 7468 (invoke "rspec" "spec/rc4_spec.rb"))))))
1f1d71e0
BW
7469 (native-inputs
7470 `(("ruby-rspec" ,ruby-rspec-2)))
7471 (synopsis "Implementation of the RC4 algorithm")
7472 (description
7473 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
7474 (home-page "https://github.com/caiges/Ruby-RC4")
7475 (license license:expat)))
f3e085a8
BW
7476
7477(define-public ruby-afm
7478 (package
7479 (name "ruby-afm")
7480 (version "0.2.2")
7481 (source
7482 (origin
7483 (method url-fetch)
7484 (uri (rubygems-uri "afm" version))
7485 (sha256
7486 (base32
7487 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
7488 (build-system ruby-build-system)
7489 (native-inputs
7490 `(("bundler" ,bundler)))
7491 (synopsis "Read Adobe Font Metrics (afm) files")
7492 (description
7493 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
7494files and use the data therein.")
7bf837fd 7495 (home-page "https://github.com/halfbyte/afm")
f3e085a8 7496 (license license:expat)))
acb6be42
BW
7497
7498(define-public ruby-ascii85
7499 (package
7500 (name "ruby-ascii85")
5854082a 7501 (version "1.0.3")
acb6be42
BW
7502 (source
7503 (origin
7504 (method url-fetch)
7505 (uri (rubygems-uri "Ascii85" version))
7506 (sha256
7507 (base32
5854082a 7508 "0658m37jjjn6drzqg1gk4p6c205mgp7g1jh2d00n4ngghgmz5qvs"))))
acb6be42
BW
7509 (build-system ruby-build-system)
7510 (native-inputs
7511 `(("bundler" ,bundler)))
7512 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
7513 (description
7514 "This library provides methods to encode and decode Ascii85
7515binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
7516@dfn{Portable Document Format} (PDF) file formats.")
7517 (home-page "https://github.com/datawraith/ascii85gem")
7518 (license license:expat)))
edf8caae
BW
7519
7520(define-public ruby-ttfunk
7521 (package
7522 (name "ruby-ttfunk")
afb7a3e8 7523 (version "1.5.1")
edf8caae
BW
7524 (source
7525 (origin
4e110825 7526 (method git-fetch)
edf8caae 7527 ;; fetch from github as the gem does not contain testing code
4e110825
EF
7528 (uri (git-reference
7529 (url "https://github.com/prawnpdf/ttfunk")
7530 (commit version)))
7531 (file-name (git-file-name name version))
edf8caae
BW
7532 (sha256
7533 (base32
4e110825 7534 "0dx9891zcli0sjrslmsvrwalv86hbjbqlmbrcasnjr069v05h9v9"))))
edf8caae
BW
7535 (build-system ruby-build-system)
7536 (arguments
7537 `(#:test-target "spec"
7538 #:phases
7539 (modify-phases %standard-phases
afb7a3e8
JL
7540 (add-before 'build 'remove-ssh
7541 (lambda _
7542 ;; remove dependency on an ssh key pair that doesn't exist
7543 (substitute* "ttfunk.gemspec"
7544 (("spec.signing_key.*") ""))
7545 #t))
edf8caae
BW
7546 (add-before 'check 'remove-rubocop
7547 (lambda _
7548 ;; remove rubocop as a dependency as not needed for testing
7549 (substitute* "ttfunk.gemspec"
7550 (("spec.add_development_dependency\\('rubocop'.*") ""))
7551 (substitute* "Rakefile"
7552 (("require 'rubocop/rake_task'") "")
afb7a3e8 7553 (("RuboCop::RakeTask.new") ""))
edf8caae
BW
7554 #t)))))
7555 (native-inputs
7556 `(("ruby-rspec" ,ruby-rspec)
afb7a3e8 7557 ("ruby-yard" ,ruby-yard)
edf8caae
BW
7558 ("bundler" ,bundler)))
7559 (synopsis "Font metrics parser for the Prawn PDF generator")
7560 (description
7561 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
7562part of the Prawn PDF generator.")
7563 (home-page "https://github.com/prawnpdf/ttfunk")
7564 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
7565 ;; for details."
7566 (license (list license:gpl2 license:gpl3 license:ruby))))
cbdd428c 7567
9270298f
BW
7568(define-public ruby-puma
7569 (package
7570 (name "ruby-puma")
63755fcd 7571 (version "3.9.1")
9270298f
BW
7572 (source
7573 (origin
a6cffe6e 7574 (method git-fetch)
9270298f 7575 ;; Fetch from GitHub because distributed gem does not contain tests.
a6cffe6e
EF
7576 (uri (git-reference
7577 (url "https://github.com/puma/puma")
7578 (commit (string-append "v" version))))
7579 (file-name (git-file-name name version))
9270298f
BW
7580 (sha256
7581 (base32
a6cffe6e 7582 "1kj75k81iik3aj73pkc9ixj9rwf95ipkyma65n28m64dgw02qi1f"))))
9270298f
BW
7583 (build-system ruby-build-system)
7584 (arguments
63755fcd
BW
7585 `(#:tests? #f ; Tests require an out-dated version of minitest.
7586 #:phases
9270298f
BW
7587 (modify-phases %standard-phases
7588 (add-before 'build 'fix-gemspec
7589 (lambda _
7590 (substitute* "puma.gemspec"
7591 (("git ls-files") "find * |sort"))
7592 #t)))))
9270298f
BW
7593 (synopsis "Simple, concurrent HTTP server for Ruby/Rack")
7594 (description
7595 "Puma is a simple, fast, threaded, and highly concurrent HTTP 1.1 server
7596for Ruby/Rack applications. Puma is intended for use in both development and
7597production environments. In order to get the best throughput, it is highly
7598recommended that you use a Ruby implementation with real threads like Rubinius
7599or JRuby.")
a6cffe6e 7600 (home-page "https://puma.io/")
9270298f
BW
7601 (license license:expat)))
7602
b0813490
BW
7603(define-public ruby-hoe-git
7604 (package
7605 (name "ruby-hoe-git")
7606 (version "1.6.0")
7607 (source
7608 (origin
7609 (method url-fetch)
7610 (uri (rubygems-uri "hoe-git" version))
7611 (sha256
7612 (base32
7613 "10jmmbjm0lkglwxbn4rpqghgg1ipjxrswm117n50adhmy8yij650"))))
7614 (build-system ruby-build-system)
7615 (propagated-inputs
7616 `(("ruby-hoe" ,ruby-hoe)
7617 ("git" ,git)))
7618 (synopsis "Hoe plugins for tighter Git integration")
7619 (description
7620 "This package provides a set of Hoe plugins for tighter Git integration.
7621It provides tasks to automate release tagging and pushing and changelog
7622generation.")
7bf837fd 7623 (home-page "https://github.com/jbarnette/hoe-git")
b0813490
BW
7624 (license license:expat)))
7625
cbdd428c
BW
7626(define-public ruby-sequel
7627 (package
7628 (name "ruby-sequel")
65a7f09c 7629 (version "4.49.0")
cbdd428c
BW
7630 (source
7631 (origin
7632 (method url-fetch)
7633 (uri (rubygems-uri "sequel" version))
7634 (sha256
7635 (base32
65a7f09c 7636 "010p4a60npppvgbyw7pq5xia8aydpgxdlhh3qjm2615kwjsw3fl8"))))
cbdd428c
BW
7637 (build-system ruby-build-system)
7638 (arguments
7639 '(#:tests? #f)) ; Avoid dependency loop with ruby-minitest-hooks.
7640 (synopsis "Database toolkit for Ruby")
7641 (description "Sequel provides thread safety, connection pooling and a
7642concise DSL for constructing SQL queries and table schemas. It includes a
7643comprehensive ORM layer for mapping records to Ruby objects and handling
7644associated records.")
e2b70d90 7645 (home-page "https://sequel.jeremyevans.net")
cbdd428c 7646 (license license:expat)))
3cc78097
BW
7647
7648(define-public ruby-timecop
7649 (package
7650 (name "ruby-timecop")
3d4a5eb5 7651 (version "0.9.1")
3cc78097
BW
7652 (source
7653 (origin
7654 (method url-fetch)
7655 (uri (rubygems-uri "timecop" version))
7656 (sha256
7657 (base32
3d4a5eb5 7658 "0d7mm786180v4kzvn1f77rhfppsg5n0sq2bdx63x9nv114zm8jrp"))))
3cc78097
BW
7659 (build-system ruby-build-system)
7660 (arguments
7661 `(#:phases
7662 (modify-phases %standard-phases
7663 (add-before 'check 'set-check-rubylib
7664 (lambda _
7665 ;; Set RUBYLIB so timecop tests finds its own lib.
7666 (setenv "RUBYLIB" "lib")
7667 #t)))))
7668 (native-inputs
7669 `(("bundler" ,bundler)
7670 ("ruby-minitest-rg" ,ruby-minitest-rg)
7671 ("ruby-mocha" ,ruby-mocha)
7672 ("ruby-activesupport" ,ruby-activesupport)))
66e07664 7673 (synopsis "Test mocks for time-dependent functions")
3cc78097
BW
7674 (description
7675 "Timecop provides \"time travel\" and \"time freezing\" capabilities,
7676making it easier to test time-dependent code. It provides a unified method to
7677mock @code{Time.now}, @code{Date.today}, and @code{DateTime.now} in a single
7678call.")
7679 (home-page "https://github.com/travisjeffery/timecop")
7680 (license license:expat)))
7681
dae620b8
BW
7682(define-public ruby-concurrent
7683 (package
7684 (name "ruby-concurrent")
1007640a 7685 (version "1.1.5")
dae620b8
BW
7686 (source
7687 (origin
8fcba3be 7688 (method git-fetch)
dae620b8
BW
7689 ;; Download from GitHub because the rubygems version does not contain
7690 ;; Rakefile.
8fcba3be
MB
7691 (uri (git-reference
7692 (url "https://github.com/ruby-concurrency/concurrent-ruby")
7693 (commit (string-append "v" version))))
7694 (file-name (git-file-name name version))
dae620b8
BW
7695 (sha256
7696 (base32
1007640a 7697 "193q2k47vk7qdvv9hlhmmdxgy91xl4imapyk1ijdg9vgf46knyzj"))))
dae620b8
BW
7698 (build-system ruby-build-system)
7699 (arguments
1007640a 7700 `(#:test-target "ci"
dae620b8
BW
7701 #:phases
7702 (modify-phases %standard-phases
520e89eb 7703 (add-before 'replace-git-ls-files 'remove-extra-gemspecs
dae620b8
BW
7704 (lambda _
7705 ;; Delete extra gemspec files so 'first-gemspec' chooses the
7706 ;; correct one.
7707 (delete-file "concurrent-ruby-edge.gemspec")
7708 (delete-file "concurrent-ruby-ext.gemspec")
7709 #t))
1007640a 7710 (replace 'replace-git-ls-files
520e89eb 7711 (lambda _
1007640a
MB
7712 ;; XXX: The default substitution made by this phase is not fully
7713 ;; compatible with "git ls-files". The latter produces file names
7714 ;; such as "lib/foo", whereas ruby-build-system uses "find . [...]"
7715 ;; which gives "./lib/foo". That difference in turn breaks the
7716 ;; comparison against a glob pattern in this script.
7717 (substitute* "concurrent-ruby.gemspec"
7718 (("git ls-files") "find * -type f | sort"))
7719 #t))
7720 (add-before 'build 'remove-jar-from-gemspec
520e89eb 7721 (lambda _
1007640a
MB
7722 ;; The gemspec wants to include a JAR file that we do not build
7723 ;; nor need.
7724 (substitute* "concurrent-ruby.gemspec"
7725 (("'lib/concurrent/concurrent_ruby.jar'")
7726 ""))
7727 #t))
7728 (add-before 'build 'remove-rake_compiler_dock-dependency
7729 (lambda _
7730 ;; This library is only used when building for non-MRI targets.
7731 (substitute* "Rakefile"
7732 (("require 'rake_compiler_dock'")
7733 ""))
520e89eb 7734 #t))
9019b37f
BW
7735 (add-before 'check 'remove-timecop-dependency
7736 ;; Remove timecop-dependent tests as having timecop as a depedency
7737 ;; causes circular depedencies.
7738 (lambda _
7739 (delete-file "spec/concurrent/executor/timer_set_spec.rb")
7740 (delete-file "spec/concurrent/scheduled_task_spec.rb")
7741 #t)))))
dae620b8
BW
7742 (native-inputs
7743 `(("ruby-rake-compiler" ,ruby-rake-compiler)
9019b37f 7744 ("ruby-rspec" ,ruby-rspec)))
dae620b8
BW
7745 (synopsis "Concurrency tools for Ruby")
7746 (description
7747 "This library provides modern concurrency tools including agents,
7748futures, promises, thread pools, actors, supervisors, and more. It is
7749inspired by Erlang, Clojure, Go, JavaScript, actors and classic concurrency
7750patterns.")
7751 (home-page "http://www.concurrent-ruby.com")
7752 (license license:expat)))
2de61e34
BW
7753
7754(define-public ruby-pkg-config
7755 (package
7756 (name "ruby-pkg-config")
884a80dd 7757 (version "1.2.5")
2de61e34
BW
7758 (source
7759 (origin
7760 (method url-fetch)
7761 (uri (rubygems-uri "pkg-config" version))
7762 (sha256
7763 (base32
884a80dd 7764 "056mzqdh4yjznsg36fi0xiq76f24vxlhzh2n4az919l3x5k318ar"))))
2de61e34
BW
7765 (build-system ruby-build-system)
7766 (arguments
7767 ;; Tests require extra files not included in the gem.
7768 `(#:tests? #f))
7769 (synopsis "Detect libraries for compiling Ruby native extensions")
7770 (description
7771 "@code{pkg-config} can be used in your extconf.rb to properly detect need
7772libraries for compiling Ruby native extensions.")
7773 (home-page "https://github.com/ruby-gnome2/pkg-config")
7774 (license license:lgpl2.0+)))
6689c636
MFM
7775
7776(define-public ruby-net-http-digest-auth
7777 (package
7778 (name "ruby-net-http-digest-auth")
ba074a85 7779 (version "1.4.1")
6689c636
MFM
7780 (source
7781 (origin
7782 (method url-fetch)
7783 (uri (rubygems-uri "net-http-digest_auth" version))
7784 (sha256
7785 (base32
ba074a85 7786 "1nq859b0gh2vjhvl1qh1zrk09pc7p54r9i6nnn6sb06iv07db2jb"))))
6689c636
MFM
7787 (build-system ruby-build-system)
7788 (native-inputs
7789 `(("ruby-hoe" ,ruby-hoe)))
7790 (synopsis "RFC 2617 HTTP digest authentication library")
7791 (description
7792 "This library implements HTTP's digest authentication scheme based on
7793RFC 2617. This enables the use of the digest authentication scheme instead
7794of the more insecure basic authentication scheme.")
7bf837fd 7795 (home-page "https://github.com/drbrain/net-http-digest_auth")
6689c636 7796 (license license:expat)))
06116573 7797
7798(define-public ruby-mail
7799 (package
7800 (name "ruby-mail")
04de0cb5 7801 (version "2.6.6")
06116573 7802 (source
7803 (origin
7804 (method url-fetch)
7805 (uri (rubygems-uri "mail" version))
7806 (sha256
7807 (base32
04de0cb5 7808 "0d7lhj2dw52ycls6xigkfz6zvfhc6qggply9iycjmcyj9760yvz9"))))
06116573 7809 (build-system ruby-build-system)
7810 (propagated-inputs
7811 `(("ruby-mime-types" ,ruby-mime-types)))
7812 (arguments
7813 ;; Tests require extra gems not included in the Gemfile.
7814 ;; XXX: Try enabling this for the next version with mini_mime.
7815 `(#:tests? #f))
7816 (synopsis "Mail library for Ruby")
7817 (description
7818 "Mail is an internet library for Ruby that is designed to handle email
7819generation, parsing and sending. The purpose of this library is to provide
7820a single point of access to handle all email functions, including sending
7821and receiving emails. All network type actions are done through proxy
7822methods to @code{Net::SMTP}, @code{Net::POP3} etc.
7823
7824Mail has been designed with a very simple object oriented system that
7825really opens up the email messages you are parsing, if you know what you
7826are doing, you can fiddle with every last bit of your email directly.")
7827 (home-page "https://github.com/mikel/mail")
7828 (license license:expat)))
9b4c8e1b 7829
4d372cb9
CB
7830(define-public ruby-mathn
7831 (package
7832 (name "ruby-mathn")
7833 (version "0.1.0")
7834 (source
7835 (origin
7836 (method url-fetch)
7837 (uri (rubygems-uri "mathn" version))
7838 (sha256
7839 (base32
7840 "1wn812llln9jzgybz2d7536q39z3gi99i6fi0j1dapcpzvhgrr0p"))))
7841 (build-system ruby-build-system)
7842 (native-inputs
7843 `(("bundler" ,bundler)
7844 ("ruby-rake-compiler" ,ruby-rake-compiler)))
7845 (synopsis "Extends math operations for increased precision")
7846 (description
7847 "This gem makes mathematical operations more precise in Ruby and
7848integrates other mathematical standard libraries. Prior to Ruby 2.5,
7849@code{mathn} was part of the Ruby standard library.")
7850 (home-page "https://github.com/ruby/mathn")
7851 (license license:bsd-2)))
7852
9b4c8e1b
BW
7853(define-public ruby-code-statistics
7854 (package
7855 (name "ruby-code-statistics")
7856 (version "0.2.13")
7857 (source
7858 (origin
7859 (method url-fetch)
7860 (uri (rubygems-uri "code_statistics" version))
7861 (sha256
7862 (base32
7863 "07rdpsbwbmh4vp8nxyh308cj7am2pbrfhv9v5xr2d5gq8hnnsm93"))))
7864 (build-system ruby-build-system)
7865 (arguments
7866 `(#:tests? #f)) ; Not all test code is included in gem.
7867 (synopsis "Port of the rails 'rake stats' method")
7868 (description
7869 "This gem is a port of the rails 'rake stats' method so it can be made
7870more robust and work for non rails projects.")
7871 (home-page "http://github.com/danmayer/code_statistics")
7872 (license license:expat)))
f90c25c1
CL
7873
7874(define-public ruby-rubypants
7875 (package
7876 (name "ruby-rubypants")
7877 (version "0.6.0")
7878 (source (origin
7879 (method url-fetch)
7880 (uri (rubygems-uri "rubypants" version))
7881 (sha256
7882 (base32
7883 "0xpqkslan2wkyal2h9qhplkr5d4sdn7q6csigrhnljjpp8j4qfsh"))))
7884 (build-system ruby-build-system)
7885 (arguments
7886 '(#:tests? #f)) ; need Codecov
7887 (synopsis "Port of the smart-quotes library SmartyPants")
7888 (description
7889 "RubyPants is a Ruby port of the smart-quotes library SmartyPants. The
7890original SmartyPants is a web publishing plug-in for Movable Type, Blosxom,
7891and BBEdit that easily translates plain ASCII punctuation characters into
7892smart typographic punctuation HTML entities.")
7893 (home-page "https://github.com/jmcnevin/rubypants")
7894 (license license:bsd-2)))
beb34835
CL
7895
7896(define-public ruby-org-ruby
7897 (package
7898 (name "ruby-org-ruby")
7899 (version "0.9.12")
7900 (source (origin
7901 (method url-fetch)
7902 (uri (rubygems-uri "org-ruby" version))
7903 (sha256
7904 (base32
7905 "0x69s7aysfiwlcpd9hkvksfyld34d8kxr62adb59vjvh8hxfrjwk"))))
7906 (build-system ruby-build-system)
7907 (arguments
7908 '(#:tests? #f)) ; no rakefile
7909 (propagated-inputs
7910 `(("ruby-rubypants" ,ruby-rubypants)))
7911 (synopsis "Org-mode parser written in Ruby")
7912 (description
7913 "Org-ruby is an org-mode parser written in Ruby. The most significant
7914thing this library does today is convert org-mode files to HTML or Textile or
7915Markdown.")
7916 (home-page "https://github.com/wallyqs/org-ruby")
7917 (license license:expat)))
670ee20a
BW
7918
7919(define-public ruby-rake
7920 (package
7921 (name "ruby-rake")
d6fb32b8 7922 (version "12.3.1")
670ee20a
BW
7923 (source
7924 (origin
7925 (method url-fetch)
7926 (uri (rubygems-uri "rake" version))
7927 (sha256
7928 (base32
d6fb32b8 7929 "1idi53jay34ba9j68c3mfr9wwkg3cd9qh0fn9cg42hv72c6q8dyg"))))
670ee20a
BW
7930 (build-system ruby-build-system)
7931 (native-inputs
7932 `(("bundler" ,bundler)))
7933 (synopsis "Rake is a Make-like program implemented in Ruby")
7934 (description
7935 "Rake is a Make-like program where tasks and dependencies are specified
7936in standard Ruby syntax.")
7937 (home-page "https://github.com/ruby/rake")
7938 (license license:expat)))
45498f51 7939
51420124 7940(define-public ruby-childprocess
45498f51
DM
7941 (package
7942 (name "ruby-childprocess")
459e4a1a 7943 (version "3.0.0")
45498f51
DM
7944 (source
7945 (origin
7946 (method url-fetch)
7947 (uri (rubygems-uri "childprocess" version))
7948 (sha256
7949 (base32
459e4a1a 7950 "1ic028k8xgm2dds9mqnvwwx3ibaz32j8455zxr9f4bcnviyahya5"))))
45498f51
DM
7951 (build-system ruby-build-system)
7952 (arguments
7953 `(#:tests? #f))
7954 (native-inputs
7955 `(("bundler" ,bundler)
7956 ("ruby-rspec" ,ruby-rspec)))
7957 (propagated-inputs
7958 `(("ruby-ffi" ,ruby-ffi)))
7959 (synopsis "Control external programs running in the background, in Ruby")
7960 (description "@code{childprocess} provides a gem to control external
7961programs running in the background, in Ruby.")
459e4a1a 7962 (home-page "https://github.com/enkessler/childprocess")
45498f51 7963 (license license:expat)))
1f10e28d 7964
0d16905b
JL
7965(define-public ruby-public-suffix
7966 (package
7967 (name "ruby-public-suffix")
9de12df7 7968 (version "4.0.1")
0d16905b
JL
7969 (source (origin
7970 (method url-fetch)
7971 (uri (rubygems-uri "public_suffix" version))
7972 (sha256
7973 (base32
9de12df7 7974 "0xnfv2j2bqgdpg2yq9i2rxby0w2sc9h5iyjkpaas2xknwrgmhdb0"))))
0d16905b
JL
7975 (build-system ruby-build-system)
7976 (arguments
1f4fc125
CB
7977 '(#:phases
7978 (modify-phases %standard-phases
7979 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
7980 ;; including it as an input can lead to circular dependencies.
7981 (add-after 'unpack 'remove-rubocop-from-Rakefile
7982 (lambda _
7983 (substitute* "Rakefile"
7984 (("require \"rubocop/rake\\_task\"") "")
7985 (("RuboCop::RakeTask\\.new") ""))
7986 #t)))))
7987 (native-inputs
7988 `(("bundler" ,bundler)
7989 ("ruby-yard" ,ruby-yard)
7990 ("ruby-mocha" ,ruby-mocha)
7991 ("ruby-minitest-reporters" ,ruby-minitest-reporters)))
0d16905b
JL
7992 (home-page "https://simonecarletti.com/code/publicsuffix-ruby/")
7993 (synopsis "Domain name parser")
7994 (description "The gem @code{public_suffix} is a domain name parser,
7995written in Ruby, and based on the @dfn{Public Suffix List}. A public suffix
7996is one under which Internet users can (or historically could) directly
7997register names. Some examples of public suffixes are @code{.com},
7998@code{.co.uk} and @code{pvt.k12.ma.us}. The Public Suffix List is a list of
7999all known public suffixes.")
8000 (license license:expat)))
6f2c4efb
JL
8001
8002(define-public ruby-addressable
8003 (package
8004 (name "ruby-addressable")
91f7ee87 8005 (version "2.7.0")
6f2c4efb
JL
8006 (source (origin
8007 (method url-fetch)
8008 (uri (rubygems-uri "addressable" version))
8009 (sha256
8010 (base32
91f7ee87 8011 "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy"))))
6f2c4efb 8012 (build-system ruby-build-system)
0a794b30
CB
8013 (arguments
8014 '(#:test-target "spec"
8015 #:phases
8016 (modify-phases %standard-phases
8017 (add-after 'unpack 'remove-unnecessary-dependencies-from-Gemfile
8018 (lambda _
8019 (substitute* "Gemfile"
8020 (("git: 'https://github.com/sporkmonger/rack-mount.git',") "")
8021 ((".*launchy.*") "")
8022 ((".*rake.*") "gem 'rake'\n")
8023 ((".*redcarpet.*") ""))
8024 #t))
8025 (add-before 'check 'delete-network-dependent-test
8026 (lambda _
8027 (delete-file "spec/addressable/net_http_compat_spec.rb")
8028 #t)))))
8029 (native-inputs
8030 `(("ruby-rspec" ,ruby-rspec)
8031 ("bundler" ,bundler)
8032 ("ruby-idn-ruby" ,ruby-idn-ruby)
8033 ("ruby-sporkmonger-rack-mount" ,ruby-sporkmonger-rack-mount)
8034 ("ruby-rspec-its", ruby-rspec-its)
8035 ("ruby-yard" ,ruby-yard)
8036 ("ruby-simplecov" ,ruby-simplecov)))
6f2c4efb
JL
8037 (propagated-inputs
8038 `(("ruby-public-suffix" ,ruby-public-suffix)))
6f2c4efb
JL
8039 (home-page "https://github.com/sporkmonger/addressable")
8040 (synopsis "Alternative URI implementation")
8041 (description "Addressable is a replacement for the URI implementation that
8042is part of Ruby's standard library. It more closely conforms to RFC 3986,
8043RFC 3987, and RFC 6570 (level 4), providing support for IRIs and URI templates.")
8044 (license license:asl2.0)))
9c7f15c0 8045
305e9b33
MB
8046(define-public ruby-colorize
8047 (package
8048 (name "ruby-colorize")
8049 (version "0.8.1")
8050 (source (origin
8051 (method url-fetch)
8052 (uri (rubygems-uri "colorize" version))
8053 (sha256
8054 (base32
8055 "133rqj85n400qk6g3dhf2bmfws34mak1wqihvh3bgy9jhajw580b"))))
8056 (build-system ruby-build-system)
8057 (arguments
8058 '(#:phases (modify-phases %standard-phases
8059 (add-before 'check 'remove-codeclimate-dependency
8060 (lambda _
8061 (substitute* "test/test_colorize.rb"
8062 ;; Do not hook the tests into the online CodeClimate
8063 ;; service which is unnecessary for these tests.
8064 (("require 'codeclimate-test-reporter'")
8065 "")
8066 (("CodeClimate.*") ""))
8067 #t)))))
8068 (synopsis "Add color effects to the @code{String} class")
8069 (description
8070 "This package extends the @code{String} class and adds a
8071@code{ColorizedString} with methods to set text color, background color,
8072and text effects.")
8073 (home-page "http://github.com/fazibear/colorize")
8074 (license license:gpl2+)))
8075
9c7f15c0
JL
8076(define-public ruby-colorator
8077 (package
8078 (name "ruby-colorator")
8079 (version "1.1.0")
8080 (source (origin
8081 (method url-fetch)
8082 (uri (rubygems-uri "colorator" version))
8083 (sha256
8084 (base32
8085 "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"))))
8086 (build-system ruby-build-system)
8087 (arguments
8088 ;; No test target
8089 `(#:tests? #f))
8090 (home-page "http://octopress.org/colorator/")
8091 (synopsis "Terminal color library")
8092 (description "Colorator is a Ruby gem that helps you colorize your text
8093for the terminal.")
8094 (license license:expat)))
78b9c291
JL
8095
8096(define-public ruby-command-line-reporter
8097 (package
8098 (name "ruby-command-line-reporter")
b448e408 8099 (version "4.0.1")
78b9c291
JL
8100 (source (origin
8101 (method url-fetch)
8102 (uri (rubygems-uri "command_line_reporter" version))
8103 (sha256
8104 (base32
b448e408 8105 "1l0zxkh5n9dxfw46lpkg416ljpldlq1bgdhqh0d118dk338nz4ll"))))
78b9c291
JL
8106 (build-system ruby-build-system)
8107 (arguments
8108 ;; No Rakefile
8109 `(#:tests? #f
8110 #:phases
8111 (modify-phases %standard-phases
8112 (add-before 'build 'fix-dependencies
8113 (lambda _
8114 (substitute* ".gemspec"
8115 ;; colored is unmaintained
8116 (("colored") "colorator")
8117 ;; colorator version
8118 (("= 1.2") "= 1.1"))
8119 #t)))))
8120 (propagated-inputs `(("ruby-colorator" ,ruby-colorator)))
8121 (home-page "https://github.com/wbailey/command_line_reporter")
8122 (synopsis "Report production while executing Ruby scripts")
8123 (description "This gem provides a DSL that makes it easy to write reports
8124of various types in ruby. It eliminates the need to litter your source with
8125puts statements, instead providing a more readable, expressive interface to
8126your application.")
8127 (license license:asl2.0)))
f22c0387
JL
8128
8129(define-public ruby-command-line-reporter-3
8130 (package
8131 (inherit ruby-command-line-reporter)
8132 (version "3.3.6")
8133 (source (origin
8134 (method url-fetch)
8135 (uri (rubygems-uri "command_line_reporter" version))
8136 (sha256
8137 (base32
8138 "1h39zqqxp3k4qk49ajpx0jps1vmvxgkh43mqkb6znk583bl0fv71"))))))
6bba8ecf
JL
8139
8140(define-public ruby-rdoc
8141 (package
8142 (name "ruby-rdoc")
8143 (version "6.0.4")
8144 (source
8145 (origin
8146 (method url-fetch)
8147 (uri (rubygems-uri "rdoc" version))
8148 (sha256
8149 (base32
8150 "0anv42cqcdc6g4n386mrva7mgav5i0c2ry3yzvzzc6z6hymkmcr7"))))
8151 (build-system ruby-build-system)
8152 (native-inputs
8153 `(("bundler" ,bundler)))
8154 (home-page "https://ruby.github.io/rdoc/")
8155 (synopsis "HTML and command-line documentation utility")
8156 (description "RDoc produces HTML and command-line documentation for Ruby
8157projects. RDoc includes the +rdoc+ and +ri+ tools for generating and displaying
8158documentation from the command-line.")
8159 (license license:gpl2+)))
18077ffc
JL
8160
8161(define-public ruby-sass-listen
8162 (package
8163 (name "ruby-sass-listen")
8164 (version "4.0.0")
8165 (source (origin
8166 (method url-fetch)
8167 (uri (rubygems-uri "sass-listen" version))
8168 (sha256
8169 (base32
8170 "0xw3q46cmahkgyldid5hwyiwacp590zj2vmswlll68ryvmvcp7df"))))
8171 (build-system ruby-build-system)
8172 (arguments
8173 ;; No test target
8174 `(#:tests? #f))
8175 (propagated-inputs
8176 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
8177 ("ruby-rb-inotify" ,ruby-rb-inotify)))
8178 (home-page "https://github.com/sass/listen")
8179 (synopsis "File modification notification library")
8180 (description "The Listen gem listens to file modifications and notifies you
8181about the changes.")
8182 (license license:expat)))
0c8eedc1
JL
8183
8184(define-public ruby-terminfo
8185 (package
8186 (name "ruby-terminfo")
8187 (version "0.1.1")
8188 (source
8189 (origin
8190 (method url-fetch)
8191 (uri (rubygems-uri "ruby-terminfo" version))
8192 (sha256
8193 (base32
8194 "0rl4ic5pzvrpgd42z0c1s2n3j39c9znksblxxvmhkzrc0ckyg2cm"))))
8195 (build-system ruby-build-system)
8196 (arguments
8197 `(#:test-target "test"
8198 ;; Rakefile requires old packages and would need modification to
8199 ;; work with current software.
8200 #:tests? #f))
8201 (inputs
8202 `(("ncurses" ,ncurses)))
8203 (native-inputs
8204 `(("ruby-rubygems-tasks" ,ruby-rubygems-tasks)
8205 ("ruby-rdoc" ,ruby-rdoc)))
8206 (home-page "http://www.a-k-r.org/ruby-terminfo/")
8207 (synopsis "Terminfo binding for Ruby")
8208 (description "Ruby-terminfo provides terminfo binding for Ruby.")
8209 (license license:bsd-3)))
ddc3a667
JL
8210
8211(define-public ruby-diffy
8212 (package
8213 (name "ruby-diffy")
8214 (version "3.2.1")
8215 (source
8216 (origin
8217 (method url-fetch)
8218 (uri (rubygems-uri "diffy" version))
8219 (sha256
8220 (base32
8221 "119imrkn01agwhx5raxhknsi331y5i4yda7r0ws0an6905ximzjg"))))
8222 (build-system ruby-build-system)
8223 (arguments
8224 ;; No tests
8225 `(#:tests? #f))
8226 (native-inputs
8227 `(("ruby-rspec" ,ruby-rspec)))
8228 (home-page "https://github.com/samg/diffy")
8229 (synopsis "Convenient diffing in ruby")
8230 (description "Diffy provides a convenient way to generate a diff from two
8231strings or files.")
8232 (license license:expat)))
6456beef
JL
8233
8234(define-public ruby-sass-spec
8235 (package
8236 (name "ruby-sass-spec")
8237 (version "3.5.4")
11df8321
TGR
8238 (source
8239 (origin
8240 (method git-fetch)
8241 (uri (git-reference
8242 (url "https://github.com/sass/sass-spec.git")
8243 (commit (string-append "v" version))))
8244 (file-name (git-file-name name version))
8245 (sha256
8246 (base32 "1zsw66830w0xlc7kxz6fm4b5nyb44vdsdgm9mgy06s5aixx83pwr"))))
6456beef
JL
8247 (build-system ruby-build-system)
8248 (propagated-inputs
8249 `(("ruby-command-line-reporter-3" ,ruby-command-line-reporter-3)
8250 ("ruby-diffy" ,ruby-diffy)
8251 ("ruby-terminfo" ,ruby-terminfo)))
8252 (arguments
2c7cb711
CB
8253 `(;; This package contains tests for a sass implementation, and the to
8254 ;; avoid any circular dependencies, the tests are not run here
8255 #:tests? #f
8256 #:phases
8257 (modify-phases %standard-phases
8258 (add-after 'unpack 'patch-test
8259 (lambda _
8260 (delete-file "spec/values/colors/alpha_hex-3.5/error")
8261 (substitute* "spec/values/colors/alpha_hex-3.5/expected_output.css"
8262 (("string") "color")))))))
6456beef
JL
8263 (home-page "https://github.com/sass/sass-spec")
8264 (synopsis "Test suite for Sass")
8265 (description "Sass Spec is a test suite for Sass. Test cases are all in
8266the @file{spec} directory.")
8267 (license license:expat)))
f00f4492
JL
8268
8269(define-public ruby-sass
8270 (package
8271 (name "ruby-sass")
11ff2adc 8272 (version "3.6.0")
f00f4492
JL
8273 (source (origin
8274 (method url-fetch)
8275 (uri (rubygems-uri "sass" version))
8276 (sha256
8277 (base32
11ff2adc 8278 "18c6prbw9wl8bqhb2435pd9s0lzarl3g7xf8pmyla28zblvwxmyh"))))
f00f4492
JL
8279 (build-system ruby-build-system)
8280 (propagated-inputs
8281 `(("ruby-sass-listen" ,ruby-sass-listen)))
8282 (native-inputs
11ff2adc
CB
8283 `(("ruby-sass-spec" ,ruby-sass-spec)
8284 ("ruby-mathn" ,ruby-mathn)))
3497086b 8285 (home-page "https://sass-lang.com/")
f00f4492
JL
8286 (synopsis "CSS extension language")
8287 (description "Sass is a CSS extension language. It extends CSS with
8288features that don't exist yet like variables, nesting, mixins and inheritance.")
8289 (license license:expat)))
5e242cb4 8290
9efc888d
CB
8291(define-public ruby-sassc
8292 (package
8293 (name "ruby-sassc")
3e776b44 8294 (version "2.2.1")
9efc888d
CB
8295 (source
8296 (origin
8297 (method url-fetch)
8298 (uri (rubygems-uri "sassc" version))
8299 (sha256
8300 (base32
3e776b44 8301 "09bnid7r5z5hcin5hykvpvv8xig27wbbckxwis60z2aaxq4j9siz"))))
9efc888d
CB
8302 (build-system ruby-build-system)
8303 (arguments
3e776b44
CB
8304 '(#:modules ((guix build ruby-build-system)
8305 (guix build utils)
8306 (ice-9 textual-ports))
8307 #:phases
9efc888d
CB
8308 (modify-phases %standard-phases
8309 ;; TODO: This would be better as a snippet, but the ruby-build-system
8310 ;; doesn't seem to support that
8311 (add-after 'unpack 'remove-libsass
8312 (lambda _
8313 (delete-file-recursively "ext")
3e776b44
CB
8314 (with-atomic-file-replacement "sassc.gemspec"
8315 (lambda (in out)
8316 (let* ((gemspec (get-string-all in))
8317 (index (string-contains gemspec "libsass_dir")))
8318 (display (string-append
8319 (string-take gemspec index)
8320 "\nend\n")
8321 out))))
9efc888d
CB
8322 #t))
8323 (add-after 'unpack 'dont-check-the-libsass-version
8324 (lambda _
8325 (substitute* "test/native_test.rb"
8326 (("assert_equal.*Native\\.version") ""))
8327 #t))
8328 (add-after 'unpack 'remove-git-from-gemspec
8329 (lambda _
8330 (substitute* "sassc.gemspec"
3e776b44 8331 (("`git ls-files -z`") "`find . -type f -print0 |sort -z`"))
9efc888d
CB
8332 #t))
8333 (add-after 'unpack 'remove-extensions-from-gemspec
8334 (lambda _
8335 (substitute* "sassc.gemspec"
3e776b44 8336 (("\\[\"ext/extconf.rb\"\\]") "[]"))
9efc888d
CB
8337 #t))
8338 (add-after 'unpack 'fix-Rakefile
8339 (lambda _
8340 (substitute* "Rakefile"
3e776b44 8341 (("test: 'compile:libsass'") ":test"))
9efc888d
CB
8342 #t))
8343 (add-after 'unpack 'remove-unnecessary-dependencies
8344 (lambda _
8345 (substitute* "test/test_helper.rb"
8346 (("require \"pry\"") ""))
8347 #t))
8348 (add-before 'build 'patch-native.rb
8349 (lambda* (#:key inputs #:allow-other-keys)
8350 (substitute* "lib/sassc/native.rb"
8351 ((".*gem_root = spec.gem_dir") "")
8352 (("ffi_lib .*\n")
8353 (string-append
8354 "ffi_lib '" (assoc-ref inputs "libsass") "/lib/libsass.so'")))
8355 #t))
8356 ;; The gemspec still references the libsass files, so just keep the
8357 ;; one in the gem.
8358 (delete 'extract-gemspec))))
8359 (propagated-inputs
8360 `(("ruby-ffi" ,ruby-ffi)
8361 ("ruby-rake" ,ruby-rake)))
8362 (inputs
8363 `(("libsass" ,libsass)))
8364 (native-inputs
8365 `(("bundler" ,bundler)
3e776b44 8366 ("ruby-rake-compiler" ,ruby-rake-compiler)
9efc888d
CB
8367 ("ruby-minitest-around" ,ruby-minitest-around)
8368 ("ruby-test-construct" ,ruby-test-construct)))
8369 (synopsis "Use libsss from Ruby")
8370 (description
8371 "This library provides Ruby q@acronym{FFI, Foreign Function Interface}
8372bindings to the libsass library. This enables rendering
8373@acronym{SASS,Syntactically awesome style sheets} from Ruby code.")
8374 (home-page "https://github.com/sass/sassc-ruby")
8375 (license license:expat)))
8376
5e242cb4
JL
8377(define-public ruby-jekyll-sass-converter
8378 (package
8379 (name "ruby-jekyll-sass-converter")
8380 (version "1.5.2")
8381 (source (origin
8382 (method url-fetch)
8383 (uri (rubygems-uri "jekyll-sass-converter" version))
8384 (sha256
8385 (base32
8386 "008ikh5fk0n6ri54mylcl8jn0mq8p2nfyfqif2q3pp0lwilkcxsk"))))
8387 (build-system ruby-build-system)
8388 (propagated-inputs
8389 `(("ruby-sass" ,ruby-sass)))
8390 (arguments
8391 ;; No rakefile
8392 `(#:tests? #f))
8393 (home-page "https://github.com/jekyll/jekyll-sass-converter")
8394 (synopsis "Sass converter for Jekyll")
8395 (description "This gem provide built-in support for the Sass converter
8396in Jekyll.")
8397 (license license:expat)))
ceac6f6f
JL
8398
8399(define-public ruby-jekyll-watch
8400 (package
8401 (name "ruby-jekyll-watch")
6cbba8a3 8402 (version "2.1.2")
ceac6f6f
JL
8403 (source (origin
8404 (method url-fetch)
8405 (uri (rubygems-uri "jekyll-watch" version))
8406 (sha256
8407 (base32
6cbba8a3 8408 "1s9ly83sp8albvgdff12xy2h4xd8lm6z2fah4lzmk2yvp85jzdzv"))))
ceac6f6f
JL
8409 (build-system ruby-build-system)
8410 (propagated-inputs
6cbba8a3 8411 `(("ruby-listen" ,ruby-listen)))
ceac6f6f
JL
8412 (arguments
8413 ;; No rakefile
8414 `(#:tests? #f))
8415 (home-page "https://github.com/jekyll/jekyll-watch")
8416 (synopsis "Jekyll auto-rebuild support")
8417 (description "This gems add the @code{--watch} switch to the jekyll CLI
8418interface. It allows Jekyll to rebuild your site when a file changes.")
8419 (license license:expat)))
3224a5a8
JL
8420
8421(define-public ruby-parallel
8422 (package
8423 (name "ruby-parallel")
c41fba01
CB
8424 (version "1.13.0")
8425 (source
8426 (origin
8427 (method git-fetch)
8428 (uri (git-reference
8429 (url "https://github.com/grosser/parallel.git")
8430 (commit (string-append "v" version))))
8431 (file-name (git-file-name name version))
8432 (sha256
8433 (base32
8434 "1isqzbqxz2ndad4i5z3lb9ldrhaijfncj8bmffv04sq44sv87ikv"))))
3224a5a8 8435 (build-system ruby-build-system)
c41fba01
CB
8436 (arguments
8437 `(;; TODO 3 test failures
8438 ;; rspec ./spec/parallel_spec.rb:190 # Parallel.in_processes does not
8439 ;; open unnecessary pipes
8440 ;; rspec './spec/parallel_spec.rb[1:9:7]' # Parallel.each works with
8441 ;; SQLite in processes
8442 ;; rspec './spec/parallel_spec.rb[1:9:16]' # Parallel.each works with
8443 ;; SQLite in threads
8444 #:tests? #f
8445 #:test-target "rspec-rerun:spec"
8446 #:phases
8447 (modify-phases %standard-phases
8448 (add-after 'unpack 'patch-Gemfile
8449 (lambda _
8450 (substitute* "Gemfile"
8451 (("gem 'rspec-legacy_formatters'") "")
8452 (("gem 'activerecord.*$") "gem 'activerecord'\n"))))
8453 (add-before 'check 'delete-Gemfile.lock
8454 (lambda _
8455 ;; Bundler isn't being used for fetching dependendencies, so
8456 ;; delete the Gemfile.lock
8457 (delete-file "Gemfile.lock")
8458 #t))
8459 (add-before 'build 'patch-gemspec
8460 (lambda _
8461 (substitute* "parallel.gemspec"
8462 (("git ls-files") "find"))
8463 #t)))))
8464 (native-inputs
8465 `(("ruby-rspec" ,ruby-rspec)
8466 ("ruby-rspec-rerun" ,ruby-rspec-rerun)
8467 ("bundler" ,bundler)
8468 ("ruby-activerecord" ,ruby-activerecord)
8469 ("ruby-progressbar" ,ruby-progressbar)
8470 ("ruby-bump" ,ruby-bump)
8471 ("procps" ,procps)
8472 ("lsof" ,lsof)
8473 ("ruby-mysql2" ,ruby-mysql2)
8474 ("ruby-sqlite3" ,ruby-sqlite3)
8475 ("ruby-i18n" ,ruby-i18n)))
3224a5a8
JL
8476 (home-page "https://github.com/grosser/parallel")
8477 (synopsis "Parallel processing in Ruby")
8478 (description "Parallel allows you to run any code in parallel Processes
8479(to use all CPUs) or Threads(to speedup blocking operations). It is best
8480suited for map-reduce or e.g. parallel downloads/uploads.")
8481 (license license:expat)))
83d9f672
JL
8482
8483(define-public ruby-cane
8484 (package
8485 (name "ruby-cane")
8486 (version "3.0.0")
8487 (source (origin
8488 (method url-fetch)
8489 (uri (rubygems-uri "cane" version))
8490 (sha256
8491 (base32
8492 "0yf5za3l7lhrqa3g56sah73wh33lbxy5y3cb7ij0a2bp1b4kwhih"))))
8493 (build-system ruby-build-system)
8494 (arguments `(#:tests? #f)); No rakefile
8495 (home-page "https://github.com/square/cane")
8496 (propagated-inputs
8497 `(("ruby-parallel" ,ruby-parallel)))
8498 (synopsis "Code quality threshold checking")
8499 (description "Cane fails your build if code quality thresholds are not met.")
8500 (license license:asl2.0)))
00d71efc
JL
8501
8502(define-public ruby-morecane
8503 (package
8504 (name "ruby-morecane")
8505 (version "0.2.0")
8506 (source (origin
8507 (method url-fetch)
8508 (uri (rubygems-uri "morecane" version))
8509 (sha256
8510 (base32
8511 "0w70vb8z5bdhvr21h660aa43m5948pv0bd27z7ngai2iwdvqd771"))))
8512 (build-system ruby-build-system)
8513 (home-page "https://github.com/yob/morecane")
8514 (arguments `(#:tests? #f)); No rakefile
8515 (propagated-inputs
8516 `(("ruby-parallel" ,ruby-parallel)))
8517 (synopsis "Extra checks for cane")
8518 (description "The cane gem provides a great framework for running quality
8519checks over your ruby project as part of continuous integration build. It
8520comes with a few checks out of the box, but also provides an API for loading
8521custom checks. This gem provides a set of additional checks.")
8522 (license license:expat)))
abbe629c
JL
8523
8524(define-public ruby-pdf-reader
8525 (package
8526 (name "ruby-pdf-reader")
8527 (version "2.1.0")
8528 (source (origin
8529 (method url-fetch)
8530 (uri (rubygems-uri "pdf-reader" version))
8531 (sha256
8532 (base32
8533 "1b3ig4wpcgdbqa7yw0ahwbmikkkywn2a22bfmrknl5ls7g066x45"))))
8534 (build-system ruby-build-system)
8535 (arguments `(#:test-target "spec"))
8536 (native-inputs
8537 `(("bundler" ,bundler)
8538 ("ruby-rspec" ,ruby-rspec)
8539 ("ruby-cane" ,ruby-cane)
8540 ("ruby-morecane" ,ruby-morecane)))
8541 (propagated-inputs
8542 `(("ruby-afm" ,ruby-afm)
8543 ("ruby-ascii85" ,ruby-ascii85)
8544 ("ruby-hashery" ,ruby-hashery)
8545 ("ruby-rc4" ,ruby-rc4)
8546 ("ruby-ttfunk" ,ruby-ttfunk)))
8547 (home-page "https://github.com/yob/pdf-reader")
8548 (synopsis "PDF parser in Ruby")
8549 (description "The PDF::Reader library implements a PDF parser conforming as
8550much as possible to the PDF specification from Adobe. It provides programmatic
8551access to the contents of a PDF file with a high degree of flexibility.")
8552 (license license:gpl3+)))
461fb859
JL
8553
8554(define-public ruby-pdf-inspector
8555 (package
8556 (name "ruby-pdf-inspector")
8557 (version "1.3.0")
8558 (source (origin
8559 (method url-fetch)
8560 (uri (rubygems-uri "pdf-inspector" version))
8561 (sha256
8562 (base32
8563 "1g853az4xzgqxr5xiwhb76g4sqmjg4s79mm35mp676zjsrwpa47w"))))
8564 (build-system ruby-build-system)
8565 (propagated-inputs
8566 `(("ruby-pdf-reader" ,ruby-pdf-reader)))
8567 (arguments `(#:tests? #f)); No rakefile
8568 (home-page "https://github.com/prawnpdf/pdf-inspector")
8569 (synopsis "Analysis classes for inspecting PDF output")
8570 (description "This library provides a number of PDF::Reader based tools for
8571use in testing PDF output. Presently, the primary purpose of this tool is to
8572support the tests found in Prawn, a pure Ruby PDF generation library.")
8573 (license license:gpl3+)))
770e3b53
JL
8574
8575(define-public ruby-pdf-core
8576 (package
8577 (name "ruby-pdf-core")
8578 (version "0.8.1")
8579 (source (origin
8580 (method url-fetch)
8581 (uri (rubygems-uri "pdf-core" version))
8582 (sha256
8583 (base32
8584 "15d6m99bc8bbzlkcg13qfpjjzphfg5x905pjbfygvpcxsm8gnsvg"))))
8585 (build-system ruby-build-system)
8586 (arguments
8587 ; No test target
8588 `(#:tests? #f))
8589 (home-page "https://github.com/prawnpdf/pdf-core")
8590 (synopsis "Low level PDF features for Prawn")
8591 (description "This is an experimental gem that extracts low-level PDF
8592functionality from Prawn.")
8593 (license license:gpl3+)))
37fbced7 8594
7ad8dd08
JL
8595(define-public ruby-prawn
8596 (package
8597 (name "ruby-prawn")
8598 (version "2.2.2")
8599 (source (origin
8600 (method url-fetch)
8601 (uri (rubygems-uri "prawn" version))
8602 (sha256
8603 (base32
8604 "1qdjf1v6sfl44g3rqxlg8k4jrzkwaxgvh2l4xws97a8f3xv4na4m"))))
8605 (build-system ruby-build-system)
8606 (arguments
8607 ; No tests
8608 `(#:tests? #f
8609 #:phases
8610 (modify-phases %standard-phases
8611 (add-before 'build 'fix-dependencies
8612 (lambda _
8613 (substitute* "prawn.gemspec"
8614 (("~> 0.7.0") "~> 0.7"))
8615 #t)))))
8616 (propagated-inputs
8617 `(("ruby-pdf-core" ,ruby-pdf-core)
8618 ("ruby-ttfunk" ,ruby-ttfunk)))
8619 (native-inputs
8620 `(("bundler" ,bundler)
8621 ("ruby-pdf-inspector" ,ruby-pdf-inspector)
8622 ("ruby-rspec" ,ruby-rspec)
8623 ("ruby-simplecov" ,ruby-simplecov)
8624 ("ruby-yard" ,ruby-yard)))
8625 (home-page "http://prawnpdf.org/api-docs/2.0/")
8626 (synopsis "PDF generation for Ruby")
8627 (description "Prawn is a pure Ruby PDF generation library.")
8628 (license license:gpl3+)))
197ca8ec
JL
8629
8630(define-public ruby-prawn-table
8631 (package
8632 (name "ruby-prawn-table")
8633 (version "0.2.2")
8634 (source (origin
8635 (method url-fetch)
8636 (uri (rubygems-uri "prawn-table" version))
8637 (sha256
8638 (base32
8639 "1nxd6qmxqwl850icp18wjh5k0s3amxcajdrkjyzpfgq0kvilcv9k"))))
8640 (build-system ruby-build-system)
197ca8ec 8641 (propagated-inputs
0927b039
CB
8642 `(("ruby-prawn" ,ruby-prawn)
8643 ("ruby-pdf-inspector" ,ruby-pdf-inspector)))
8644 (native-inputs
8645 `(("bundler" ,bundler)
8646 ("ruby-yard" ,ruby-yard)
8647 ("ruby-mocha" ,ruby-mocha)
8648 ("ruby-coderay" ,ruby-coderay)
8649 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
8650 ("ruby-simplecov" ,ruby-simplecov)
8651 ("ruby-rspec-2" ,ruby-rspec-2)))
8652 (arguments
8653 '(;; TODO: 1 test fails
8654 ;; Failure/Error: pdf.page_count.should == 1
8655 ;; expected: 1
8656 ;; got: 2 (using ==)
8657 ;; # ./spec/table_spec.rb:1308
8658 ;;
8659 ;; 225 examples, 1 failure
8660 #:tests? #f
8661 #:phases
8662 (modify-phases %standard-phases
8663 (add-before 'check 'patch-gemspec
8664 (lambda _
8665 (substitute* "prawn-table.gemspec"
8666 ;; Loosen the requirement for pdf-inspector
8667 (("~> 1\\.1\\.0") ">= 0")
8668 ;; Loosen the requirement for pdf-reader
8669 (("~> 1\\.2") ">= 0"))))
8670 (replace 'check
8671 (lambda* (#:key tests? #:allow-other-keys)
8672 (when tests?
8673 (invoke "rspec"))
8674 #t)))))
197ca8ec
JL
8675 (home-page "https://github.com/prawnpdf/prawn-table")
8676 (synopsis "Tables support for Prawn")
8677 (description "This gem provides tables support for Prawn.")
8678 (license license:gpl3+)))
03127069
JL
8679
8680(define-public ruby-kramdown
8681 (package
8682 (name "ruby-kramdown")
8683 (version "1.17.0")
8684 (source (origin
8685 (method url-fetch)
8686 (uri (rubygems-uri "kramdown" version))
8687 (sha256
8688 (base32
8689 "1n1c4jmrh5ig8iv1rw81s4mw4xsp4v97hvf8zkigv4hn5h542qjq"))))
8690 (build-system ruby-build-system)
8691 (arguments `(#:tests? #f)); FIXME: some test failures
8692 (native-inputs
8693 `(("ruby-prawn" ,ruby-prawn)
8694 ("ruby-prawn-table" ,ruby-prawn-table)))
8695 (home-page "https://kramdown.gettalong.org/")
8696 (synopsis "Markdown parsing and converting library")
8697 (description "Kramdown is a library for parsing and converting a superset
8698of Markdown. It is completely written in Ruby, supports standard Markdown
8699(with some minor modifications) and various extensions that have been made
8700popular by the PHP @code{Markdown Extra} package and @code{Maruku}.")
8701 (license license:expat)))
fa0063bc
JL
8702
8703(define-public ruby-http-parser.rb
8704 (package
8705 (name "ruby-http-parser.rb")
8706 (version "0.6.0")
8707 (source
8708 (origin
8709 (method url-fetch)
8710 (uri (rubygems-uri "http_parser.rb" version))
8711 (sha256
8712 (base32
8713 "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"))))
8714 (build-system ruby-build-system)
8715 (arguments
8716 ;; No tests
8717 `(#:tests? #f))
8718 (native-inputs
8719 `(("ruby-rake-compiler" ,ruby-rake-compiler)
8720 ("ruby-rspec" ,ruby-rspec)))
8721 (home-page "https://github.com/tmm1/http_parser.rb")
8722 (synopsis "HTTP parser un Ruby")
8723 (description "This gem is a simple callback-based HTTP request/response
8724parser for writing http servers, clients and proxies.")
8725 (license license:expat)))
5e2f74bd
JL
8726
8727(define-public ruby-em-websocket
8728 (package
8729 (name "ruby-em-websocket")
8730 (version "0.5.1")
8731 (source
8732 (origin
8733 (method url-fetch)
8734 (uri (rubygems-uri "em-websocket" version))
8735 (sha256
8736 (base32
8737 "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"))))
8738 (build-system ruby-build-system)
8739 (arguments
8740 ;; No tests
8741 `(#:tests? #f))
8742 (propagated-inputs
8743 `(("ruby-eventmachine" ,ruby-eventmachine)
8744 ("ruby-http-parser.rb" ,ruby-http-parser.rb)))
8745 (native-inputs
8746 `(("bundler" ,bundler)
8747 ("ruby-rspec" ,ruby-rspec)))
8748 (home-page "https://github.com/igrigorik/em-websocket")
8749 (synopsis "EventMachine based WebSocket server")
8750 (description "Em-websocket is an EventMachine based WebSocket server
8751implementation.")
8752 (license license:expat)))
4ce0414b
JL
8753
8754(define-public ruby-rouge
8755 (package
8756 (name "ruby-rouge")
55cc5ef8 8757 (version "3.13.0")
4ce0414b
JL
8758 (source (origin
8759 (method url-fetch)
8760 (uri (rubygems-uri "rouge" version))
8761 (sha256
8762 (base32
55cc5ef8 8763 "1y90nx9ph9adnrpcsvs2adca2l3dyz8am2d2kzxkwd3a086ji7aw"))))
4ce0414b
JL
8764 (build-system ruby-build-system)
8765 (arguments `(#:tests? #f)); No rakefile
8766 (home-page "http://rouge.jneen.net/")
8767 (synopsis "Code highlighter")
8768 (description "Rouge is a code highlighter written in Ruby. It supports more
8769than 100 languages and outputs HTML or ANSI 256-color text. Its HTML output
8770is compatible with stylesheets designed for pygments.")
8771 (license (list
8772 ;; rouge is licensed under expat
8773 license:expat
8774 ;; pygments is licensed under bsd-2
8775 license:bsd-2))))
2c5028bd
JL
8776
8777(define-public ruby-rouge-2
8778 (package
8779 (inherit ruby-rouge)
8780 (version "2.2.1")
8781 (source (origin
8782 (method url-fetch)
8783 (uri (rubygems-uri "rouge" version))
8784 (sha256
8785 (base32
8786 "02kpahk5nkc33yxnn75649kzxaz073wvazr2zyg491nndykgnvcs"))))))
2e072e37
JL
8787
8788(define-public ruby-hashie
8789 (package
8790 (name "ruby-hashie")
8791 (version "3.6.0")
8792 (source (origin
8793 (method url-fetch)
8794 (uri (rubygems-uri "hashie" version))
8795 (sha256
8796 (base32
8797 "13bdzfp25c8k51ayzxqkbzag3wj5gc1jd8h7d985nsq6pn57g5xh"))))
8798 (build-system ruby-build-system)
8799 (native-inputs
8800 `(("bundler" ,bundler)))
8801 (arguments `(#:tests? #f)); FIXME: Could not locate Gemfile or .bundle/ directory
8802 (home-page "https://github.com/intridea/hashie")
8803 (synopsis "Extensions to Ruby Hashes")
8804 (description "Hashie is a collection of classes and mixins that make Ruby
8805hashes more powerful.")
8806 (license license:expat)))
73bfc125
JL
8807
8808(define-public ruby-heredoc-unindent
8809 (package
8810 (name "ruby-heredoc-unindent")
8811 (version "1.2.0")
8812 (source (origin
8813 (method url-fetch)
8814 (uri (rubygems-uri "heredoc_unindent" version))
8815 (sha256
8816 (base32
8817 "14ijr2fsjwhrkjkcaz81d5xnfa4vvgvcflrff83avqw9klm011yw"))))
8818 (build-system ruby-build-system)
8819 (native-inputs
8820 `(("ruby-hoe" ,ruby-hoe)))
8821 (home-page "https://github.com/adrianomitre/heredoc_unindent")
8822 (synopsis "Heredoc indentation cleaner")
8823 (description "This gem removes common margin from indented strings, such
8824as the ones produced by indented heredocs. In other words, it strips out
4f66ae28 8825leading whitespace chars at the beginning of each line, but only as much as
73bfc125
JL
8826the line with the smallest margin.
8827
8828It is acknowledged that many strings defined by heredocs are just code and
8829fact is that most parsers are insensitive to indentation. If, however, the
8830strings are to be used otherwise, be it for printing or testing, the extra
8831indentation will probably be an issue and hence this gem.")
8832 (license license:expat)))
f8ae2ee5
JL
8833
8834(define-public ruby-safe-yaml
8835 (package
8836 (name "ruby-safe-yaml")
7fa83fa8 8837 (version "1.0.5")
28cf8dab
CB
8838 (source
8839 (origin
28cf8dab
CB
8840 (method git-fetch)
8841 (uri (git-reference
8842 (url "https://github.com/dtao/safe_yaml.git")
8843 (commit version)))
8844 (file-name (git-file-name name version))
8845 (sha256
8846 (base32
7fa83fa8 8847 "1a0wh7y3va2m7bjza95na2snw0vrdh9syz40mpjvjphbc4ph3pzg"))))
f8ae2ee5
JL
8848 (build-system ruby-build-system)
8849 (native-inputs
8850 `(("ruby-rspec" ,ruby-rspec)
8851 ("ruby-hashie" ,ruby-hashie)
8852 ("ruby-heredoc-unindent" ,ruby-heredoc-unindent)))
28cf8dab
CB
8853 (arguments
8854 '(#:test-target "spec"
8855 #:phases
8856 (modify-phases %standard-phases
8857 (add-before 'check 'set-TZ
8858 (lambda _
8859 ;; This test is dependent on the timezone
8860 ;; spec/transform/to_date_spec.rb:35
8861 ;; # SafeYAML::Transform::ToDate converts times to the local
8862 ;; timezone
8863 (setenv "TZ" "UTC-11")
8864 #t)))))
f8ae2ee5
JL
8865 (home-page "https://github.com/dtao/safe_yaml")
8866 (synopsis "YAML parser")
8867 (description "The SafeYAML gem provides an alternative implementation of
8868YAML.load suitable for accepting user input in Ruby applications.")
8869 (license license:expat)))
f1ec4d76
JL
8870
8871(define-public ruby-mercenary
8872 (package
8873 (name "ruby-mercenary")
8874 (version "0.3.6")
8875 (source (origin
8876 (method url-fetch)
8877 (uri (rubygems-uri "mercenary" version))
8878 (sha256
8879 (base32
8880 "10la0xw82dh5mqab8bl0dk21zld63cqxb1g16fk8cb39ylc4n21a"))))
8881 (build-system ruby-build-system)
8882 (arguments `(#:test-target "spec"))
8883 (native-inputs
8884 `(("bundler" ,bundler)))
8885 (home-page "https://github.com/jekyll/mercenary")
8886 (synopsis "Command-line apps library in Ruby")
8887 (description "Mercenary is a lightweight and flexible library for writing
8888command-line apps in Ruby.")
8889 (license license:expat)))
a13d451e
JL
8890
8891(define-public ruby-liquid
8892 (package
8893 (name "ruby-liquid")
8894 (version "4.0.0")
8895 (source (origin
8896 (method url-fetch)
8897 (uri (rubygems-uri "liquid" version))
8898 (sha256
8899 (base32
8900 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))
8901 (build-system ruby-build-system)
8902 (arguments `(#:tests? #f)); No rakefile
8903 (home-page "https://shopify.github.io/liquid/")
8904 (synopsis "Template language")
8905 (description "Liquid is a template language written in Ruby. It is used
8906to load dynamic content on storefronts.")
8907 (license license:expat)))
49395112
JL
8908
8909(define-public ruby-forwardable-extended
8910 (package
8911 (name "ruby-forwardable-extended")
8912 (version "2.6.0")
8913 (source (origin
8914 (method url-fetch)
8915 (uri (rubygems-uri "forwardable-extended" version))
8916 (sha256
8917 (base32
8918 "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"))))
8919 (build-system ruby-build-system)
8920 (arguments `(#:tests? #f)); Cyclic dependency on luna-rspec-formatters
8921 (home-page "https://github.com/envygeeks/forwardable-extended")
8922 (synopsis "Delegation to hashes and instance variables in Forwardable")
8923 (description "Forwardable Extended provides more @code{Forwardable}
8924methods for your source as @code{Forwardable::Extended}.")
8925 (license license:expat)))
37296113
JL
8926
8927(define-public ruby-pathutil
8928 (package
8929 (name "ruby-pathutil")
feaaa603 8930 (version "0.16.2")
37296113
JL
8931 (source (origin
8932 (method url-fetch)
8933 (uri (rubygems-uri "pathutil" version))
8934 (sha256
8935 (base32
feaaa603 8936 "12fm93ljw9fbxmv2krki5k5wkvr7560qy8p4spvb9jiiaqv78fz4"))))
37296113
JL
8937 (build-system ruby-build-system)
8938 (propagated-inputs
8939 `(("ruby-forwardable-extended" ,ruby-forwardable-extended)))
8940 (native-inputs
8941 `(("bundler" ,bundler)
8942 ("ruby-rspec" ,ruby-rspec)))
8943 ;; Fails with: cannot load such file --
8944 ;; /tmp/guix-build-ruby-pathutil-0.16.0.drv-0/gem/benchmark/support/task
8945 (arguments `(#:tests? #f))
8946 (home-page "https://github.com/envygeeks/pathutil")
8947 (synopsis "Extended implementation of Pathname")
8948 (description "Pathutil tries to be a faster pure Ruby implementation of
8949Pathname.")
8950 (license license:expat)))
49e1dde5
JL
8951
8952(define-public jekyll
8953 (package
8954 (name "jekyll")
fcf82fd3 8955 (version "3.8.6")
49e1dde5
JL
8956 (source (origin
8957 (method url-fetch)
8958 (uri (rubygems-uri "jekyll" version))
8959 (sha256
8960 (base32
fcf82fd3 8961 "1ph1jjjl25vmzif7bvxzviq7azjm384pm7ba4k24cah94285bzhz"))))
49e1dde5
JL
8962 (build-system ruby-build-system)
8963 (arguments
fcf82fd3 8964 ;; No rakefile, but a test subdirectory.
49e1dde5
JL
8965 `(#:tests? #f
8966 #:phases
8967 (modify-phases %standard-phases
8968 (add-before 'build 'fix-i18n
8969 (lambda _
8970 (substitute* ".gemspec"
8971 (("~> 0.7") ">= 0.7"))
8972 #t)))))
8973 (propagated-inputs
8974 `(("ruby-addressable" ,ruby-addressable)
8975 ("ruby-colorator" ,ruby-colorator)
8976 ("ruby-em-websocket" ,ruby-em-websocket)
8977 ("ruby-i18n" ,ruby-i18n)
8978 ("ruby-jekyll-sass-converter" ,ruby-jekyll-sass-converter)
8979 ("ruby-jekyll-watch" ,ruby-jekyll-watch)
8980 ("ruby-kramdown" ,ruby-kramdown)
8981 ("ruby-liquid" ,ruby-liquid)
8982 ("ruby-mercenary" ,ruby-mercenary)
8983 ("ruby-pathutil" ,ruby-pathutil)
8984 ("ruby-rouge" ,ruby-rouge-2)
8985 ("ruby-safe-yaml" ,ruby-safe-yaml)))
8986 (home-page "https://jekyllrb.com/")
8987 (synopsis "Static site generator")
8988 (description "Jekyll is a simple, blog aware, static site generator.")
8989 (license license:expat)))
37a0f470
JL
8990
8991(define-public ruby-jekyll-paginate-v2
8992 (package
8993 (name "ruby-jekyll-paginate-v2")
8994 (version "2.0.0")
8995 (source (origin
8996 (method url-fetch)
8997 (uri (rubygems-uri "jekyll-paginate-v2" version))
8998 (sha256
8999 (base32
9000 "154bfpyml6abxww9868hhyfvxasl8qhsc5zy2q30c7dxaj0igdib"))))
9001 (build-system ruby-build-system)
9002 (propagated-inputs
9003 `(("jekyll" ,jekyll)))
9004 (home-page "https://github.com/sverrirs/jekyll-paginate-v2")
9005 (synopsis "Pagination Generator for Jekyll 3")
9006 (description "The Pagination Generator forms the core of the pagination
9007logic in Jekyll. It calculates and generates the pagination pages.")
9008 (license license:expat)))
909eae21
CB
9009
9010(define-public ruby-faraday
9011 (package
9012 (name "ruby-faraday")
9013 (version "0.15.4")
9014 (source
9015 (origin
9016 (method url-fetch)
9017 (uri (rubygems-uri "faraday" version))
9018 (sha256
9019 (base32
9020 "0s72m05jvzc1pd6cw1i289chas399q0a14xrwg4rvkdwy7bgzrh0"))))
9021 (build-system ruby-build-system)
9022 (arguments
9023 '(#:tests? #f))
9024 (propagated-inputs
9025 `(("ruby-multipart-post" ,ruby-multipart-post)))
9026 (synopsis "Ruby HTTP/REST API client library")
9027 (description
9028 "Faraday is a HTTP/REST API client library which provides a common
9029interface over different adapters.")
9030 (home-page "https://github.com/lostisland/faraday")
9031 (license license:expat)))
a058cbfd
CB
9032
9033(define-public ruby-nio4r
9034 (package
9035 (name "ruby-nio4r")
7923b9bf 9036 (version "2.5.2")
a058cbfd
CB
9037 (source
9038 (origin
9039 (method url-fetch)
9040 (uri (rubygems-uri "nio4r" version))
9041 (sha256
9042 (base32
7923b9bf 9043 "0gnmvbryr521r135yz5bv8354m7xn6miiapfgpg1bnwsvxz8xj6c"))))
a058cbfd
CB
9044 (build-system ruby-build-system)
9045 (arguments
9046 '(#:phases
9047 (modify-phases %standard-phases
9048 (add-after 'unpack 'remove-unnecessary-dependencies
9049 (lambda _
9050 (substitute* "spec/spec_helper.rb"
9051 ;; Coveralls is for uploading test coverage information to an
9052 ;; online service, and thus unnecessary for building the Guix
9053 ;; package
9054 (("require \"coveralls\"") "")
9055 (("Coveralls\\.wear!") "")
9056 ;; Remove rspec/retry as we are not retrying the tests
9057 (("require \"rspec/retry\"") "")
9058 (("config\\.display_try_failure_messages = true") "")
9059 (("config\\.verbose_retry = true") ""))
9060 #t))
9061 (add-before 'check 'compile
9062 (lambda _
9063 (invoke "rake" "compile")
9064 #t))
9065 (replace 'check
9066 (lambda* (#:key tests? #:allow-other-keys)
9067 (when tests?
9068 (invoke "rspec"))
9069 #t)))))
9070 (native-inputs
9071 `(("bundler" ,bundler)
9072 ("ruby-rake-compiler" ,ruby-rake-compiler)
9073 ("ruby-rspec" ,ruby-rspec)
9074 ("ruby-rubocop" ,ruby-rubocop)))
9075 (synopsis "New I/O for Ruby")
9076 (description
9077 "@code{nio} provides cross-platform asynchronous I/O primitives in Ruby
9078for scalable network clients and servers.")
9079 (home-page "https://github.com/socketry/nio4r")
9080 (license license:expat)))
f9da1ada
CB
9081
9082(define-public ruby-globalid
9083 (package
9084 (name "ruby-globalid")
9085 (version "0.4.2")
9086 (source
9087 (origin
9088 (method url-fetch)
9089 (uri (rubygems-uri "globalid" version))
9090 (sha256
9091 (base32
9092 "1zkxndvck72bfw235bd9nl2ii0lvs5z88q14706cmn702ww2mxv1"))))
9093 (build-system ruby-build-system)
9094 (arguments
9095 '(;; No included tests
9096 #:tests? #f))
9097 (propagated-inputs
9098 `(("ruby-activesupport" ,ruby-activesupport)))
9099 (synopsis "Generate URIs idenfitying model instances in Ruby")
9100 (description
9101 "@code{GlobalID} provides a way to generate URIs from a model in Ruby that
9102uniquely identify it.")
9103 (home-page "https://rubyonrails.org/")
9104 (license license:expat)))
15606d98
CB
9105
9106(define-public ruby-sprockets
9107 (package
9108 (name "ruby-sprockets")
9109 (version "3.7.2")
9110 (source
9111 (origin
9112 (method url-fetch)
9113 (uri (rubygems-uri "sprockets" version))
9114 (sha256
9115 (base32
9116 "182jw5a0fbqah5w9jancvfmjbk88h8bxdbwnl4d3q809rpxdg8ay"))))
9117 (build-system ruby-build-system)
9118 (arguments
9119 '(;; No included tests
9120 #:tests? #f))
9121 (propagated-inputs
9122 `(("ruby-concurrent" ,ruby-concurrent)
9123 ("ruby-rack" ,ruby-rack)))
9124 (synopsis "Sprockets is a Rack-based asset packaging system")
9125 (description
9126 "Sprockets is a Rack-based asset packaging system that concatenates and
9127serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.")
9128 (home-page "https://github.com/rails/sprockets")
9129 (license license:expat)))
acb9e3d8
PN
9130
9131(define-public ruby-mustermann
9132 (package
9133 (name "ruby-mustermann")
9134 (version "1.0.3")
9135 (source
9136 (origin
9137 (method url-fetch)
9138 (uri (rubygems-uri "mustermann" version))
9139 (sha256
9140 (base32
9141 "0lycgkmnyy0bf29nnd2zql5a6pcf8sp69g9v4xw0gcfcxgpwp7i1"))))
9142 (build-system ruby-build-system)
9143 (arguments
9144 ;; No tests.
9145 '(#:tests? #f))
9146 (synopsis "Library implementing patterns that behave like regular expressions")
9147 (description "Given a string pattern, Mustermann will turn it into an
9148object that behaves like a regular expression and has comparable performance
9149characteristics.")
9150 (home-page "https://github.com/sinatra/mustermann")
9151 (license license:expat)))
3bb094e2 9152
7bddb6aa
BL
9153(define-public ruby-htmlentities
9154 (package
9155 (name "ruby-htmlentities")
9156 (version "4.3.4")
9157 (source
9158 (origin
9159 (method url-fetch)
9160 (uri (rubygems-uri "htmlentities" version))
9161 (sha256
9162 (base32
9163 "1nkklqsn8ir8wizzlakncfv42i32wc0w9hxp00hvdlgjr7376nhj"))))
9164 (build-system ruby-build-system)
9165 (arguments
9166 `(#:phases
9167 (modify-phases %standard-phases
9168 (replace 'check
9169 (lambda _
9170 (map (lambda (file)
9171 (invoke "ruby" "-Itest" file))
9172 (find-files "./test" ".*_test\\.rb")))))))
9173 (synopsis "Encode and decode (X)HTML entities")
9174 (description
9175 "This package provides a module for encoding and decoding (X)HTML
9176entities.")
9177 (home-page "https://github.com/threedaymonk/htmlentities")
9178 (license license:expat)))
9179
3bb094e2
PN
9180(define-public ruby-sinatra
9181 (package
9182 (name "ruby-sinatra")
9183 (version "2.0.5")
9184 (source
9185 (origin
9186 (method url-fetch)
9187 (uri (rubygems-uri "sinatra" version))
9188 (sha256
9189 (base32
9190 "1gasgn5f15myv08k10i16p326pchxjsy37pgqfw0xm66kcc5d7ry"))))
9191 (build-system ruby-build-system)
9192 (propagated-inputs
9193 `(("ruby-mustermann" ,ruby-mustermann)
9194 ("ruby-rack" ,ruby-rack)
9195 ("ruby-rack-protection" ,ruby-rack-protection)
9196 ("ruby-tilt" ,ruby-tilt)))
9197 (synopsis "DSL for quick web applications creation in Ruby")
9198 (description
9199 "Sinatra is a DSL for quickly creating web applications in Ruby with
9200minimal effort.")
9201 (home-page "http://sinatrarb.com/")
9202 (license license:expat)))
6e87695b
PN
9203
9204(define-public ruby-thin
9205 (package
9206 (name "ruby-thin")
9207 (version "1.7.2")
9208 (source
9209 (origin
9210 (method url-fetch)
9211 (uri (rubygems-uri "thin" version))
9212 (sha256
9213 (base32
9214 "0nagbf9pwy1vg09k6j4xqhbjjzrg5dwzvkn4ffvlj76fsn6vv61f"))))
9215 (build-system ruby-build-system)
9216 (arguments
9217 ;; No tests.
9218 '(#:tests? #f))
9219 (propagated-inputs
9220 `(("ruby-daemons" ,ruby-daemons)
9221 ("ruby-eventmachine" ,ruby-eventmachine)
9222 ("ruby-rack" ,ruby-rack)))
9223 (synopsis "Thin and fast web server for Ruby")
9224 (description "Thin is a Ruby web server that glues together 3 Ruby libraries:
9225@itemize
9226@item the Mongrel parser,
9227@item Event Machine, a network I/O library with high scalability, performance
9228and stability,
9229@item Rack, a minimal interface between webservers and Ruby frameworks.
9230@end itemize\n")
60783303 9231 (home-page "https://github.com/macournoyer/thin")
6e87695b 9232 (license license:ruby)))
be6016db
PN
9233
9234(define-public ruby-skinny
9235 (package
9236 (name "ruby-skinny")
9237 (version "0.2.4")
9238 (source
9239 (origin
9240 (method url-fetch)
9241 (uri (rubygems-uri "skinny" version))
9242 (sha256
9243 (base32
9244 "1y3yvx88ylgz4d2s1wskjk5rkmrcr15q3ibzp1q88qwzr5y493a9"))))
9245 (build-system ruby-build-system)
9246 (arguments
9247 '(#:tests? #f ; No included tests
9248 #:phases
9249 (modify-phases %standard-phases
9250 (add-before 'build 'patch-gemspec
9251 (lambda _
9252 (substitute* ".gemspec"
9253 (("<eventmachine>.freeze, \\[\\\"~> 1.0.0\"")
9254 "<eventmachine>, [\">= 1.0.0\"")
9255 (("<thin>.freeze, \\[\\\"< 1.7\", ") "<thin>, ["))
9256 #t)))))
9257 (propagated-inputs
9258 `(("ruby-eventmachine" ,ruby-eventmachine)
9259 ("ruby-thin" ,ruby-thin)))
9260 (synopsis "Simple, upgradable WebSockets for Ruby Thin")
9261 (description "Skinny is a simple, upgradable WebSockets for Ruby, using
9262the Thin library.")
9263 (home-page "https://github.com/sj26/skinny")
9264 (license license:expat)))
df747c8d
PN
9265
9266(define-public mailcatcher
9267 (package
9268 (name "mailcatcher")
9269 (version "0.7.1")
9270 (source
9271 (origin
9272 (method url-fetch)
9273 (uri (rubygems-uri "mailcatcher" version))
9274 (sha256
9275 (base32
9276 "02w1ycyfv7x0sh9799lz7xa65p5qvl5z4pa8a7prb68h2zwkfq0n"))))
9277 (build-system ruby-build-system)
9278 (arguments
9279 ;; Tests require web/assets which is not included in the output. We
9280 ;; might be able to fix this by adding the Git repository to the GEM_PATH
9281 ;; of the tests. See ruby-mysql2.
9282 '(#:tests? #f
9283 #:phases
9284 (modify-phases %standard-phases
9285 (add-before 'build 'patch-gemspec
9286 (lambda _
9287 (substitute* ".gemspec"
9288 (("<eventmachine>.freeze, \\[\\\"= 1.0.9.1")
9289 "<eventmachine>, [\">= 1.0.9.1")
9290 (("<rack>.freeze, \\[\\\"~> 1.5") "<rack>, [\">= 1.5")
9291 (("<thin>.freeze, \\[\\\"~> 1.5.0") "<thin>, [\">= 1.5.0")
9292 (("<sinatra>.freeze, \\[\\\"~> 1.2") "<sinatra>, [\">= 1.2"))
9293 #t))
9294 (add-before 'build 'loosen-dependency-contraint
9295 (lambda _
9296 (substitute* "lib/mail_catcher.rb"
9297 (("\"eventmachine\", \"1.0.9.1\"") "\"eventmachine\", \">= 1.0.9.1\"")
9298 (("\"rack\", \"~> 1.5\"") "\"rack\", \">= 1.5\"")
9299 (("\"thin\", \"~> 1.5.0\"") "\"thin\", \">= 1.5.0\"")
9300 (("\"sinatra\", \"~> 1.2\"") "\"sinatra\", \">= 1.2\""))
9301 #t)))))
9302 (inputs
9303 `(("ruby-eventmachine" ,ruby-eventmachine)
9304 ("ruby-mail" ,ruby-mail)
9305 ("ruby-rack" ,ruby-rack)
9306 ("ruby-sinatra" ,ruby-sinatra)
9307 ("ruby-skinny" ,ruby-skinny)
9308 ("ruby-sqlite3" ,ruby-sqlite3)
9309 ("ruby-thin" ,ruby-thin)))
9310 (synopsis "SMTP server which catches messages to display them a browser")
9311 (description
9312 "MailCatcher runs a super simple SMTP server which catches any message
9313sent to it to display in a web interface. Run mailcatcher, set your favourite
9314app to deliver to smtp://127.0.0.1:1025 instead of your default SMTP server,
9315then check out http://127.0.0.1:1080 to see the mail.")
9316 (home-page "https://mailcatcher.me")
9317 (license license:expat)))
fc4f7c45
MK
9318
9319(define-public ruby-backport
9320 (package
9321 (name "ruby-backport")
b62863b8 9322 (version "1.1.2")
fc4f7c45
MK
9323 (source
9324 (origin
b62863b8 9325 ;; The gem does not include test code, so fetch from the Git repository.
fc4f7c45
MK
9326 (method git-fetch)
9327 (uri (git-reference
9328 (url "https://github.com/castwide/backport.git")
9329 (commit (string-append "v" version))))
9330 (file-name (git-file-name name version))
9331 (sha256
b62863b8 9332 (base32 "18fpg1n7n2z02ykz9v1x1q0cqa2lvivf8ygka768s01q1r9wfwv2"))))
fc4f7c45
MK
9333 (build-system ruby-build-system)
9334 (arguments
9335 `(#:test-target "spec"))
9336 (native-inputs
9337 `(("bundler" ,bundler)
9338 ("ruby-rspec" ,ruby-rspec)))
9339 (inputs
9340 `(("ruby-simplecov" ,ruby-simplecov)))
9341 (synopsis "Pure Ruby library for event-driven IO")
9342 (description
9343 "This package provides a pure Ruby library for event-driven IO.")
9344 (home-page "https://github.com/castwide/backport")
9345 (license license:expat)))
369faa59
JL
9346
9347(define-public ruby-json-schema
9348 (package
9349 (name "ruby-json-schema")
9350 (version "2.8.1")
9351 (source
9352 (origin
9353 (method url-fetch)
9354 (uri (rubygems-uri "json-schema" version))
9355 (sha256
9356 (base32
9357 "1yv5lfmr2nzd14af498xqd5p89f3g080q8wk0klr3vxgypsikkb5"))))
9358 (build-system ruby-build-system)
9359 (arguments
9360 `(#:tests? #f ; no tests
9361 #:phases
9362 (modify-phases %standard-phases
9363 (replace 'build
9364 (lambda _
9365 (invoke "gem" "build" ".gemspec"))))))
9366 (propagated-inputs
9367 `(("ruby-addressable" ,ruby-addressable)))
9368 (synopsis "Ruby JSON Schema Validator")
9369 (description "This library provides Ruby with an interface for validating
9370JSON objects against a JSON schema conforming to JSON Schema Draft 4. Legacy
9371support for JSON Schema Draft 3, JSON Schema Draft 2, and JSON Schema Draft 1
9372is also included.")
9373 (home-page "https://github.com/ruby-json-schema/json-schema")
9374 (license license:expat)))
44881cad
JL
9375
9376(define-public swagger-diff
9377 (package
9378 (name "swagger-diff")
9379 (version "1.1.2")
9380 (source
9381 (origin
9382 (method url-fetch)
9383 (uri (rubygems-uri "swagger-diff" version))
9384 (sha256
9385 (base32
9386 "1hxx50nga1bqn254iqjcdwkc9c72364ks9lyjyw10ajz0l0ly7sn"))))
9387 (build-system ruby-build-system)
9388 (arguments
9389 `(#:test-target "spec"
9390 #:phases
9391 (modify-phases %standard-phases
9392 ;; Don't run or require rubocop, the code linting tool, as this is a
9393 ;; bit unnecessary.
9394 (add-after 'unpack 'dont-run-rubocop
9395 (lambda _
9396 (substitute* "Rakefile"
9397 ((".*rubocop.*") "")
9398 ((".*RuboCop.*") ""))
9399 #t)))))
9400 (propagated-inputs
9401 `(("ruby-json-schema" ,ruby-json-schema)))
9402 (native-inputs
9403 `(("bundler" ,bundler)
9404 ("ruby-rspec-core" ,ruby-rspec-core)
9405 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
9406 (synopsis
9407 "Compare Open API Initiative specification files")
9408 (description
9409 "Swagger::Diff is a utility for comparing two different Open API
9410Initiative (OAI) specifications (formerly known as Swagger specifications).
9411It is intended to determine whether a newer API specification is
9412backwards-compatible with an older API specification.")
9413 (home-page "https://github.com/civisanalytics/swagger-diff")
9414 (license license:bsd-3)))
9e065a8a
BL
9415
9416(define-public ruby-reverse-markdown
9417 (package
9418 (name "ruby-reverse-markdown")
9419 (version "1.1.0")
9420 (source
9421 (origin
9422 (method url-fetch)
9423 (uri (rubygems-uri "reverse_markdown" version))
9424 (sha256
9425 (base32
9426 "0w7y5n74daajvl9gixr91nh8670d7mkgspkk3ql71m8azq3nffbg"))))
9427 (build-system ruby-build-system)
9428 (propagated-inputs
9429 `(("ruby-nokogiri" ,ruby-nokogiri)))
9430 (native-inputs
9431 `(("bundler" ,bundler)
9432 ("ruby-rspec" ,ruby-rspec)
9433 ("ruby-kramdown" ,ruby-kramdown)
9434 ("ruby-simplecov" ,ruby-simplecov)))
9435 (arguments
9436 `(#:phases
9437 (modify-phases %standard-phases
9438 (replace 'check
9439 (lambda* (#:key tests? #:allow-other-keys)
9440 (when tests?
9441 (invoke "rspec"))
9442 #t)))))
9443 (synopsis "Convert HTML into Markdown")
9444 (description
9445 "This Ruby module allows you to map simple HTML back into
9446Markdown---e.g., if you want to import existing HTML data in your
9447application.")
9448 (home-page "https://github.com/xijo/reverse_markdown")
9449 (license license:wtfpl2)))
9450
a9e2de7e
BL
9451(define-public ruby-solargraph
9452 (package
9453 (name "ruby-solargraph")
9454 (version "0.36.0")
9455 (source
9456 (origin
9457 (method url-fetch)
9458 (uri (rubygems-uri "solargraph" version))
9459 (sha256
9460 (base32
9461 "0b93xzkgd1h06da9gdnwivj1mzbil8lc072y2838dy6i7bxgpy9i"))))
9462 (build-system ruby-build-system)
9463 (propagated-inputs
9464 `(("ruby-backport" ,ruby-backport)
9465 ("bundler" ,bundler)
9466 ("ruby-htmlentities" ,ruby-htmlentities)
9467 ("ruby-jaro-winkler" ,ruby-jaro-winkler)
9468 ("ruby-maruku" ,ruby-maruku)
9469 ("ruby-nokogiri" ,ruby-nokogiri)
9470 ("ruby-parser" ,ruby-parser)
9471 ("ruby-reverse-markdown" ,ruby-reverse-markdown)
9472 ("ruby-rubocop" ,ruby-rubocop)
9473 ("ruby-thor" ,ruby-thor)
9474 ("ruby-tilt" ,ruby-tilt)
9475 ("ruby-yard" ,ruby-yard)))
9476 (native-inputs
9477 `(("ruby-rspec" ,ruby-rspec)
9478 ("ruby-pry" ,ruby-pry)
9479 ("ruby-simplecov" ,ruby-simplecov)
9480 ("ruby-webmock" ,ruby-webmock-2)))
9481 ;; FIXME: can't figure out how to run the tests properly:
9482
9483 ;; An error occurred while loading spec_helper.
9484 ;; Failure/Error: return gem_original_require(path)
9485 ;; LoadError:
9486 ;; cannot load such file -- spec_helper
9487 (arguments
9488 '(#:tests? #f
9489 #:phases
9490 (modify-phases %standard-phases
9491 (replace 'check
9492 (lambda* (#:key tests? #:allow-other-keys)
9493 (when tests?
9494 (invoke "rspec"))
9495 #t)))))
9496 (synopsis
9497 "IDE tools for code completion, inline documentation, and static analysis")
9498 (description
9499 "Solargraph provides a comprehensive suite of tools for Ruby
9500programming: intellisense, diagnostics, inline documentation, and type
9501checking.")
9502 (home-page "https://solargraph.org/")
9503 (license license:expat)))
0c558aa9
DNB
9504
9505(define-public ruby-wayback-machine-downloader
9506 (package
9507 (name "ruby-wayback-machine-downloader")
9508 (version "2.2.1")
9509 (source
9510 (origin
9511 (method url-fetch)
9512 (uri (rubygems-uri
9513 "wayback_machine_downloader"
9514 version))
9515 (sha256
9516 (base32
9517 "12kb1qmvmmsaihqab1prn6cmynkn6cgb4vf41mgv22wkcgv5wgk2"))))
9518 (build-system ruby-build-system)
9519 (arguments
9520 '(#:tests? #f)) ; no tests
9521 (synopsis "Download archived websites from the Wayback Machine")
9522 (description
9523 "Wayback Machine Downloader is a command line tool for downloading
9524websites from the Internet Archive's Wayback Machine (archive.org).
9525It allows fine grained control over what to download by specifying
9526which snapshots to consider and what files to include.")
9527 (home-page
9528 "https://github.com/hartator/wayback-machine-downloader")
9529 (license license:expat)))
e6483f8c
MB
9530
9531(define-public ruby-wwtd
9532 (package
9533 (name "ruby-wwtd")
9534 (version "1.4.1")
9535 (home-page "http://github.com/grosser/wwtd")
9536 (source (origin
9537 (method git-fetch)
9538 (uri (git-reference
9539 (url home-page)
9540 (commit (string-append "v" version))))
9541 (file-name (git-file-name name version))
9542 (sha256
9543 (base32
9544 "0gw7vfnbb41cy67yw82zji3jkhfsgmzcgzaszm99ax77y18wclf2"))
9545 (modules '((guix build utils)))
9546 (snippet
9547 '(begin
9548 ;; Remove bundled library.
9549 (delete-file "spec/rake-12.3.0.gem")
9550 #t))))
9551 (build-system ruby-build-system)
9552 (arguments
9553 '(;; XXX: Tests need multiple versions of ruby, wants to run
9554 ;; `bundle install`, etc.
9555 #:tests? #f
9556 #:phases (modify-phases %standard-phases
9557 (replace 'replace-git-ls-files
9558 (lambda _
9559 (substitute* "wwtd.gemspec"
9560 (("git ls-files lib/ bin/`")
9561 "find lib/ bin/ -type f |sort`"))
9562 #t))
9563 (add-before 'check 'remove-version-constraints
9564 (lambda _
9565 (delete-file "Gemfile.lock")
9566 #t))
9567 (replace 'check
9568 (lambda* (#:key tests? #:allow-other-keys)
9569 (if tests?
9570 (invoke "rspec" "spec/")
9571 (format #t "test suite not run~%"))
9572 #t)))))
9573 (native-inputs
9574 `(("ruby-bump" ,ruby-bump)
9575 ("ruby-rspec" ,ruby-rspec)))
9576 (synopsis "Run @file{.travis.yml} files locally")
9577 (description
9578 "WWTD is a @dfn{Travis Simulator} that lets you run test matrices
9579defined in @file{.travis.yml} on your local machine, using @code{rvm},
9580@code{rbenv}, or @code{chruby} to test different versions of Ruby.")
9581 (license license:expat)))