gnu: Add ruby-zeitwerk.
[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>
e4fb673a 10;;; Copyright © 2017, 2018, 2019, 2020, 2021 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>
a8cdfd53 23;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
49994222 24;;; Copyright © 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr>
b7e76699 25;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
40afc2f4 26;;; Copyright © 2020 Holgr Peters <holger.peters@posteo.de>
0af8398b 27;;; Copyright © 2020 Giacomo Leidi <goodoldpaul@autistici.org>
c7358514 28;;; Copyright © 2021 EuAndreh <eu@euandre.org>
6ef8c59a
PP
29;;;
30;;; This file is part of GNU Guix.
31;;;
32;;; GNU Guix is free software; you can redistribute it and/or modify it
33;;; under the terms of the GNU General Public License as published by
34;;; the Free Software Foundation; either version 3 of the License, or (at
35;;; your option) any later version.
36;;;
37;;; GNU Guix is distributed in the hope that it will be useful, but
38;;; WITHOUT ANY WARRANTY; without even the implied warranty of
39;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
40;;; GNU General Public License for more details.
41;;;
42;;; You should have received a copy of the GNU General Public License
43;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
44
45(define-module (gnu packages ruby)
46 #:use-module ((guix licenses) #:prefix license:)
47 #:use-module (gnu packages)
1db791d5 48 #:use-module (gnu packages base)
933dad91 49 #:use-module (gnu packages bison)
24be6751 50 #:use-module (gnu packages c)
15b16c2c 51 #:use-module (gnu packages check)
6ef8c59a 52 #:use-module (gnu packages compression)
2a9ce5cb 53 #:use-module (gnu packages crypto)
0af8398b 54 #:use-module (gnu packages curl)
4a9e0585 55 #:use-module (gnu packages databases)
255d1bbe 56 #:use-module (gnu packages dbm)
c41fba01 57 #:use-module (gnu packages rails)
6ef8c59a 58 #:use-module (gnu packages readline)
6ef8c59a 59 #:use-module (gnu packages autotools)
c84dd8d4 60 #:use-module (gnu packages haskell-xyz)
ad79eb55 61 #:use-module (gnu packages java)
6ef8c59a 62 #:use-module (gnu packages libffi)
f3d7bb93 63 #:use-module (gnu packages libidn)
c41fba01
CB
64 #:use-module (gnu packages linux)
65 #:use-module (gnu packages lsof)
34138e42 66 #:use-module (gnu packages maths)
0c8eedc1 67 #:use-module (gnu packages ncurses)
fe5dd5f4 68 #:use-module (gnu packages networking)
3ca43524 69 #:use-module (gnu packages node)
dff5392f 70 #:use-module (gnu packages protobuf)
ac09beba 71 #:use-module (gnu packages python)
44d10b1f 72 #:use-module (gnu packages python-xyz)
763624f5 73 #:use-module (gnu packages ragel)
30f08487 74 #:use-module (gnu packages rsync)
cd0322a3 75 #:use-module (gnu packages sqlite)
cc2b77df 76 #:use-module (gnu packages tls)
66e20863 77 #:use-module (gnu packages version-control)
6ef8c59a
PP
78 #:use-module (guix packages)
79 #:use-module (guix download)
bda0c139 80 #:use-module (guix git-download)
ebd8e447 81 #:use-module (guix gexp)
6ef8c59a 82 #:use-module (guix utils)
acf735f2 83 #:use-module (guix build-system gnu)
e920bfca 84 #:use-module (gnu packages xml)
c2c4e5b2 85 #:use-module (gnu packages web)
15b16c2c
CB
86 #:use-module (guix build-system ruby)
87 #:use-module ((srfi srfi-1) #:select (alist-delete)))
6ef8c59a 88
9622928d
MC
89(define %prawn-project-licenses
90 ;; This set of licenses applies to most (all?) components of the Prawn
91 ;; project (it is triple licensed).
92 (list license:ruby
93 license:gpl2+
94 license:gpl3+))
95
6ef8c59a
PP
96(define-public ruby
97 (package
98 (name "ruby")
4914c157 99 (version "2.6.5")
6ef8c59a
PP
100 (source
101 (origin
102 (method url-fetch)
6becfdff
MW
103 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
104 (version-major+minor version)
12d39eb5 105 "/ruby-" version ".tar.xz"))
6ef8c59a
PP
106 (sha256
107 (base32
4914c157 108 "0qhsw2mr04f3lqinkh557msr35pb5rdaqy4vdxcj91flgxqxmmnm"))
65e84e31
BW
109 (modules '((guix build utils)))
110 (snippet `(begin
111 ;; Remove bundled libffi
c033c195 112 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
65e84e31 113 #t))))
6ef8c59a
PP
114 (build-system gnu-build-system)
115 (arguments
116 `(#:test-target "test"
fd248cb8 117 #:configure-flags '("--enable-shared") ; dynamic linking
6ef8c59a 118 #:phases
9656b8be 119 (modify-phases %standard-phases
65e84e31 120 (add-before 'configure 'replace-bin-sh-and-remove-libffi
9656b8be
BW
121 (lambda _
122 (substitute* '("Makefile.in"
123 "ext/pty/pty.c"
124 "io.c"
125 "lib/mkmf.rb"
126 "process.c"
127 "test/rubygems/test_gem_ext_configure_builder.rb"
128 "test/rdoc/test_rdoc_parser.rb"
129 "test/ruby/test_rubyoptions.rb"
130 "test/ruby/test_process.rb"
131 "test/ruby/test_system.rb"
132 "tool/rbinstall.rb")
133 (("/bin/sh") (which "sh")))
134 #t)))))
6ef8c59a
PP
135 (inputs
136 `(("readline" ,readline)
6ef8c59a
PP
137 ("openssl" ,openssl)
138 ("libffi" ,libffi)
4914c157
CB
139 ("gdbm" ,gdbm)))
140 (propagated-inputs
141 `(("zlib" ,zlib)))
6ef8c59a
PP
142 (native-search-paths
143 (list (search-path-specification
144 (variable "GEM_PATH")
3cb3fa67 145 (files (list (string-append "lib/ruby/vendor_ruby"))))))
6becfdff 146 (synopsis "Programming language interpreter")
6ef8c59a
PP
147 (description "Ruby is a dynamic object-oriented programming language with
148a focus on simplicity and productivity.")
bf3be6a5 149 (home-page "https://www.ruby-lang.org")
6ef8c59a
PP
150 (license license:ruby)))
151
1cc7d340
RP
152(define-public ruby-2.7
153 (package
154 (inherit ruby)
763e6133 155 (version "2.7.2")
1cc7d340
RP
156 (source
157 (origin
158 (method url-fetch)
763e6133 159 (uri (string-append "https://cache.ruby-lang.org/pub/ruby/"
1cc7d340
RP
160 (version-major+minor version)
161 "/ruby-" version ".tar.gz"))
162 (sha256
163 (base32
763e6133 164 "1m63461mxi3fg4y3bspbgmb0ckbbb1ldgf9xi0piwkpfsk80cmvf"))
1cc7d340
RP
165 (modules '((guix build utils)))
166 (snippet `(begin
167 ;; Remove bundled libffi
168 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
169 #t))))
170 (arguments
171 `(#:test-target "test"
172 #:configure-flags '("--enable-shared") ; dynamic linking
173 #:phases
174 (modify-phases %standard-phases
175 (add-before 'configure 'replace-bin-sh-and-remove-libffi
176 (lambda _
177 (substitute* '("configure.ac"
178 "template/Makefile.in"
179 "lib/rubygems/installer.rb"
180 "ext/pty/pty.c"
181 "io.c"
182 "lib/mkmf.rb"
183 "process.c"
184 "test/rubygems/test_gem_ext_configure_builder.rb"
185 "test/rdoc/test_rdoc_parser.rb"
186 "test/ruby/test_rubyoptions.rb"
187 "test/ruby/test_process.rb"
188 "test/ruby/test_system.rb"
189 "tool/rbinstall.rb")
190 (("/bin/sh") (which "sh")))
191 #t)))))
192 (native-inputs
193 `(("autoconf" ,autoconf)))))
194
03c51c04
RP
195(define-public ruby-3.0
196 (package
197 (inherit ruby-2.7)
198 (version "3.0.0")
199 (source
200 (origin
201 (method url-fetch)
202 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
203 (version-major+minor version)
204 "/ruby-" version ".tar.xz"))
205 (sha256
206 (base32
207 "1cbcixwnr0y8q0lg67wjgplp06kjd6p6hjjh680csv3v0bpsxgv8"))))))
208
227fab3e
CB
209(define-public ruby-2.5
210 (package
211 (inherit ruby)
a09ff632 212 (version "2.5.8")
227fab3e
CB
213 (source
214 (origin
215 (method url-fetch)
216 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
217 (version-major+minor version)
218 "/ruby-" version ".tar.xz"))
219 (sha256
220 (base32
a09ff632 221 "0vad5ah1lrdhxsyqr5iqc8c7r7qczpmm76cz8rsf4crimpzv5483"))
227fab3e
CB
222 (modules '((guix build utils)))
223 (snippet `(begin
224 ;; Remove bundled libffi
225 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
226 #t))))))
227
93cae02f
CB
228(define-public ruby-2.4
229 (package
230 (inherit ruby)
dfe211f9 231 (version "2.4.10")
93cae02f
CB
232 (source
233 (origin
234 (method url-fetch)
235 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
236 (version-major+minor version)
237 "/ruby-" version ".tar.xz"))
238 (sha256
239 (base32
dfe211f9 240 "1prhqlgik1zmw9lakl6hkriqslspw48pvhxff17h7ns42p8qwrnm"))
93cae02f
CB
241 (modules '((guix build utils)))
242 (snippet `(begin
243 ;; Remove bundled libffi
244 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
245 #t))))))
246
933dad91
RW
247(define-public mruby
248 (package
249 (name "mruby")
2d1a621b 250 (version "2.1.2")
933dad91
RW
251 (source
252 (origin
253 (method git-fetch)
254 (uri (git-reference
b0e7b699 255 (url "https://github.com/mruby/mruby")
933dad91
RW
256 (commit version)))
257 (file-name (git-file-name name version))
258 (sha256
259 (base32
2d1a621b 260 "0fhfv8pi7i8jn2vgk2n2rjnbnfa12nhj514v8i4k353n7q4pmkh3"))))
933dad91
RW
261 (build-system gnu-build-system)
262 (arguments
263 `(#:test-target "test"
264 #:phases
265 (modify-phases %standard-phases
266 (delete 'configure)
267 (add-after 'unpack 'enable-verbose-tests
268 (lambda _
269 (substitute* "Makefile"
270 (("ruby ./minirake" m)
271 (string-append m " --verbose")))
272 #t))
273 (add-after 'unpack 'disable-broken-tests
274 (lambda _
275 (substitute* "mrbgems/mruby-io/test/io.rb"
276 (("assert\\('IO.popen.+$" m)
277 (string-append m "skip \"Hangs in the Guix build environment\"\n"))
278 (("assert\\('IO#isatty.+$" m)
279 (string-append m "skip \"Disable for Guix; there is no /dev/tty\"\n"))
280 ;; This one is really weird. The *expected* output is all wrong.
281 (("assert\\('`cmd`.*" m)
282 (string-append m "skip \"Disable for Guix\"\n"))
283 (("echo foo")
284 (string-append (which "echo") " foo")))
285 #t))
286 ;; There is no install target
287 (replace 'install
288 (lambda* (#:key outputs #:allow-other-keys)
289 (let* ((out (assoc-ref outputs "out"))
290 (bin (string-append out "/bin"))
291 (lib (string-append out "/lib")))
292 (mkdir-p bin)
293 (copy-recursively "build/host/bin" bin)
294 (mkdir-p lib)
295 (copy-recursively "build/host/lib" lib))
296 #t)))))
297 (native-inputs
298 `(("ruby" ,ruby)
299 ("bison" ,bison)))
300 (home-page "https://github.com/mruby/mruby")
301 (synopsis "Lightweight Ruby")
302 (description "mruby is the lightweight implementation of the Ruby
303language. Its syntax is Ruby 1.9 compatible. mruby can be linked and
304embedded within your application.")
305 (license license:expat)))
306
34372d39
RW
307(define-public ruby-commander
308 (package
309 (name "ruby-commander")
310 (version "4.4.7")
311 (source
312 (origin
313 (method url-fetch)
314 (uri (rubygems-uri "commander" version))
315 (sha256
316 (base32
317 "1pxakz596fjqak3cdbha6iva1dlqis86i3kjrgg6lf3sp8i5vhwg"))))
318 (build-system ruby-build-system)
319 (arguments
320 `(#:test-target "spec"
321 #:phases
322 (modify-phases %standard-phases
323 ;; Don't run or require rubocop, the code linting tool, as this is a
324 ;; bit unnecessary.
325 (add-after 'unpack 'dont-run-rubocop
326 (lambda _
327 (substitute* "Rakefile"
328 ((".*rubocop.*") "")
329 ((".*RuboCop.*") ""))
330 #t)))))
331 (propagated-inputs
332 `(("ruby-highline" ,ruby-highline)))
333 (native-inputs
334 `(("bundler" ,bundler)
335 ("ruby-rspec-core" ,ruby-rspec-core)
336 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
337 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
338 ("ruby-simplecov" ,ruby-simplecov)))
339 (home-page "https://github.com/commander-rb/commander")
340 (synopsis "Library for building Ruby command-line executables")
341 (description
342 "Commander aims to be a complete solution for Ruby command-line
343executables. Commander bridges the gap between other terminal related
344libraries (OptionParser, HighLine), while providing many new features, and an
345elegant API.")
346 (license license:expat)))
347
823ed097
CB
348(define-public ruby-highline
349 (package
350 (name "ruby-highline")
6742c6f6 351 (version "2.0.1")
823ed097
CB
352 (source
353 (origin
354 (method url-fetch)
355 (uri (rubygems-uri "highline" version))
356 (sha256
357 (base32
6742c6f6 358 "0gr6pckj2jayxw1gdgh9193j5jag5zrrqqlrnl4jvcwpyd3sn2zc"))))
823ed097
CB
359 (build-system ruby-build-system)
360 (arguments
361 `(#:tests? #f)) ;; TODO: NameError: uninitialized constant SPEC
362 (native-inputs
363 `(("bundler" ,bundler)
364 ("ruby-code-statistics" ,ruby-code-statistics)))
365 (synopsis
366 "HighLine helps you build command-line interfaces")
367 (description
368 "HighLine provides a high-level IO library that provides validation,
369type conversion, and more for command-line interfaces. HighLine also includes
370a menu system for providing multiple options to the user.")
371 (home-page "https://github.com/JEG2/highline")
372 (license (list license:gpl2 license:ruby))))
373
bda0c139
DT
374(define-public ruby-hoe
375 (package
376 (name "ruby-hoe")
d0d2dd24 377 (version "3.21.0")
bda0c139 378 (source (origin
e83c6d00
DT
379 (method url-fetch)
380 (uri (rubygems-uri "hoe" version))
bda0c139
DT
381 (sha256
382 (base32
d0d2dd24 383 "0qid0n56mgsjvq5ksxajv0gb92akky8imwgvw22ajms5g4fd6nf4"))))
bda0c139 384 (build-system ruby-build-system)
d0d2dd24
CB
385 (arguments
386 '(#:phases
387 (modify-phases %standard-phases
388 ;; One of the tests fails if the SOURCE_DATE_EPOCH environment
389 ;; variable is set, so unset it for the duration of the tests.
390 ;;
391 ;; TestHoe#test_possibly_better
392 ;; [/tmp/guix-build-ruby-hoe-3.20.0.drv-0/gem/test/test_hoe.rb:250]:
393 ;; Expected: 2019-11-12 00:00:00 UTC
394 ;; Actual: 1970-01-01 00:00:00 UTC
395 (add-before 'check 'unset-SOURCE-DATE-EPOCH
396 (lambda _
397 (unsetenv "SOURCE_DATE_EPOCH")
398 #t))
399 (add-after 'check 'set-SOURCE-DATE-EPOCH-again
400 (lambda _
401 (setenv "SOURCE_DATE_EPOCH" "1")
402 #t)))))
bda0c139
DT
403 (synopsis "Ruby project management helper")
404 (description
405 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
406maintain, and release projects and includes a dynamic plug-in system allowing
407for easy extensibility. Hoe ships with plug-ins for all the usual project
408tasks including rdoc generation, testing, packaging, deployment, and
409announcement.")
2f3800e5 410 (home-page "https://www.zenspider.com/projects/hoe.html")
bda0c139
DT
411 (license license:expat)))
412
022170dc
PP
413(define-public ruby-rake-compiler
414 (package
415 (name "ruby-rake-compiler")
7ac6bd00 416 (version "1.1.0")
022170dc
PP
417 (source (origin
418 (method url-fetch)
e83c6d00 419 (uri (rubygems-uri "rake-compiler" version))
022170dc
PP
420 (sha256
421 (base32
7ac6bd00 422 "0l4hg21v0phfrfsc2hilgmwvn2imxr0byqh8dv16bya1s5d3km0q"))))
022170dc
PP
423 (build-system ruby-build-system)
424 (arguments
e83c6d00 425 '(#:tests? #f)) ; needs cucumber
022170dc 426 (synopsis "Building and packaging helper for Ruby native extensions")
e881752c 427 (description "Rake-compiler provides a framework for building and
022170dc
PP
428packaging native C and Java extensions in Ruby.")
429 (home-page "https://github.com/rake-compiler/rake-compiler")
430 (license license:expat)))
431
30f08487
RW
432(define-public ruby-rsync
433 (package
434 (name "ruby-rsync")
435 (version "1.0.9")
436 (source
437 (origin
438 (method url-fetch)
439 (uri (rubygems-uri "rsync" version))
440 (sha256
441 (base32
442 "0p8b27q1gvxilqfq2528xpwglzcm2myikkjxpqk7mwbwg9r6knxv"))))
443 (build-system ruby-build-system)
444 (arguments
445 '(#:test-target "spec"
446 #:phases
447 (modify-phases %standard-phases
448 (add-after 'unpack 'remove-coveralls-requirement
449 (lambda _
450 (substitute* "spec/spec_helper.rb"
451 (("require 'coveralls'") "")
452 (("Coveralls.wear!") ""))
453 #t)))))
454 (native-inputs
455 `(("bundler" ,bundler)
456 ("rsync" ,rsync)
457 ("ruby-rspec-core" ,ruby-rspec-core)
458 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
459 ("ruby-rspec-mocks" ,ruby-rspec-mocks)))
460 (home-page "https://github.com/jbussdieker/ruby-rsync")
461 (synopsis "Ruby wrapper around rsync")
462 (description
463 "Ruby Rsync is a Ruby library that can synchronize files between remote
464hosts by wrapping the @file{rsync} binary.")
465 (license license:expat)))
466
acf735f2
DT
467(define-public ruby-i18n
468 (package
469 (name "ruby-i18n")
92dddf6b 470 (version "1.7.0")
acf735f2
DT
471 (source (origin
472 (method url-fetch)
e83c6d00 473 (uri (rubygems-uri "i18n" version))
acf735f2
DT
474 (sha256
475 (base32
92dddf6b 476 "0hmypvx9iyc0b4hski7aic2xzm09cg1c7q1qlpnk3k8s5acxzyhl"))))
acf735f2
DT
477 (build-system ruby-build-system)
478 (arguments
0bfdfd37 479 '(#:tests? #f)) ; no tests
cbb50182 480 (propagated-inputs `(("concurrent-ruby" ,ruby-concurrent)))
acf735f2
DT
481 (synopsis "Internationalization library for Ruby")
482 (description "Ruby i18n is an internationalization and localization
483solution for Ruby programs. It features translation and localization,
484interpolation of values to translations, pluralization, customizable
485transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
486translation data, custom key/scope separator, custom exception handlers, and
487an extensible architecture with a swappable backend.")
92dddf6b 488 (home-page "https://github.com/ruby-i18n/i18n")
acf735f2 489 (license license:expat)))
eb0c2dd6 490
62b138ca
CB
491(define-public ruby-iruby
492 (package
493 (name "ruby-iruby")
494 (version "0.3")
495 (source
496 (origin
497 (method url-fetch)
498 (uri (rubygems-uri "iruby" version))
499 (sha256
500 (base32
501 "1wdf2c0x8y6cya0n3y0p3p7b1sxkb2fdavdn2k58rf4rs37s7rzn"))))
502 (build-system ruby-build-system)
503 (arguments
504 ;; TODO: Tests currently fail.
505 ;;
506 ;; Finished in 1.764405s, 1.1335 runs/s, 5.1009 assertions/s.
507 ;;
508 ;; 1) Failure:
509 ;; IntegrationTest#test_interaction [/tmp/guix-build-ruby-iruby-0.3.drv-0/gem/test/integration_test.rb:25]:
510 ;; In [ expected
511 ;;
512 ;; 2 runs, 9 assertions, 1 failures, 0 errors, 0 skips
513 '(#:tests? #f
514 #:phases
515 (modify-phases %standard-phases
516 (add-after 'unpack 'patch-ipython
517 (lambda* (#:key inputs #:allow-other-keys)
518 (substitute* "lib/iruby/command.rb"
519 (("version = `")
520 (string-append
521 "version = `"
522 (assoc-ref inputs "python-ipython")
523 "/bin/"))
524 (("Kernel\\.exec\\('")
525 (string-append
526 "Kernel.exec('"
527 (assoc-ref inputs "python-ipython")
528 "/bin/")))
529 #t)))))
530 (inputs
531 `(("python-ipython" ,python-ipython)))
532 (propagated-inputs
533 `(("ruby-bond" ,ruby-bond)
534 ("ruby-data_uri" ,ruby-data_uri)
535 ("ruby-mimemagic" ,ruby-mimemagic)
536 ("ruby-multi-json" ,ruby-multi-json)
537 ("ruby-cztop" ,ruby-cztop)
538 ;; Optional inputs
539 ("ruby-pry" ,ruby-pry)))
540 (synopsis "Ruby kernel for Jupyter/IPython")
541 (description
542 "This package provides a Ruby kernel for Jupyter/IPython frontends (e.g.
543notebook).")
544 (home-page "https://github.com/SciRuby/iruby")
545 (license license:expat)))
546
eb0c2dd6
DT
547;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
548;; dependencies use RSpec for their test suites! To avoid these circular
549;; dependencies, we disable tests for all of the RSpec-related packages.
87688ff3 550(define-public ruby-rspec-support
eb0c2dd6
DT
551 (package
552 (name "ruby-rspec-support")
bee67d18 553 (version "3.8.0")
eb0c2dd6
DT
554 (source (origin
555 (method url-fetch)
e83c6d00 556 (uri (rubygems-uri "rspec-support" version))
eb0c2dd6
DT
557 (sha256
558 (base32
bee67d18 559 "0p3m7drixrlhvj2zpc38b11x145bvm311x6f33jjcxmvcm0wq609"))))
eb0c2dd6
DT
560 (build-system ruby-build-system)
561 (arguments
562 '(#:tests? #f)) ; avoid dependency cycles
563 (synopsis "RSpec support library")
564 (description "Support utilities for RSpec gems.")
565 (home-page "https://github.com/rspec/rspec-support")
566 (license license:expat)))
567
568(define-public ruby-rspec-core
569 (package
570 (name "ruby-rspec-core")
bee67d18 571 (version "3.8.0")
eb0c2dd6
DT
572 (source (origin
573 (method url-fetch)
e83c6d00 574 (uri (rubygems-uri "rspec-core" version))
eb0c2dd6
DT
575 (sha256
576 (base32
bee67d18 577 "1p1s5bnbqp3sxk67y0fh0x884jjym527r0vgmhbm81w7aq6b7l4p"))))
eb0c2dd6
DT
578 (build-system ruby-build-system)
579 (arguments
580 '(#:tests? #f)) ; avoid dependency cycles
581 (propagated-inputs
582 `(("ruby-rspec-support" ,ruby-rspec-support)))
583 (synopsis "RSpec core library")
584 (description "Rspec-core provides the RSpec test runner and example
585groups.")
586 (home-page "https://github.com/rspec/rspec-core")
587 (license license:expat)))
e6962009 588
64c318f2
BW
589(define-public ruby-rspec-core-2
590 (package (inherit ruby-rspec-core)
591 (version "2.14.8")
592 (source (origin
593 (method url-fetch)
594 (uri (rubygems-uri "rspec-core" version))
595 (sha256
596 (base32
597 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
598 (propagated-inputs `())))
599
20c05ea9 600(define-public ruby-diff-lcs
e6962009
DT
601 (package
602 (name "ruby-diff-lcs")
e2fcef39 603 (version "1.3")
e6962009
DT
604 (source (origin
605 (method url-fetch)
e83c6d00 606 (uri (rubygems-uri "diff-lcs" version))
e6962009
DT
607 (sha256
608 (base32
e2fcef39 609 "18w22bjz424gzafv6nzv98h0aqkwz3d9xhm7cbr1wfbyas8zayza"))))
e6962009
DT
610 (build-system ruby-build-system)
611 (arguments
612 '(#:tests? #f)) ; avoid dependency cycles
613 (synopsis "Compute the difference between two Enumerable sequences")
614 (description "Diff::LCS computes the difference between two Enumerable
615sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
616It includes utilities to create a simple HTML diff output format and a
617standard diff-like tool.")
618 (home-page "https://github.com/halostatue/diff-lcs")
619 (license license:expat)))
620
621(define-public ruby-rspec-expectations
622 (package
623 (name "ruby-rspec-expectations")
bee67d18 624 (version "3.8.2")
e6962009
DT
625 (source (origin
626 (method url-fetch)
e83c6d00 627 (uri (rubygems-uri "rspec-expectations" version))
e6962009
DT
628 (sha256
629 (base32
bee67d18 630 "18l21hy1zdc2pgc2yb17k3n2al1khpfr0z6pijlm852iz6vj0dkm"))))
e6962009
DT
631 (build-system ruby-build-system)
632 (arguments
633 '(#:tests? #f)) ; avoid dependency cycles
634 (propagated-inputs
635 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 636 ("ruby-diff-lcs" ,ruby-diff-lcs)))
e881752c 637 (synopsis "RSpec expectations library")
e6962009
DT
638 (description "Rspec-expectations provides a simple API to express expected
639outcomes of a code example.")
640 (home-page "https://github.com/rspec/rspec-expectations")
641 (license license:expat)))
4f2a0cac 642
fb157f25
BW
643(define-public ruby-rspec-expectations-2
644 (package (inherit ruby-rspec-expectations)
645 (version "2.14.5")
646 (source (origin
647 (method url-fetch)
648 (uri (rubygems-uri "rspec-expectations" version))
649 (sha256
650 (base32
651 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
652 (propagated-inputs
653 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
654
818b402c
MC
655(define-public ruby-sorcerer
656 (package
657 (name "ruby-sorcerer")
658 (version "2.0.1")
659 (source
660 (origin
661 (method url-fetch)
662 (uri (rubygems-uri "sorcerer" version))
663 (sha256
664 (base32
665 "0d32ha9pp9slpmsm027pkdpbr9vc5jn2m8rl6hwwx6a87m8cr58h"))))
666 (build-system ruby-build-system)
667 (synopsis "Ripper-style abstract syntax tree to Ruby source generator")
668 (description "Sorcerer generates Ruby code from a Ripper-like abstract
669syntax tree (i.e. S-Expressions). Sorcerer is targeted mainly at small
7230f6d5
TGR
670snippets of Ruby code, expressible in a single line. Longer examples may be
671re-sourced, but they will be rendered in a single-line format.")
818b402c
MC
672 (home-page "https://github.com/rspec-given/sorcerer")
673 (license license:expat)))
674
906b9a14
MC
675(define-public ruby-given-core
676 (package
677 (name "ruby-given-core")
678 (version "3.8.0")
679 (source
680 (origin
681 (method url-fetch)
682 (uri (rubygems-uri "given_core" version))
683 (sha256
684 (base32
685 "1lzyqllbbv6as3qgwz2007mvy7wy247bgkch9adnmh1zfa73bkrg"))))
686 (build-system ruby-build-system)
687 (arguments '(#:tests? #f)) ;no test suite for the core package
688 (propagated-inputs
689 `(("ruby-sorcerer" ,ruby-sorcerer)))
690 (synopsis "Core abstractions used by rspec-given and minitest-given")
691 (description "Given_core is the basic functionality behind rspec-given and
692minitest-given, extensions that allow the use of Given/When/Then terminology
693when defining specifications.")
694 (home-page "https://github.com/rspec-given/rspec-given")
695 (license license:expat)))
696
9c171558
MC
697(define-public ruby-rspec-given
698 (package
699 (name "ruby-rspec-given")
700 (version "3.8.0")
701 (source
702 (origin
703 (method url-fetch)
704 (uri (rubygems-uri "rspec-given" version))
705 (sha256
706 (base32
707 "1783bazja10kbha8hk15khvybsq88siyax02cpkk688604h54nji"))))
708 (build-system ruby-build-system)
709 (arguments
710 `(#:test-target "rs"
711 #:phases
712 (modify-phases %standard-phases
713 (add-after 'unpack 'fix-rakefile
714 (lambda _
715 (substitute* '("Rakefile" "rakelib/gemspec.rake")
716 (("require '\\./lib/given/.*") "")
717 (("Given::VERSION") (format #f "~s" ,version))
718 ;; Fix the error: "cannot load such file -- example_helper"
719 (("sh \"rspec")
720 "sh \"rspec -Ilib:examples"))
721 #t))
722 (add-after 'extract-gemspec 'delete-failing-tests
723 ;; See: https://github.com/jimweirich/rspec-given/issues/57.
724 (lambda _
725 (substitute* ".gemspec"
726 (("\"spec/lib/given/natural_assertion_spec.rb\".freeze, ")
727 "")
728 (("\"examples/integration/failing_messages_spec.rb\".freeze, ")
729 ""))
730 (delete-file "spec/lib/given/natural_assertion_spec.rb")
731 (delete-file "examples/integration/failing_messages_spec.rb")
732 #t)))))
733 (native-inputs
734 `(("ruby-rspec" ,ruby-rspec)
735 ("ruby-minitest" ,ruby-minitest)))
736 (propagated-inputs
737 `(("ruby-given-core" ,ruby-given-core)
738 ("ruby-rspec" ,ruby-rspec)))
739 (synopsis "Given/When/Then for RSpec and Minitest")
740 (description "Given is an RSpec extension that allows the use of
741Given/When/Then terminology when defining specifications, in a way similar to
742the Cucumber Gherkin language.")
743 (home-page "https://github.com/rspec-given/rspec-given")
744 (license license:expat)))
745
999ffb26
DM
746(define-public ruby-rspec-its
747 (package
748 (name "ruby-rspec-its")
b2244c68 749 (version "1.3.0")
999ffb26
DM
750 (source
751 (origin
3306f02a
CB
752 (method git-fetch)
753 (uri (git-reference
b0e7b699 754 (url "https://github.com/rspec/rspec-its")
3306f02a
CB
755 (commit (string-append "v" version))))
756 (file-name (git-file-name name version))
999ffb26
DM
757 (sha256
758 (base32
b2244c68 759 "02mlsc9d4d1cjj5vahi8v3q8hyn9fyiv8nnlidhgfh186qp20g1p"))))
999ffb26
DM
760 (build-system ruby-build-system)
761 (arguments
3306f02a
CB
762 `(#:test-target "spec"
763 #:phases
764 (modify-phases %standard-phases
765 (add-after 'unpack 'dont-install-gems-from-gemfile
766 (lambda _
767 (substitute* "Gemfile"
768 (("rspec rspec-core rspec-expectations rspec-mocks rspec-support")
769 ""))
770 #t))
7c8eb479 771 (add-before 'build 'loosen-ffi-requirement
b2244c68 772 (lambda _
7c8eb479 773 ;; Accept any version of ruby-ffi.
b2244c68 774 (substitute* "Gemfile"
7c8eb479
MB
775 ((" gem 'ffi', '~> 1\\.9\\.25'")
776 " gem 'ffi'"))
b2244c68 777 #t))
3306f02a
CB
778 (add-before 'build 'remove-unnecessary-dependency-versions-from-gemfile
779 (lambda _
780 (substitute* "rspec-its.gemspec"
781 (("rake.*") "rake'\n")
b2244c68
BH
782 (("spec.add_development_dependency 'cucumber'.*")
783 "spec.add_development_dependency 'cucumber'\n")
3306f02a 784 (("bundler.*") "bundler'\n")
b2244c68 785 (("\"aruba.*") "'aruba'\n"))
3306f02a 786 #t)))))
999ffb26
DM
787 (propagated-inputs
788 `(("ruby-rspec-core" ,ruby-rspec-core)
789 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
3306f02a
CB
790 (native-inputs
791 `(("bundler" ,bundler)
792 ("ruby-cucumber" ,ruby-cucumber)
b2244c68 793 ("ruby-ffi" ,ruby-ffi)
3306f02a
CB
794 ("ruby-aruba" ,ruby-aruba)))
795 (synopsis "RSpec extension that provides the @code{its} method")
796 (description
797 "RSpec::Its provides the its method as a short-hand to specify the expected
798value of an attribute. For example, one can use @code{its(:size)\\{should
799eq(1)\\}}.")
999ffb26
DM
800 (home-page "https://github.com/rspec/rspec-its")
801 (license license:expat)))
802
d7bd7016
MC
803;;; This variant is used to break a cycle with ruby-protobuf.
804(define-public ruby-rspec-its-minimal
805 (hidden-package
806 (package
807 (inherit ruby-rspec-its)
808 (arguments
809 (substitute-keyword-arguments (package-arguments ruby-rspec-its)
810 ((#:tests? _ #f) #f)))
811 (native-inputs '()))))
812
4f2a0cac
DT
813(define-public ruby-rspec-mocks
814 (package
815 (name "ruby-rspec-mocks")
bee67d18 816 (version "3.8.0")
4f2a0cac
DT
817 (source (origin
818 (method url-fetch)
e83c6d00 819 (uri (rubygems-uri "rspec-mocks" version))
4f2a0cac
DT
820 (sha256
821 (base32
bee67d18 822 "06y508cjqycb4yfhxmb3nxn0v9xqf17qbd46l1dh4xhncinr4fyp"))))
4f2a0cac
DT
823 (build-system ruby-build-system)
824 (arguments
825 '(#:tests? #f)) ; avoid dependency cycles
826 (propagated-inputs
827 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 828 ("ruby-diff-lcs" ,ruby-diff-lcs)))
4f2a0cac
DT
829 (synopsis "RSpec stubbing and mocking library")
830 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
831support for stubbing and mocking.")
832 (home-page "https://github.com/rspec/rspec-mocks")
833 (license license:expat)))
d4fde1f2 834
6da9adeb
BW
835(define-public ruby-rspec-mocks-2
836 (package (inherit ruby-rspec-mocks)
837 (version "2.14.6")
838 (source (origin
839 (method url-fetch)
840 (uri (rubygems-uri "rspec-mocks" version))
841 (sha256
842 (base32
843 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
844 (propagated-inputs
845 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
846
198bc648
CB
847(define-public ruby-rspec-rerun
848 (package
849 (name "ruby-rspec-rerun")
850 (version "1.1.0")
851 (source
852 (origin
853 (method url-fetch)
854 (uri (rubygems-uri "rspec-rerun" version))
855 (sha256
856 (base32
857 "1gy7znkcaqhpccfnk2nvaqbsvgxy3q57cmjwkl9fi1zabaq5lbkj"))))
858 (build-system ruby-build-system)
859 (arguments
860 '(;; No included tests
861 #:tests? #f))
862 (propagated-inputs `(("ruby-rspec" ,ruby-rspec)))
863 (synopsis "Track failed RSpec tests to re-run them")
864 (description
865 "This package provides an automated way to track, and then re-run failed
866RSpec tests.")
867 (home-page "https://github.com/dblock/rspec-rerun")
868 (license license:expat)))
869
9c4cb1ef
CD
870(define-public ruby-rspec-wait
871 (package
872 (name "ruby-rspec-wait")
873 (version "0.0.9")
874 (source
875 (origin
876 (method url-fetch)
877 (uri (rubygems-uri "rspec-wait" version))
878 (sha256
879 (base32
880 "0gvj1bp5ccx001dyvcgk2j49s5sl6vs9fdaqqb08z3bd1554hsww"))))
881 (build-system ruby-build-system)
882 (arguments
883 '(#:phases
884 (modify-phases %standard-phases
885 (replace 'check
886 (lambda _
887 (invoke "rake" "spec"))))))
888 (native-inputs
889 `(("bundler" ,bundler)))
890 (propagated-inputs
891 `(("ruby-rspec" ,ruby-rspec)))
892 (home-page "https://github.com/laserlemon/rspec-wait")
893 (synopsis "Wait for conditions in RSpec")
894 (description
895 "RSpec::Wait strives to make it easier to test asynchronous or slow
896interactions.")
897 (license license:expat)))
898
d4fde1f2
DT
899(define-public ruby-rspec
900 (package
901 (name "ruby-rspec")
bee67d18 902 (version "3.8.0")
d4fde1f2
DT
903 (source (origin
904 (method url-fetch)
e83c6d00 905 (uri (rubygems-uri "rspec" version))
d4fde1f2
DT
906 (sha256
907 (base32
bee67d18 908 "15ppasvb9qrscwlyjz67ppw1lnxiqnkzx5vkx1bd8x5n3dhikxc3"))))
d4fde1f2
DT
909 (build-system ruby-build-system)
910 (arguments
911 '(#:tests? #f)) ; avoid dependency cycles
912 (propagated-inputs
913 `(("ruby-rspec-core" ,ruby-rspec-core)
914 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
915 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
916 (synopsis "Behavior-driven development framework for Ruby")
917 (description "RSpec is a behavior-driven development (BDD) framework for
918Ruby. This meta-package includes the RSpec test runner, along with the
919expectations and mocks frameworks.")
35739712 920 (home-page "https://rspec.info/")
d4fde1f2 921 (license license:expat)))
2cbc105b 922
5ac984b3
BW
923(define-public ruby-rspec-2
924 (package (inherit ruby-rspec)
925 (version "2.14.1")
926 (source (origin
927 (method url-fetch)
928 (uri (rubygems-uri "rspec" version))
929 (sha256
930 (base32
931 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
932 (propagated-inputs
933 `(("ruby-rspec-core" ,ruby-rspec-core-2)
934 ("ruby-rspec-mocks" ,ruby-rspec-mocks-2)
935 ("ruby-rspec-expectations" ,ruby-rspec-expectations-2)))))
936
2cbc105b
DT
937;; Bundler is yet another source of circular dependencies, so we must disable
938;; its test suite as well.
939(define-public bundler
940 (package
941 (name "bundler")
cbee8e31 942 (version "2.1.4")
2cbc105b
DT
943 (source (origin
944 (method url-fetch)
e83c6d00 945 (uri (rubygems-uri "bundler" version))
2cbc105b
DT
946 (sha256
947 (base32
cbee8e31 948 "12glbb1357x91fvd004jgkw7ihlkpc9dwr349pd7j83isqhls0ah"))))
2cbc105b
DT
949 (build-system ruby-build-system)
950 (arguments
951 '(#:tests? #f)) ; avoid dependency cycles
952 (synopsis "Ruby gem bundler")
953 (description "Bundler automatically downloads and installs a list of gems
954specified in a \"Gemfile\", as well as their dependencies.")
2f3800e5 955 (home-page "https://bundler.io/")
2cbc105b 956 (license license:expat)))
98b87b82 957
cf36174f
RW
958(define-public ruby-builder
959 (package
960 (name "ruby-builder")
42b48db2 961 (version "3.2.3")
cf36174f
RW
962 (source (origin
963 (method url-fetch)
964 (uri (rubygems-uri "builder" version))
965 (sha256
966 (base32
42b48db2 967 "0qibi5s67lpdv1wgcj66wcymcr04q6j4mzws6a479n0mlrmh5wr1"))))
cf36174f
RW
968 (build-system ruby-build-system)
969 (arguments
970 `(#:phases
971 (modify-phases %standard-phases
972 (add-after 'unpack 'do-not-use-rvm
973 (lambda _
974 (substitute* "rakelib/tags.rake"
975 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
976 #t)))))
977 (synopsis "Ruby library to create structured data")
978 (description "Builder provides a number of builder objects that make it
979easy to create structured data. Currently the following builder objects are
980supported: XML Markup and XML Events.")
981 (home-page "https://github.com/jimweirich/builder")
982 (license license:expat)))
983
566f71f8
CB
984(define-public ruby-bump
985 (package
986 (name "ruby-bump")
987 (version "0.7.0")
988 (source
989 (origin
990 (method url-fetch)
991 (uri (rubygems-uri "bump" version))
992 (sha256
993 (base32
994 "1xinbr9rzh6cj75x24niwgqcnbhdxc68a8bc41lk8xv6fd906fym"))))
995 (build-system ruby-build-system)
996 (arguments
997 '(;; No included tests
998 #:tests? #f))
999 (synopsis "Tool for working with Rubygems")
1000 (description
1001 "Bump provides commands to manage Rubygem versioning, updating to the
1002next patch version for example.")
1003 (home-page "https://github.com/gregorym/bump")
1004 (license license:expat)))
1005
ad79eb55
RW
1006(define-public ruby-rjb
1007 (package
1008 (name "ruby-rjb")
aeb4e61e 1009 (version "1.5.5")
ad79eb55
RW
1010 (source (origin
1011 (method url-fetch)
1012 (uri (rubygems-uri "rjb" version))
1013 (sha256
1014 (base32
aeb4e61e 1015 "1ppj8rbicj3w0nhh7f73mflq19yd7pzdzkh2a91hcvphriy5b0ca"))))
ad79eb55
RW
1016 (build-system ruby-build-system)
1017 (arguments
1018 `(#:tests? #f ; no rakefile
1019 #:phases
1020 (modify-phases %standard-phases
1021 (add-before 'build 'set-java-home
1022 (lambda* (#:key inputs #:allow-other-keys)
1023 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
1024 #t)))))
1025 (native-inputs
d2540f80 1026 `(("jdk" ,icedtea "jdk")))
ad79eb55
RW
1027 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
1028 (description "RJB is a bridge program that connects Ruby and Java via the
1029Java Native Interface.")
2f3800e5 1030 (home-page "https://www.artonx.org/collabo/backyard/?RubyJavaBridge")
ad79eb55
RW
1031 (license license:lgpl2.1+)))
1032
f9ae2c06
PP
1033(define-public ruby-log4r
1034 (package
1035 (name "ruby-log4r")
1036 (version "1.1.10")
1037 (source
1038 (origin
1039 (method url-fetch)
1040 (uri (rubygems-uri "log4r" version))
1041 (sha256
1042 (base32
1043 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
1044 (build-system ruby-build-system)
1045 (arguments
1046 '(#:tests? #f)) ; no Rakefile in gem
1047 (synopsis "Flexible logging library for Ruby")
1048 (description "Comprehensive and flexible logging library written
1049in Ruby for use in Ruby programs. It features a hierarchical logging
1050system of any number of levels, custom level names, logger
1051inheritance, multiple output destinations per log event, execution
1052tracing, custom formatting, thread safteyness, XML and YAML
1053configuration, and more.")
1054 (home-page "http://log4r.rubyforge.org/")
1055 (license license:bsd-3)))
1056
71a03c29
RW
1057(define-public ruby-atoulme-antwrap
1058 (package
1059 (name "ruby-atoulme-antwrap")
1060 (version "0.7.5")
1061 (source (origin
1062 (method url-fetch)
1063 (uri (rubygems-uri "atoulme-Antwrap" version))
1064 (sha256
1065 (base32
1066 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
1067 (build-system ruby-build-system)
1068 ;; Test data required for most of the tests are not included.
1069 (arguments `(#:tests? #f))
1070 (native-inputs
1071 `(("ruby-hoe" ,ruby-hoe)))
1072 (inputs
1073 `(("ruby-rjb" ,ruby-rjb)))
1074 (synopsis "Ruby wrapper for the Ant build tool")
1075 (description "Antwrap is a Ruby module that wraps the Apache Ant build
1076tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
1077script.")
1078 (home-page "http://rubyforge.org/projects/antwrap/")
1079 (license license:expat)))
1080
fe1ddad5
RW
1081(define-public ruby-atoulme-saikuro
1082 (package
1083 (name "ruby-atoulme-saikuro")
1084 (version "1.2.1")
1085 (source (origin
1086 (method url-fetch)
1087 (uri (rubygems-uri "atoulme-Saikuro" version))
1088 (sha256
1089 (base32
1090 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
1091 (build-system ruby-build-system)
1092 ;; FIXME: There are no unit tests. The tests are demonstrations of the
1093 ;; "saikuro" tool.
1094 (arguments `(#:tests? #f))
1095 (synopsis "Cyclomatic complexity analyzer")
1096 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
1097given Ruby source code Saikuro will generate a report listing the cyclomatic
1098complexity of each method found. In addition, Saikuro counts the number of
1099lines per method and can generate a listing of the number of tokens on each
1100line of code.")
1101 (home-page "http://www.github.com/atoulme/Saikuro")
1102 ;; File headers contain the BSD-3 license and the README.rdoc says that
1103 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
1104 ;; of the Expat license.
1105 (license license:bsd-3)))
1106
ff350f98
GL
1107(define-public ruby-awesome-print
1108 (package
1109 (name "ruby-awesome-print")
1110 (version "1.8.0")
1111 (source
1112 (origin
1113 (method url-fetch)
1114 (uri (rubygems-uri "awesome_print" version))
1115 (sha256
1116 (base32
1117 "14arh1ixfsd6j5md0agyzvksm5svfkvchb90fp32nn7y3avcmc2h"))))
1118 (build-system ruby-build-system)
1119 (arguments
1120 `(#:phases
1121 (modify-phases %standard-phases
1122 (replace 'check
1123 (lambda _
1124 ;; Remove failing test.
1125 (for-each delete-file
1126 '("spec/ext/nokogiri_spec.rb"
1127 "spec/colors_spec.rb"
1128 "spec/formats_spec.rb"
1129 "spec/methods_spec.rb"
1130 "spec/misc_spec.rb"
1131 "spec/objects_spec.rb"))
1132 (invoke "rspec" "-c" "spec"))))))
1133 (native-inputs
1134 `(("ruby-nokogiri" ,ruby-nokogiri)
1135 ("ruby-rspec" ,ruby-rspec)
1136 ("ruby-simplecov" ,ruby-simplecov)))
1137 (synopsis "Pretty print Ruby objects to visualize their structure")
1138 (description
1139 "Ruby dubugging companion: pretty print Ruby objects to visualize their
1140structure. Supports custom object formatting via plugins.")
1141 (home-page "https://github.com/awesome-print/awesome_print")
1142 (license license:expat)))
1143
c84dd8d4
MC
1144(define-public ruby-pandoc-ruby
1145 (package
1146 (name "ruby-pandoc-ruby")
1147 (version "2.1.4")
1148 (source
1149 (origin
1150 (method git-fetch) ;the gem lacks many test files
1151 (uri (git-reference
b0e7b699 1152 (url "https://github.com/xwmx/pandoc-ruby")
c84dd8d4
MC
1153 (commit version)))
1154 (file-name (git-file-name name version))
1155 (sha256
1156 (base32
1157 "03a11clhycyn0jhc7g9davpqd83sn60jqwjy1y145ag9sq6sp935"))))
1158 (build-system ruby-build-system)
1159 (arguments
1160 `(#:phases
1161 (modify-phases %standard-phases
1162 (add-after 'unpack 'disable-failing-tests
1163 ;; TODO: Remove this phase after ghc-pandoc gets upgraded to 2.9.2+
1164 ;; (see: https://github.com/xwmx/pandoc-ruby/issues/39).
1165 (lambda _
1166 (substitute* "test/test_conversions.rb"
1167 (("next if from == to.*" all)
1168 (string-append
1169 all
1170 " next if ['plain', 'beamer'].include? to\n")))
1171 #t))
1172 (add-after 'unpack 'patch-pandoc-path
1173 (lambda* (#:key inputs #:allow-other-keys)
8cc8e584 1174 (let ((pandoc (string-append (assoc-ref inputs "pandoc")
c84dd8d4
MC
1175 "/bin/pandoc")))
1176 (substitute* "lib/pandoc-ruby.rb"
1177 (("@@pandoc_path = 'pandoc'")
1178 (format #f "@@pandoc_path = '~a'" pandoc)))
1179 (substitute* "test/test_pandoc_ruby.rb"
1180 (("('|\")pandoc" _ quote)
1181 (string-append quote pandoc))
1182 (("\\^pandoc")
1183 ".*pandoc"))
1184 #t)))
1185 (add-after 'extract-gemspec 'remove-Gemfile.lock
1186 (lambda _
1187 (delete-file "Gemfile.lock")
1188 (substitute* "pandoc-ruby.gemspec"
1189 (("Gemfile\\.lock") ""))
1190 #t)))))
1191 (native-inputs
1192 `(("ruby-mocha" ,ruby-mocha)))
1193 (inputs
8cc8e584 1194 `(("pandoc" ,pandoc)))
c84dd8d4
MC
1195 (synopsis "Ruby wrapper for Pandoc")
1196 (description "PandocRuby is a wrapper for Pandoc, a Haskell library with
1197command line tools for converting one markup format to another. Pandoc can
1198convert documents from a variety of formats including markdown,
1199reStructuredText, textile, HTML, DocBook, LaTeX, and MediaWiki markup to a
1200variety of other formats, including markdown, reStructuredText, HTML, LaTeX,
1201ConTeXt, PDF, RTF, DocBook XML, OpenDocument XML, ODT, GNU Texinfo, MediaWiki
1202markup, groff man pages, HTML slide shows, EPUB, Microsoft Word docx, and
1203more.")
1204 (home-page "https://github.com/xwmx/pandoc-ruby")
1205 (license license:expat)))
1206
0af8398b
GL
1207(define-public ruby-patron
1208 (package
1209 (name "ruby-patron")
1210 (version "0.13.3")
1211 (source
1212 (origin
1213 (method url-fetch)
1214 (uri (rubygems-uri "patron" version))
1215 (sha256
1216 (base32
1217 "0523gddx88zql2mq6655k60gy2ac8vybpzkcf90lmd9nx7wl3fi9"))))
1218 (build-system ruby-build-system)
1219 (inputs
1220 `(("curl" ,curl)))
1221 (arguments
1222 `(#:tests? #f)) ; no included tests
1223 (synopsis "Ruby HTTP client library based on @code{libcurl}")
1224 (description
1225 "Patron is a Ruby HTTP client library based on @code{libcurl}. It does
1226not try to expose the full power (read complexity) of @code{libcurl} but
1227instead tries to provide a sane API while taking advantage of @code{libcurl}
1228under the hood.")
1229 (home-page "https://github.com/toland/patron")
1230 (license license:expat)))
1231
fef0564c
MC
1232(define-public ruby-slim
1233 (package
1234 (name "ruby-slim")
1235 (version "4.1.0")
1236 (source
1237 (origin
1238 (method url-fetch)
1239 (uri (rubygems-uri "slim" version))
1240 (sha256
1241 (base32
1242 "0gjx30g84c82qzg32bd7giscvb4206v7mvg56kc839w9wjagn36n"))))
1243 (build-system ruby-build-system)
1244 (arguments
1245 `(#:phases
1246 (modify-phases %standard-phases
1247 ;; See: https://github.com/slim-template/slim/issues/857 and
1248 ;; https://github.com/slim-template/slim/issues/858.
1249 (add-after 'unpack 'skip-broken-tests
1250 (lambda _
1251 (substitute* "test/core/test_embedded_engines.rb"
1252 (("def test_render_with_markdown")
1253 "def skipped_test_render_with_markdown"))
1254 (substitute* "test/translator/test_translator.rb"
1255 (("raise (\"Missing test for.*)" _ tail)
1256 (string-append "print " tail)))
1257 #t))
1258 ;; See: https://salsa.debian.org/ruby-team/ruby-slim/-/commit/
1259 ;; 824862bd99d1675bc699d8fc71ba965a785c1f44.
1260 (add-after 'unpack 'prevent-bundler-interference
1261 (lambda _
1262 (substitute* "Rakefile"
1263 (("require 'bundler/setup'") "nil")
1264 (("Bundler::GemHelper\\.install_tasks") "nil"))
1265 #t)))))
1266 (native-inputs
1267 `(("ruby-rack-test" ,ruby-rack-test)
1268 ("ruby-sinatra" ,ruby-sinatra)))
1269 (propagated-inputs
1270 `(("ruby-temple" ,ruby-temple)
1271 ("ruby-tilt" ,ruby-tilt)))
1272 (synopsis "Minimalist template language for Ruby")
1273 (description "Slim is a template language for Ruby that aims to reduce the
1274syntax to the minimum while remaining clear.")
1275 (home-page "http://slim-lang.com/")
1276 (license license:expat)))
1277
34138e42
BW
1278(define-public ruby-asciidoctor
1279 (package
751bf33d 1280 (name "ruby-asciidoctor")
5df1126c 1281 (version "2.0.10")
751bf33d
MC
1282 (source
1283 (origin
5df1126c
MC
1284 (method git-fetch) ;the gem release lacks a Rakefile
1285 (uri (git-reference
b0e7b699 1286 (url "https://github.com/asciidoctor/asciidoctor")
5df1126c
MC
1287 (commit (string-append "v" version))))
1288 (file-name (git-file-name name version))
751bf33d 1289 (sha256
34138e42 1290 (base32
5df1126c 1291 "0jaxpnsdnx3qyjw5p2lsx1swny12q1i2vxw2kgdp4vlsyjv95z95"))))
751bf33d
MC
1292 (build-system ruby-build-system)
1293 (arguments
1294 `(#:test-target "test:all"
1295 #:phases
1296 (modify-phases %standard-phases
5df1126c 1297 (replace 'replace-git-ls-files
751bf33d 1298 (lambda _
5df1126c
MC
1299 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1300 ;; git ls-files output is merged in ruby-build-system.
1301 (substitute* "asciidoctor.gemspec"
1302 (("`git ls-files -z`")
1303 "`find . -type f -print0 |sort -z|cut -zc3-`"))
1304 #t))
1305 (add-after 'extract-gemspec 'strip-version-requirements
1306 (lambda _
1307 (delete-file "Gemfile")
1308 (substitute* "asciidoctor.gemspec"
1309 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1310 (string-append stripped "\n")))
751bf33d
MC
1311 #t)))))
1312 (native-inputs
5df1126c
MC
1313 `(("ruby-erubis" ,ruby-erubis)
1314 ("ruby-minitest" ,ruby-minitest)
751bf33d
MC
1315 ("ruby-nokogiri" ,ruby-nokogiri)
1316 ("ruby-asciimath" ,ruby-asciimath)
5df1126c
MC
1317 ("ruby-coderay" ,ruby-coderay)
1318 ("ruby-cucumber" ,ruby-cucumber)
1319 ("ruby-haml" ,ruby-haml)
1320 ("ruby-rouge" ,ruby-rouge)
1321 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
1322 ("ruby-simplecov" ,ruby-simplecov)
1323 ("ruby-slim" ,ruby-slim)
1324 ("ruby-tilt" ,ruby-tilt)))
751bf33d
MC
1325 (synopsis "Converter from AsciiDoc content to other formats")
1326 (description "Asciidoctor is a text processor and publishing toolchain for
1327converting AsciiDoc content to HTML5, DocBook 5 (or 4.5), PDF, and other
1328formats.")
1329 (home-page "https://asciidoctor.org")
1330 (license license:expat)))
34138e42 1331
15b188c3
MC
1332(define-public ruby-prawn-icon
1333 (package
1334 (name "ruby-prawn-icon")
1335 (version "2.5.0")
1336 (source
1337 (origin
1338 (method url-fetch)
1339 (uri (rubygems-uri "prawn-icon" version))
1340 (sha256
1341 (base32
1342 "1ivkdf8rdf92hhy97vbmc2a4w97vcvqd58jcj4z9hz3hfsb1526w"))))
1343 (build-system ruby-build-system)
1344 (arguments
1345 `(#:test-target "spec"
1346 #:phases (modify-phases %standard-phases
1347 (add-after 'unpack 'remove-unnecessary-dependencies
1348 (lambda _
1349 (substitute* '("Rakefile" "spec/spec_helper.rb")
1350 ((".*[Bb]undler.*") "")
1351 (("^require 'rubocop.*") "")
1352 (("^RuboCop.*") ""))
1353 #t)))))
1354 (native-inputs
1355 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
1356 ("ruby-pdf-reader" ,ruby-pdf-reader)
1357 ("ruby-rspec" ,ruby-rspec)
1358 ("ruby-simplecov" ,ruby-simplecov)))
1359 (propagated-inputs
1360 `(("ruby-prawn" ,ruby-prawn)))
1361 (synopsis "Icon fonts for use with the Prawn PDF toolkit")
1362 (description "@code{Prawn::Icon} provides various icon fonts including
1363FontAwesome, PaymentFont and Foundation Icons for use with the Prawn PDF
1364toolkit.")
1365 (home-page "https://github.com/jessedoyle/prawn-icon/")
1366 (license %prawn-project-licenses)))
1367
2d877f6e
MC
1368(define-public ruby-css-parser
1369 (package
1370 (name "ruby-css-parser")
1371 (version "1.7.1")
1372 (source
1373 (origin
1374 (method url-fetch)
1375 (uri (rubygems-uri "css_parser" version))
1376 (sha256
1377 (base32
1378 "04c4dl8cm5rjr50k9qa6yl9r05fk9zcb1zxh0y0cdahxlsgcydfw"))))
1379 (build-system ruby-build-system)
1380 (arguments `(#:tests? #f)) ;gem doesn't ship with test suite
1381 (propagated-inputs
1382 `(("ruby-addressable" ,ruby-addressable)))
1383 (synopsis "Ruby Cascading Style Sheets (CSS) parser")
1384 (description "This package allows loading, parsing and cascading Cascading
1385Style Sheets (CSS) rule sets in Ruby.")
1386 (home-page "https://github.com/premailer/css_parser")
1387 (license license:expat)))
1388
95692655
MC
1389(define-public ruby-prawn-svg
1390 (package
1391 (name "ruby-prawn-svg")
1392 (version "0.30.0")
1393 (source
1394 (origin
1395 (method url-fetch)
1396 (uri (rubygems-uri "prawn-svg" version))
1397 (sha256
1398 (base32
1399 "0df3l49cy3xpwi0b73hmi2ykbjg9kjwrvhk0k3z7qhh5ghmmrn77"))))
1400 (build-system ruby-build-system)
1401 (arguments
1402 `(#:phases (modify-phases %standard-phases
1403 (add-after 'unpack 'do-not-use-bundler
1404 (lambda _
1405 (substitute* "spec/spec_helper.rb"
1406 ((".*[Bb]undler.*") ""))
1407 #t))
1408 (replace 'check
1409 (lambda* (#:key tests? #:allow-other-keys)
1410 (when tests?
1411 (invoke "rspec" "-Ilib" "-rprawn-svg"))
1412 #t)))))
1413 (native-inputs
1414 `(("ruby-rspec" ,ruby-rspec)))
1415 (propagated-inputs
1416 `(("ruby-css-parser" ,ruby-css-parser)
1417 ("ruby-prawn" ,ruby-prawn)))
1418 (synopsis "SVG renderer for the Prawn PDF library")
1419 (description "This library allows rendering Scalable Vector Graphics (SVG)
1420graphics directly into a Portable Document Format (PDF) document using the
1421Prawn module.")
1422 (home-page "https://github.com/mogest/prawn-svg")
1423 (license license:expat)))
1424
ce52f2b1
MC
1425(define-public ruby-prawn-templates
1426 (package
1427 (name "ruby-prawn-templates")
1428 (version "0.1.2")
1429 (source
1430 (origin
1431 (method git-fetch)
1432 (uri (git-reference
8ed4c468 1433 (url "https://github.com/prawnpdf/prawn-templates")
ce52f2b1
MC
1434 (commit version)))
1435 (file-name (git-file-name name version))
1436 (sha256
1437 (base32
1438 "0wll54wxxwixpwazfn4ffbqvqbfrl01cfsv8y11vnlzy7isx5xvl"))))
1439 (build-system ruby-build-system)
1440 (arguments
1441 `(#:phases (modify-phases %standard-phases
1442 (add-after 'unpack 'do-not-use-bundler
1443 (lambda _
1444 (substitute* "spec/spec_helper.rb"
1445 ((".*[Bb]undler.*") ""))
1446 #t))
1447 (replace 'check
1448 (lambda* (#:key tests? #:allow-other-keys)
1449 (when tests?
1450 (invoke "rspec"))
1451 #t)))))
1452 (native-inputs
1453 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
1454 ("ruby-rspec" ,ruby-rspec)))
1455 (propagated-inputs
1456 `(("ruby-pdf-reader" ,ruby-pdf-reader)
1457 ("ruby-prawn" ,ruby-prawn)))
1458 (synopsis "Prawn extension to include or combine PDF documents")
1459 (description "This @strong{unmaintained} package provides a Prawn
1460extension that allows including other Portable Document Format (PDF) documents
1461as background or combining several PDF documents into one. This functionality
1462used to be part of Prawn itself, but was extracted from Prawn 0.15.0 because
1463of its many longstanding issues.")
1464 (home-page "https://github.com/prawnpdf/prawn-templates")
1465 (license %prawn-project-licenses)))
1466
f949b60e
MC
1467(define-public ruby-polyglot
1468 (package
1469 (name "ruby-polyglot")
1470 (version "0.3.5")
1471 (source
1472 (origin
1473 (method url-fetch)
1474 (uri (rubygems-uri "polyglot" version))
1475 (sha256
1476 (base32
1477 "1bqnxwyip623d8pr29rg6m8r0hdg08fpr2yb74f46rn1wgsnxmjr"))))
1478 (build-system ruby-build-system)
1479 (arguments `(#:tests? #f)) ;no test suite
1480 (synopsis "Augment @code{require} to load non-Ruby file types")
1481 (description "The Polyglot library allows a Ruby module to register a
1482loader for the file type associated with a filename extension, and it augments
1483@code{require} to find and load matching files.")
1484 (home-page "https://github.com/cjheath/polyglot")
1485 (license license:expat)))
1486
1f183ca0
MC
1487(define-public ruby-treetop
1488 (package
1489 (name "ruby-treetop")
1490 (version "1.6.10")
1491 (source
1492 (origin
1493 (method git-fetch) ;no test suite in distributed gem
1494 (uri (git-reference
8ed4c468 1495 (url "https://github.com/cjheath/treetop")
1f183ca0
MC
1496 (commit (string-append "v" version))))
1497 (file-name (git-file-name name version))
1498 (sha256
1499 (base32
1500 "1dmk94z6ivhrz5hsq68vl5vgydhkz89n394rha1ymddw3rymbfcv"))))
1501 (build-system ruby-build-system)
1502 (arguments
1503 `(#:test-target "spec"
1504 #:phases
1505 (modify-phases %standard-phases
1506 (replace 'replace-git-ls-files
1507 (lambda _
1508 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1509 ;; git ls-files output is merged in ruby-build-system.
1510 (substitute* "treetop.gemspec"
1511 (("`git ls-files -z`")
1512 "`find . -type f -print0 |sort -z|cut -zc3-`"))
1513 #t)))))
1514 (native-inputs
1515 `(("ruby-activesupport" ,ruby-activesupport)
1516 ("ruby-rr" ,ruby-rr)
1517 ("ruby-rspec" ,ruby-rspec)))
1518 (propagated-inputs
1519 `(("ruby-polyglot" ,ruby-polyglot)))
1520 (synopsis "Ruby-based parsing DSL based on parsing expression grammars")
1521 (description "This package provides a Ruby-based Parsing Expression
1522Grammar (PEG) parser generator Domain Specific Language (DSL).")
1523 (home-page "https://github.com/cjheath/treetop")
1524 (license license:expat)))
1525
b47c85a5
GL
1526(define-public ruby-typhoeus
1527 (package
1528 (name "ruby-typhoeus")
1529 (version "1.4.0")
1530 (source
1531 (origin
1532 (method url-fetch)
1533 (uri (rubygems-uri "typhoeus" version))
1534 (sha256
1535 (base32
1536 "1m22yrkmbj81rzhlny81j427qdvz57yk5wbcf3km0nf3bl6qiygz"))))
1537 (build-system ruby-build-system)
1538 (arguments
1539 `(#:tests? #f)) ; no included tests
1540 (propagated-inputs
1541 `(("ruby-ethon" ,ruby-ethon)))
1542 (synopsis "@code{libcurl} wrapper in Ruby")
1543 (description
1544 "Like a modern code version of the mythical beast with 100 serpent heads,
1545Typhoeus runs HTTP requests in parallel while cleanly encapsulating handling
1546logic.")
1547 (home-page "https://github.com/typhoeus/typhoeus")
1548 (license license:expat)))
1549
8588e668
EF
1550(define-public ruby-rubocop-rspec
1551 (package
1552 (name "ruby-rubocop-rspec")
1553 (version "2.2.0")
1554 (source
1555 (origin
1556 (method git-fetch)
1557 (uri (git-reference
1558 (url "https://github.com/rubocop-hq/rubocop-rspec")
1559 (commit (string-append "v" version))))
1560 (file-name (git-file-name name version))
1561 (sha256
1562 (base32
1563 "0gdpjpympb6qc77bang759z7z6lckf14ghkx8v6614agxg8l3g5y"))))
1564 (build-system ruby-build-system)
1565 (arguments
1566 '(#:test-target "internal_investigation"
1567 #:phases
1568 (modify-phases %standard-phases
1569 (add-before 'check 'set-HOME
1570 (lambda _
1571 (setenv "HOME" "/tmp")
1572 #t)))))
1573 (propagated-inputs
1574 `(("ruby-rubocop" ,ruby-rubocop)
1575 ("ruby-rubocop-ast" ,ruby-rubocop-ast)))
1576 (native-inputs
1577 `(("ruby-rack" ,ruby-rack)
1578 ("ruby-rspec" ,ruby-rspec)
1579 ("ruby-rubocop-performance" ,ruby-rubocop-performance)
1580 ("ruby-simplecov" ,ruby-simplecov)
1581 ("ruby-yard" ,ruby-yard)))
1582 (synopsis "Code style checking for RSpec files")
1583 (description "This package provides a plugin for the RuboCop code style
1584enforcing & linting tool.")
1585 (home-page "https://github.com/rubocop-hq/rubocop-rspec")
1586 (license license:expat)))
1587
301d1bac
EF
1588(define-public ruby-rubocop-rspec-minimal
1589 (hidden-package
1590 (package
1591 (inherit ruby-rubocop-rspec)
1592 (arguments
1593 (substitute-keyword-arguments (package-arguments ruby-rubocop-rspec)
1594 ((#:tests? _ #f) #f)))
1595 (propagated-inputs '())
1596 (native-inputs '()))))
1597
66861792
MC
1598(define-public ruby-rubocop-performance
1599 (package
1600 (name "ruby-rubocop-performance")
cc128eef 1601 (version "1.9.2")
66861792
MC
1602 (source
1603 (origin
cc128eef
EF
1604 (method git-fetch)
1605 (uri (git-reference
1606 (url "https://github.com/rubocop-hq/rubocop-performance")
1607 (commit (string-append "v" version))))
1608 (file-name (git-file-name name version))
66861792
MC
1609 (sha256
1610 (base32
cc128eef 1611 "04lmkmz6c0ccs5miikrww7lakp7y6xz00g7b47ay7rn7sx5j6qyf"))))
66861792
MC
1612 (build-system ruby-build-system)
1613 (arguments
cc128eef
EF
1614 `(#:tests? #f ; tests require a git checkout of rubocop's source code.
1615 #:phases
1616 (modify-phases %standard-phases
1617 (replace 'replace-git-ls-files
1618 (lambda _
1619 (substitute* "rubocop-performance.gemspec"
1620 (("`git ls-files -z config lib LICENSE.txt README.md`")
1621 "`find config lib LICENSE.txt README.md -type f -print0 |sort -z`"))
1622 #t))
1623 (add-before 'check 'set-HOME
1624 (lambda _
1625 (setenv "HOME" "/tmp")
1626 #t)))))
66861792 1627 (propagated-inputs
cc128eef
EF
1628 `(("ruby-rubocop" ,ruby-rubocop)
1629 ("ruby-rubocop-ast" ,ruby-rubocop-ast)))
1630 (native-inputs
1631 `(("ruby-bump" ,ruby-bump)
1632 ("ruby-yard" ,ruby-yard)))
66861792
MC
1633 (synopsis "Performance optimizations checkers for Ruby code")
1634 (description "This package provides a collection of RuboCop cops to check
1635for performance optimizations in Ruby code.")
1636 (home-page "https://docs.rubocop.org/rubocop-performance/")
1637 (license license:expat)))
1638
301d1bac
EF
1639(define-public ruby-rubocop-performance-minimal
1640 (hidden-package
1641 (package
1642 (inherit ruby-rubocop-performance)
1643 (arguments
1644 (substitute-keyword-arguments (package-arguments ruby-rubocop-performance)
1645 ((#:tests? _ #f) #f)))
1646 (propagated-inputs '())
1647 (native-inputs '()))))
1648
c7ab342a
MC
1649(define-public ruby-gimme
1650 (let ((revision "1")
1651 (commit "4e71f0236f1271871916dd403261d26533db34c0"))
1652 (package
1653 (name "ruby-gimme")
1654 (version (git-version "0.5.0" revision commit))
1655 (source
1656 (origin
1657 (method git-fetch)
1658 (uri (git-reference
8ed4c468 1659 (url "https://github.com/searls/gimme")
c7ab342a
MC
1660 (commit commit)))
1661 (file-name (git-file-name name version))
1662 (sha256
1663 (base32
1664 "0hrd32ygvf3i7h47ak8f623cz8ns9q7g60nnnvvlnywbggjaz3h6"))))
1665 (build-system ruby-build-system)
1666 (native-inputs
1667 `(("ruby-coveralls" ,ruby-coveralls)
1668 ("ruby-cucumber" ,ruby-cucumber)
1669 ("ruby-pry" ,ruby-pry)
1670 ("ruby-simplecov" ,ruby-simplecov)
1671 ("ruby-rspec-given" ,ruby-rspec-given)))
1672 (arguments
1673 `(;; The cucumber task fails with error: "index 3 out of matches
1674 ;; (IndexError)", apparently due to our newer Cucumber version.
1675 ;; TODO: Try the "default" task with a future release.
1676 #:test-target "spec"
1677 #:phases
1678 (modify-phases %standard-phases
1679 (add-after 'extract-gemspec 'prepare-for-tests
1680 (lambda _
1681 ;; Delete failing tests (possibly due to our newer rspec
1682 ;; version).
1683 (delete-file "spec/gimme/gives_class_methods_spec.rb")
1684 (delete-file "spec/gimme/rspec_adapter_spec.rb")
1685 (delete-file "spec/gimme/verifies_class_methods_spec.rb")
1686 ;; Fix duplicate version requirements and de-register files.
1687 (delete-file "Gemfile")
1688 (delete-file "Gemfile.lock")
1689 (substitute* "gimme.gemspec"
1690 ((".*\"Gemfile\".*") "")
1691 ((".*\"Gemfile\\.lock\",.*") "")
1692 ((".*(rspec|cucumber).*\">= 0\".*") "")
1693 (("\"spec/gimme/gives_class_methods_spec.rb\",") "")
1694 (("\"spec/gimme/rspec_adapter_spec.rb\",") "")
1695 (("\"spec/gimme/verifies_class_methods_spec.rb\",") "")
1696 ;; All of these gems relate to development, and are
1697 ;; unnecessary when running the tests.
1698 ((".*(add|gem).*guard-.*") "")
1699 ((".*(add|gem).*jeweler.*") "")
1700 ((".*(add|gem).*pry.*") "")
1701 ((".*(add|gem).*growl.*") "")
1702 ((".*(add|gem).*rb-fsevent.*") ""))
1703 #t)))))
1704 (synopsis "Lightweight test double library for Ruby")
1705 (description "Gimme is a very lightweight test double library for Ruby,
1706based on Mockito (a mocking framework for Java). It is an opinionated (but
1707not noisy) means to facilitate test-driving by enabling the authors to specify
1708only what they care about.")
1709 (home-page "https://github.com/searls/gimme")
1710 (license license:expat))))
1711
97295c2a
MC
1712(define-public ruby-standard
1713 (package
1714 (name "ruby-standard")
1715 (version "0.4.7")
1716 (source
1717 (origin
1718 (method git-fetch) ;no test suite in distributed gem
1719 (uri (git-reference
8ed4c468 1720 (url "https://github.com/testdouble/standard")
97295c2a
MC
1721 (commit (string-append "v" version))))
1722 (file-name (git-file-name name version))
1723 (sha256
1724 (base32
1725 "0ylx0lm2pbbgr5h7fban592w96bl3wxmvfcpcdfrhkxnpg5kiwgv"))))
1726 (build-system ruby-build-system)
1727 (arguments
1728 ;; TODO: the tests are currently broken due to using a newer Rubocop.
1729 `(#:tests? #f
1730 #:phases
1731 (modify-phases %standard-phases
1732 (add-after 'unpack 'relax-version-requiremens
1733 (lambda _
1734 (delete-file "Gemfile")
1735 (delete-file "Gemfile.lock")
1736 #t))
1737 (replace 'replace-git-ls-files
1738 (lambda _
1739 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1740 ;; git ls-files output is merged in ruby-build-system.
1741 (substitute* "standard.gemspec"
1742 (("`git ls-files -z`")
1743 "`find . -type f -not -regex '.*\\.gem$' -print0 \
1744|sort -z|cut -zc3-`"))
1745 #t)))))
1746 (native-inputs
1747 `(("ruby-gimme" ,ruby-gimme)
1748 ("ruby-pry" ,ruby-pry)
1749 ("ruby-simplecov" ,ruby-simplecov)))
1750 (propagated-inputs
1751 `(("ruby-rubocop" ,ruby-rubocop)
1752 ("ruby-rubocop-performance" ,ruby-rubocop-performance)))
1753 (synopsis "Ruby Style Guide, with linter & automatic code fixer")
1754 (description "Standard is a port of StandardJS. Like StandardJS, it aims
1755to save time in the following ways:
1756@itemize
1757@item No configuration.
1758@item Automatically format code.
1759@item Catch style issues and programmer errors early.
1760@end itemize")
1761 (home-page "https://github.com/testdouble/standard")
1762 (license license:expat)))
1763
db9f951b 1764(define-public ruby-chunky-png
4c91f184
MC
1765 (package
1766 (name "ruby-chunky-png")
d065517b 1767 (version "1.3.14")
4c91f184
MC
1768 (source
1769 (origin
1770 (method git-fetch)
1771 (uri (git-reference
8ed4c468 1772 (url "https://github.com/wvanbergen/chunky_png")
4c91f184
MC
1773 (commit (string-append "v" version))))
1774 (file-name (git-file-name name version))
1775 (sha256
d065517b 1776 (base32 "1m7y11ix38h5a2pj5v81qdmvqh980ql9hp62hk2dxwkwsa4nh22h"))))
4c91f184
MC
1777 (build-system ruby-build-system)
1778 (arguments
1779 `(#:test-target "spec"
1780 #:phases
1781 (modify-phases %standard-phases
1782 (add-after 'unpack 'disable-bundler
1783 (lambda _
1784 (substitute* (find-files "." "\\.rb$")
1785 (("require.*bundler/setup.*") ""))
1786 #t))
1787 (replace 'replace-git-ls-files
1788 (lambda _
1789 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1790 ;; git ls-files output is merged in ruby-build-system.
1791 (substitute* "chunky_png.gemspec"
1792 (("`git ls-files`")
1793 "`find . -type f -not -regex '.*\\.gem$' |sort |cut -c3-`"))
1794 #t)))))
1795 (native-inputs
1796 `(("bundler" ,bundler)
1797 ("ruby-rspec" ,ruby-rspec)
1798 ("ruby-standard" ,ruby-standard)
1799 ("ruby-yard" ,ruby-yard)))
1800 (synopsis "Ruby library to handle PNG images")
1801 (description "ChunkyPNG is a pure Ruby library that can read and write
db9f951b
MC
1802Portable Network Graphics (PNG) images without depending on an external image
1803library. It tries to be memory efficient and reasonably fast. It has
1804features such as:
1805@itemize
1806@item
1807Decoding support for any image that the PNG standard allows. This includes all
1808standard color modes, all bit depths, all transparency, and interlacing and
1809filtering options.
1810@item
1811Encoding support for images of all color modes (true color, grayscale, and
1812indexed) and transparency for all these color modes. The best color mode is
1813chosen automatically, based on the amount of used colors.
1814@item Read/write access to the image's pixels.
1815@item Read/write access to all image metadata that is stored in chunks.
1816@item
1817Memory efficiency: @code{fixnum} are used, i.e. 4 or 8 bytes of memory per
1818pixel, depending on the hardware).
1819@item
1820Performance: ChunkyPNG is reasonably fast for Ruby standards, by only using
1821integer math and a highly optimized saving routine.
1822@item Interoperability with RMagick.
ed02857b
TGR
1823@end itemize
1824
1825ChunkyPNG is vulnerable to decompression bombs and can run out of memory when
1826loading a specifically crafted PNG file. This is hard to fix in pure Ruby.
1827Deal with untrusted images in a separate process, e.g., by using @code{fork}
1828or a background processing library.")
4c91f184
MC
1829 (home-page "https://github.com/wvanbergen/chunky_png/wiki")
1830 (license license:expat)))
db9f951b 1831
f421785b
MC
1832(define-public ruby-text-hyphen
1833 (package
1834 (name "ruby-text-hyphen")
1835 (version "1.4.1")
1836 (source
1837 (origin
1838 (method url-fetch)
1839 (uri (rubygems-uri "text-hyphen" version))
1840 (sha256
1841 (base32
1842 "1gj4awvs9ryf960m0iawg43jyjmfwcqgfwrbcfp890a57b9ag7q1"))))
1843 (build-system ruby-build-system)
1844 (native-inputs
1845 `(("ruby-hoe" ,ruby-hoe)))
1846 (synopsis "Ruby library to hyphenate words in various languages")
1847 (description "Text::Hyphen is a Ruby library to hyphenate words in various
1848languages using Ruby-fied versions of TeX hyphenation patterns. It will
1849properly hyphenate various words according to the rules of the language the
1850word is written in. The algorithm is based on that of the TeX typesetting
1851system by Donald E. Knuth.")
1852 (home-page "https://github.com/halostatue/text-hyphen")
1853 ;; The whole is licensed under the Expat license, but parts use various
1854 ;; versions of the LaTeX Project Public License.
1855 (license license:expat)))
1856
7d94616d
MC
1857(define-public ruby-open-uri-cached
1858 (package
1859 (name "ruby-open-uri-cached")
1860 (version "0.0.5")
1861 (source
1862 (origin
1863 (method url-fetch)
1864 (uri (rubygems-uri "open-uri-cached" version))
1865 (sha256
1866 (base32
1867 "13xy2vhrgz9mdxhklw5fszhamsdxh8ysf3l40g92hqm4hm288wap"))))
1868 (build-system ruby-build-system)
1869 (arguments
1870 `(#:tests? #f)) ;no test suite
1871 (synopsis "OpenURI with transparent disk caching")
1872 (description "OpenURI with transparent disk caching, which is
1873useful to avoid making excessive queries, for example when scraping
1874web pages.")
1875 (home-page "https://github.com/tigris/open-uri-cached")
1876 (license license:expat)))
1877
9c5a7d00
MC
1878(define-public ruby-asciidoctor-pdf
1879 ;; Use the latest commit, as the last tag doesn't build with the
1880 ;; latest Ruby dependencies in Guix.
1881 (let ((revision "1")
1882 (commit "d257440df895d1595a3825ef58b32e4b290ba1c3"))
1883 (package
1884 (name "ruby-asciidoctor-pdf")
1885 (version (git-version "1.5.3" revision commit))
1886 (source
1887 (origin
1888 (method git-fetch) ;no test suite in the distributed gem
1889 (uri (git-reference
8ed4c468 1890 (url "https://github.com/asciidoctor/asciidoctor-pdf")
9c5a7d00
MC
1891 (commit commit)))
1892 (file-name (git-file-name name version))
1893 (sha256
1894 (base32
1895 "1563d11ghzsrsg4inwfwj6b9hb5sk5b429f49fwq5qg3sq76kgjj"))))
1896 (build-system ruby-build-system)
1897 (arguments
1898 `(#:test-target "spec"
1899 #:phases
1900 (modify-phases %standard-phases
1901 (add-after 'unpack 'remove-failing-tests
1902 ;; Two tests module fail for unknown reasons, *only* when
1903 ;; ran in the build container (see:
1904 ;; https://github.com/asciidoctor/asciidoctor-pdf/issues/1725#issuecomment-658777965).
1905 (lambda _
1906 (delete-file "spec/audio_spec.rb")
1907 (delete-file "spec/video_spec.rb")
1908 #t))
1909 (add-after 'extract-gemspec 'strip-version-requirements
1910 (lambda _
1911 (substitute* "asciidoctor-pdf.gemspec"
1912 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1913 (string-append stripped "\n")))
1914 #t))
1915 (replace 'replace-git-ls-files
1916 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1917 ;; git ls-files output is merged in ruby-build-system.
1918 (lambda _
1919 (substitute* "asciidoctor-pdf.gemspec"
1920 (("`git ls-files -z`")
1921 "`find . -type f -not -regex '.*\\.gem$' -print0 \
1922|sort -z|cut -zc3-`"))
1923 #t))
1924 ;; The tests rely on the Gem being installed, so move the check phase
1925 ;; after the install phase.
1926 (delete 'check)
1927 (add-after 'install 'check
1928 (lambda* (#:key outputs tests? #:allow-other-keys)
1929 (let ((new-gem (string-append (assoc-ref outputs "out")
1930 "/lib/ruby/vendor_ruby")))
1931 (setenv "GEM_PATH"
1932 (string-append (getenv "GEM_PATH") ":" new-gem))
1933 (when tests?
1934 (invoke "rspec" "-t" "~visual" "-t" "~cli" "-t" "~network"))
1935 #t))))))
1936 (native-inputs
1937 `(("ruby-chunky-png" ,ruby-chunky-png)
1938 ("ruby-coderay" ,ruby-coderay)
1939 ("ruby-pdf-inspector" ,ruby-pdf-inspector)
1940 ("ruby-rouge" ,ruby-rouge)
1941 ("ruby-rspec" ,ruby-rspec)))
1942 (propagated-inputs
1943 `(("ruby-asciidoctor" ,ruby-asciidoctor)
1944 ("ruby-concurrent-ruby" ,ruby-concurrent)
1945 ("ruby-open-uri-cached" ,ruby-open-uri-cached)
1946 ("ruby-prawn" ,ruby-prawn)
1947 ("ruby-prawn-icon" ,ruby-prawn-icon)
1948 ("ruby-prawn-svg" ,ruby-prawn-svg)
1949 ("ruby-prawn-table" ,ruby-prawn-table)
1950 ("ruby-prawn-templates" ,ruby-prawn-templates)
1951 ("ruby-safe-yaml" ,ruby-safe-yaml)
1952 ("ruby-text-hyphen" ,ruby-text-hyphen)
1953 ("ruby-thread-safe" ,ruby-thread-safe)
1954 ("ruby-treetop" ,ruby-treetop)
1955 ("ruby-ttfunk" ,ruby-ttfunk)))
1956 (synopsis"AsciiDoc to Portable Document Format (PDF)} converter")
1957 (description "Asciidoctor PDF is an extension for Asciidoctor that
1958converts AsciiDoc documents to Portable Document Format (PDF) using the Prawn
1959PDF library. It has features such as:
1960@itemize
1961@item Direct AsciiDoc to PDF conversion
1962@item Configuration-driven theme (style and layout)
1963@item Scalable Vector Graphics (SVG) support
1964@item PDF document outline (i.e., bookmarks)
1965@item Table of contents page(s)
1966@item Document metadata (title, authors, subject, keywords, etc.)
1967@item Internal cross reference links
1968@item Syntax highlighting with Rouge, Pygments, or CodeRay
1969@item Page numbering
1970@item Customizable running content (header and footer)
1971@item
1972“Keep together” blocks (i.e., page breaks avoided in certain block content)
1973@item Orphaned section titles avoided
1974@item Autofit verbatim blocks (as permitted by base_font_size_min setting)
1975@item Table border settings honored
1976@item Font-based icons
1977@item Custom TrueType (TTF) fonts
1978@item Double-sided printing mode (margins alternate on recto and verso pages)
1979@end itemize")
1980 (home-page "https://asciidoctor.org/docs/asciidoctor-pdf")
1981 (license license:expat))))
1982
d5840f77
CB
1983(define-public ruby-ast
1984 (package
1985 (name "ruby-ast")
308104f8 1986 (version "2.4.1")
d5840f77
CB
1987 (source
1988 (origin
308104f8
MC
1989 (method git-fetch) ;no test included in gem from v2.4.1
1990 (uri (git-reference
1991 (url "https://github.com/whitequark/ast")
1992 (commit (string-append "v" version))))
1993 (file-name (git-file-name name version))
d5840f77
CB
1994 (sha256
1995 (base32
308104f8 1996 "0k8vya256chimy473g818gim06m5rjgh6mz5sc5g8xz3csh3rysi"))))
d5840f77
CB
1997 (build-system ruby-build-system)
1998 (arguments
1999 '(#:phases
2000 (modify-phases %standard-phases
2001 (add-after 'unpack 'remove-coveralls-requirement
2002 (lambda _
2003 (substitute* "test/helper.rb"
2004 (("require 'coveralls'") "")
2005 (("Coveralls::SimpleCov::Formatter") ""))
2006 #t))
2007 (add-after 'extract-gemspec 'remove-unnecessary-requirements
2008 (lambda _
2009 (substitute* "ast.gemspec"
2010 ((".*coveralls.*") "\n")
2011 (("%q<rest-client>.*") "%q<rest-client>.freeze, [\">= 0\"])\n")
2012 (("%q<mime-types>.*") "%q<mime-types>.freeze, [\">= 0\"])\n")
2013 (("%q<rake>.*") "%q<rake>.freeze, [\">= 0\"])\n"))
2014 #t)))))
2015 (native-inputs
2016 `(("bundler" ,bundler)
2017 ("ruby-simplecov" ,ruby-simplecov)
2018 ("ruby-json-pure" ,ruby-json-pure)
2019 ("ruby-mime-times" ,ruby-mime-types)
2020 ("ruby-yard" ,ruby-yard)
2021 ("ruby-kramdown" ,ruby-kramdown)
2022 ("ruby-rest-client" ,ruby-rest-client)
2023 ("ruby-bacon" ,ruby-bacon)
2024 ("ruby-bacon-colored-output" ,ruby-bacon-colored-output)
2025 ("ruby-racc" ,ruby-racc)))
2026 (synopsis "Library for working with Abstract Syntax Trees")
2027 (description
2028 "@code{ast} is a Ruby library for working with Abstract Syntax Trees.
2029It does this through immutable data structures.")
2030 (home-page "https://whitequark.github.io/ast/")
2031 (license license:expat)))
2032
b88502c9
BW
2033(define-public ruby-sporkmonger-rack-mount
2034 ;; Testing the addressable gem requires a newer commit than that released, so
2035 ;; use an up to date version.
2036 (let ((revision "1")
2037 (commit "076aa2c47d9a4c081f1e9bcb56a826a9e72bd5c3"))
2038 (package
2039 (name "ruby-sporkmonger-rack-mount")
2040 (version (git-version "0.8.3" revision commit))
2041 (source (origin
2042 (method git-fetch)
2043 (uri (git-reference
b0e7b699 2044 (url "https://github.com/sporkmonger/rack-mount")
b88502c9
BW
2045 (commit commit)))
2046 (file-name (git-file-name name version))
2047 (sha256
2048 (base32
2049 "1scx273g3xd93424x9lxc4zyvcp2niknbw5mkz6wkivpf7xsyxdq"))))
2050 (build-system ruby-build-system)
2051 (arguments
2052 ;; Tests currently fail so disable them.
2053 ;; https://github.com/sporkmonger/rack-mount/pull/1
2054 `(#:tests? #f))
2055 (propagated-inputs `(("ruby-rack" ,ruby-rack)))
2056 (synopsis "Stackable dynamic tree based Rack router")
2057 (description
2058 "@code{Rack::Mount} supports Rack's @code{X-Cascade} convention to
2059continue trying routes if the response returns pass. This allows multiple
2060routes to be nested or stacked on top of each other.")
2061 (home-page "https://github.com/sporkmonger/rack-mount")
2062 (license license:expat))))
2063
2f9e0b68
RW
2064(define-public ruby-ci-reporter
2065 (package
2066 (name "ruby-ci-reporter")
2067 (version "2.0.0")
2068 (source (origin
2069 (method url-fetch)
2070 (uri (rubygems-uri "ci_reporter" version))
2071 (sha256
2072 (base32
2073 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
2074 (build-system ruby-build-system)
2075 (arguments
2076 `(#:test-target "rspec"))
2077 (propagated-inputs
2078 `(("ruby-builder" ,ruby-builder)))
2079 (native-inputs
2080 `(("bundler" ,bundler)
2081 ("ruby-rspec" ,ruby-rspec)))
2082 (synopsis "Generate XML reports of runs test")
2083 (description
2084 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
2085you to generate XML reports of your test runs. The resulting files can be
2086read by a continuous integration system that understands Ant's JUnit report
2087format.")
2088 (home-page "https://github.com/nicksieger/ci_reporter")
2089 (license license:expat)))
2090
2ed201c1
CB
2091(define-public ruby-contracts
2092 (package
2093 (name "ruby-contracts")
2094 (version "0.16.0")
2095 (source
2096 (origin
2097 (method url-fetch)
2098 (uri (rubygems-uri "contracts" version))
2099 (sha256
2100 (base32
2101 "119f5p1n6r5svbx8h09za6a4vrsnj5i1pzr9cqdn9hj3wrxvyl3a"))))
2102 (build-system ruby-build-system)
2103 (arguments
2104 '(#:test-target "spec"
2105 #:phases
2106 (modify-phases %standard-phases
2107 ;; Don't run or require rubocop, the code linting tool, as this is a
2108 ;; bit unnecessary.
2109 (add-after 'unpack 'dont-run-rubocop
2110 (lambda _
2111 (substitute* "Rakefile"
2112 ((".*rubocop.*") "")
2113 ((".*RuboCop.*") ""))
2114 #t)))))
2115 (native-inputs
2116 `(("ruby-rspec" ,ruby-rspec)))
2117 (synopsis "Method contracts for Ruby")
2118 (description
2119 "This library provides contracts for Ruby. A contract describes the
2120correct inputs and output for a method, and will raise an error if a incorrect
2121value is found.")
2122 (home-page "https://github.com/egonSchiele/contracts.ruby")
2123 (license license:bsd-2)))
2124
6f8bf0eb
CB
2125(define-public ruby-crack
2126 (package
2127 (name "ruby-crack")
16c0cc5c 2128 (version "0.4.5")
6f8bf0eb
CB
2129 (source
2130 (origin
2131 (method url-fetch)
2132 (uri (rubygems-uri "crack" version))
2133 (sha256
2134 (base32
16c0cc5c 2135 "1cr1kfpw3vkhysvkk3wg7c54m75kd68mbm9rs5azdjdq57xid13r"))))
6f8bf0eb
CB
2136 (build-system ruby-build-system)
2137 (arguments
2138 `(#:phases
2139 (modify-phases %standard-phases
2140 (replace 'check
2141 (lambda* (#:key tests? #:allow-other-keys)
2142 (when tests?
2143 (for-each (lambda (file)
2144 (display file)(display "\n")
2145 (invoke "ruby" "-Ilib" "-Itest" "-rrubygems" file))
2146 (find-files "test" ".*rb$")))
2147 #t)))))
2148 (propagated-inputs
16c0cc5c 2149 `(("ruby-rexml" ,ruby-rexml)))
6f8bf0eb
CB
2150 (synopsis "Simple JSON and XML parsing for Ruby")
2151 (description
2152 "@code{crack} provides really simple JSON and XML parsing, extracted from
2153code in Merb and Rails.")
2154 (home-page "https://github.com/jnunemaker/crack")
2155 (license license:expat)))
2156
bef3506e
CB
2157(define-public ruby-cliver
2158 (package
2159 (name "ruby-cliver")
2160 (version "0.3.2")
2161 (source
2162 (origin
2163 (method url-fetch)
2164 (uri (rubygems-uri "cliver" version))
2165 (sha256
2166 (base32
2167 "096f4rj7virwvqxhkavy0v55rax10r4jqf8cymbvn4n631948xc7"))))
2168 (build-system ruby-build-system)
2169 (arguments
2170 '(#:phases
2171 (modify-phases %standard-phases
2172 ;; Avoid a incompatibility between rspec@2 and rake. Using rspec@3
2173 ;; would be nice, but the tests look to be incompatible:
2174 ;;
2175 ;; NoMethodError: undefined method `last_comment'
2176 (replace 'check
2177 (lambda* (#:key tests? #:allow-other-keys)
2178 (when tests?
2179 (invoke "rspec"))
2180 #t)))))
2181 (native-inputs
2182 `(("bundler" ,bundler)
2183 ("ruby-rspec" ,ruby-rspec-2)))
2184 (synopsis "Assertions for command-line dependencies in Ruby")
2185 (description
2186 "@code{cliver} provides a way to detect missing command-line
2187dependencies, including versions.")
2188 (home-page "https://github.com/yaauie/cliver")
2189 (license license:expat)))
2190
fe5dd5f4
CB
2191(define-public ruby-czmq-ffi-gen
2192 (package
2193 (name "ruby-czmq-ffi-gen")
2194 (version "0.13.0")
2195 (source
2196 (origin
2197 (method url-fetch)
2198 (uri (rubygems-uri "czmq-ffi-gen" version))
2199 (sha256
2200 (base32
2201 "1yf719dmf4mwks1hqdsy6i5kzfvlsha69sfnhb2fr2cgk2snbys3"))))
2202 (build-system ruby-build-system)
2203 (arguments
2204 '(#:tests? #f ;; Tests are not included in the release on rubygems.org
2205 #:phases
2206 (modify-phases %standard-phases
2207 (add-after 'unpack 'patch-lib_dirs
2208 (lambda* (#:key inputs #:allow-other-keys)
2209 (substitute* "lib/czmq-ffi-gen/czmq/ffi.rb"
2210 (("lib\\_dirs = \\[.*\\]")
2211 (string-append "lib_dirs = ['"
2212 (assoc-ref inputs "czmq") "/lib"
2213 "']")))
2214 (substitute* "lib/czmq-ffi-gen/libzmq.rb"
2215 (("lib\\_dirs = \\[.*\\]")
2216 (string-append "lib_dirs = ['"
2217 (assoc-ref inputs "zeromq") "/lib"
2218 "']"))))))))
2219 (inputs
2220 `(("zeromq" ,zeromq)
2221 ("czmq" ,czmq)))
2222 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
2223 (synopsis "Low-level Ruby bindings for CZMQ (generated using zproject)")
2224 (description
2225 "These Ruby bindings are not intended to be directly used, but rather
2226used by higher level bindings like those provided by CZTop.")
2227 (home-page
2228 "https://github.com/paddor/czmq-ffi-gen")
2229 (license license:isc)))
2230
d0afff26
CB
2231(define-public ruby-cztop
2232 (package
2233 (name "ruby-cztop")
2234 (version "0.12.2")
2235 (source
2236 (origin
2237 (method url-fetch)
2238 (uri (rubygems-uri "cztop" version))
2239 (sha256
2240 (base32
2241 "0yqbpaiw5d7f271d73lyrsh8xpx6n4zi6xqwfgi00dacxrq3s3fa"))))
2242 (build-system ruby-build-system)
2243 (arguments
2244 '(#:test-target "spec"
2245 #:phases
2246 (modify-phases %standard-phases
2247 (add-after 'unpack 'patch-lib_paths
2248 (lambda* (#:key inputs #:allow-other-keys)
2249 (substitute* "lib/cztop/poller/zmq.rb"
2250 (("lib\\_paths = \\[.*\\]")
2251 (string-append "lib_paths = ['"
2252 (assoc-ref inputs "zeromq") "/lib"
2253 "']"))))))))
2254 (native-inputs
2255 `(("bundler" ,bundler)
2256 ("ruby-rspec" ,ruby-rspec)))
2257 (inputs
2258 `(("zeromq" ,zeromq)))
2259 (propagated-inputs
2260 `(("ruby-czmq-ffi-gen" ,ruby-czmq-ffi-gen)))
2261 (synopsis "CZMQ Ruby bindings")
2262 (description
2263 "CZMQ Ruby bindings, based on the generated low-level FFI bindings of
2264CZMQ. The focus of of CZTop is on being easy to use and providing first class
2265support for security mechanisms.")
2266 (home-page "https://github.com/paddor/cztop")
2267 (license license:isc)))
2268
b004fb6a
RW
2269(define-public ruby-saikuro-treemap
2270 (package
2271 (name "ruby-saikuro-treemap")
2272 (version "0.2.0")
2273 (source (origin
2274 (method url-fetch)
2275 (uri (rubygems-uri "saikuro_treemap" version))
2276 (sha256
2277 (base32
2278 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
2279 (build-system ruby-build-system)
2280 ;; Some of the tests fail because the generated JSON has keys in a
2281 ;; different order. This is a problem with the test suite rather than any
2282 ;; of the involved libraries.
2283 (arguments `(#:tests? #f))
2284 (propagated-inputs
2285 `(("ruby-json-pure" ,ruby-json-pure)
2286 ("ruby-atoulme-saikuro" ,ruby-atoulme-saikuro)))
2287 (synopsis "Generate complexity treemap based on saikuro analysis")
2288 (description
2289 "This gem generates a treemap showing the complexity of Ruby code on
2290which it is run. It uses Saikuro under the covers to analyze Ruby code
2291complexity.")
7bf837fd 2292 (home-page "https://github.com/ThoughtWorksStudios/saikuro_treemap")
b004fb6a
RW
2293 (license license:expat)))
2294
92b37500
CB
2295(define-public ruby-oauth2
2296 (package
2297 (name "ruby-oauth2")
5dd10be5 2298 (version "1.4.2")
92b37500
CB
2299 (source
2300 (origin
2301 (method url-fetch)
2302 (uri (rubygems-uri "oauth2" version))
2303 (sha256
5dd10be5 2304 (base32 "15i9z4j5pcjkr30lkcd79xzbr4kpmy0bqgwa436fqyqk646fv036"))))
92b37500
CB
2305 (build-system ruby-build-system)
2306 (arguments
5dd10be5 2307 '(#:tests? #f)) ; no included tests
92b37500
CB
2308 (propagated-inputs
2309 `(("ruby-faraday" ,ruby-faraday)
2310 ("ruby-jwt" ,ruby-jwt)
2311 ("ruby-multi-json" ,ruby-multi-json)
2312 ("ruby-multi-xml" ,ruby-multi-xml)
2313 ("ruby-rack" ,ruby-rack)))
2314 (synopsis "Ruby wrapper for the OAuth 2.0")
2315 (description
2316 "This package provides a Ruby wrapper for the OAuth 2.0 protocol built
2317with a similar style to the original OAuth spec.")
2318 (home-page "https://github.com/oauth-xx/oauth2")
2319 (license license:expat)))
2320
29dc4823
CB
2321(define-public ruby-omniauth
2322 (package
2323 (name "ruby-omniauth")
984d6438 2324 (version "2.0.3")
29dc4823
CB
2325 (source
2326 (origin
2327 (method url-fetch)
2328 (uri (rubygems-uri "omniauth" version))
2329 (sha256
984d6438 2330 (base32 "105mzgvmn2kjaacxw01h4wqv33r7hfn5z8fxlkk3jcjar14j71bh"))))
29dc4823 2331 (build-system ruby-build-system)
29dc4823
CB
2332 (propagated-inputs
2333 `(("ruby-hashie" ,ruby-hashie)
984d6438
EF
2334 ("ruby-rack" ,ruby-rack)
2335 ("ruby-rack-protection" ,ruby-rack-protection)))
2336 (native-inputs
2337 `(("ruby-rspec" ,ruby-rspec)))
29dc4823
CB
2338 (synopsis "Generalized Rack framework for multiple-provider authentication")
2339 (description
2340 "This package provides a generalized Rack framework for multiple-provider
2341authentication.")
2342 (home-page "https://github.com/omniauth/omniauth")
2343 (license license:expat)))
2344
d6084cdb
CB
2345(define-public ruby-omniauth-oauth2
2346 (package
2347 (name "ruby-omniauth-oauth2")
51b3ea8d 2348 (version "1.7.1")
d6084cdb
CB
2349 (source
2350 (origin
2351 (method url-fetch)
2352 (uri (rubygems-uri "omniauth-oauth2" version))
2353 (sha256
2354 (base32
51b3ea8d 2355 "10fr2b58sp7l6nfdvxpbi67374hkrvsf507cvda89jjs0jacy319"))))
d6084cdb
CB
2356 (build-system ruby-build-system)
2357 (arguments
2358 '(#:phases
2359 (modify-phases %standard-phases
2360 (add-after 'unpack 'remove-unnecessary-dependencies
2361 (lambda _
2362 ;; The coveralls gem submits coverage information to an online
2363 ;; service, and is unnecessary when running the tests
2364 (substitute* "Gemfile"
2365 ((".*coveralls\"") ""))
2366 (substitute* "spec/helper.rb"
2367 (("require \"coveralls\"") "")
2368 (("Coveralls::SimpleCov::Formatter") ""))
2369 #t)))))
2370 (propagated-inputs
2371 `(("ruby-oauth2" ,ruby-oauth2)
2372 ("ruby-omniauth" ,ruby-omniauth)))
2373 (native-inputs
2374 `(("bundler" ,bundler)
2375 ("ruby-rspec" ,ruby-rspec)
2376 ("ruby-simplecov" ,ruby-simplecov)
2377 ("ruby-rack-test" ,ruby-rack-test)
a4d61297 2378 ("ruby-webmock" ,ruby-webmock)))
d6084cdb
CB
2379 (synopsis "Abstract OAuth2 strategy for OmniAuth")
2380 (description
2381 "This library provides a generic OAuth2 strategy for OmniAuth. It
2382doesn't provide a way to gather user information, so should be used as a
2383building block for authentication strategies.")
2384 (home-page "https://github.com/omniauth/omniauth-oauth2")
2385 (license license:expat)))
2386
433e3154
CB
2387(define-public ruby-open4
2388 (package
2389 (name "ruby-open4")
2390 (version "1.3.4")
2391 (source
2392 (origin
2393 (method url-fetch)
2394 (uri (rubygems-uri "open4" version))
2395 (sha256
2396 (base32
2397 "1cgls3f9dlrpil846q0w7h66vsc33jqn84nql4gcqkk221rh7px1"))))
2398 (build-system ruby-build-system)
2399 (arguments
2400 '(#:phases
2401 (modify-phases %standard-phases
2402 (add-after 'unpack 'patch
2403 (lambda _
2404 (substitute* "rakefile"
2405 ;; Update the Rakefile so it works
2406 (("-rubygems") "-rrubygems")
2407 (("Config") "RbConfig"))
2408 #t))
2409 (add-before 'check 'set-LIB
2410 (lambda _
2411 ;; This is used in the rakefile when running the tests
2412 (setenv "LIB" "open4")
2413 #t)))))
2414 (synopsis "Open child processes from Ruby and manage them easily")
2415 (description
2416 "@code{Open4} is a Ruby library to run child processes and manage their
2417input and output.")
2418 (home-page "https://github.com/ahoward/open4")
2419 (license license:ruby)))
2420
cef87ed6
CB
2421(define-public ruby-options
2422 (package
2423 (name "ruby-options")
2424 (version "2.3.2")
2425 (source
2426 (origin
2427 (method url-fetch)
2428 (uri (rubygems-uri "options" version))
2429 (sha256
2430 (base32
2431 "1s650nwnabx66w584m1cyw82icyym6hv5kzfsbp38cinkr5klh9j"))))
2432 (build-system ruby-build-system)
2433 (arguments
2434 '(#:tests? #f ;; TODO: NameError: uninitialized constant Config
2435 #:phases
2436 (modify-phases %standard-phases
2437 (add-before 'check 'set-LIB
2438 (lambda _
2439 ;; This is used in the Rakefile, and setting it avoids an issue
2440 ;; with running the tests.
fe27238c
CB
2441 (setenv "LIB" "options")
2442 #t)))))
cef87ed6
CB
2443 (synopsis "Ruby library to parse options from *args cleanly")
2444 (description
2445 "The @code{options} library helps with parsing keyword options in Ruby
2446functions.")
2447 (home-page "https://github.com/ahoward/options")
2448 (license license:ruby)))
2449
d15dbe83
CB
2450(define-public ruby-erubi
2451 (package
2452 (name "ruby-erubi")
2453 (version "1.8.0")
2454 (source
2455 (origin
2456 (method url-fetch)
2457 (uri (rubygems-uri "erubi" version))
2458 (sha256
2459 (base32
2460 "1kagnf6ziahj0d781s6ryy6fwqwa3ad4xbzzj84p9m4nv4c2jir1"))))
2461 (build-system ruby-build-system)
2462 (synopsis "ERB template engine for Ruby")
2463 (description
2464 "Erubi is a ERB template engine for Ruby. It is a simplified fork of
2465Erubis")
2466 (home-page "https://github.com/jeremyevans/erubi")
2467 (license license:expat)))
2468
d64ebebd
BW
2469(define-public ruby-erubis
2470 (package
2471 (name "ruby-erubis")
2472 (version "2.7.0")
2473 (source
2474 (origin
2475 (method url-fetch)
2476 (uri (rubygems-uri "erubis" version))
2477 (sha256
2478 (base32
2479 "1fj827xqjs91yqsydf0zmfyw9p4l2jz5yikg3mppz6d7fi8kyrb3"))))
2480 (build-system ruby-build-system)
2481 (arguments
2482 '(#:tests? #f)) ; tests do not run properly with Ruby 2.0
2483 (synopsis "Implementation of embedded Ruby (eRuby)")
2484 (description
2485 "Erubis is a fast implementation of embedded Ruby (eRuby) with several
2486features such as multi-language support, auto escaping, auto trimming spaces
2487around @code{<% %>}, a changeable embedded pattern, and Ruby on Rails
2488support.")
2489 (home-page "http://www.kuwata-lab.com/erubis/")
2490 (license license:expat)))
2491
45270b18
GL
2492(define-public ruby-ethon
2493 (package
2494 (name "ruby-ethon")
2495 (version "0.12.0")
2496 (source
2497 (origin
2498 (method url-fetch)
2499 (uri (rubygems-uri "ethon" version))
2500 (sha256
2501 (base32
2502 "0gggrgkcq839mamx7a8jbnp2h7x2ykfn34ixwskwb0lzx2ak17g9"))))
2503 (build-system ruby-build-system)
2504 (arguments
2505 `(#:tests? #f)) ; no included tests
2506 (inputs
2507 `(("curl" ,curl)))
2508 (propagated-inputs
2509 `(("ruby-ffi" ,ruby-ffi)))
2510 (synopsis "Very lightweight @code{libcurl} wrapper")
2511 (description
2512 "Ethon is a very basic @code{libcurl} wrapper using ffi.")
2513 (home-page "https://github.com/typhoeus/ethon")
2514 (license license:expat)))
2515
3ca43524
CB
2516(define-public ruby-execjs
2517 (package
2518 (name "ruby-execjs")
2519 (version "2.7.0")
2520 (source
2521 (origin
2522 ;; fetch from github as the gem does not contain testing code
2523 (method git-fetch)
2524 (uri (git-reference
b0e7b699 2525 (url "https://github.com/rails/execjs")
3ca43524
CB
2526 (commit (string-append "v" version))))
2527 (file-name (git-file-name name version))
2528 (sha256
2529 (base32
2530 "0c0vd2mmqq3ar4plbwi2wsbr31vn4h45i19r5km66skydnnbp1y6"))))
2531 (build-system ruby-build-system)
2532 (native-inputs
2533 `(("bundler" ,bundler)
2534 ;; The test suite tests all the available backends. Currenly, this just
2535 ;; means the node backend.
2536 ;;
2537 ;; PASSED: test:node
2538 ;; SKIPPED: test:duktape, ;; test:javascriptcore, test:jscript,
2539 ;; test:miniracer, test:rubyracer, ;; test:rubyrhino, test:v8
2540 ("node" ,node)))
2541 (synopsis "Run JavaScript code from Ruby")
2542 (description
2543 "ExecJS lets you run JavaScript code from Ruby. It automatically picks a
2544runtime to evaluate your JavaScript program, then returns the result to you as
2545a Ruby object.")
2546 (home-page "https://github.com/rails/execjs")
2547 (license license:expat)))
2548
6623a151
MB
2549(define-public ruby-fakefs
2550 (package
2551 (name "ruby-fakefs")
2552 (version "1.2.2")
2553 (home-page "https://github.com/fakefs/fakefs")
2554 (source (origin
2555 ;; The Rubygems release does not contain tests.
2556 (method git-fetch)
2557 (uri (git-reference
2558 (url home-page)
2559 (commit (string-append "v" version))))
2560 (file-name (git-file-name name version))
2561 (sha256
2562 (base32
2563 "008dq9knyip2bfbl0mrk8b8r7bv0k3bf128wcfqsgy1rqal4mgwk"))))
2564 (build-system ruby-build-system)
2565 (arguments
2566 '(#:phases (modify-phases %standard-phases
2567 (replace 'replace-git-ls-files
2568 (lambda _
2569 (substitute* "fakefs.gemspec"
2570 (("`git ls-files lib README.md LICENSE`")
2571 "`find lib README.md LICENSE -type f | sort`"))
2572 #t))
2573 (add-before 'check 'remove-version-constraints
2574 (lambda _
2575 ;; Drop hard version requirements for test dependencies.
2576 (substitute* "fakefs.gemspec"
2577 (("(.*add_development_dependency .*), .*" _ dep)
2578 (string-append dep "\n")))
a011f67b 2579 #t)))))
6623a151
MB
2580 (native-inputs
2581 `(("ruby-bump" ,ruby-bump)
2582 ("ruby-maxitest" ,ruby-maxitest)
2583 ("ruby-rubocop" ,ruby-rubocop)
2584 ("ruby-rspec" ,ruby-rspec)))
2585 (synopsis "Fake file system for Ruby")
2586 (description
2587 "This package provides a fake file system for use in test suites. It
2588avoids the need for manually creating temporary directories, or dealing
2589with platform intricacies in @code{File} and @code{FileUtils}.")
2590 (license license:expat)))
2591
cc53e630
RW
2592(define-public ruby-orderedhash
2593 (package
2594 (name "ruby-orderedhash")
2595 (version "0.0.6")
2596 (source (origin
2597 (method url-fetch)
2598 (uri (rubygems-uri "orderedhash" version))
2599 (sha256
2600 (base32
2601 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
2602 (build-system ruby-build-system)
2603 (arguments
2604 '(#:tests? #f)) ; no test suite
2605 (synopsis "Ruby library providing an order-preserving hash")
2606 (description "Orderedhash is a Ruby library providing a hash
2607implementation that preserves the order of items and features some array-like
2608extensions.")
2609 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
2610 (license license:public-domain)))
2611
28c5d42d
PP
2612(define-public ruby-libxml
2613 (package
2614 (name "ruby-libxml")
acbc5062 2615 (version "3.0.0")
28c5d42d
PP
2616 (source
2617 (origin
2618 (method url-fetch)
2619 (uri (rubygems-uri "libxml-ruby" version))
2620 (sha256
2621 (base32
acbc5062 2622 "0xy8wmjwjcnv36zi042678ncjzpxvy351ccbv7mzkns2n3kxfp54"))))
28c5d42d
PP
2623 (build-system ruby-build-system)
2624 (inputs
2625 `(("zlib" ,zlib)
2626 ("libxml2" ,libxml2)))
2627 (arguments
2628 '(#:tests? #f ; test suite hangs for unknown reason
2629 #:gem-flags
5b98944d
CB
2630 (list "--no-document" ; TODO: Re-enable when documentation
2631 ; generation works
2632 "--"
28c5d42d
PP
2633 (string-append "--with-xml2-include="
2634 (assoc-ref %build-inputs "libxml2")
2635 "/include/libxml2" ))))
2636 (synopsis "Ruby bindings for GNOME Libxml2")
2637 (description "The Libxml-Ruby project provides Ruby language bindings for
2638the GNOME Libxml2 XML toolkit.")
2f3800e5 2639 (home-page "https://xml4r.github.com/libxml-ruby")
28c5d42d
PP
2640 (license license:expat)))
2641
b3222518
CB
2642(define-public ruby-lino
2643 (package
2644 (name "ruby-lino")
2645 (version "1.1.0")
2646 (source
2647 (origin
2648 (method url-fetch)
2649 (uri (rubygems-uri "lino" version))
2650 (sha256
2651 (base32
2652 "11d29g0fk372b9fcpyr0k6hxm2b4j4igpysmi542hgbbgqgp9cd3"))))
2653 (build-system ruby-build-system)
2654 (arguments
2655 '(#:tests? #f)) ; No included tests
2656 (propagated-inputs
2657 `(("ruby-hamster" ,ruby-hamster)
2658 ("ruby-open4" ,ruby-open4)))
2659 (synopsis "Build and execute commands in Ruby")
2660 (description
2661 "@code{Lino} provides an interface to run external commands. It provides
2662an interface to add options as well as managing the standard input, output and
2663error streams.")
2664 (home-page "https://github.com/tobyclemson/lino")
2665 (license license:expat)))
2666
8b9bde07
RW
2667(define-public ruby-xml-simple
2668 (package
2669 (name "ruby-xml-simple")
2670 (version "1.1.5")
2671 (source (origin
2672 (method url-fetch)
2673 (uri (rubygems-uri "xml-simple" version))
2674 (sha256
2675 (base32
2676 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
2677 (build-system ruby-build-system)
2678 (arguments
2679 '(#:tests? #f)) ; no test suite
2680 (synopsis "Simple Ruby library for XML processing")
2681 (description "This library provides a simple API for XML processing in
2682Ruby.")
2683 (home-page "https://github.com/maik/xml-simple")
2684 (license license:ruby)))
2685
2cb3ab48
RW
2686(define-public ruby-thor
2687 (package
2688 (name "ruby-thor")
bb719d6a 2689 (version "1.0.1")
2cb3ab48 2690 (source (origin
bb719d6a
MB
2691 ;; Pull from git because the gem has no tests.
2692 (method git-fetch)
2693 (uri (git-reference
2694 (url "https://github.com/erikhuda/thor")
2695 (commit (string-append "v" version))))
2696 (file-name (git-file-name name version))
2cb3ab48
RW
2697 (sha256
2698 (base32
bb719d6a 2699 "1anrx5vynk57hn5c8ig5pgkmcsbj9q5mvckd5rviw1jid7n89k57"))))
2cb3ab48
RW
2700 (build-system ruby-build-system)
2701 (arguments
bb719d6a
MB
2702 '(#:phases (modify-phases %standard-phases
2703 (add-after 'unpack 'fix-readline-tests
2704 (lambda _
2705 ;; Ensure Readline is initialized before running the
2706 ;; test to avoid a type clash with the mock ::Readline.
2707 ;; See <https://github.com/erikhuda/thor/pull/717>.
2708 (substitute* "spec/line_editor/readline_spec.rb"
2709 (("unless defined\\? ::Readline" all)
2710 (string-append "Thor::LineEditor::Readline.available?\n"
2711 all)))
2712 #t))
2713 (add-after 'unpack 'remove-coveralls-dependency
2714 (lambda _
2715 ;; Do not hook the test suite into the online
2716 ;; coveralls service.
2717 (substitute* "Gemfile"
2718 ((".*coveralls.*") ""))
2719 (substitute* "spec/helper.rb"
2720 (("require \"coveralls\"") "")
2721 (("Coveralls::SimpleCov::Formatter") "")
2722 ;; Also drop the WebMock dependency which is only
2723 ;; present to allow a coveralls.io connection, and
2724 ;; would otherwise introduce a circular dependency.
2725 (("require \"webmock/rspec\"") "")
2726 (("WebMock\\.disable_net_connect.*") ""))
2727 #t))
2728 (add-after 'unpack 'disable-network-tests
2729 (lambda _
2730 ;; These tests attempt to look up example.com.
2731 (substitute* "spec/actions/file_manipulation_spec.rb"
2732 (("it \"accepts (https?) remote sources" _ proto)
2733 (string-append "xit \"accepts " proto " remote sources")))
2734 #t))
2735 (add-after 'unpack 'disable-quality-tests
2736 (lambda _
2737 ;; These tests attempt to check the git repository for
2738 ;; tabs vs spaces, double vs single quotes, etc, and
2739 ;; depend on the git checkout.
2740 (delete-file "spec/quality_spec.rb")
2741 #t))
2742 (add-before 'check 'make-files-writable
2743 (lambda _
2744 ;; The tests needs rw access to the test suite.
2745 (for-each make-file-writable (find-files "spec"))
2746 #t))
2747 (replace 'check
2748 (lambda _
2749 (invoke "rspec" "spec"))))))
2cb3ab48 2750 (native-inputs
bb719d6a
MB
2751 `(("ruby-rspec" ,ruby-rspec)
2752 ("ruby-simplecov" ,ruby-simplecov)))
2cb3ab48
RW
2753 (synopsis "Ruby toolkit for building command-line interfaces")
2754 (description "Thor is a toolkit for building powerful command-line
2755interfaces.")
2756 (home-page "http://whatisthor.com/")
2757 (license license:expat)))
2758
ec79018e
RW
2759(define-public ruby-lumberjack
2760 (package
2761 (name "ruby-lumberjack")
41700efa 2762 (version "1.0.13")
ec79018e
RW
2763 (source (origin
2764 (method url-fetch)
2765 (uri (rubygems-uri "lumberjack" version))
2766 (sha256
2767 (base32
41700efa 2768 "06im7gcg42x77yhz2w5da2ly9xz0n0c36y5ks7xs53v0l9g0vf5n"))))
ec79018e
RW
2769 (build-system ruby-build-system)
2770 (native-inputs
8be62d3f
BW
2771 `(("ruby-rspec" ,ruby-rspec)
2772 ("ruby-timecop" ,ruby-timecop)))
ec79018e
RW
2773 (synopsis "Logging utility library for Ruby")
2774 (description "Lumberjack is a simple logging utility that can be a drop in
2775replacement for Logger or ActiveSupport::BufferedLogger. It provides support
2776for automatically rolling log files even with multiple processes writing the
2777same log file.")
7bf837fd 2778 (home-page "https://github.com/bdurand/lumberjack")
ec79018e
RW
2779 (license license:expat)))
2780
2a9ce5cb
CB
2781(define-public ruby-rbnacl
2782 (package
2783 (name "ruby-rbnacl")
2784 (version "6.0.1")
2785 (source
2786 (origin
2787 (method url-fetch)
2788 (uri (rubygems-uri "rbnacl" version))
2789 (sha256
2790 (base32
2791 "0ajxy5kj2jw09wdsla3jmha8w07vj5l14288xr9djpl327g3lzhn"))))
2792 (build-system ruby-build-system)
2793 (arguments
2794 `(#:phases
2795 (modify-phases %standard-phases
2796 (add-after 'unpack 'remove-unnecessary-dependencies
2797 (lambda _
2798 ;; Coveralls relates to a network service, and Rubocop to code
2799 ;; linting and both are unnecessary to run the tests
2800 (substitute* "Gemfile"
2801 ((".*rubocop.*") "\n")
2802 ((".*guard-rspec.*") "\n")
2803 ((".*coveralls.*") "\n"))
2804 (substitute* "spec/spec_helper.rb"
2805 (("require \"coveralls\"") "")
2806 (("Coveralls.wear!") ""))
2807 #t))
2808 (add-after 'unpack 'use-libsodium-from-store
2809 (lambda* (#:key inputs #:allow-other-keys)
2810 (substitute* '("lib/rbnacl/init.rb"
2811 "lib/rbnacl/sodium.rb")
2812 (("ffi_lib \\[.+\\]")
2813 (string-append "ffi_lib [\""
2814 (assoc-ref inputs "libsodium") "/lib/libsodium.so"
2815 "\"]")))
2816 #t))
2817 ;; Run Rspec directly to avoid the Rubocop dependency in the Rakefile
2818 (replace 'check
2819 (lambda* (#:key tests? #:allow-other-keys)
2820 (when tests?
2821 (invoke "rspec"))
2822 #t)))))
2823 (propagated-inputs
2824 `(("ruby-ffi" ,ruby-ffi)))
2825 (inputs
2826 `(("libsodium" ,libsodium)))
2827 (native-inputs
2828 `(("bundler" ,bundler)
2829 ("ruby-rspec" ,ruby-rspec)))
2830 (synopsis "Ruby FFI binding to libsodium")
2831 (description
2832 "This package provides Ruby FFI bindings to the Networking and
2833Cryptography (NaCl) library, also known as libsodium. This provides a
2834high-level toolkit for building cryptographic systems and protocols.")
2835 (home-page "https://github.com/crypto-rb/rbnacl")
2836 (license license:expat)))
2837
70b4cf38
RW
2838(define-public ruby-nenv
2839 (package
2840 (name "ruby-nenv")
12313cd0 2841 (version "0.3.0")
70b4cf38
RW
2842 (source (origin
2843 (method url-fetch)
2844 (uri (rubygems-uri "nenv" version))
2845 (sha256
2846 (base32
12313cd0 2847 "0r97jzknll9bhd8yyg2bngnnkj8rjhal667n7d32h8h7ny7nvpnr"))))
70b4cf38
RW
2848 (build-system ruby-build-system)
2849 (arguments
2850 `(#:tests? #f)) ; no tests included
2851 (native-inputs
2852 `(("ruby-rspec" ,ruby-rspec)
2853 ("bundler" ,bundler)))
2854 (synopsis "Ruby interface for modifying the environment")
2855 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
2856and inspect the environment.")
2857 (home-page "https://github.com/e2/nenv")
2858 (license license:expat)))
2859
af59d4b4
MB
2860(define-public ruby-ptools
2861 (package
2862 (name "ruby-ptools")
2863 (version "1.3.5")
2864 (source (origin
2865 (method url-fetch)
2866 (uri (rubygems-uri "ptools" version))
2867 (sha256
2868 (base32
2869 "1jb1h1nsk9zwykpniw8filbsk26kjsdlpk5wz6w0zyamcd41h87j"))))
2870 (build-system ruby-build-system)
2871 (arguments
2872 '(#:phases (modify-phases %standard-phases
2873 (add-after 'unpack 'patch-/bin/ls
2874 (lambda _
2875 (substitute* "test/test_binary.rb"
2876 (("/bin/ls")
2877 (which "ls")))
2878 #t))
2879 (add-before 'install 'create-gem
2880 (lambda _
2881 ;; Do not attempt to sign the gem.
2882 (substitute* "Rakefile"
2883 (("spec\\.signing_key = .*")
2884 ""))
2885 (invoke "rake" "gem:create"))))))
2886 (synopsis "Extra methods for Ruby's @code{File} class")
2887 (description
2888 "The @dfn{ptools} (power tools) library extends Ruby's core @code{File}
2889class with many additional methods modelled after common POSIX tools, such as
2890@code{File.which} for finding executables, @code{File.tail} to print the last
2891lines of a file, @code{File.wc} to count words, and so on.")
2892 (home-page "https://github.com/djberg96/ptools")
2893 (license license:artistic2.0)))
2894
8d9e9f28
RW
2895(define-public ruby-permutation
2896 (package
2897 (name "ruby-permutation")
2898 (version "0.1.8")
2899 (source (origin
2900 (method url-fetch)
2901 (uri (rubygems-uri "permutation" version))
2902 (sha256
2903 (base32
2904 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
2905 (build-system ruby-build-system)
2906 (arguments
2907 `(#:phases
2908 (modify-phases %standard-phases
2909 (add-after 'unpack 'fix-rakefile
2910 (lambda _
2911 (substitute* "Rakefile"
2912 (("require 'rake/gempackagetask'")
2913 "require 'rubygems/package_task'")
2914 (("include Config") ""))
2915 #t))
2916 (replace 'check
2917 (lambda _
9923d5a4 2918 (invoke "ruby" "-Ilib" "test/test.rb"))))))
8d9e9f28
RW
2919 (synopsis "Library to perform operations with sequence permutations")
2920 (description "This package provides a Ruby library to perform different
2921operations with permutations of sequences, such as strings and arrays.")
2f3800e5 2922 (home-page "https://flori.github.io/permutation")
8d9e9f28
RW
2923 (license license:gpl2))) ; GPL 2 only
2924
c5d14d42
RW
2925(define-public ruby-shellany
2926 (package
2927 (name "ruby-shellany")
2928 (version "0.0.1")
2929 (source (origin
2930 (method url-fetch)
2931 (uri (rubygems-uri "shellany" version))
2932 (sha256
2933 (base32
2934 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
2935 (build-system ruby-build-system)
2936 (arguments
2937 `(#:test-target "default"
2938 #:phases
2939 (modify-phases %standard-phases
2940 (add-after 'unpack 'fix-version-test
2941 (lambda _
2942 (substitute* "spec/shellany_spec.rb"
2943 (("^RSpec") "require \"shellany\"\nRSpec"))
2944 #t)))))
2945 (native-inputs
2946 `(("ruby-rspec" ,ruby-rspec)
2947 ("ruby-nenv" ,ruby-nenv)
2948 ("bundler" ,bundler)))
2949 (synopsis "Capture command output")
2950 (description "Shellany is a Ruby library providing functions to capture
2951the output produced by running shell commands.")
2952 (home-page "https://rubygems.org/gems/shellany")
2953 (license license:expat)))
2954
d152162f
RW
2955(define-public ruby-notiffany
2956 (package
2957 (name "ruby-notiffany")
8c1e4a4f 2958 (version "0.1.3")
d152162f
RW
2959 (source (origin
2960 (method url-fetch)
2961 (uri (rubygems-uri "notiffany" version))
2962 (sha256
2963 (base32
8c1e4a4f 2964 "0f47h3bmg1apr4x51szqfv3rh2vq58z3grh4w02cp3bzbdh6jxnk"))))
d152162f
RW
2965 (build-system ruby-build-system)
2966 ;; Tests are not included in the gem.
2967 (arguments `(#:tests? #f))
2968 (propagated-inputs
2969 `(("ruby-shellany" ,ruby-shellany)
2970 ("ruby-nenv" ,ruby-nenv)))
2971 (native-inputs
2972 `(("bundler" ,bundler)))
01eb17de
VC
2973 (synopsis "Wrapper library for notification libraries")
2974 (description "Notiffany is a Ruby wrapper library for notification
d152162f
RW
2975libraries such as Libnotify.")
2976 (home-page "https://github.com/guard/notiffany")
2977 (license license:expat)))
2978
96bf7521
MB
2979(define-public ruby-forking-test-runner
2980 (package
2981 (name "ruby-forking-test-runner")
2982 (version "1.6.0")
2983 (home-page "https://github.com/grosser/forking_test_runner")
2984 (source (origin
2985 (method git-fetch)
2986 (uri (git-reference (url home-page)
2987 (commit (string-append "v" version))))
2988 (file-name (git-file-name name version))
2989 (sha256
2990 (base32
2991 "1mrglzkj2nrgisccf2f30zbfmcs0awv1g3lw994b2az90fl39x8m"))))
2992 (build-system ruby-build-system)
2993 (arguments
2994 '(#:test-target "spec"
2995 ;; FIXME: ActiveRecord depends on sqlite3 1.3.6, but Guix has
2996 ;; 1.4.1, which in turn breaks the tests that use ActiveRecord.
2997 #:tests? #f
2998 #:phases (modify-phases %standard-phases
2999 (replace 'replace-git-ls-files
3000 (lambda _
3001 (substitute* "forking_test_runner.gemspec"
3002 (("`git ls-files lib/ bin/ MIT-LICENSE`")
3003 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
3004 #t))
3005 (add-before 'check 'remove-version-constraints
3006 (lambda _
3007 ;; Ignore hard coded version constraints for the tests.
3008 (delete-file "Gemfile.lock")
3009 #t))
3010 (add-before 'check 'set-HOME
3011 (lambda _
3012 ;; Many tests invoke Bundler, and fails when Bundler
3013 ;; warns that /homeless-shelter does not exist.
3014 (setenv "HOME" "/tmp")
3015 #t)))))
3016 (native-inputs
3017 `(("ruby-activerecord" ,ruby-activerecord)
3018 ("ruby-bump" ,ruby-bump)
3019 ("ruby-rspec" ,ruby-rspec)
3020 ("ruby-sqlite3" ,ruby-sqlite3)
3021 ("ruby-wwtd" ,ruby-wwtd)))
3022 (propagated-inputs
3023 `(("ruby-parallel-tests" ,ruby-parallel-tests)))
3024 (synopsis "Run every test in a fork")
3025 (description
3026 "This package is a wrapper around @code{parallel_tests} that runs every
3027test in a fork to avoid pollution and get clean output per test.")
3028 (license license:expat)))
3029
8528365b
RW
3030(define-public ruby-formatador
3031 (package
3032 (name "ruby-formatador")
3033 (version "0.2.5")
3034 (source (origin
3035 (method url-fetch)
3036 (uri (rubygems-uri "formatador" version))
3037 (sha256
3038 (base32
3039 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
3040 (build-system ruby-build-system)
3041 ;; Circular dependency: Tests require ruby-shindo, which requires
3042 ;; ruby-formatador at runtime.
3043 (arguments `(#:tests? #f))
3044 (synopsis "Ruby library to format text on stdout")
3045 (description "Formatador is a Ruby library to format text printed to the
3046standard output stream.")
7bf837fd 3047 (home-page "https://github.com/geemus/formatador")
8528365b
RW
3048 (license license:expat)))
3049
5437c741
CB
3050(define-public ruby-fuubar
3051 (package
3052 (name "ruby-fuubar")
3053 (version "2.3.2")
3054 (source
3055 (origin
3056 ;; Fetch from the git repository, as the gem package doesn't include
3057 ;; the tests.
3058 (method git-fetch)
3059 (uri (git-reference
b0e7b699 3060 (url "https://github.com/thekompanee/fuubar")
5437c741
CB
3061 (commit (string-append "releases/v" version))))
3062 (file-name (git-file-name name version))
3063 (sha256
3064 (base32
3065 "0jm1x2xp13csbnadixaikj7mlkp5yk4byx51npm56zi13izp7259"))))
3066 (build-system ruby-build-system)
3067 (arguments
3068 '(;; TODO: Some tests fail, unsure why.
3069 ;; 21 examples, 7 failures
3070 #:tests? #f
3071 #:phases
3072 (modify-phases %standard-phases
3073 (add-before 'build 'delete-certificate
3074 (lambda _
3075 ;; Remove 's.cert_chain' as we do not build with a private key
3076 (substitute* "fuubar.gemspec"
3077 ((".*cert_chain.*") "")
3078 ((".*signing_key.*") ""))
3079 #t))
3080 (replace 'check
3081 (lambda* (#:key tests? #:allow-other-keys)
3082 (when tests?
3083 (invoke "rspec"))
3084 #t)))))
3085 (native-inputs
3086 `(("bundler" ,bundler)))
3087 (propagated-inputs
3088 `(("ruby-rspec-core" ,ruby-rspec-core)
3089 ("ruby-progressbar" ,ruby-progressbar)))
3090 (synopsis "Fuubar is an RSpec formatter that uses a progress bar")
3091 (description
3092 "Fuubar is an RSpec formatter that uses a progress bar instead of a
3093string of letters and dots as feedback. It also stops on the first test
3094failure.")
3095 (home-page "https://github.com/thekompanee/fuubar")
3096 (license license:expat)))
3097
8ea991e3
CB
3098(define-public ruby-haml
3099 (package
3100 (name "ruby-haml")
3101 (version "5.0.4")
3102 (source
3103 (origin
3104 (method url-fetch)
3105 (uri (rubygems-uri "haml" version))
3106 (sha256
3107 (base32
3108 "1q0a9fvqh8kn6wm97fcks6qzbjd400bv8bx748w8v87m7p4klhac"))))
3109 (build-system ruby-build-system)
3110 (arguments
3111 '(#:tests? #f)) ; No included tests
3112 (propagated-inputs
3113 `(("ruby-tilt" ,ruby-tilt)
3114 ("ruby-temple" ,ruby-temple)))
3115 (synopsis "Haml is a Ruby library to generate HTML documents")
3116 (description
3117 "@acronym{Haml, HTML Abstraction Markup Language} is a layer on top of
3118HTML or XML that is designed to express the structure of documents using
3119indentation rather than closing tags. It was originally envisioned as a
3120plugin for Ruby on Rails, but it can function as a stand-alone templating
3121engine.")
3122 (home-page "http://haml.info/")
3123 (license license:expat)))
3124
353b7eb8
CB
3125(define-public ruby-hamster
3126 (package
3127 (name "ruby-hamster")
3128 (version "3.0.0")
3129 (source
3130 (origin
3131 (method url-fetch)
3132 (uri (rubygems-uri "hamster" version))
3133 (sha256
3134 (base32
3135 "1n1lsh96vnyc1pnzyd30f9prcsclmvmkdb3nm5aahnyizyiy6lar"))))
3136 (build-system ruby-build-system)
3137 (arguments
3138 '(#:phases
3139 (modify-phases %standard-phases
3140 (add-after 'unpack 'remove-unnecessary-dependencies
3141 (lambda _
3142 ;; pry is a debugging tool, and is unnecessary when running the
3143 ;; tests
3144 (substitute* "spec/lib/hamster/vector/insert_spec.rb"
3145 (("require 'pry'") ""))
3146 (substitute* "spec/spec_helper.rb"
3147 (("require \"pry\"") "")
3148 ;; CodeClimate is an online service, and is unnecessary for
3149 ;; running the tests
3150 (("require \"codeclimate-test-reporter\"") "")
3151 (("CodeClimate.*\n") ""))
3152 #t))
3153 ;; No Rakefile is included, so run rspec directly.
3154 (replace 'check
3155 (lambda* (#:key tests? #:allow-other-keys)
3156 (when tests?
3157 (invoke "rspec"))
3158 #t)))))
3159 (propagated-inputs
3160 `(("ruby-concurrent" ,ruby-concurrent)))
3161 (native-inputs
3162 `(("ruby-rspec" ,ruby-rspec)))
3163 (synopsis "Efficient, immutable, thread-safe collection classes for Ruby")
3164 (description
3165 "Hamster provides 6 persistent data structures: @code{Hash}, @code{Vector},
3166@code{Set}, @code{SortedSet}, @code{List}, and @code{Deque} (which works as an
3167immutable queue or stack).")
3168 (home-page "https://github.com/hamstergem/hamster")
3169 (license license:expat)))
3170
21781436
CB
3171(define-public ruby-hashdiff
3172 (package
3173 (name "ruby-hashdiff")
f7bd9d23 3174 (version "1.0.1")
21781436
CB
3175 (source
3176 (origin
3177 (method url-fetch)
3178 (uri (rubygems-uri "hashdiff" version))
3179 (sha256
3180 (base32
f7bd9d23 3181 "1nynpl0xbj0nphqx1qlmyggq58ms1phf5i03hk64wcc0a17x1m1c"))))
21781436
CB
3182 (build-system ruby-build-system)
3183 (arguments
3184 '(#:phases
3185 (modify-phases %standard-phases
f7bd9d23 3186 ;; Run tests directly via rspec to avoid depending on rubocop.
21781436
CB
3187 (replace 'check
3188 (lambda* (#:key tests? #:allow-other-keys)
3189 (when tests?
3190 (invoke "rspec"))
3191 #t)))))
3192 (native-inputs
3193 `(("bundler" ,bundler)
3194 ("ruby-rspec" ,ruby-rspec-2)))
3195 (synopsis "HashDiff computes the smallest difference between two hashes")
3196 (description
3197 "HashDiff is a Ruby library to compute the smallest difference between
3198two hashes.")
3199 (home-page "https://github.com/liufengyun/hashdiff")
3200 (license license:expat)))
3201
3cc8e029
MB
3202(define-public ruby-hydra
3203 ;; No releases yet.
3204 (let ((commit "5abfa378743756ae4d9306cc134bcc482f5c9525")
3205 (revision "0"))
3206 (package
3207 (name "ruby-hydra")
3208 (version (git-version "0.0" revision commit))
3209 (home-page "https://github.com/hyphenation/hydra")
3210 (source (origin
3211 (method git-fetch)
3212 (uri (git-reference (url home-page) (commit commit)))
3213 (file-name (git-file-name name version))
3214 (sha256
3215 (base32
3216 "1cik398l2765y3d9sdhjzki3303hkry58ac6jlkiy7iy62nm529f"))))
3217 (build-system ruby-build-system)
3218 (arguments
3219 '(#:phases (modify-phases %standard-phases
3220 (add-after 'unpack 'make-files-writable
3221 (lambda _
3222 (for-each make-file-writable (find-files "."))
3223 #t))
3224 (replace 'check
3225 (lambda _
3226 (invoke "rspec"))))))
3227 (native-inputs
3228 `(("ruby-rspec" ,ruby-rspec)))
3229 (propagated-inputs
3230 `(("ruby-byebug" ,ruby-byebug)))
3231 (synopsis "Ruby hyphenation patterns")
3232 (description
3233 "ruby-hydra is a Ruby library for working with hyphenation patterns.")
3234 (license license:expat))))
3235
7ac4610f
RW
3236(define-public ruby-shindo
3237 (package
3238 (name "ruby-shindo")
3239 (version "0.3.8")
3240 (source (origin
3241 (method url-fetch)
3242 (uri (rubygems-uri "shindo" version))
3243 (sha256
3244 (base32
3245 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
3246 (build-system ruby-build-system)
3247 (arguments
3248 `(#:test-target "shindo_tests"
3249 #:phases
3250 (modify-phases %standard-phases
3251 (add-after 'unpack 'fix-tests
0b060e34
CB
3252 (lambda _
3253 (substitute* "tests/tests_helper.rb"
3254 (("-rubygems") ""))
3255 (substitute* "Rakefile"
3256 (("system \"shindo") "system \"./bin/shindo")
3257 ;; This test doesn't work, so we disable it.
3258 (("fail \"The build_error test should fail") "#")
3259 ((" -rubygems") ""))
3260 #t)))))
7ac4610f
RW
3261 (propagated-inputs
3262 `(("ruby-formatador" ,ruby-formatador)))
3263 (synopsis "Simple depth first Ruby testing")
3264 (description "Shindo is a simple depth first testing library for Ruby.")
3265 (home-page "https://github.com/geemus/shindo")
3266 (license license:expat)))
3267
f13636f2
RW
3268(define-public ruby-rubygems-tasks
3269 (package
3270 (name "ruby-rubygems-tasks")
f0f5f2d3 3271 (version "0.2.5")
f13636f2
RW
3272 (source (origin
3273 (method url-fetch)
3274 (uri (rubygems-uri "rubygems-tasks" version))
3275 (sha256
3276 (base32
f0f5f2d3 3277 "1x3sz3n2dlknd3v7w1mrq6f0ag6pwzhjvg7z29p75w3p42ma1gbx"))))
f13636f2
RW
3278 (build-system ruby-build-system)
3279 ;; Tests need Internet access.
3280 (arguments `(#:tests? #f))
3281 (native-inputs
3282 `(("ruby-rspec" ,ruby-rspec)
3283 ("ruby-yard" ,ruby-yard)))
3284 (synopsis "Rake tasks for managing and releasing Ruby Gems")
3285 (description "Rubygems-task provides Rake tasks for managing and releasing
3286Ruby Gems.")
3287 (home-page "https://github.com/postmodern/rubygems-tasks")
3288 (license license:expat)))
3289
cb6bc5df
CB
3290(define-public ruby-rubyzip
3291 (package
3292 (name "ruby-rubyzip")
3293 (version "1.2.1")
3294 (source
3295 (origin
3296 (method url-fetch)
3297 (uri (rubygems-uri "rubyzip" version))
3298 (sha256
3299 (base32
3300 "06js4gznzgh8ac2ldvmjcmg9v1vg9llm357yckkpylaj6z456zqz"))))
3301 (build-system ruby-build-system)
3302 (arguments
3303 '(#:phases
3304 (modify-phases %standard-phases
3305 (add-before 'check 'patch-tests
3306 (lambda* (#:key inputs #:allow-other-keys)
3307 (substitute* "test/gentestfiles.rb"
3308 (("/usr/bin/zip")
3309 (string-append
3310 (assoc-ref inputs "zip") "/bin/zip")))
3311 (substitute* "test/input_stream_test.rb"
3312 (("/usr/bin/env ruby") (which "ruby")))
3313 #t)))))
3314 (native-inputs
3315 `(("bundler" ,bundler)
3316 ("ruby-simplecov" ,ruby-simplecov)
3317 ("zip" ,zip)
3318 ("unzip" ,unzip)))
3319 (synopsis "Ruby module is for reading and writing zip files")
3320 (description
3321 "The rubyzip module provides ways to read from and create zip files.")
702a1012 3322 (home-page "https://github.com/rubyzip/rubyzip")
cb6bc5df
CB
3323 (license license:bsd-2)))
3324
58b59742
RW
3325(define-public ruby-simplecov-html
3326 (package
3327 (name "ruby-simplecov-html")
53fd476f 3328 (version "0.10.2")
58b59742
RW
3329 (source (origin
3330 (method url-fetch)
3331 (uri (rubygems-uri "simplecov-html" version))
3332 (sha256
3333 (base32
53fd476f 3334 "1lihraa4rgxk8wbfl77fy9sf0ypk31iivly8vl3w04srd7i0clzn"))))
58b59742 3335 (build-system ruby-build-system)
8b749cf3 3336 (arguments `(#:tests? #f)) ; there are no tests
58b59742
RW
3337 (native-inputs
3338 `(("bundler" ,bundler)))
3339 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
3340 (description "This package provides the default HTML formatter for
3341the SimpleCov code coverage tool for Ruby version 1.9 and above.")
3342 (home-page "https://github.com/colszowka/simplecov-html")
3343 (license license:expat)))
3344
a84fa2ad
RW
3345(define-public ruby-simplecov
3346 (package
3347 (name "ruby-simplecov")
d432682b 3348 (version "0.17.1")
a84fa2ad
RW
3349 (source (origin
3350 (method url-fetch)
3351 (uri (rubygems-uri "simplecov" version))
3352 (sha256
3353 (base32
d432682b 3354 "1135k46nik05sdab30yxb8264lqiz01c8v000g16cl9pjc4mxrdw"))))
a84fa2ad
RW
3355 (build-system ruby-build-system)
3356 ;; Simplecov depends on rubocop for code style checking at build time.
3357 ;; Rubocop needs simplecov at build time.
3358 (arguments `(#:tests? #f))
3359 (propagated-inputs
3360 `(("ruby-json" ,ruby-json)
3361 ("ruby-docile" ,ruby-docile)
3362 ("ruby-simplecov-html" ,ruby-simplecov-html)))
3363 (native-inputs
3364 `(("bundler" ,bundler)))
3365 (synopsis "Code coverage framework for Ruby")
3366 (description "SimpleCov is a code coverage framework for Ruby with a
3367powerful configuration library and automatic merging of coverage across test
3368suites.")
7bf837fd 3369 (home-page "https://github.com/colszowka/simplecov")
a84fa2ad
RW
3370 (license license:expat)))
3371
98b87b82
DT
3372(define-public ruby-useragent
3373 (package
3374 (name "ruby-useragent")
959d908d 3375 (version "0.16.10")
98b87b82
DT
3376 (source (origin
3377 (method url-fetch)
e83c6d00 3378 (uri (rubygems-uri "useragent" version))
98b87b82
DT
3379 (sha256
3380 (base32
959d908d 3381 "1fv5kvq494swy0p17h9qya9r50w15xsi9zmvhzb8gh55kq6ki50p"))))
98b87b82
DT
3382 (build-system ruby-build-system)
3383 (arguments
e83c6d00 3384 '(#:tests? #f)) ; no test suite
98b87b82
DT
3385 (synopsis "HTTP user agent parser for Ruby")
3386 (description "UserAgent is a Ruby library that parses and compares HTTP
3387User Agents.")
3388 (home-page "https://github.com/gshutler/useragent")
3389 (license license:expat)))
96086cc5 3390
f7e9b2f3
CB
3391(define-public ruby-backports
3392 (package
3393 (name "ruby-backports")
3394 (version "3.11.4")
3395 (source
3396 (origin
3397 (method url-fetch)
3398 (uri (rubygems-uri "backports" version))
3399 (sha256
3400 (base32
3401 "1hshjxww2h7s0dk57njrygq4zpp0nlqrjfya7zwm27iq3rhc3y8g"))))
3402 (build-system ruby-build-system)
3403 (arguments
3404 '(;; TODO: This should be default, but there is one test failure
3405 #:test-target "all_spec"))
3406 (native-inputs
3407 `(("ruby-mspec" ,ruby-mspec)
3408 ("ruby-activesupport" ,ruby-activesupport)))
3409 (synopsis "Backports of the features in newer Ruby versions")
3410 (description
3411 "Backports enables more compatibility across Ruby versions by providing
3412backports of some features.")
3413 (home-page "https://github.com/marcandre/backports")
3414 (license license:expat)))
3415
96086cc5
DT
3416(define-public ruby-bacon
3417 (package
3418 (name "ruby-bacon")
e83c6d00 3419 (version "1.2.0")
96086cc5
DT
3420 (source (origin
3421 (method url-fetch)
e83c6d00 3422 (uri (rubygems-uri "bacon" version))
96086cc5
DT
3423 (sha256
3424 (base32
e83c6d00 3425 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
96086cc5 3426 (build-system ruby-build-system)
96086cc5
DT
3427 (synopsis "Small RSpec clone")
3428 (description "Bacon is a small RSpec clone providing all essential
3429features.")
3430 (home-page "https://github.com/chneukirchen/bacon")
3431 (license license:expat)))
de59d316 3432
a8d2bf3c
CB
3433(define-public ruby-bacon-bits
3434 (package
3435 (name "ruby-bacon-bits")
3436 (version "0.1.0")
3437 (source
3438 (origin
3439 (method url-fetch)
3440 (uri (rubygems-uri "bacon-bits" version))
3441 (sha256
3442 (base32
3443 "1ghpj8ja94lhi8rgi872hqk4fd2amz2k7g9znd64z5dj7v6l0dmx"))))
3444 (build-system ruby-build-system)
3445 (arguments
3446 ;; No tests
3447 '(#:tests? #f))
3448 (propagated-inputs `(("ruby-bacon" ,ruby-bacon)))
3449 (synopsis "Extensions to Bacon, for disabling tests, before and after
3450blocks and more")
3451 (description
3452 "This extends the bacon testing framework with useful extensions to
3453disable tests, have before and after blocks that run once and more.")
3454 (home-page "https://github.com/cldwalker/bacon-bits")
3455 (license license:expat)))
3456
65f65889
CB
3457(define-public ruby-bacon-colored-output
3458 (package
3459 (name "ruby-bacon-colored-output")
3460 (version "1.1.1")
3461 (source
3462 (origin
3463 (method url-fetch)
3464 (uri (rubygems-uri "bacon-colored_output" version))
3465 (sha256
3466 (base32
3467 "1znyh3vkfdlmf19p3k4zip88ibym41dn5g4p4n5hmks2iznb7qpx"))))
3468 (build-system ruby-build-system)
3469 (arguments
3470 '(;; No included tests
3471 #:tests? #f))
3472 (propagated-inputs
3473 `(("ruby-bacon" ,ruby-bacon)))
3474 (synopsis "Colored output for Bacon test framework")
3475 (description
3476 "This package adds color through ANSI escape codes to Bacon test
3477output.")
3478 (home-page "https://github.com/whitequark/bacon-colored_output")
3479 (license license:expat)))
3480
e259bdf0
DT
3481(define-public ruby-connection-pool
3482 (package
3483 (name "ruby-connection-pool")
58021db4 3484 (version "2.2.2")
e259bdf0
DT
3485 (source (origin
3486 (method url-fetch)
e83c6d00 3487 (uri (rubygems-uri "connection_pool" version))
e259bdf0
DT
3488 (sha256
3489 (base32
58021db4 3490 "0lflx29mlznf1hn0nihkgllzbj8xp5qasn8j7h838465pi399k68"))))
e259bdf0
DT
3491 (build-system ruby-build-system)
3492 (native-inputs
3493 `(("bundler" ,bundler)))
3494 (synopsis "Generic connection pool for Ruby")
3495 (description "Connection_pool provides a generic connection pooling
3496interface for Ruby programs.")
3497 (home-page "https://github.com/mperham/connection_pool")
3498 (license license:expat)))
4c0aeb44 3499
4a98314d
MB
3500(define-public ruby-fast-gettext
3501 (package
3502 (name "ruby-fast-gettext")
c3beb7ce 3503 (version "2.0.3")
4a98314d
MB
3504 (home-page "https://github.com/grosser/fast_gettext")
3505 (source (origin
3506 (method git-fetch)
3507 (uri (git-reference (url home-page)
3508 (commit (string-append "v" version))))
3509 (file-name (git-file-name name version))
3510 (sha256
3511 (base32
c3beb7ce 3512 "1dg14apq5sfjshhcq0idphhs7aq9ikzswhqmn689p1h76mxqr1v6"))))
4a98314d
MB
3513 (build-system ruby-build-system)
3514 (arguments
3515 '(#:test-target "spec"
3516 #:phases (modify-phases %standard-phases
3517 (add-before 'check 'remove-version-constraints
3518 (lambda _
3519 (delete-file "Gemfile.lock")
3520 #t))
3521 (add-before 'check 'remove-activerecord-test
3522 (lambda _
3523 ;; FIXME: This test fails because ActiveRecord depends on
3524 ;; a different version of ruby-sqlite than the currently
3525 ;; available one.
3526 (delete-file
3527 "spec/fast_gettext/translation_repository/db_spec.rb")
3528 #t))
3529 (add-before 'check 'disable-i18n-test
3530 (lambda _
3531 ;; XXX: This test checks i18n intricasies with Rails 3 and
3532 ;; automatically disables itself for Rails 4.0, but does
3533 ;; not know about newer versions as it has not been updated
3534 ;; since 2014. Disable for later versions of Rails too.
3535 (substitute* "spec/fast_gettext/vendor/string_spec.rb"
3536 (((string-append "ActiveRecord::VERSION::MAJOR == 4 and "
3537 "ActiveRecord::VERSION::MINOR == 0"))
3538 "ActiveRecord::VERSION::MAJOR >= 4"))
3539 #t)))))
3540 (native-inputs
3541 `(;; For tests.
3542 ("ruby-activerecord" ,ruby-activerecord)
3543 ("ruby-activesupport" ,ruby-activesupport)
3544 ("ruby-bump" ,ruby-bump)
3545 ("ruby-forking-test-runner" ,ruby-forking-test-runner)
3546 ("ruby-i18n" ,ruby-i18n)
3547 ("ruby-rubocop" ,ruby-rubocop)
3548 ("ruby-rspec" ,ruby-rspec)
3549 ("ruby-single-cov" ,ruby-single-cov)
3550 ("ruby-sqlite3" ,ruby-sqlite3)
3551 ("ruby-wwtd" ,ruby-wwtd)))
3552 (synopsis "Fast implementation of @code{GetText}")
3553 (description
3554 "This package provides an alternative implementation of the Ruby
3555@code{GetText} library that is approximately 12x faster yet thread safe.")
3556 ;; Some parts are covered by the Ruby license, see file headers.
3557 (license (list license:expat license:ruby))))
3558
4c0aeb44
DT
3559(define-public ruby-net-http-persistent
3560 (package
3561 (name "ruby-net-http-persistent")
185ea446 3562 (version "3.0.0")
4c0aeb44
DT
3563 (source (origin
3564 (method url-fetch)
e83c6d00 3565 (uri (rubygems-uri "net-http-persistent" version))
4c0aeb44
DT
3566 (sha256
3567 (base32
185ea446 3568 "156rv95bgxfz6qw5y1r7c7bswr77918hygl8dyl14qzbqc5vyp18"))))
4c0aeb44 3569 (build-system ruby-build-system)
4c0aeb44
DT
3570 (native-inputs
3571 `(("ruby-connection-pool" ,ruby-connection-pool)
3572 ("ruby-hoe" ,ruby-hoe)))
3573 (synopsis "Persistent HTTP connection manager")
3574 (description "Net::HTTP::Persistent manages persistent HTTP connections
3575using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
3576 (home-page "https://github.com/drbrain/net-http-persistent")
3577 (license license:expat)))
afbbdf77 3578
f88bacaf
RW
3579(define-public ruby-power-assert
3580 (package
3581 (name "ruby-power-assert")
6754323b 3582 (version "1.1.5")
f88bacaf
RW
3583 (source (origin
3584 (method url-fetch)
3585 (uri (rubygems-uri "power_assert" version))
3586 (sha256
3587 (base32
6754323b 3588 "1dii0wkfa0jm8sk9b20zl1z4980dmrjh0zqnii058485pp3ws10s"))))
f88bacaf 3589 (build-system ruby-build-system)
6754323b
CB
3590 (arguments
3591 '(#:tests? #f)) ; No included tests
f88bacaf
RW
3592 (native-inputs
3593 `(("bundler" ,bundler)))
3594 (synopsis "Assert library with descriptive assertion messages")
3595 (description "Power-assert is an assertion library providing descriptive
3596assertion messages for tests.")
3597 (home-page "https://github.com/k-tsj/power_assert")
3598 (license (list license:bsd-2 license:ruby))))
3599
e42e3bfa
CB
3600(define-public ruby-powerpack
3601 (package
3602 (name "ruby-powerpack")
3603 (version "0.1.2")
3604 (source
3605 (origin
3606 (method url-fetch)
3607 (uri (rubygems-uri "powerpack" version))
3608 (sha256
3609 (base32
3610 "1r51d67wd467rpdfl6x43y84vwm8f5ql9l9m85ak1s2sp3nc5hyv"))))
3611 (build-system ruby-build-system)
3612 (arguments
3613 '(#:test-target "spec"))
3614 (native-inputs
3615 `(("bundler" ,bundler)
3616 ("ruby-rspec" ,ruby-rspec)
3617 ("ruby-yard" ,ruby-yard)))
3618 (synopsis "Useful extensions to core Ruby classes")
3619 (description
3620 "This package provides a few useful extensions to core Ruby classes,
3621including @code{Array}, @code{Enumerable}, @code{Hash}, @code{Numeric}, and
3622@code{String}.")
3623 (home-page "https://github.com/bbatsov/powerpack")
3624 (license license:expat)))
3625
347eb21e
RW
3626(define-public ruby-locale
3627 (package
3628 (name "ruby-locale")
3629 (version "2.1.2")
3630 (source (origin
3631 (method url-fetch)
3632 (uri (rubygems-uri "locale" version))
3633 (sha256
3634 (base32
3635 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
3636 (build-system ruby-build-system)
3637 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3638 ;; which needs ruby-gettext, which needs ruby-locale. To break the
3639 ;; dependency cycle we disable tests.
3640 (arguments `(#:tests? #f))
3641 (native-inputs
3642 `(("bundler" ,bundler)
3643 ("ruby-yard" ,ruby-yard)))
3644 (synopsis "Ruby library providing basic localization APIs")
3645 (description
3646 "Ruby-Locale is the pure ruby library which provides basic APIs for
3647localization.")
3648 (home-page "https://github.com/ruby-gettext/locale")
3649 (license (list license:lgpl3+ license:ruby))))
3650
09e2b0af
CB
3651(define-public ruby-temple
3652 (package
3653 (name "ruby-temple")
b1c79cab 3654 (version "0.8.2")
09e2b0af
CB
3655 (source
3656 (origin
3657 (method url-fetch)
3658 (uri (rubygems-uri "temple" version))
3659 (sha256
3660 (base32
b1c79cab 3661 "060zzj7c2kicdfk6cpnn40n9yjnhfrr13d0rsbdhdij68chp2861"))))
09e2b0af
CB
3662 (build-system ruby-build-system)
3663 (native-inputs
3664 `(("ruby-tilt" ,ruby-tilt)
3665 ("ruby-bacon" ,ruby-bacon)
3666 ("ruby-erubis" ,ruby-erubis)))
3667 (synopsis "Template compilation framework in Ruby")
3668 (description
3669 "Temple is an abstraction and framework for compiling templates to pure
3670Ruby.")
3671 (home-page "https://github.com/judofyr/temple")
3672 (license license:expat)))
3673
e2333ea3
RW
3674(define-public ruby-text
3675 (package
3676 (name "ruby-text")
3677 (version "1.3.1")
3678 (source (origin
3679 (method url-fetch)
3680 (uri (rubygems-uri "text" version))
3681 (sha256
3682 (base32
3683 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
3684 (build-system ruby-build-system)
3685 (synopsis "Collection of text algorithms for Ruby")
3686 (description
3687 "This package provides a collection of text algorithms: Levenshtein,
3688Soundex, Metaphone, Double Metaphone, Porter Stemming.")
7bf837fd 3689 (home-page "https://github.com/threedaymonk/text")
e2333ea3
RW
3690 (license license:expat)))
3691
c1f52261
RW
3692(define-public ruby-gettext
3693 (package
3694 (name "ruby-gettext")
3695 (version "3.1.7")
3696 (source (origin
3697 (method url-fetch)
3698 (uri (rubygems-uri "gettext" version))
3699 (sha256
3700 (base32
3701 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
3702 (build-system ruby-build-system)
3703 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3704 ;; which needs ruby-gettext. To break the dependency cycle we disable
3705 ;; tests.
3706 (arguments `(#:tests? #f))
3707 (propagated-inputs
3708 `(("ruby-locale" ,ruby-locale)
3709 ("ruby-text" ,ruby-text)))
3710 (native-inputs
3711 `(("bundler" ,bundler)
3712 ("ruby-yard" ,ruby-yard)))
3713 (synopsis "GNU gettext-like program for Ruby")
3714 (description
3715 "Gettext is a GNU gettext-like program for Ruby. The catalog
3716file (po-file) used is the same as that used by GNU gettext, allowing you to
3717use GNU gettext tools for maintenance.")
2f3800e5 3718 (home-page "https://ruby-gettext.github.com/")
c1f52261
RW
3719 (license (list license:lgpl3+ license:ruby))))
3720
cc5aeb8c
RW
3721(define-public ruby-packnga
3722 (package
3723 (name "ruby-packnga")
1d60c436 3724 (version "1.0.4")
cc5aeb8c
RW
3725 (source (origin
3726 (method url-fetch)
3727 (uri (rubygems-uri "packnga" version))
3728 (sha256
3729 (base32
1d60c436 3730 "1vv2j0i43s4xid2km5hgrrxqlqpwgq8nlm8kaxfg2531c1vwfsd4"))))
cc5aeb8c
RW
3731 (build-system ruby-build-system)
3732 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
3733 ;; To break the dependency cycle we disable tests.
3734 (arguments `(#:tests? #f))
3735 (propagated-inputs
3736 `(("ruby-gettext" ,ruby-gettext)
3737 ("ruby-yard" ,ruby-yard)))
3738 (native-inputs
3739 `(("bundler" ,bundler)))
3740 (synopsis "Utility library to package internationalized libraries")
3741 (description
3742 "Packnga is a library to translate to many languages using YARD.")
3743 (home-page "http://ranguba.org/packnga/")
3744 (license license:lgpl2.0+)))
3745
93dc8684
CB
3746(define-public ruby-test-construct
3747 (package
3748 (name "ruby-test-construct")
3749 (version "2.0.1")
3750 (source
3751 (origin
3752 (method url-fetch)
3753 (uri (rubygems-uri "test_construct" version))
3754 (sha256
3755 (base32
3756 "1a2ym3l068d0pxzzr95kvqx87zpdsarxslz9ygd4qfm9frrz0kgj"))))
3757 (build-system ruby-build-system)
3758 (native-inputs
3759 `(("bundler" ,bundler)
3760 ("ruby-mocha" ,ruby-mocha)
3761 ("ruby-rspec" ,ruby-rspec)))
3762 (synopsis "Creates temporary files and directories for testing")
3763 (description
3764 "TestConstruct is a @acronym{DSL, Domain Specific Language} for creating
3765temporary files and directories during tests.")
3766 (home-page "https://github.com/bhb/test_construct")
3767 (license license:expat)))
3768
3383f5bd
RW
3769(define-public ruby-test-unit
3770 (package
3771 (name "ruby-test-unit")
d74d96e4 3772 (version "3.2.5")
3383f5bd
RW
3773 (source (origin
3774 (method url-fetch)
3775 (uri (rubygems-uri "test-unit" version))
3776 (sha256
3777 (base32
d74d96e4 3778 "05bx36fw01iqz0xqhvjfrwjgnj1zx3b2vn6w1fzp19rchd7zqc52"))))
3383f5bd
RW
3779 (build-system ruby-build-system)
3780 (propagated-inputs
3781 `(("ruby-power-assert" ,ruby-power-assert)))
3782 (native-inputs
3783 `(("bundler" ,bundler)
3784 ("ruby-packnga" ,ruby-packnga)
3785 ("ruby-yard" ,ruby-yard)))
3786 (synopsis "Unit testing framework for Ruby")
3787 (description "@code{Test::Unit} is unit testing framework for Ruby, based
3788on xUnit principles. These were originally designed by Kent Beck, creator of
3789extreme programming software development methodology, for Smalltalk's SUnit.
3790It allows writing tests, checking results and automated testing in Ruby.")
2f3800e5 3791 (home-page "https://test-unit.github.io/")
3383f5bd
RW
3792 (license (list license:psfl license:ruby))))
3793
76b732fb
CB
3794(define-public ruby-markaby
3795 (package
3796 (name "ruby-markaby")
3797 (version "0.9.0")
3798 (source
3799 (origin
3800 (method url-fetch)
3801 (uri (rubygems-uri "markaby" version))
3802 (sha256
3803 (base32
3804 "1j4jc31ycydbkh5h3q6zwidzpavg3g5mbb5lqyaczd3jrq78rd7i"))))
3805 (build-system ruby-build-system)
3806 (arguments
3807 '(#:phases
3808 (modify-phases %standard-phases
3809 ;; Run rspec manually without using the Rakefile, as the versions of
3810 ;; Rake and RSpec 2 are incompatible:
3811 ;;
3812 ;; NoMethodError: undefined method `last_comment'
3813 (replace 'check
3814 (lambda* (#:key tests? #:allow-other-keys)
3815 (when tests?
3816 (invoke "rspec"))
3817 #t)))))
3818 (propagated-inputs
3819 `(("ruby-builder" ,ruby-builder)))
3820 (native-inputs
3821 `(("bundler" ,bundler)
3822 ("ruby-rspec" ,ruby-rspec-2)))
3823 (synopsis "Write HTML pages in pure Ruby")
3824 (description
3825 "Markaby allows writing HTML packages in pure Ruby. This is similar to
e54af322 3826the functionality provided by @acronym{ERB, Embedded Ruby}, but without the
76b732fb 3827mixture of HTML and additional ERB syntax.")
41181b76 3828 (home-page "https://markaby.github.io/")
76b732fb
CB
3829 (license license:expat)))
3830
b9511aa9
CB
3831(define-public ruby-maruku
3832 (package
3833 (name "ruby-maruku")
3834 (version "0.7.3")
3835 (source
3836 (origin
3837 (method url-fetch)
3838 (uri (rubygems-uri "maruku" version))
3839 (sha256
3840 (base32
3841 "1r7bxpgnx2hp3g12bjrmdrpv663dfqxsdp0af69kjhxmaxpia56x"))))
3842 (build-system ruby-build-system)
3843 (arguments
3844 '(;; TODO: 3 tests seem to fail due to HTML encoding issues
3845 #:tests? #f
3846 #:phases
3847 (modify-phases %standard-phases
3848 (replace 'check
3849 (lambda* (#:key tests? #:allow-other-keys)
3850 (when tests?
3851 (invoke "rspec"))
3852 #t)))))
3853 (native-inputs
3854 `(("ruby-rspec" ,ruby-rspec)
3855 ("ruby-simplecov" ,ruby-simplecov)
3856 ("ruby-nokogiri-diff" ,ruby-nokogiri-diff)))
3857 (synopsis "Markdown interpreter in Ruby")
3858 (description
3859 "Maruku is a Markdown interpreter in Ruby. It can export Markdown to
3860HTML, and PDF through LaTeX.")
3861 (home-page "https://github.com/bhollis/maruku")
3862 (license license:expat)))
3863
25d6d49b
RW
3864(define-public ruby-metaclass
3865 (package
3866 (name "ruby-metaclass")
3867 (version "0.0.4")
3868 (source (origin
3869 (method url-fetch)
3870 (uri (rubygems-uri "metaclass" version))
3871 (sha256
3872 (base32
3873 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
3874 (build-system ruby-build-system)
3875 (arguments
3876 `(#:phases
3877 (modify-phases %standard-phases
3878 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 3879 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3880 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
3881 (substitute* "Rakefile"
3882 (("t\\.libs << \"test\"" line)
3883 (string-append line "; t.libs << \""
3cb3fa67 3884 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
3885 "/gems/test-unit-"
3886 ,(package-version ruby-test-unit)
3887 "/lib\""))))
3888 #t)))))
25d6d49b
RW
3889 (native-inputs
3890 `(("bundler" ,bundler)
3891 ("ruby-test-unit" ,ruby-test-unit)))
3892 (synopsis "Ruby library adding metaclass method to all objects")
3893 (description
3894 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
3895objects.")
7bf837fd 3896 (home-page "https://github.com/floehopper/metaclass")
25d6d49b
RW
3897 (license license:expat)))
3898
fae1c866
MB
3899(define-public ruby-mkmf-lite
3900 (package
3901 (name "ruby-mkmf-lite")
3902 (version "0.3.2")
3903 (source (origin
3904 (method url-fetch)
3905 (uri (rubygems-uri "mkmf-lite" version))
3906 (sha256
3907 (base32
3908 "0br9k6zijj1zc25n8p7f2j1mwl58nfgdknf3q13h9k156jvrir06"))))
3909 (build-system ruby-build-system)
3910 (propagated-inputs
3911 `(("ruby-ptools" ,ruby-ptools)))
3912 (synopsis "Lightweight alternative to @code{mkmf}")
3913 (description
3914 "@code{mkmf-lite} is a light version of Ruby's @code{mkmf.rb} designed
3915for use as a library. It does not create packages, builds, or log files of
3916any kind. Instead, it provides mixin methods that you can use in FFI or tests
3917to check for the presence of header files, constants, and so on.")
3918 (home-page "https://github.com/djberg96/mkmf-lite")
3919 (license license:asl2.0)))
3920
1d1d20b0
CB
3921(define-public ruby-mspec
3922 (package
3923 (name "ruby-mspec")
3924 (version "1.9.1")
3925 (source
3926 (origin
3927 (method url-fetch)
3928 (uri (rubygems-uri "mspec" version))
3929 (sha256
3930 (base32
3931 "0wmyh2n40m4srwdx9z6h6g6p46k02pzyhcsja3hqcw5h5b0hfmhd"))))
3932 (build-system ruby-build-system)
3933 (arguments
3934 '(;; TODO: 3 test failures
3935 ;; ./spec/mocks/mock_spec.rb:82
3936 ;; ./spec/utils/name_map_spec.rb:151
3937 ;; ./spec/utils/name_map_spec.rb:155
3938 #:tests? #f
3939 #:phases
3940 (modify-phases %standard-phases
3941 (add-after 'extract-gemspec 'change-dependency-constraints
3942 (lambda _
3943 (substitute* "mspec.gemspec"
3944 (("rake.*") "rake>)\n")
3945 (("rspec.*") "rspec>)\n"))
3946 #t))
3947 (replace 'check
3948 (lambda* (#:key tests? #:allow-other-keys)
3949 (when tests?
3950 (invoke "rspec" "spec"))
3951 #t)))))
3952 (native-inputs
3953 `(("bundler" ,bundler)
3954 ("ruby-rake" ,ruby-rake)
3955 ("ruby-rspec" ,ruby-rspec)))
3956 (synopsis "MSpec is a specialized framework for RubySpec")
3957 (description
3958 "MSpec is a specialized framework that is syntax-compatible with RSpec 2
3959for basic features. MSpec contains additional features that assist in writing
3960specs for Ruby implementations in ruby/spec.")
3961 (home-page "http://rubyspec.org")
3962 (license license:expat)))
3963
b8aecc31
CB
3964(define-public ruby-mysql2
3965 (package
3966 (name "ruby-mysql2")
3967 (version "0.5.2")
3968 (source
3969 (origin
3970 (method git-fetch)
3971 (uri (git-reference
b0e7b699 3972 (url "https://github.com/brianmario/mysql2")
b8aecc31
CB
3973 (commit version)))
3974 (file-name (git-file-name name version))
3975 (sha256
3976 (base32
3977 "11lvfgc2rmvkm52jp0nbi6pvhk06klznghr7llldfw8basl9n5wv"))))
3978 (build-system ruby-build-system)
3979 (arguments
3980 '(;; TODO: Tests require a running MySQL/MariaDB service
3981 #:tests? #f
3982 #:phases
3983 (modify-phases %standard-phases
3984 (replace 'replace-git-ls-files
3985 (lambda _
3986 (substitute* "mysql2.gemspec"
3987 (("git ls-files .*`") "find . -type f |sort`"))
3988 #t))
3989 (add-before 'install 'set-MAKEFLAGS
3990 (lambda* (#:key outputs #:allow-other-keys)
3991 (setenv "MAKEFLAGS"
3992 (string-append
3993 "V=1 "
3994 "prefix=" (assoc-ref outputs "out")))
3995 #t))
3996 ;; Move the 'check phase to after 'install, as then you can test
3997 ;; using the installed mysql2 gem in the store.
3998 (delete 'check)
3999 (add-after 'install 'check
4000 (lambda* (#:key outputs tests? #:allow-other-keys)
4001 (setenv "GEM_PATH"
4002 (string-append
4003 (getenv "GEM_PATH")
4004 ":"
4005 (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))
4006 (when tests?
4007 (invoke "rspec"))
4008 #t)))))
4009 (inputs
997abda9 4010 `(("mariadb-dev" ,mariadb "dev")
b8aecc31
CB
4011 ("zlib" ,zlib)))
4012 (native-inputs
4013 `(("ruby-rspec" ,ruby-rspec)
4014 ("ruby-rake-compiler" ,ruby-rake-compiler)))
4015 (synopsis "MySQL library for Ruby, binding to libmysql")
4016 (description
4017 "This package provides a simple, fast MySQL library for Ruby, binding to
4018libmysql.")
4019 (home-page "https://github.com/brianmario/mysql2")
4020 (license license:expat)))
4021
21f7b7bd
RW
4022(define-public ruby-blankslate
4023 (package
4024 (name "ruby-blankslate")
4025 (version "3.1.3")
4026 (source (origin
4027 (method url-fetch)
4028 (uri (rubygems-uri "blankslate" version))
4029 (sha256
4030 (base32
4031 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
4032 (build-system ruby-build-system)
4033 (arguments
4034 `(#:phases
4035 (modify-phases %standard-phases
4036 (replace 'check
9923d5a4 4037 (lambda _ (invoke "rspec" "spec/"))))))
21f7b7bd
RW
4038 (native-inputs
4039 `(("bundler" ,bundler)
4040 ("ruby-rspec" ,ruby-rspec)))
4041 (synopsis "Abstract base class with no predefined methods")
4042 (description
4043 "BlankSlate provides an abstract base class with no predefined
4044methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
4045as a base class when writing classes that depend upon
4046@code{method_missing} (e.g. dynamic proxies).")
7bf837fd 4047 (home-page "https://github.com/masover/blankslate")
21f7b7bd
RW
4048 (license license:expat)))
4049
afdb437c
CB
4050(define-public ruby-bond
4051 (package
4052 (name "ruby-bond")
4053 (version "0.5.1")
4054 (source
4055 (origin
4056 (method url-fetch)
4057 (uri (rubygems-uri "bond" version))
4058 (sha256
4059 (base32
4060 "1r19ifc4skyl2gxnifrxa5jvbbay9fb2in79ppgv02b6n4bhsw90"))))
4061 (build-system ruby-build-system)
18a29cb3
MC
4062 (arguments
4063 ;; The test suite fails (see:
4064 ;; https://github.com/cldwalker/bond/issues/46).
4065 `(#:tests? #f))
afdb437c
CB
4066 (native-inputs
4067 `(("ruby-bacon" ,ruby-bacon)
4068 ("ruby-bacon-bits" ,ruby-bacon-bits)
4069 ("ruby-mocha-on-bacon" ,ruby-mocha-on-bacon)))
4070 (synopsis "Bond can provide custom autocompletion for arguments, methods
4071and more")
4072 (description
4073 "Bond can autocomplete argument(s) to methods, uniquely completing per
4074module, per method and per argument. Bond provides a configuration system and
4075a DSL for creating custom completions and completion rules. Bond can also
4076load completions that ship with gems. Bond is able to offer more than irb's
4077completion since it uses the full line of input when completing as opposed to
4078irb's last-word approach.")
4079 (home-page "http://tagaholic.me/bond/")
4080 (license license:expat)))
4081
f3d7bb93
CB
4082(define-public ruby-idn-ruby
4083 (package
4084 (name "ruby-idn-ruby")
4085 (version "0.1.0")
4086 (source
4087 (origin
4088 (method url-fetch)
4089 (uri (rubygems-uri "idn-ruby" version))
4090 (sha256
4091 (base32
4092 "07vblcyk3g72sbq12xz7xj28snpxnh3sbcnxy8bglqbfqqhvmawr"))))
4093 (build-system ruby-build-system)
4094 (arguments
4095 '(#:phases
4096 (modify-phases %standard-phases
4097 (delete 'check)
4098 (add-after 'install 'check
4099 (lambda* (#:key tests? outputs #:allow-other-keys)
4100 (when tests?
4101 (let* ((gem-file (cadr (find-files "." "\\.gem")))
4102 (name-and-version (basename gem-file ".gem")))
4103 (apply invoke
4104 "ruby" "--verbose"
4105 (string-append "-I"
4106 (assoc-ref outputs "out")
4107 "/lib/ruby/vendor_ruby/gems/"
4108 name-and-version
4109 "/lib")
4110 (find-files "./test" ".*\\.rb"))))
4111 #t)))))
4112 (inputs
4113 `(("libidn" ,libidn)))
4114 (synopsis "Ruby Bindings for the GNU LibIDN library")
4115 (description
4116 "Ruby Bindings for the GNU LibIDN library, an implementation of the
4117Stringprep, Punycode and IDNA specifications. These are used to encode and
4118decode internationalized domain + names according to the IDNA2003
4119specifications.
4120
4121Included are the most important parts of the Stringprep, Punycode and IDNA
4122APIs like performing Stringprep processings, encoding to and decoding from
4123Punycode strings and converting entire domain names to and from the ACE
4124encoded form.")
4125 (home-page "https://github.com/deepfryed/idn-ruby")
4126 (license license:asl2.0)))
4127
4016ba3f
RW
4128(define-public ruby-instantiator
4129 (package
4130 (name "ruby-instantiator")
688c9076 4131 (version "0.0.7")
4016ba3f
RW
4132 (source (origin
4133 (method url-fetch)
4134 (uri (rubygems-uri "instantiator" version))
4135 (sha256
4136 (base32
688c9076 4137 "0w07w3gkyqr7m0vz5h13vm8b411660qywjm2xxxgdjv4wb3fazbr"))))
4016ba3f
RW
4138 (build-system ruby-build-system)
4139 (arguments
4140 `(#:phases
4141 (modify-phases %standard-phases
4142 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 4143 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 4144 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
4145 (substitute* "Rakefile"
4146 (("t\\.libs << \"test\"" line)
4147 (string-append line "; t.libs << \""
3cb3fa67 4148 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
4149 "/gems/test-unit-"
4150 ,(package-version ruby-test-unit)
4151 "/lib\""))))
4152 #t)))))
4016ba3f
RW
4153 (propagated-inputs
4154 `(("ruby-blankslate" ,ruby-blankslate)))
4155 (native-inputs
4156 `(("bundler" ,bundler)
4157 ("ruby-test-unit" ,ruby-test-unit)))
4158 (synopsis "Instantiate an arbitrary Ruby class")
4159 (description
4160 "Instantiator lets you instantiate an arbitrary Ruby class without
4161knowing anything about the constructor.")
4162 (home-page "https://github.com/floehopper/instantiator")
4163 (license license:expat)))
4164
97aee8d3
RW
4165(define-public ruby-introspection
4166 (package
4167 (name "ruby-introspection")
98ff58a5 4168 (version "0.0.4")
97aee8d3
RW
4169 (source (origin
4170 (method url-fetch)
4171 (uri (rubygems-uri "introspection" version))
4172 (sha256
4173 (base32
98ff58a5 4174 "1y2nbijkc0zlfmn9ss6588ilarq2kbn2i7w7pwwsli66dj84zgca"))))
97aee8d3
RW
4175 (build-system ruby-build-system)
4176 (arguments
4177 `(#:phases
4178 (modify-phases %standard-phases
4179 (add-after 'unpack 'add-test-unit-to-search-path
4180 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 4181 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
4182 (substitute* "Rakefile"
4183 (("t\\.libs << \"test\"" line)
4184 (string-append line "; t.libs << \""
3cb3fa67 4185 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
4186 "/gems/test-unit-"
4187 ,(package-version ruby-test-unit)
4188 "/lib\""))))
97aee8d3
RW
4189 #t)))))
4190 (propagated-inputs
4191 `(("ruby-instantiator" ,ruby-instantiator)
4192 ("ruby-metaclass" ,ruby-metaclass)))
4193 (native-inputs
4194 `(("bundler" ,bundler)
4195 ("ruby-blankslate" ,ruby-blankslate)
4196 ("ruby-test-unit" ,ruby-test-unit)))
4197 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
4198 (description
4199 "Introspection provides tools to inspect the hierarchy of method
4200definitions on a Ruby object.")
4201 (home-page "https://github.com/floehopper/introspection")
4202 (license license:expat)))
4203
d93062fd
RW
4204(define-public ruby-redcarpet
4205 (package
4206 (name "ruby-redcarpet")
ba4084bb 4207 (version "3.5.0")
d93062fd
RW
4208 (source (origin
4209 (method url-fetch)
4210 (uri (rubygems-uri "redcarpet" version))
4211 (sha256
4212 (base32
ba4084bb 4213 "0skcyx1h8b5ms0rp2zm3ql6g322b8c1adnkwkqyv7z3kypb4bm7k"))))
d93062fd
RW
4214 (build-system ruby-build-system)
4215 (arguments
4216 `(#:phases
4217 (modify-phases %standard-phases
4218 ;; The gem archive does not include the conformance tests.
4219 (add-after 'unpack 'disable-conformance-tests
4220 (lambda _
4221 (substitute* "Rakefile"
4222 (("task :test => %w\\[test:unit test:conformance\\]")
4223 "task :test => %w[test:unit]"))
4224 #t)))))
4225 (native-inputs
4226 `(("bundler" ,bundler)
4227 ("ruby-test-unit" ,ruby-test-unit)
4228 ("ruby-rake-compiler" ,ruby-rake-compiler)))
4229 (synopsis "Extensible Markdown to (X)HTML converter")
4230 (description
4231 "Redcarpet is an extensible Ruby library for Markdown processing and
4232conversion to (X)HTML.")
7bf837fd 4233 (home-page "https://github.com/vmg/redcarpet")
d93062fd
RW
4234 (license license:expat)))
4235
09924294
CB
4236(define-public ruby-rerun
4237 (package
4238 (name "ruby-rerun")
4239 (version "0.13.0")
4240 (source
4241 (origin
4242 (method url-fetch)
4243 (uri (rubygems-uri "rerun" version))
4244 (sha256
4245 (base32
4246 "1cskvxk8z8vmfail8na7hj91hs0qnvds9nydj04zi3dbddgnbmvz"))))
4247 (build-system ruby-build-system)
4248 (arguments
4249 '(#:tests? #f)) ; No included tests
4250 (propagated-inputs
4251 `(("ruby-listen" ,ruby-listen)))
4252 (synopsis "Run a process, and restart when some monitored files change")
4253 (description
52beae7b 4254 "Rerun is a tool to launch programs, then monitor the file system, and
09924294
CB
4255restart the program when any of the monitored files change. It's written in
4256Ruby, but can be used for all programs.")
4257 (home-page "https://github.com/alexch/rerun/")
4258 (license license:expat)))
4259
8d85543b
MB
4260(define-public ruby-maxitest
4261 (package
4262 (name "ruby-maxitest")
4263 (version "3.6.0")
4264 (home-page "https://github.com/grosser/maxitest")
4265 (source (origin
4266 ;; Pull from git because the gem does not contain tests.
4267 (method git-fetch)
4268 (uri (git-reference
4269 (url home-page)
4270 (commit (string-append "v" version))))
4271 (file-name (git-file-name name version))
4272 (sha256
4273 (base32
4274 "07b3j0bv3dx5j42jlvpvl07aaxplyi6wq688y3jl8y528ww2hjz8"))))
4275 (build-system ruby-build-system)
4276 (arguments
4277 '(#:test-target "default"
4278 #:phases (modify-phases %standard-phases
4279 (replace 'replace-git-ls-files
4280 (lambda _
4281 (substitute* "maxitest.gemspec"
4282 (("`git ls-files lib/ bin/ MIT-LICENSE Readme.md`")
4283 "`find lib/ bin/ MIT-LICENSE Readme.md -type f | sort`"))
4284 #t))
4285 (add-before 'check 'remove-version-constraints
4286 (lambda _
4287 ;; Don't use specific versions of dependencies, instead
4288 ;; take whatever is available in Guix.
4289 (delete-file "Gemfile.lock")
4290 #t))
4291 (add-before 'check 'add-mtest-on-PATH
4292 (lambda _
4293 ;; Tests use 'mtest' which is not automatically added on
4294 ;; PATH.
4295 (setenv "PATH" (string-append (getcwd) "/bin:"
4296 (getenv "PATH")))
4297 #t)))))
4298 (native-inputs
4299 `(("ps" ,procps)
4300 ("ruby-bump" ,ruby-bump)
4301 ("ruby-byebug" ,ruby-byebug)
4302 ("ruby-rspec" ,ruby-rspec)
4303 ("ruby-wwtd" ,ruby-wwtd)))
4304 (propagated-inputs
4305 `(("ruby-minitest" ,ruby-minitest)))
4306 (synopsis "Minitest with extra features")
4307 (description
4308 "Maxitest is a wrapper around Minitest with extra functionality such
4309as timeouts, an @command{mtest} executable that can run tests by line
4310number, support for interrupted tests, better backtraces, and more.")
4311 (license license:expat)))
4312
4f2a52ae
RW
4313(define-public ruby-mocha
4314 (package
4315 (name "ruby-mocha")
2fc3cc24 4316 (version "1.11.2")
4f2a52ae
RW
4317 (source (origin
4318 (method url-fetch)
4319 (uri (rubygems-uri "mocha" version))
4320 (sha256
4321 (base32
2fc3cc24 4322 "0hxmkm8qxd04vwj8mqnpyrf2dwy7g1k9zipdfhl4y71cw7ijm9n4"))))
4f2a52ae
RW
4323 (build-system ruby-build-system)
4324 (arguments
4325 `(#:phases
4326 (modify-phases %standard-phases
2fc3cc24
MB
4327 (add-before 'check 'remove-rubocop-dependency
4328 (lambda _
4329 ;; Disable dependency on Rubocop, which is just a linter,
4330 ;; and would introduce a circular dependency.
4331 (substitute* "mocha.gemspec"
4332 ((".*rubocop.*")
4333 "true\n"))
4334 #t)))))
4f2a52ae 4335 (native-inputs
2fc3cc24 4336 `(("ruby-introspection" ,ruby-introspection)))
4f2a52ae
RW
4337 (synopsis "Mocking and stubbing library for Ruby")
4338 (description
4339 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
4340allows mocking and stubbing of methods on real (non-mock) classes.")
4341 (home-page "http://gofreerange.com/mocha/docs")
e3febab5
MB
4342 ;; Mocha can be used with either license at the users choice.
4343 (license (list license:expat license:ruby))))
4f2a52ae 4344
cf646acf
CB
4345(define-public ruby-mocha-on-bacon
4346 (package
4347 (name "ruby-mocha-on-bacon")
4348 (version "0.2.3")
4349 (source
4350 (origin
4351 (method url-fetch)
4352 (uri (rubygems-uri "mocha-on-bacon" version))
4353 (sha256
4354 (base32
4355 "1h49b33rq889hn8x3wp9byczl91va16jh1w4d2wyy4yj23icdrcp"))))
4356 (build-system ruby-build-system)
4357 (arguments
4358 ;; rubygems.org release missing tests
4359 '(#:tests? #f))
4360 (propagated-inputs `(("ruby-mocha" ,ruby-mocha)))
4361 (synopsis "Mocha adapter for Bacon")
4362 (description
4363 "This package provides a Mocha adapter for Bacon, allowing you to use the
4364Mocha stubbing and mocking library with Bacon, a small RSpec clone.")
4365 (home-page
4366 "https://github.com/alloy/mocha-on-bacon")
4367 (license license:expat)))
4368
2c84ba7e
RW
4369(define-public ruby-net-ssh
4370 (package
4371 (name "ruby-net-ssh")
5803f872 4372 (version "4.2.0")
2c84ba7e
RW
4373 (source (origin
4374 (method url-fetch)
4375 (uri (rubygems-uri "net-ssh" version))
4376 (sha256
4377 (base32
5803f872 4378 "07c4v97zl1daabmri9zlbzs6yvkl56z1q14bw74d53jdj0c17nhx"))))
2c84ba7e
RW
4379 (build-system ruby-build-system)
4380 (native-inputs
a7938625
MB
4381 `(("bundler" ,bundler)
4382 ("ruby-mocha" ,ruby-mocha)
2c84ba7e
RW
4383 ("ruby-test-unit" ,ruby-test-unit)))
4384 (synopsis "Ruby implementation of the SSH2 client protocol")
4385 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
4386client protocol. It allows you to write programs that invoke and interact
4387with processes on remote servers, via SSH2.")
4388 (home-page "https://github.com/net-ssh/net-ssh")
4389 (license license:expat)))
4390
d38755cb
DM
4391(define-public ruby-net-scp
4392 (package
4393 (name "ruby-net-scp")
4394 ;; The 1.2.1 release would be incompatible with ruby-net-ssh >= 4.
4395 (version "1.2.2.rc2")
4396 (source
4397 (origin
e405f996
TGR
4398 (method git-fetch)
4399 (uri (git-reference
b0e7b699 4400 (url "https://github.com/net-ssh/net-scp")
e405f996
TGR
4401 (commit (string-append "v" version))))
4402 (file-name (git-file-name name version))
d38755cb 4403 (sha256
e405f996 4404 (base32 "1nyn17sy71fn7zs3y6wbgcn35318c10flqgc0582409095x4h0sx"))))
d38755cb
DM
4405 (build-system ruby-build-system)
4406 (native-inputs
4407 `(("bundler" ,bundler)
4408 ("ruby-test-unit" ,ruby-test-unit)
4409 ("ruby-mocha" ,ruby-mocha)))
4410 (propagated-inputs
4411 `(("ruby-net-ssh" ,ruby-net-ssh)))
4412 (synopsis "Pure-Ruby SCP client library")
4413 (description "@code{Net::SCP} is a pure-Ruby implementation of the SCP
4414client protocol.")
4415 (home-page "https://github.com/net-ssh/net-scp")
4416 (license license:expat)))
4417
2206e948
DT
4418(define-public ruby-minitest
4419 (package
4420 (name "ruby-minitest")
88a105c1 4421 (version "5.11.3")
2206e948 4422 (source (origin
e83c6d00
DT
4423 (method url-fetch)
4424 (uri (rubygems-uri "minitest" version))
2206e948
DT
4425 (sha256
4426 (base32
88a105c1 4427 "0icglrhghgwdlnzzp4jf76b0mbc71s80njn5afyfjn4wqji8mqbq"))))
2206e948 4428 (build-system ruby-build-system)
2206e948
DT
4429 (native-inputs
4430 `(("ruby-hoe" ,ruby-hoe)))
4431 (synopsis "Small test suite library for Ruby")
4432 (description "Minitest provides a complete suite of Ruby testing
4433facilities supporting TDD, BDD, mocking, and benchmarking.")
4434 (home-page "https://github.com/seattlerb/minitest")
4435 (license license:expat)))
4436
1db6e09f
RW
4437;; This is the last release of Minitest 4, which is used by some packages.
4438(define-public ruby-minitest-4
4439 (package (inherit ruby-minitest)
4440 (version "4.7.5")
4441 (source (origin
4442 (method url-fetch)
4443 (uri (rubygems-uri "minitest" version))
4444 (sha256
4445 (base32
4446 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
4447 (arguments
4448 `(#:phases
4449 (modify-phases %standard-phases
4450 (add-after 'unpack 'remove-unsupported-method
4451 (lambda _
4452 (substitute* "Rakefile"
4453 (("self\\.rubyforge_name = .*") ""))
9a7017eb
BW
4454 #t))
4455 (add-after 'build 'exclude-failing-tests
4456 (lambda _
4457 ;; Some tests are failing on Ruby 2.4 due to the deprecation of
4458 ;; Fixnum.
4459 (delete-file "test/minitest/test_minitest_spec.rb")
4460 #t)))))))
1db6e09f 4461
450a3f7f
CB
4462(define-public ruby-minitest-around
4463 (package
4464 (name "ruby-minitest-around")
4465 (version "0.5.0")
4466 (source
4467 (origin
4468 (method url-fetch)
4469 (uri (rubygems-uri "minitest-around" version))
4470 (sha256
4471 (base32
4472 "15ywnqx0719jl9c25yqfshmwcir57i5f4hr1ra9v9vay9ylcwndr"))))
4473 (build-system ruby-build-system)
4474 (arguments
4475 '(#:phases
4476 (modify-phases %standard-phases
4477 (add-after 'extract-gemspec 'remove-unnecessary-dependency-versions
4478 (lambda _
4479 (substitute* "minitest-around.gemspec"
4480 (("%q<cucumber>.*") "%q<cucumber>, [\">= 0\"])\n"))
4481 #t)))))
4482 (propagated-inputs
4483 `(("ruby-minitest" ,ruby-minitest)))
4484 (native-inputs
4485 `(("bundler" ,bundler)
4486 ("ruby-cucumber" ,ruby-cucumber)
4487 ("ruby-bump" ,ruby-bump)
4488 ("ruby-test-construct" ,ruby-test-construct)))
4489 (synopsis "Run code around tests in Minitest")
4490 (description
4491 "This library provides a way to run code around tests in Minitest,
4492written using either the unit test or spec style.")
4493 (home-page "https://github.com/splattael/minitest-around")
4494 (license license:expat)))
4495
35130835
DT
4496(define-public ruby-minitest-sprint
4497 (package
4498 (name "ruby-minitest-sprint")
4499 (version "1.1.0")
4500 (source (origin
e83c6d00
DT
4501 (method url-fetch)
4502 (uri (rubygems-uri "minitest-sprint" version))
35130835
DT
4503 (sha256
4504 (base32
e83c6d00 4505 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
35130835 4506 (build-system ruby-build-system)
35130835
DT
4507 (native-inputs
4508 `(("ruby-hoe" ,ruby-hoe)
4509 ("ruby-minitest" ,ruby-minitest)))
4510 (synopsis "Fast test suite runner for minitest")
4511 (description "Minitest-sprint is a test runner for minitest that makes it
4512easier to re-run individual failing tests.")
4513 (home-page "https://github.com/seattlerb/minitest-sprint")
4514 (license license:expat)))
4515
0808e361
DT
4516(define-public ruby-minitest-bacon
4517 (package
4518 (name "ruby-minitest-bacon")
6f9652b0 4519 (version "1.0.3")
0808e361 4520 (source (origin
e83c6d00
DT
4521 (method url-fetch)
4522 (uri (rubygems-uri "minitest-bacon" version))
0808e361
DT
4523 (sha256
4524 (base32
6f9652b0 4525 "0zhdwcl6bgha61qiyfvr7zs7ywaxc33wmj9xhxl8jdmpdvifvfaj"))))
0808e361 4526 (build-system ruby-build-system)
0808e361
DT
4527 (native-inputs
4528 `(("ruby-hoe" ,ruby-hoe)))
4529 (inputs
4530 `(("ruby-minitest" ,ruby-minitest)))
4531 (synopsis "Bacon compatibility library for minitest")
4532 (description "Minitest-bacon extends minitest with bacon-like
4533functionality, making it easier to migrate test suites from bacon to minitest.")
4534 (home-page "https://github.com/seattlerb/minitest-bacon")
4535 (license license:expat)))
4536
39dc0eb5
BW
4537(define-public ruby-minitest-focus
4538 (package
4539 (name "ruby-minitest-focus")
4540 (version "1.1.2")
4541 (source
4542 (origin
4543 (method url-fetch)
4544 (uri (rubygems-uri "minitest-focus" version))
4545 (sha256
4546 (base32
4547 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
4548 (build-system ruby-build-system)
4549 (propagated-inputs
4550 `(("ruby-minitest" ,ruby-minitest)))
4551 (native-inputs
4552 `(("ruby-hoe" ,ruby-hoe)))
4553 (synopsis "Allows a few specific tests to be focused on")
4554 (description
4555 "@code{minitest-focus} gives the ability focus on a few tests with ease
4556without having to use command-line arguments. It introduces a @code{focus}
4557class method for use in testing classes, specifying that the next defined test
4558is to be run.")
4559 (home-page "https://github.com/seattlerb/minitest-focus")
4560 (license license:expat)))
4561
99fc5cd5
BW
4562(define-public ruby-minitest-pretty-diff
4563 ;; Use git reference because gem is out of date and does not contain testing
4564 ;; script. There are no releases on GitHub.
4565 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
4566 (package
4567 (name "ruby-minitest-pretty-diff")
4568 (version (string-append "0.1-1." (string-take commit 8)))
4569 (source (origin
4570 (method git-fetch)
4571 (uri (git-reference
b0e7b699 4572 (url "https://github.com/adammck/minitest-pretty_diff")
99fc5cd5
BW
4573 (commit commit)))
4574 (file-name (string-append name "-" version "-checkout"))
4575 (sha256
4576 (base32
4577 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
4578 (build-system ruby-build-system)
4579 (arguments
4580 `(#:phases
4581 (modify-phases %standard-phases
4582 (replace 'check
4583 (lambda _
9923d5a4 4584 (invoke "script/test"))))))
99fc5cd5
BW
4585 (native-inputs
4586 `(("bundler" ,bundler)
4587 ("ruby-turn" ,ruby-turn)))
4588 (synopsis "Pretty-print hashes and arrays in MiniTest")
4589 (description
4590 "@code{minitest-pretty_diff} monkey-patches
4591@code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
4592diffing them. This makes it easier to spot differences between nested
4593structures when tests fail.")
4594 (home-page "https://github.com/adammck/minitest-pretty_diff")
4595 (license license:expat))))
4596
685d0d2f
BW
4597(define-public ruby-minitest-moar
4598 (package
4599 (name "ruby-minitest-moar")
4600 (version "0.0.4")
4601 (source
4602 (origin
4603 (method url-fetch)
4604 (uri (rubygems-uri "minitest-moar" version))
4605 (sha256
4606 (base32
4607 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
4608 (build-system ruby-build-system)
4609 (arguments
4610 `(#:phases
4611 (modify-phases %standard-phases
4612 (add-before 'check 'clean-dependencies
4613 (lambda _
4614 ;; Remove all gems defined in the Gemfile because these are not
4615 ;; truly needed.
4616 (substitute* "Gemfile"
4617 (("gem .*") ""))
4618 ;; Remove byebug as not needed to run tests.
4619 (substitute* "test/test_helper.rb"
4620 (("require 'byebug'") ""))
4621 #t)))))
4622 (native-inputs
4623 `(("bundler" ,bundler)
4624 ("ruby-minitest" ,ruby-minitest)))
4625 (synopsis "Extra features and changes to MiniTest")
4626 (description "@code{MiniTest Moar} add some additional features and
4627changes some default behaviours in MiniTest. For instance, Moar replaces the
4628MiniTest @code{Object#stub} with a global @code{stub} method.")
4629 (home-page "https://github.com/dockyard/minitest-moar")
4630 (license license:expat)))
4631
e07ef1d6
BW
4632(define-public ruby-minitest-bonus-assertions
4633 (package
4634 (name "ruby-minitest-bonus-assertions")
c9e261b7 4635 (version "3.0")
e07ef1d6
BW
4636 (source
4637 (origin
4638 (method url-fetch)
4639 (uri (rubygems-uri "minitest-bonus-assertions" version))
4640 (sha256
4641 (base32
c9e261b7 4642 "1hbq9jk904xkz868yha1bqcm6azm7kmjsll2k4pn2nrcib508h2a"))))
e07ef1d6
BW
4643 (build-system ruby-build-system)
4644 (arguments
4645 `(#:phases
4646 (modify-phases %standard-phases
4647 (add-before 'check 'clean-dependencies
4648 (lambda _
4649 ;; Remove unneeded require statement that would entail another
4650 ;; dependency.
4651 (substitute* "test/minitest_config.rb"
4652 (("require 'minitest/bisect'") ""))
4653 #t)))))
4654 (native-inputs
4655 `(("ruby-hoe" ,ruby-hoe)
4656 ("ruby-minitest-pretty-diff" ,ruby-minitest-pretty-diff)
4657 ("ruby-minitest-focus" ,ruby-minitest-focus)
4658 ("ruby-minitest-moar" ,ruby-minitest-moar)))
4659 (synopsis "Bonus assertions for @code{Minitest}")
4660 (description
4661 "Minitest bonus assertions provides extra MiniTest assertions. For
4662instance, it provides @code{assert_true}, @code{assert_false} and
4663@code{assert_set_equal}.")
4664 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
4665 (license license:expat)))
4666
e2c9a9cc
CB
4667(define-public ruby-minitest-reporters
4668 (package
4669 (name "ruby-minitest-reporters")
4670 (version "1.3.6")
4671 (source
4672 (origin
4673 (method url-fetch)
4674 (uri (rubygems-uri "minitest-reporters" version))
4675 (sha256
4676 (base32
4677 "1a3das80rwgys5rj48i5ly144nvszyqyi748bk9bss74jblcf5ay"))))
4678 (build-system ruby-build-system)
4679 (arguments
4680 '(#:phases
4681 (modify-phases %standard-phases
4682 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
4683 ;; including it as an input can lead to circular dependencies.
4684 (add-after 'unpack 'remove-rubocop-from-Rakefile
4685 (lambda _
4686 (substitute* "Rakefile"
4687 (("require 'rubocop/rake\\_task'") "")
4688 (("RuboCop::RakeTask\\.new\\(:rubocop\\)") "[].each"))
4689 #t))
4690 (add-after 'extract-gemspec 'remove-rubocop-from-gemspec
4691 (lambda _
4692 (substitute* "minitest-reporters.gemspec"
4693 ((".*%q<rubocop>.*") "\n"))
4694 #t)))))
4695 (propagated-inputs
4696 `(("ruby-ansi" ,ruby-ansi)
4697 ("ruby-builder" ,ruby-builder)
4698 ("ruby-minitest" ,ruby-minitest)
4699 ("ruby-progressbar" ,ruby-progressbar)))
4700 (native-inputs
4701 `(("bundler" ,bundler)
4702 ("ruby-maruku" ,ruby-maruku)))
4703 (synopsis "Enhanced reporting for Minitest tests")
4704 (description
4705 "@code{minitest/reporters} provides a custom Minitest runner to improve
4706how the test state is reported. A number of different reporters are
4707available, including a spec reporter, progress bar reporter, a HTML
4708reporter.")
4709 (home-page "https://github.com/kern/minitest-reporters")
4710 (license license:expat)))
4711
e582fa93
BW
4712(define-public ruby-minitest-rg
4713 (package
4714 (name "ruby-minitest-rg")
4715 (version "5.2.0")
4716 (source
4717 (origin
4718 (method url-fetch)
4719 (uri (rubygems-uri "minitest-rg" version))
4720 (sha256
4721 (base32
4722 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
4723 (build-system ruby-build-system)
4724 (arguments
4725 ;; Some tests fail even outside Guix, so disable tests.
4726 ;; https://github.com/blowmage/minitest-rg/issues/12
4727 ;; https://github.com/blowmage/minitest-rg/pull/13
4728 `(#:tests? #f))
4729 (propagated-inputs
4730 `(("ruby-minitest" ,ruby-minitest)))
4731 (synopsis "Coloured output for Minitest")
4732 (description
4733 "@code{minitest-rg} changes the colour of the output from Minitest.")
8e486e80 4734 (home-page "https://blowmage.com/minitest-rg/")
e582fa93
BW
4735 (license license:expat)))
4736
ff9d33a9
CB
4737(define-public ruby-minitest-global-expectations
4738 (package
4739 (name "ruby-minitest-global-expectations")
4740 (version "1.0.1")
4741 (source
4742 (origin
4743 (method url-fetch)
4744 (uri (rubygems-uri "minitest-global_expectations"
4745 version))
4746 (sha256
4747 (base32
4748 "1pp3k2608spj4kvqy2y16hs18an917g6vwgvphrfhjviac83090x"))))
4749 (build-system ruby-build-system)
4750 (propagated-inputs
4751 `(("ruby-minitest" ,ruby-minitest)))
4752 (synopsis "Adjust minitest behaviour for calling expectation methods")
4753 (description
4754 "Minitest-global_expectations allows continued use of expectation methods
4755on all objects. Calling expectation methods on all objects was deprecated in
4756minitest 5.12, and is planned to be removed from minitest 6.")
4757 (home-page "https://github.com/jeremyevans/minitest-global_expectations")
4758 (license license:expat)))
4759
2a96dbe6
BW
4760(define-public ruby-minitest-hooks
4761 (package
4762 (name "ruby-minitest-hooks")
eaaf8b12 4763 (version "1.4.2")
2a96dbe6
BW
4764 (source
4765 (origin
4766 (method url-fetch)
4767 (uri (rubygems-uri "minitest-hooks" version))
4768 (sha256
4769 (base32
eaaf8b12 4770 "0lnpvzijbjrvxjc43d155jnbk2mkfshrz22an711wh004scavlzc"))))
2a96dbe6
BW
4771 (build-system ruby-build-system)
4772 (arguments
4773 '(#:test-target "spec"))
4774 (native-inputs
4775 `(("ruby-sequel" ,ruby-sequel)
4776 ("ruby-sqlite3" ,ruby-sqlite3)))
4777 (synopsis "Hooks for the minitest framework")
4778 (description
4779 "Minitest-hooks adds @code{around}, @code{before_all}, @code{after_all},
4780@code{around_all} hooks for Minitest. This allows, for instance, running each
4781suite of specs inside a database transaction, running each spec inside its own
4782savepoint inside that transaction. This can significantly speed up testing
4783for specs that share expensive database setup code.")
7bf837fd 4784 (home-page "https://github.com/jeremyevans/minitest-hooks")
2a96dbe6
BW
4785 (license license:expat)))
4786
afbbdf77
DT
4787(define-public ruby-daemons
4788 (package
4789 (name "ruby-daemons")
f03153db 4790 (version "1.2.5")
afbbdf77
DT
4791 (source (origin
4792 (method url-fetch)
e83c6d00 4793 (uri (rubygems-uri "daemons" version))
afbbdf77
DT
4794 (sha256
4795 (base32
f03153db 4796 "15smbsg0gxb7nf0nrlnplc68y0cdy13dm6fviavpmw7c630sring"))))
afbbdf77
DT
4797 (build-system ruby-build-system)
4798 (arguments
4799 `(#:tests? #f)) ; no test suite
4800 (synopsis "Daemonize Ruby programs")
4801 (description "Daemons provides a way to wrap existing Ruby scripts to be
4802run as a daemon and to be controlled by simple start/stop/restart commands.")
4803 (home-page "https://github.com/thuehlinger/daemons")
4804 (license license:expat)))
b03eb6ac
CB
4805
4806(define-public ruby-data_uri
4807 (package
4808 (name "ruby-data_uri")
4809 (version "0.1.0")
4810 (source
4811 (origin
4812 (method url-fetch)
4813 (uri (rubygems-uri "data_uri" version))
4814 (sha256
4815 (base32
4816 "0fzkxgdxrlbfl4537y3n9mjxbm28kir639gcw3x47ffchwsgdcky"))))
4817 (build-system ruby-build-system)
4818 (synopsis "URI class for parsing data URIs")
4819 (description
4820 "Data @acronym{URI, universal resource idenfitier}s allow resources to be
4821embedded inside a URI. The URI::Data class provides support for parsing these
4822URIs using the normal URI.parse method.")
4823 (home-page "https://github.com/dball/data_uri")
4824 (license license:expat)))
66e20863 4825
72c785f9
MB
4826(define-public ruby-deep-merge
4827 (package
4828 (name "ruby-deep-merge")
4829 (version "1.2.1")
4830 (home-page "https://github.com/danielsdeleo/deep_merge")
4831 ;; The Rubygem source does not contain the gemspec required for tests.
4832 (source (origin
4833 (method git-fetch)
4834 (uri (git-reference (url home-page) (commit version)))
4835 (file-name (git-file-name name version))
4836 (sha256
4837 (base32
4838 "0c9rk23ilhc0n4489y6lda2wzphpzh6ish6fahlbpjhxn82wb931"))))
4839 (build-system ruby-build-system)
4840 (native-inputs
4841 `(("ruby-minitest" ,ruby-minitest)))
4842 (synopsis "Recursively merge hashes")
4843 (description
4844 "Deep Merge is a set of utility functions for @code{Hash}. It permits
4845you to merge elements inside a hash together recursively.")
4846 (license license:expat)))
4847
66e20863
DT
4848(define-public ruby-git
4849 (package
4850 (name "ruby-git")
ceaff59e 4851 (version "1.3.0")
66e20863
DT
4852 (source (origin
4853 (method url-fetch)
e83c6d00 4854 (uri (rubygems-uri "git" version))
66e20863
DT
4855 (sha256
4856 (base32
ceaff59e 4857 "1waikaggw7a1d24nw0sh8fd419gbf7awh000qhsf411valycj6q3"))))
66e20863
DT
4858 (build-system ruby-build-system)
4859 (arguments
e83c6d00
DT
4860 `(#:tests? #f ; no tests
4861 #:phases (modify-phases %standard-phases
4862 (add-after 'install 'patch-git-binary
4863 (lambda* (#:key inputs outputs #:allow-other-keys)
66e20863
DT
4864 ;; Make the default git binary an absolute path to the
4865 ;; store.
e83c6d00
DT
4866 (let ((git (string-append (assoc-ref inputs "git")
4867 "/bin/git"))
3cb3fa67
CB
4868 (config (string-append
4869 (assoc-ref outputs "out")
4870 "/lib/ruby/vendor_ruby/gems/git-"
4871 ,version "/lib/git/config.rb")))
e83c6d00 4872 (substitute* (list config)
66e20863
DT
4873 (("'git'")
4874 (string-append "'" git "'")))
e83c6d00 4875 #t))))))
66e20863
DT
4876 (inputs
4877 `(("git" ,git)))
4878 (synopsis "Ruby wrappers for Git")
4879 (description "Ruby/Git is a Ruby library that can be used to create, read
4880and manipulate Git repositories by wrapping system calls to the git binary.")
4881 (home-page "https://github.com/schacon/ruby-git")
4882 (license license:expat)))
71d3e2c2 4883
95598153
MB
4884(define-public ruby-hocon
4885 (package
4886 (name "ruby-hocon")
fd13ec5f 4887 (version "1.3.1")
95598153
MB
4888 (home-page "https://github.com/puppetlabs/ruby-hocon")
4889 (source (origin
4890 (method git-fetch)
4891 (uri (git-reference (url home-page) (commit version)))
4892 (file-name (git-file-name name version))
4893 (sha256
4894 (base32
fd13ec5f 4895 "172hh2zr0n9nnszv0qvlgwszgkrq84yahrg053m68asy79zpmbqr"))))
95598153
MB
4896 (build-system ruby-build-system)
4897 (arguments
4898 '(#:phases (modify-phases %standard-phases
4899 (replace 'check
4900 (lambda* (#:key tests? #:allow-other-keys)
4901 (if tests?
4902 (invoke "rspec")
4903 (format #t "test suite not run~%"))
4904 #t)))))
4905 (native-inputs
4906 `(("bundler" ,bundler)
4907 ("ruby-rspec" ,ruby-rspec)))
4908 (synopsis "HOCON config library")
4909 (description
4910 "This package provides Ruby support for the @acronym{HOCON,
4911Human-Optimized Config Object Notation} configuration file format. It
4912supports parsing and modifying HOCON and JSON files, and rendering parsed
4913objects back to a @code{String}.")
4914 (license license:asl2.0)))
4915
71d3e2c2
DT
4916(define-public ruby-slop
4917 (package
4918 (name "ruby-slop")
d14e5eaa 4919 (version "4.5.0")
71d3e2c2
DT
4920 (source (origin
4921 (method url-fetch)
e83c6d00 4922 (uri (rubygems-uri "slop" version))
71d3e2c2
DT
4923 (sha256
4924 (base32
d14e5eaa 4925 "0bfm8535g0rkn9cbjndkckf0f7a3wj0rg4rqhrpsgxnbfdf2lm0p"))))
71d3e2c2
DT
4926 (build-system ruby-build-system)
4927 (native-inputs
4928 `(("ruby-minitest" ,ruby-minitest)))
4929 (synopsis "Ruby command line option parser")
4930 (description "Slop provides a Ruby domain specific language for gathering
4931options and parsing command line flags.")
4932 (home-page "https://github.com/leejarvis/slop")
4933 (license license:expat)))
e778a549 4934
5337f8b9
DT
4935(define-public ruby-slop-3
4936 (package (inherit ruby-slop)
4937 (version "3.6.0")
4938 (source (origin
4939 (method url-fetch)
4940 (uri (rubygems-uri "slop" version))
4941 (sha256
4942 (base32
4943 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
4944
ca914b5b
CB
4945(define-public ruby-multi-xml
4946 (package
4947 (name "ruby-multi-xml")
4948 (version "0.6.0")
4949 (source
4950 (origin
4951 (method url-fetch)
4952 (uri (rubygems-uri "multi_xml" version))
4953 (sha256
4954 (base32
4955 "0lmd4f401mvravi1i1yq7b2qjjli0yq7dfc4p1nj5nwajp7r6hyj"))))
4956 (build-system ruby-build-system)
4957 (arguments
4958 '(#:tests? #f)) ; No included tests
4959 (synopsis "Swappable XML backends for Ruby")
4960 (description
4961 "@code{MultiXml} provides swappable XML backends utilizing either LibXML,
4962Nokogiri, Ox, or REXML.")
4963 (home-page "https://github.com/sferik/multi_xml")
4964 (license license:expat)))
4965
e778a549
DT
4966(define-public ruby-multipart-post
4967 (package
4968 (name "ruby-multipart-post")
4969 (version "2.0.0")
4970 (source (origin
4971 (method url-fetch)
e83c6d00 4972 (uri (rubygems-uri "multipart-post" version))
e778a549
DT
4973 (sha256
4974 (base32
e83c6d00 4975 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
e778a549
DT
4976 (build-system ruby-build-system)
4977 (native-inputs
4978 `(("bundler" ,bundler)))
4979 (synopsis "Multipart POST library for Ruby")
4980 (description "Multipart-Post Adds multipart POST capability to Ruby's
4981net/http library.")
4982 (home-page "https://github.com/nicksieger/multipart-post")
4983 (license license:expat)))
f8da3af0 4984
9a97e7ce
CB
4985(define-public ruby-multi-json
4986 (package
4987 (name "ruby-multi-json")
1b6f5475 4988 (version "1.13.1")
9a97e7ce
CB
4989 (source
4990 (origin
b872b47b 4991 (method git-fetch)
1b6f5475
BW
4992 ;; Tests are not distributed at rubygems.org so download from GitHub
4993 ;; instead.
b872b47b
EF
4994 (uri (git-reference
4995 (url "https://github.com/intridea/multi_json")
4996 (commit (string-append "v" version))))
4997 (file-name (git-file-name name version))
9a97e7ce
CB
4998 (sha256
4999 (base32
b872b47b 5000 "18wpb6p01rrkl4v33byh70vxj2a5jxkfxzv3pz8z6pssy4ymwkm4"))))
9a97e7ce
CB
5001 (build-system ruby-build-system)
5002 (arguments
1b6f5475
BW
5003 `(#:phases
5004 (modify-phases %standard-phases
5005 (add-after 'unpack 'remove-signing-key-reference
5006 (lambda _
5007 (substitute* "multi_json.gemspec"
5008 ((".*spec.signing_key.*") ""))
5009 #t)))))
5010 (native-inputs
5011 `(("bundler" ,bundler)
5012 ("ruby-rspec" ,ruby-rspec)
5013 ("ruby-yard" ,ruby-yard)
5014 ("ruby-json-pure" ,ruby-json-pure)
5015 ("ruby-oj" ,ruby-oj)
5016 ("ruby-yajl-ruby" ,ruby-yajl-ruby)))
9a97e7ce
CB
5017 (synopsis "Common interface to multiple JSON libraries for Ruby")
5018 (description
5019 "This package provides a common interface to multiple JSON libraries,
5020including Oj, Yajl, the JSON gem (with C-extensions), the pure-Ruby JSON gem,
5021NSJSONSerialization, gson.rb, JrJackson, and OkJson.")
1b6f5475 5022 (home-page "https://github.com/intridea/multi_json")
9a97e7ce
CB
5023 (license license:expat)))
5024
5edef88b
BW
5025(define-public ruby-multi-test
5026 (package
5027 (name "ruby-multi-test")
5028 (version "0.1.2")
5029 (source
5030 (origin
5031 (method url-fetch)
5032 (uri (rubygems-uri "multi_test" version))
5033 (sha256
5034 (base32
5035 "1sx356q81plr67hg16jfwz9hcqvnk03bd9n75pmdw8pfxjfy1yxd"))))
5036 (build-system ruby-build-system)
5037 (arguments
5038 '(;; Tests require different sets of specific gem versions to be available,
5039 ;; and there is no gemfile that specifies the newest versions of
5040 ;; dependencies to be tested.
5041 #:tests? #f))
5042 (synopsis
5043 "Interface to testing libraries loaded into a running Ruby process")
5044 (description
5045 "@code{multi_test} provides a uniform interface onto whatever testing
5046libraries that have been loaded into a running Ruby process to help control
5047rogue test/unit/autorun requires.")
5048 (home-page "https://github.com/cucumber/multi_test")
9a97e7ce
CB
5049 (license license:expat)))
5050
f8da3af0
DT
5051(define-public ruby-arel
5052 (package
5053 (name "ruby-arel")
aecd533d 5054 (version "9.0.0")
f8da3af0
DT
5055 (source (origin
5056 (method url-fetch)
5057 (uri (rubygems-uri "arel" version))
5058 (sha256
5059 (base32
aecd533d 5060 "1jk7wlmkr61f6g36w9s2sn46nmdg6wn2jfssrhbhirv5x9n95nk0"))))
f8da3af0
DT
5061 (build-system ruby-build-system)
5062 (arguments '(#:tests? #f)) ; no tests
5063 (home-page "https://github.com/rails/arel")
5064 (synopsis "SQL AST manager for Ruby")
6f23e2fb
TGR
5065 (description "Arel is an SQL @dfn{Abstract Syntax Tree} (AST) manager for
5066Ruby. It simplifies the generation of complex SQL queries and adapts to
5067various relational database implementations.")
f8da3af0 5068 (license license:expat)))
616eaead 5069
554bf4f6
CB
5070(define-public ruby-marcel
5071 (package
5072 (name "ruby-marcel")
5073 (version "0.3.3")
5074 (source
5075 (origin
5076 (method url-fetch)
5077 (uri (rubygems-uri "marcel" version))
5078 (sha256
5079 (base32
5080 "1nxbjmcyg8vlw6zwagf17l9y2mwkagmmkg95xybpn4bmf3rfnksx"))))
5081 (build-system ruby-build-system)
5082 (arguments
5083 '(;; No included tests
5084 #:tests? #f))
5085 (propagated-inputs
5086 `(("ruby-mimemagic" ,ruby-mimemagic)))
5087 (synopsis "MIME type detection using magic numbers, filenames and extensions")
5088 (description
5089 "@code{marcel} provides @acronym{MIME, Multipurpose Internet Mail
5090Extensions} type detection using magic numbers, filenames, and extensions")
5091 (home-page "https://github.com/basecamp/marcel")
5092 (license license:expat)))
5093
616eaead 5094(define-public ruby-minitar
bfaf8efd
BW
5095 ;; We package from the GitHub source to fix the security issue reported at
5096 ;; https://github.com/halostatue/minitar/issues/16.
5097 (let ((commit "e25205ecbb6277ae8a3df1e6a306d7ed4458b6e4"))
5098 (package
5099 (name "ruby-minitar")
5100 (version (string-append "0.5.4-1." (string-take commit 8)))
5101 (source
5102 (origin
5103 (method git-fetch)
5104 (uri (git-reference
b0e7b699 5105 (url "https://github.com/halostatue/minitar")
bfaf8efd
BW
5106 (commit commit)))
5107 (file-name (string-append name "-" version "-checkout"))
5108 (sha256
5109 (base32
5110 "1iywfx07jgjqcmixzkxk9zdwfmij1fyg1z2jlwzj15cj7s99qlfv"))))
5111 (build-system ruby-build-system)
5112 (arguments
5113 '(#:tests? #f)) ; missing a gemspec
5114 (synopsis "Ruby library and utility for handling tar archives")
5115 (description
5116 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
616eaead 5117that provides the ability to deal with POSIX tar archive files.")
bfaf8efd
BW
5118 (home-page "http://www.github.com/atoulme/minitar")
5119 (license (list license:gpl2+ license:ruby)))))
bea1c0e2
DT
5120
5121(define-public ruby-mini-portile
5122 (package
5123 (name "ruby-mini-portile")
5124 (version "0.6.2")
5125 (source
5126 (origin
5127 (method url-fetch)
5128 (uri (rubygems-uri "mini_portile" version))
5129 (sha256
5130 (base32
5131 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
5132 (build-system ruby-build-system)
5133 (arguments
5134 '(#:tests? #f)) ; tests require network access
5135 (synopsis "Ports system for Ruby developers")
5136 (description "Mini-portile is a port/recipe system for Ruby developers.
5137It provides a standard way to compile against specific versions of libraries
5138to reproduce user environments.")
7bf837fd 5139 (home-page "https://github.com/flavorjones/mini_portile")
bea1c0e2 5140 (license license:expat)))
e920bfca 5141
d000fc92
BW
5142(define-public ruby-mini-portile-2
5143 (package (inherit ruby-mini-portile)
a88ac044 5144 (version "2.4.0")
d000fc92
BW
5145 (source (origin
5146 (method url-fetch)
5147 (uri (rubygems-uri "mini_portile2" version))
5148 (sha256
5149 (base32
a88ac044 5150 "15zplpfw3knqifj9bpf604rb3wc1vhq6363pd6lvhayng8wql5vy"))))))
d000fc92 5151
e920bfca
DT
5152(define-public ruby-nokogiri
5153 (package
5154 (name "ruby-nokogiri")
62cc7344 5155 (version "1.10.9")
e920bfca
DT
5156 (source (origin
5157 (method url-fetch)
5158 (uri (rubygems-uri "nokogiri" version))
5159 (sha256
5160 (base32
62cc7344 5161 "12j76d0bp608932xkzmfi638c7aqah57l437q8494znzbj610qnm"))))
e920bfca
DT
5162 (build-system ruby-build-system)
5163 (arguments
5164 ;; Tests fail because Nokogiri can only test with an installed extension,
5165 ;; and also because many test framework dependencies are missing.
7b01f250 5166 `(#:tests? #f
e920bfca
DT
5167 #:gem-flags (list "--" "--use-system-libraries"
5168 (string-append "--with-xml2-include="
5169 (assoc-ref %build-inputs "libxml2")
5e7f1b0b
BW
5170 "/include/libxml2" ))
5171 #:phases
5172 (modify-phases %standard-phases
7b01f250
BW
5173 (add-before 'build 'patch-extconf
5174 ;; 'pkg-config' is not included in the GEM_PATH during
5175 ;; installation, so we add it directly to the load path.
5176 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 5177 (let* ((pkg-config (assoc-ref inputs "ruby-pkg-config")))
7b01f250
BW
5178 (substitute* "ext/nokogiri/extconf.rb"
5179 (("gem 'pkg-config'.*")
5180 (string-append "$:.unshift '"
3cb3fa67 5181 pkg-config "/lib/ruby/vendor_ruby"
7b01f250
BW
5182 "/gems/pkg-config-"
5183 ,(package-version ruby-pkg-config)
5184 "/lib'\n"))))
5e7f1b0b 5185 #t)))))
e920bfca 5186 (native-inputs
7b01f250 5187 `(("ruby-hoe" ,ruby-hoe)))
e920bfca
DT
5188 (inputs
5189 `(("zlib" ,zlib)
5190 ("libxml2" ,libxml2)
5191 ("libxslt" ,libxslt)))
5192 (propagated-inputs
7b01f250
BW
5193 `(("ruby-mini-portile" ,ruby-mini-portile-2)
5194 ("ruby-pkg-config" ,ruby-pkg-config)))
e920bfca
DT
5195 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
5196 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
5197both CSS3 selector and XPath 1.0 support.")
5198 (home-page "http://www.nokogiri.org/")
5199 (license license:expat)))
30b0b725
DT
5200
5201(define-public ruby-method-source
5202 (package
5203 (name "ruby-method-source")
ec08f469 5204 (version "1.0.0")
30b0b725
DT
5205 (source
5206 (origin
5207 (method url-fetch)
5208 (uri (rubygems-uri "method_source" version))
5209 (sha256
5210 (base32
ec08f469 5211 "1pnyh44qycnf9mzi1j6fywd5fkskv3x7nmsqrrws0rjn5dd4ayfp"))))
30b0b725 5212 (build-system ruby-build-system)
c8355037 5213 (arguments
b52bf667
CB
5214 `(#:test-target "spec"
5215 #:phases
5216 (modify-phases %standard-phases
5217 (add-after 'unpack 'remove-git-ls-files
5218 (lambda* (#:key outputs #:allow-other-keys)
5219 (substitute* "Rakefile"
5220 (("git ls-files") "find . -type f"))
5221 #t)))))
30b0b725 5222 (native-inputs
b52bf667 5223 `(("ruby-rspec" ,ruby-rspec)))
30b0b725
DT
5224 (synopsis "Retrieve the source code for Ruby methods")
5225 (description "Method_source retrieves the source code for Ruby methods.
5226Additionally, it can extract source code from Proc and Lambda objects or just
5227extract comments.")
5228 (home-page "https://github.com/banister/method_source")
5229 (license license:expat)))
2e3fdea4
DT
5230
5231(define-public ruby-coderay
5232 (package
5233 (name "ruby-coderay")
5cf0997a 5234 (version "1.1.2")
2e3fdea4
DT
5235 (source
5236 (origin
5237 (method url-fetch)
5238 (uri (rubygems-uri "coderay" version))
5239 (sha256
5240 (base32
5cf0997a 5241 "15vav4bhcc2x3jmi3izb11l4d9f3xv8hp2fszb7iqmpsccv1pz4y"))))
2e3fdea4
DT
5242 (build-system ruby-build-system)
5243 (arguments
5244 '(#:tests? #f)) ; missing test files
5245 (synopsis "Ruby syntax highlighting library")
5246 (description "Coderay is a Ruby library that provides syntax highlighting
5247for select languages.")
5248 (home-page "http://coderay.rubychan.de")
5249 (license license:expat)))
96e76083 5250
f9083965
MC
5251(define-public ruby-cuke-modeler
5252 (package
5253 (name "ruby-cuke-modeler")
5254 (version "3.1.0")
5255 (source
5256 (origin
5257 (method url-fetch)
5258 (uri (rubygems-uri "cuke_modeler" version))
5259 (sha256
5260 (base32
5261 "19smj3g3wvz0203l549sadpcxgh0ir350a6k78gq0bmlv9cchmjb"))))
5262 (build-system ruby-build-system)
5263 (arguments `(#:tests? #f)) ;no test suite in gem
5264 (propagated-inputs
5265 `(("ruby-gherkin" ,ruby-gherkin)))
5266 (synopsis "Gherkin test suite analysis tool")
5267 (description "CukeModeler facilitates modeling a test suite that is
5268written in Gherkin (e.g. Cucumber, SpecFlow, Lettuce, etc.). It does this by
5269providing an abstraction layer on top of the Abstract Syntax Tree (AST) that
5270the @code{cucumber-gherkin} generates when parsing features, as well as
5271providing models for feature files and directories in order to be able to have
5272a fully traversable model tree of a test suite's structure. These models can
5273then be analyzed or manipulated more easily than the underlying AST layer.")
5274 (home-page "https://github.com/enkessler/cuke_modeler")
5275 (license license:expat)))
5276
2156cc9c
MB
5277(define-public ruby-parallel-tests
5278 (package
5279 (name "ruby-parallel-tests")
8a01e2fa 5280 (version "3.0.0")
2156cc9c
MB
5281 (home-page "https://github.com/grosser/parallel_tests")
5282 (source (origin
5283 (method git-fetch)
5284 (uri (git-reference
5285 (url home-page)
5286 (commit (string-append "v" version))))
5287 (file-name (string-append name version))
5288 (sha256
5289 (base32
8a01e2fa 5290 "08a6ndqn2dqacmc7yg48k0dh2rfrynvhkd5hiay16dl9m1r9q8pz"))))
2156cc9c
MB
5291 (build-system ruby-build-system)
5292 (arguments
5293 '(#:test-target "default"
5294 #:phases (modify-phases %standard-phases
5295 (add-after 'patch-source-shebangs 'patch-shell-invokations
5296 (lambda _
5297 (substitute* '("lib/parallel_tests/tasks.rb"
5298 "spec/parallel_tests/tasks_spec.rb")
5299 (("/bin/sh") (which "sh"))
5300 (("/bin/bash") (which "bash")))
5301 #t))
5302 (add-before 'check 'remove-version-constraints
5303 (lambda _
5304 ;; Remove hard coded version constraints, instead just
5305 ;; use whatever versions are available in Guix.
5306 (delete-file "Gemfile.lock")
5307 (substitute* "Gemfile"
5308 (("'minitest',.*")
5309 "'minitest'\n")
5310 (("'cucumber',.*")
5311 "'cucumber'\n"))
5312 #t))
5313 (add-before 'check 'disable-rails-test
5314 (lambda _
5315 ;; XXX: This test attempts to download and run the test
5316 ;; suites of multiple Rails versions(!) directly.
5317 (delete-file "spec/rails_spec.rb")
5318 #t))
5319 (add-before 'check 'set-HOME
5320 (lambda _
5321 ;; Some tests check the output of Bundler, and fail when
5322 ;; Bundler warns that /homeless-shelter does not exist.
5323 (setenv "HOME" "/tmp")
5324 #t)))))
5325 (native-inputs
5326 `(("ruby-bump" ,ruby-bump)
5327 ("ruby-cucumber" ,ruby-cucumber)
8a01e2fa 5328 ("ruby-cuke-modeler" ,ruby-cuke-modeler)
2156cc9c
MB
5329 ("ruby-minitest" ,ruby-minitest)
5330 ("ruby-rake" ,ruby-rake)
5331 ("ruby-rspec" ,ruby-rspec)
5332 ("ruby-spinach" ,ruby-spinach)))
5333 (propagated-inputs
5334 `(("ruby-parallel" ,ruby-parallel)))
5335 (synopsis "Run tests in parallel")
5336 (description
5337 "This package can speed up @code{Test::Unit}, @code{RSpec},
5338@code{Cucumber}, and @code{Spinach} tests by running them concurrently
5339across multiple CPU cores.")
5340 (license license:expat)))
5341
54993457
CB
5342(define-public ruby-parser
5343 (package
5344 (name "ruby-parser")
8c7f4e18 5345 (version "3.0.0.0")
54993457
CB
5346 (source
5347 (origin
5348 (method url-fetch)
5349 (uri (rubygems-uri "parser" version))
5350 (sha256
5351 (base32
8c7f4e18 5352 "1jixakyzmy0j5c1rb0fjrrdhgnyryvrr6vgcybs14jfw09akv5ml"))))
54993457 5353 (build-system ruby-build-system)
6dfe26bf
TOF
5354 (arguments
5355 '(#:tests? #f)) ; tests not included in gem
54993457
CB
5356 (native-inputs
5357 `(("bundler" ,bundler)
5358 ("ruby-cliver" ,ruby-cliver)
5359 ("ruby-simplecov" ,ruby-simplecov)
5360 ("ruby-racc" ,ruby-racc)))
5361 (inputs
5362 `(("ragel" ,ragel)))
5363 (propagated-inputs
5364 `(("ruby-ast" ,ruby-ast)))
5365 (synopsis "Ruby parser written in pure Ruby")
5366 (description
5367 "This package provides a Ruby parser written in pure Ruby.")
5368 (home-page "https://github.com/whitequark/parser")
5369 (license license:expat)))
5370
a8cdfd53
MC
5371(define-public ruby-sexp-processor
5372 (package
5373 (name "ruby-sexp-processor")
5374 (version "4.15.0")
5375 (source
5376 (origin
5377 (method url-fetch)
5378 (uri (rubygems-uri "sexp_processor" version))
5379 (sha256
5380 (base32
5381 "0d1vks77xnd0m3s94a58f9bkdwlaml5qdkmprx279m2s0pc2gv55"))))
5382 (build-system ruby-build-system)
5383 (native-inputs
5384 ;; TODO: Add ruby-minitest-proveit once available.
5385 `(("hoe" ,ruby-hoe)))
5386 (synopsis "ParseTree fork which includes generic S-exp processing tools")
5387 (description "The sexp_processor package is derived from ParseTree, but
5388contrary to ParseTree, it includes all the generic S-exp processing tools.
5389Amongst the included tools are @code{Sexp}, @code{SexpProcessor} and
5390@code{Environment}")
5391 (home-page "https://github.com/seattlerb/sexp_processor")
5392 (license license:expat)))
5393
24be6751
MC
5394(define-public ruby-ruby-parser
5395 (package
5396 (name "ruby-ruby-parser")
5397 (version "3.14.2")
5398 (source
5399 (origin
5400 (method url-fetch)
5401 (uri (rubygems-uri "ruby_parser" version))
5402 (sha256
5403 (base32
5404 "09qcdyjjw3p7g6cjm5m9swkms1xnv35ndiy7yw24cas16qrhha6c"))))
5405 (build-system ruby-build-system)
5406 (native-inputs
5407 `(("hoe" ,ruby-hoe)
5408 ("racc" ,ruby-racc)
5409 ("unifdef" ,unifdef)))
5410 (propagated-inputs
5411 `(("ruby-sexp-processor" ,ruby-sexp-processor)))
5412 (home-page "https://github.com/seattlerb/ruby_parser/")
5413 (synopsis "Ruby parser written in pure Ruby")
5414 (description "The ruby_parser (RP) package provides a Ruby parser written
5415in pure Ruby. It outputs S-expressions which can be manipulated and converted
5416back to Ruby via the @code{ruby2ruby} library.")
5417 (license license:expat)))
5418
16f423cb
CB
5419(define-public ruby-prawn-manual-builder
5420 (package
5421 (name "ruby-prawn-manual-builder")
1d4f0019 5422 (version "0.3.1")
16f423cb
CB
5423 (source
5424 (origin
5425 (method url-fetch)
5426 (uri (rubygems-uri "prawn-manual_builder" version))
5427 (sha256
1d4f0019 5428 (base32 "1vlg5w7wq43g2hgpgra2nrcxj1kb4ayqliz4gmja2rhs037j2vzs"))))
16f423cb
CB
5429 (build-system ruby-build-system)
5430 (arguments
1d4f0019 5431 '(#:tests? #f ; no included tests
16f423cb
CB
5432 #:phases
5433 (modify-phases %standard-phases
5434 (add-after 'extract-gemspec 'patch-gemspec
5435 (lambda _
5436 (substitute* ".gemspec"
5437 ;; Loosen the requirement for pdf-inspector
5438 (("~> 1\\.0\\.7") ">= 0")))))))
5439 (propagated-inputs
5440 `(("ruby-coderay" ,ruby-coderay)))
5441 (synopsis "Tool for writing manuals for Prawn and Prawn accessories")
5442 (description
5443 "This package provides a tool for writing manuals for Prawn and Prawn
5444accessories")
5445 (home-page "https://github.com/prawnpdf/prawn-manual_builder")
cc10ca33 5446 (license %prawn-project-licenses)))
16f423cb 5447
268643b9
CB
5448(define-public ruby-progress_bar
5449 (package
5450 (name "ruby-progress_bar")
5451 (version "1.1.0")
5452 (source
5453 (origin
5454 (method url-fetch)
5455 (uri (rubygems-uri "progress_bar" version))
5456 (sha256
5457 (base32
5458 "1qc40mr6p1z9a3vlpnsg1zfgk1qswviql2a31y63wpv3vr6b5f48"))))
5459 (build-system ruby-build-system)
5460 (arguments
5461 '(#:test-target "spec"))
5462 (propagated-inputs
5463 `(("ruby-highline" ,ruby-highline)
5464 ("ruby-options" ,ruby-options)))
5465 (native-inputs
5466 `(("bundler" ,bundler)
5467 ("ruby-rspec" ,ruby-rspec)
5468 ("ruby-timecop" ,ruby-timecop)))
5469 (synopsis
5470 "Ruby library for displaying progress bars")
5471 (description
5472 "ProgressBar is a simple library for displaying progress bars. The
5473maximum value is configurable, and additional information can be displayed
5474like the percentage completion, estimated time remaining, elapsed time and
5475rate.")
5476 (home-page "https://github.com/paul/progress_bar")
5477 (license license:wtfpl2)))
5478
95f85d44
CB
5479(define-public ruby-dep
5480 (package
5481 (name "ruby-dep")
5482 (version "1.5.0")
5483 (source
5484 (origin
5485 (method url-fetch)
5486 (uri (rubygems-uri "ruby_dep" version))
5487 (sha256
5488 (base32
5489 "1c1bkl97i9mkcvkn1jks346ksnvnnp84cs22gwl0vd7radybrgy5"))))
5490 (build-system ruby-build-system)
5491 (arguments
5492 '(#:tests? #f)) ; No included tests
5493 (synopsis "Creates a version constraint of supported Rubies")
5494 (description
5495 "This package helps create a version constraint of supported Rubies,
5496suitable for a gemspec file.")
5497 (home-page "https://github.com/e2/ruby_dep")
5498 (license license:expat)))
5499
158a9253
CB
5500(define-public ruby-progressbar
5501 (package
5502 (name "ruby-progressbar")
2d2a2363 5503 (version "1.10.1")
158a9253
CB
5504 (source
5505 (origin
5506 (method url-fetch)
5507 (uri (rubygems-uri "ruby-progressbar" version))
5508 (sha256
2d2a2363 5509 (base32 "1k77i0d4wsn23ggdd2msrcwfy0i376cglfqypkk2q77r2l3408zf"))))
158a9253
CB
5510 (build-system ruby-build-system)
5511 (arguments
5512 '(;; TODO: There looks to be a circular dependency with ruby-fuubar.
5513 #:tests? #f))
5514 (synopsis "Text progress bar library for Ruby")
5515 (description
5516 "Ruby/ProgressBar is an flexible text progress bar library for Ruby.
5517The output can be customized with a formatting system.")
5518 (home-page "https://github.com/jfelchner/ruby-progressbar")
5519 (license license:expat)))
5520
96e76083
DT
5521(define-public ruby-pry
5522 (package
5523 (name "ruby-pry")
a0d93c17 5524 (version "0.13.1")
96e76083
DT
5525 (source
5526 (origin
5527 (method url-fetch)
5528 (uri (rubygems-uri "pry" version))
5529 (sha256
5530 (base32
a0d93c17 5531 "0iyw4q4an2wmk8v5rn2ghfy2jaz9vmw2nk8415nnpx2s866934qk"))))
96e76083
DT
5532 (build-system ruby-build-system)
5533 (arguments
5534 '(#:tests? #f)) ; no tests
5535 (propagated-inputs
5536 `(("ruby-coderay" ,ruby-coderay)
1960d4fd 5537 ("ruby-method-source" ,ruby-method-source)))
96e76083
DT
5538 (synopsis "Ruby REPL")
5539 (description "Pry is an IRB alternative and runtime developer console for
5540Ruby. It features syntax highlighting, a plugin architecture, runtime
5541invocation, and source and documentation browsing.")
a0d93c17 5542 (home-page "https://cobaltbluemedia.com/pryrepl/")
96e76083 5543 (license license:expat)))
1415792a 5544
def7908a
MB
5545(define-public ruby-single-cov
5546 (package
5547 (name "ruby-single-cov")
5548 (version "1.3.2")
5549 (home-page "https://github.com/grosser/single_cov")
5550 (source (origin
5551 (method git-fetch)
5552 (uri (git-reference (url home-page)
5553 (commit (string-append "v" version))))
5554 (file-name (git-file-name name version))
5555 (sha256
5556 (base32
5557 "05qdzpcai1p23a120gb9bxkfl4y73k9hicx34ch2lsk31lgi9bl7"))))
5558 (build-system ruby-build-system)
5559 (arguments
5560 '(#:test-target "default"
5561 #:phases (modify-phases %standard-phases
5562 (replace 'replace-git-ls-files
5563 (lambda _
5564 (substitute* "single_cov.gemspec"
5565 (("`git ls-files lib/ bin/ MIT-LICENSE`")
5566 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
5567 #t))
5568 (add-before 'check 'remove-version-constraints
5569 (lambda _
5570 (delete-file "Gemfile.lock")
5571 #t))
5572 (add-before 'check 'make-files-writable
5573 (lambda _
5574 ;; Tests need to create local directories and open files
5575 ;; with write permissions.
5576 (for-each make-file-writable
5577 (find-files "specs" #:directories? #t))
5578 #t))
5579 (add-before 'check 'disable-failing-test
5580 (lambda _
5581 ;; XXX: This test copies assets from minitest, but can
5582 ;; not cope with the files being read-only. Just skip
5583 ;; it for now.
5584 (substitute* "specs/single_cov_spec.rb"
5585 (("it \"complains when coverage is bad\"")
5586 "xit \"complains when coverage is bad\""))
5587 #t)))))
5588 (native-inputs
5589 `(("ruby-bump" ,ruby-bump)
5590 ("ruby-minitest" ,ruby-minitest)
5591 ("ruby-rspec" ,ruby-rspec)
5592 ("ruby-simplecov" ,ruby-simplecov)))
5593 (synopsis "Code coverage reporting tool")
5594 (description
5595 "This package provides actionable code coverage reports for Ruby
5596projects. It has very little overhead and can be easily integrated with
5597development tools to catch coverage problems early.")
5598 (license license:expat)))
5599
f30382b4
EF
5600(define-public ruby-oedipus-lex
5601 (package
5602 (name "ruby-oedipus-lex")
5603 (version "2.5.2")
5604 (source
5605 (origin
5606 (method url-fetch)
5607 (uri (rubygems-uri "oedipus_lex" version))
5608 (sha256
5609 (base32
5610 "1v1rk78khwq87ar300lwll570zxpkq9rjnpgc9mgsyd6mm9qjz4w"))))
5611 (build-system ruby-build-system)
5612 (native-inputs
5613 `(("ruby-hoe" ,ruby-hoe)))
5614 (synopsis "Ruby lexer")
5615 (description
5616 "Oedipus Lex is a lexer generator in the same family as Rexical and Rex.
5617It is based primarily on generating code much like you would a hand-written
5618lexer. It uses StrScanner within a multi-level case statement. As such,
5619Oedipus matches on the first match, not the longest.")
5620 (home-page "https://github.com/seattlerb/oedipus_lex")
5621 (license license:expat)))
5622
051deeb7
RW
5623(define-public ruby-guard
5624 (package
5625 (name "ruby-guard")
5626 (version "2.13.0")
5627 (source (origin
3c6128f6 5628 (method git-fetch)
051deeb7
RW
5629 ;; The gem does not include a Rakefile, nor does it contain a
5630 ;; gemspec file, nor does it come with the tests. This is why
5631 ;; we fetch the tarball from Github.
3c6128f6
EF
5632 (uri (git-reference
5633 (url "https://github.com/guard/guard")
5634 (commit (string-append "v" version))))
5635 (file-name (git-file-name name version))
051deeb7
RW
5636 (sha256
5637 (base32
3c6128f6 5638 "16pxcszr0g2jnl3090didxh1d8z5m2mly14m3w4rspb8fmclsnjs"))))
051deeb7
RW
5639 (build-system ruby-build-system)
5640 (arguments
5641 `(#:tests? #f ; tests require cucumber
5642 #:phases
5643 (modify-phases %standard-phases
5644 (add-after 'unpack 'remove-git-ls-files
5645 (lambda* (#:key outputs #:allow-other-keys)
5646 (substitute* "guard.gemspec"
5647 (("git ls-files -z") "find . -type f -print0"))
5648 #t))
5649 (replace 'build
5650 (lambda _
9923d5a4 5651 (invoke "gem" "build" "guard.gemspec"))))))
051deeb7
RW
5652 (propagated-inputs
5653 `(("ruby-formatador" ,ruby-formatador)
5654 ("ruby-listen" ,ruby-listen)
5655 ("ruby-lumberjack" ,ruby-lumberjack)
5656 ("ruby-nenv" ,ruby-nenv)
5657 ("ruby-notiffany" ,ruby-notiffany)
5658 ("ruby-pry" ,ruby-pry)
5659 ("ruby-shellany" ,ruby-shellany)
5660 ("ruby-thor" ,ruby-thor)))
5661 (native-inputs
5662 `(("bundler" ,bundler)
5663 ("ruby-rspec" ,ruby-rspec)))
5664 (synopsis "Tool to handle events on file system modifications")
5665 (description
5666 "Guard is a command line tool to easily handle events on file system
5667modifications. Guard automates various tasks by running custom rules whenever
5668file or directories are modified.")
3c6128f6 5669 (home-page "https://guardgem.org/")
051deeb7
RW
5670 (license license:expat)))
5671
c09bc60d
MB
5672(define-public ruby-spinach
5673 (package
5674 (name "ruby-spinach")
5675 (version "0.11.0")
702a1012 5676 (home-page "https://github.com/codegram/spinach")
c09bc60d
MB
5677 (source (origin
5678 (method url-fetch)
5679 (uri (rubygems-uri "spinach" version))
5680 (sha256
5681 (base32
5682 "1mv053mqz9c8ngqa6wp1ymk2fax6j0yqzax6918akrdr7c3fx3c6"))))
5683 (build-system ruby-build-system)
5684 (arguments
5685 ;; FIXME: Disable tests altogether because they depend on 'capybara'
5686 ;; which in turn depends on many other unpackaged gems. Enable once
5687 ;; capybara is available.
5688 '(#:tests? #f))
5689 (propagated-inputs
5690 `(("ruby-colorize" ,ruby-colorize)
5691 ("ruby-gherkin-ruby" ,ruby-gherkin-ruby)
5692 ("ruby-json" ,ruby-json)))
5693 (synopsis "Gherkin-based BDD framework")
5694 (description
5695 "Spinach is a high-level @acronym{BDD, Behavior-driven development}
5696framework that leverages the expressive @code{Gherkin} language to help you
5697define executable specifications of your code.")
5698 (license license:expat)))
5699
bcbb3cc9
CB
5700(define-public ruby-tilt
5701 (package
5702 (name "ruby-tilt")
c3f15f54 5703 (version "2.0.10")
bcbb3cc9
CB
5704 (source
5705 (origin
c3f15f54
MC
5706 (method git-fetch) ;the distributed gem lacks tests
5707 (uri (git-reference
b0e7b699 5708 (url "https://github.com/rtomayko/tilt")
c3f15f54
MC
5709 (commit (string-append "v" version))))
5710 (file-name (git-file-name name version))
bcbb3cc9
CB
5711 (sha256
5712 (base32
c3f15f54 5713 "0adb7fg7925n2rd9a8kkqz3mgylw2skp9hkh9qc1rnph72mqsm6r"))))
bcbb3cc9
CB
5714 (build-system ruby-build-system)
5715 (arguments
5716 '(#:phases
5717 (modify-phases %standard-phases
5718 (add-after 'unpack 'remove-some-dependencies
5719 (lambda _
5720 (substitute* "Gemfile"
5721 ;; TODO ronn is used for generating the manual
5722 (("gem 'ronn'.*") "\n")
5723 ;; ruby-haml has a runtime dependency on ruby-tilt, so don't
5724 ;; pass it in as a native-input
5725 (("gem 'haml'.*") "\n")
5726 ;; TODO Not all of these gems are packaged for Guix yet:
5727 ;; less, coffee-script, livescript, babel-transpiler,
5728 ;; typescript-node
5729 (("if can_execjs") "if false")
5730 ;; Disable the secondary group to reduce the number of
5731 ;; dependencies. None of the normal approaches work, so patch
5732 ;; the Gemfile instead.
5733 (("group :secondary") "[].each"))
5734 #t)))))
cfa4a318
MC
5735 (propagated-inputs
5736 `(("ruby-pandoc-ruby" ,ruby-pandoc-ruby)
5737 ("ruby-sassc" ,ruby-sassc)))
bcbb3cc9
CB
5738 (native-inputs
5739 `(("bundler" ,bundler)
5740 ("ruby-yard" ,ruby-yard)
5741 ("ruby-builder" ,ruby-builder)
5742 ("ruby-erubis" ,ruby-erubis)
cfa4a318 5743 ("ruby-markaby" ,ruby-markaby)))
bcbb3cc9
CB
5744 (synopsis "Generic interface to multiple Ruby template engines")
5745 (description
5746 "Tilt is a thin interface over a number of different Ruby template
5747engines in an attempt to make their usage as generic as possible.")
5748 (home-page "https://github.com/rtomayko/tilt/")
5749 (license license:expat)))
5750
1415792a
DT
5751(define-public ruby-thread-safe
5752 (package
5753 (name "ruby-thread-safe")
313dd5dd 5754 (version "0.3.6")
1415792a
DT
5755 (source
5756 (origin
5757 (method url-fetch)
5758 (uri (rubygems-uri "thread_safe" version))
5759 (sha256
5760 (base32
313dd5dd 5761 "0nmhcgq6cgz44srylra07bmaw99f5271l0dpsvl5f75m44l0gmwy"))))
1415792a
DT
5762 (build-system ruby-build-system)
5763 (arguments
5764 '(#:tests? #f)) ; needs simplecov, among others
5765 (synopsis "Thread-safe utilities for Ruby")
5766 (description "The thread_safe library provides thread-safe collections and
5767utilities for Ruby.")
5768 (home-page "https://github.com/ruby-concurrency/thread_safe")
5769 (license license:asl2.0)))
08a1b701
DT
5770
5771(define-public ruby-tzinfo
5772 (package
5773 (name "ruby-tzinfo")
76e1093b 5774 (version "2.0.4")
08a1b701
DT
5775 (source
5776 (origin
76e1093b
EF
5777 (method git-fetch)
5778 (uri (git-reference
5779 ;; Pull from git because the gem has no tests.
5780 (url "https://github.com/tzinfo/tzinfo")
5781 (commit (string-append "v" version))))
5782 (file-name (git-file-name name version))
08a1b701
DT
5783 (sha256
5784 (base32
76e1093b 5785 "0jaq1givdaz5jxz47xngyj3j315n872rk97mnpm5njwm48wy45yh"))))
08a1b701 5786 (build-system ruby-build-system)
740fea08
CB
5787 (arguments
5788 '(#:phases
5789 (modify-phases %standard-phases
5790 (add-after 'unpack 'skip-safe-tests
5791 (lambda _
5792 (substitute* "test/test_utils.rb"
5793 (("def safe_test\\(options = \\{\\}\\)")
5794 "def safe_test(options = {})
5795 skip('The Guix build environment has an unsafe load path')"))
76e1093b
EF
5796 #t))
5797 (add-before 'check 'pre-check
5798 (lambda _
5799 (setenv "HOME" (getcwd))
5800 (substitute* "Gemfile"
5801 (("simplecov.*") "simplecov'\n"))
5802 #t))
5803 (replace 'check
5804 (lambda* (#:key tests? test-target #:allow-other-keys)
5805 (when tests?
5806 (invoke "bundler" "exec" "rake" test-target))
740fea08 5807 #t)))))
08a1b701 5808 (propagated-inputs
76e1093b
EF
5809 `(("ruby-concurrent-ruby" ,ruby-concurrent)))
5810 (native-inputs
5811 `(("ruby-simplecov" ,ruby-simplecov)))
08a1b701
DT
5812 (synopsis "Time zone library for Ruby")
5813 (description "TZInfo is a Ruby library that provides daylight savings
5814aware transformations between times in different time zones.")
2f3800e5 5815 (home-page "https://tzinfo.github.io")
1e12924a
BW
5816 (license license:expat)))
5817
5818(define-public ruby-tzinfo-data
5819 (package
5820 (name "ruby-tzinfo-data")
ebd8e447 5821 (version "1.2021.1")
1e12924a
BW
5822 (source
5823 (origin
bb1e7ed0 5824 (method git-fetch)
1e12924a
BW
5825 ;; Download from GitHub because the rubygems version does not contain
5826 ;; Rakefile or tests.
bb1e7ed0
EF
5827 (uri (git-reference
5828 (url "https://github.com/tzinfo/tzinfo-data")
5829 (commit (string-append "v" version))))
5830 (file-name (git-file-name name version))
1e12924a
BW
5831 (sha256
5832 (base32
ebd8e447 5833 "0yzyr3rf8qaw6kxfc0gwpxsb7gl3rhfpx9g1c2z15vapyminhi60"))))
1e12924a 5834 (build-system ruby-build-system)
ebd8e447
EF
5835 (arguments
5836 `(#:phases
5837 (modify-phases %standard-phases
5838 (add-after 'unpack 'patch-source
5839 (lambda* (#:key inputs #:allow-other-keys)
5840 (substitute* "Rakefile"
5841 (("https://data.iana.org/time-zones/releases")
5842 (assoc-ref inputs "tzdata")))
5843 #t))
5844 (add-before 'check 'pre-check
5845 (lambda _
5846 (setenv "HOME" (getcwd))
5847 (substitute* "Rakefile"
5848 ;; Don't need gpg, and it may break after a time.
5849 (("gpg ") "echo ")
5850 ((" sh\\(\\\"make -C" text)
5851 (string-append " sh(\"sed -i 's@/bin/sh@sh@' #{tzdb_combined_path}/Makefile \")\n"
5852 " sh(\"sed -i 's@cc=@cc?=@' #{tzdb_combined_path}/Makefile \")\n" text)))
5853 (setenv "cc" ,(cc-for-target))
5854 #t)))))
1e12924a
BW
5855 (propagated-inputs
5856 `(("ruby-tzinfo" ,ruby-tzinfo)))
ebd8e447
EF
5857 (native-inputs
5858 `(("tzdata"
5859 ,(file-union "tzdata-for-ruby-tzdata-info"
5860 `(("tzdata2021a.tar.gz"
5861 ,(origin
5862 (method url-fetch)
5863 (uri "https://data.iana.org/time-zones/releases/tzdata2021a.tar.gz")
5864 (sha256
5865 (base32
5866 "022fn6gkmp7pamlgab04x0dm5hnyn2m2fcnyr3pvm36612xd5rrr"))))
5867 ("tzdata2021a.tar.gz.asc"
5868 ,(origin
5869 (method url-fetch)
5870 (uri "https://data.iana.org/time-zones/releases/tzdata2021a.tar.gz.asc")
5871 (sha256
5872 (base32
5873 "0n7h2w8ji1lrxpk0d44wyfshlhr7c9jmwj6lqbxlyvqnfi3gbicx"))))
5874 ("tzcode2021a.tar.gz"
5875 ,(origin
5876 (method url-fetch)
5877 (uri "https://data.iana.org/time-zones/releases/tzcode2021a.tar.gz")
5878 (sha256
5879 (base32
5880 "1l02b0jiwp3fl0xd6227i69d26rmx3yrnq0ssq9vvdmm4jhvyipb"))))
5881 ("tzcode2021a.tar.gz.asc"
5882 ,(origin
5883 (method url-fetch)
5884 (uri "https://data.iana.org/time-zones/releases/tzcode2021a.tar.gz.asc")
5885 (sha256
5886 (base32
5887 "1qhlj4lr810s47s1lwcvv1sgvg2sflf98w4sbg1lc8wzv5qxxv7g")))))))))
1e12924a
BW
5888 (synopsis "Data from the IANA Time Zone database")
5889 (description
5890 "This library provides @code{TZInfo::Data}, which contains data from the
5891IANA Time Zone database packaged as Ruby modules for use with @code{TZInfo}.")
2f3800e5 5892 (home-page "https://tzinfo.github.io")
08a1b701 5893 (license license:expat)))
c99e2247 5894
48e6851f
RW
5895(define-public ruby-rb-inotify
5896 (package
5897 (name "ruby-rb-inotify")
32bbfea8 5898 (version "0.9.10")
48e6851f
RW
5899 (source
5900 (origin
5901 (method url-fetch)
5902 (uri (rubygems-uri "rb-inotify" version))
5903 (sha256
5904 (base32
32bbfea8 5905 "0yfsgw5n7pkpyky6a9wkf1g9jafxb0ja7gz0qw0y14fd2jnzfh71"))))
48e6851f
RW
5906 (build-system ruby-build-system)
5907 (arguments
5908 '(#:tests? #f ; there are no tests
5909 #:phases
5910 (modify-phases %standard-phases
5911 ;; Building the gemspec with rake is not working here since it is
5912 ;; generated with Jeweler. It is also unnecessary because the
5913 ;; existing gemspec does not use any development tools to generate a
5914 ;; list of files.
5915 (replace 'build
5916 (lambda _
9923d5a4 5917 (invoke "gem" "build" "rb-inotify.gemspec"))))))
48e6851f
RW
5918 (propagated-inputs
5919 `(("ruby-ffi" ,ruby-ffi)))
5920 (native-inputs
5921 `(("ruby-yard" ,ruby-yard)))
5922 (synopsis "Ruby wrapper for Linux's inotify")
5923 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
5924kernel subsystem for monitoring changes to files and directories.")
5925 (home-page "https://github.com/nex3/rb-inotify")
5926 (license license:expat)))
5927
a75bdfce
RW
5928(define-public ruby-pry-editline
5929 (package
5930 (name "ruby-pry-editline")
5931 (version "1.1.2")
5932 (source (origin
5933 (method url-fetch)
5934 (uri (rubygems-uri "pry-editline" version))
5935 (sha256
5936 (base32
5937 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
5938 (build-system ruby-build-system)
5939 (arguments `(#:tests? #f)) ; no tests included
5940 (native-inputs
5941 `(("bundler" ,bundler)))
5942 (synopsis "Open the current REPL line in an editor")
5943 (description
5944 "This gem provides a plugin for the Ruby REPL to enable opening the
5945current line in an external editor.")
5946 (home-page "https://github.com/tpope/pry-editline")
5947 (license license:expat)))
5948
d3b20a02
RW
5949(define-public ruby-sdoc
5950 (package
5951 (name "ruby-sdoc")
6700dc33 5952 (version "1.1.0")
d3b20a02
RW
5953 (source (origin
5954 (method url-fetch)
5955 (uri (rubygems-uri "sdoc" version))
5956 (sha256
5957 (base32
6700dc33 5958 "1am73dldx1fqlw2xny5vyk00pgkisg6bvs0pa8jjd7c19drjczrd"))))
d3b20a02
RW
5959 (build-system ruby-build-system)
5960 (arguments
5961 `(#:phases
5962 (modify-phases %standard-phases
fc29d5e6 5963 (add-before 'check 'set-rubylib-and-patch-gemfile
d3b20a02 5964 (lambda _
fdf3a68d 5965 (setenv "RUBYLIB" "lib")
fc29d5e6
BW
5966 (substitute* "sdoc.gemspec"
5967 (("s.add_runtime_dependency.*") "\n")
5968 (("s.add_dependency.*") "\n"))
5969 (substitute* "Gemfile"
5970 (("gem \"rake\".*")
5971 "gem 'rake'\ngem 'rdoc'\ngem 'json'\n"))
d3b20a02
RW
5972 #t)))))
5973 (propagated-inputs
5974 `(("ruby-json" ,ruby-json)))
5975 (native-inputs
5976 `(("bundler" ,bundler)
fdf3a68d
BW
5977 ("ruby-minitest" ,ruby-minitest)
5978 ("ruby-hoe" ,ruby-hoe)))
d3b20a02
RW
5979 (synopsis "Generate searchable RDoc documentation")
5980 (description
5981 "SDoc is an RDoc documentation generator to build searchable HTML
5982documentation for Ruby code.")
7bf837fd 5983 (home-page "https://github.com/voloko/sdoc")
d3b20a02
RW
5984 (license license:expat)))
5985
70b002aa
RW
5986(define-public ruby-tins
5987 (package
5988 (name "ruby-tins")
fbefd6ff 5989 (version "1.15.0")
70b002aa
RW
5990 (source (origin
5991 (method url-fetch)
5992 (uri (rubygems-uri "tins" version))
5993 (sha256
5994 (base32
fbefd6ff 5995 "09whix5a7ics6787zrkwjmp16kqyh6560p9f317syks785805f7s"))))
70b002aa
RW
5996 (build-system ruby-build-system)
5997 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
5998 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
5999 ;; the gemspec.
6000 (arguments
6001 `(#:tests? #f ; there are no tests
6002 #:phases
6003 (modify-phases %standard-phases
6004 (replace 'build
6005 (lambda _
6006 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
6007 ;; causes an error.
6008 (substitute* "tins.gemspec"
6009 (("\"lib/spruz\", ") ""))
9923d5a4 6010 (invoke "gem" "build" "tins.gemspec"))))))
70b002aa
RW
6011 (synopsis "Assorted tools for Ruby")
6012 (description "Tins is a Ruby library providing assorted tools.")
6013 (home-page "https://github.com/flori/tins")
6014 (license license:expat)))
6015
bc8277e4
RW
6016(define-public ruby-gem-hadar
6017 (package
6018 (name "ruby-gem-hadar")
e4fb673a 6019 (version "1.11.0")
bc8277e4
RW
6020 (source (origin
6021 (method url-fetch)
6022 (uri (rubygems-uri "gem_hadar" version))
6023 (sha256
6024 (base32
e4fb673a 6025 "160abb3l4n3gkhd86f22n981bhqxkbf5ym6fhsk796pix6696pd5"))))
bc8277e4
RW
6026 (build-system ruby-build-system)
6027 ;; This gem needs itself at development time. We disable rebuilding of the
6028 ;; gemspec to avoid this loop.
6029 (arguments
6030 `(#:tests? #f ; there are no tests
6031 #:phases
6032 (modify-phases %standard-phases
6033 (replace 'build
6034 (lambda _
9923d5a4 6035 (invoke "gem" "build" "gem_hadar.gemspec"))))))
bc8277e4
RW
6036 (propagated-inputs
6037 `(("git" ,git)
6038 ("ruby-tins" ,ruby-tins)
3fd577e3 6039 ("ruby-yard" ,ruby-yard)))
bc8277e4
RW
6040 (synopsis "Library for the development of Ruby gems")
6041 (description
6042 "This library contains some useful functionality to support the
6043development of Ruby gems.")
6044 (home-page "https://github.com/flori/gem_hadar")
6045 (license license:expat)))
6046
d8cafe29
RW
6047(define-public ruby-minitest-tu-shim
6048 (package
6049 (name "ruby-minitest-tu-shim")
6050 (version "1.3.3")
6051 (source (origin
6052 (method url-fetch)
6053 (uri (rubygems-uri "minitest_tu_shim" version))
6054 (sha256
6055 (base32
6056 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
6057 (build-system ruby-build-system)
6058 (arguments
6059 `(#:phases
6060 (modify-phases %standard-phases
6061 (add-after 'unpack 'fix-test-include-path
6062 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 6063 (let* ((minitest (assoc-ref inputs "ruby-minitest-4")))
761e7042
BW
6064 (substitute* "Rakefile"
6065 (("Hoe\\.add_include_dirs .*")
6066 (string-append "Hoe.add_include_dirs \""
3cb3fa67 6067 minitest "/lib/ruby/vendor_ruby"
761e7042
BW
6068 "/gems/minitest-"
6069 ,(package-version ruby-minitest-4)
6070 "/lib" "\""))))
6071 #t))
d8cafe29
RW
6072 (add-before 'check 'fix-test-assumptions
6073 (lambda _
6074 ;; The test output includes the file name, so a couple of tests
6075 ;; fail. Changing the regular expressions slightly fixes this
6076 ;; problem.
6077 (substitute* "test/test_mini_test.rb"
6078 (("output.sub!\\(.*, 'FILE:LINE'\\)")
6079 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
6080 (("gsub\\(/.*, 'FILE:LINE'\\)")
6081 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
6082 #t)))))
6083 (propagated-inputs
6084 `(("ruby-minitest-4" ,ruby-minitest-4)))
6085 (native-inputs
6086 `(("ruby-hoe" ,ruby-hoe)))
6087 (synopsis "Adapter library between minitest and test/unit")
6088 (description
6089 "This library bridges the gap between the small and fast minitest and
6090Ruby's large and slower test/unit.")
6091 (home-page "https://rubygems.org/gems/minitest_tu_shim")
6092 (license license:expat)))
6093
fd83a212
RW
6094(define-public ruby-term-ansicolor
6095 (package
6096 (name "ruby-term-ansicolor")
f3a6311a 6097 (version "1.6.0")
fd83a212
RW
6098 (source (origin
6099 (method url-fetch)
6100 (uri (rubygems-uri "term-ansicolor" version))
6101 (sha256
6102 (base32
f3a6311a 6103 "1b1wq9ljh7v3qyxkk8vik2fqx2qzwh5lval5f92llmldkw7r7k7b"))))
fd83a212
RW
6104 (build-system ruby-build-system)
6105 ;; Rebuilding the gemspec seems to require git, even though this is not a
6106 ;; git repository, so we just build the gem from the existing gemspec.
6107 (arguments
6108 `(#:phases
6109 (modify-phases %standard-phases
39ecb977
CB
6110 (add-after 'unpack 'fix-test
6111 (lambda -
6112 (substitute* "tests/hsl_triple_test.rb"
6113 (("0\\\\\\.0%")
6114 "0\\.?0?%"))))
fd83a212
RW
6115 (replace 'build
6116 (lambda _
9923d5a4 6117 (invoke "gem" "build" "term-ansicolor.gemspec"))))))
fd83a212
RW
6118 (propagated-inputs
6119 `(("ruby-tins" ,ruby-tins)))
6120 (native-inputs
6121 `(("ruby-gem-hadar" ,ruby-gem-hadar)
6122 ("ruby-minitest-tu-shim" ,ruby-minitest-tu-shim)))
6123 (synopsis "Ruby library to control the attributes of terminal output")
6124 (description
6125 "This Ruby library uses ANSI escape sequences to control the attributes
6126of terminal output.")
2f3800e5 6127 (home-page "https://flori.github.io/term-ansicolor/")
fd83a212
RW
6128 ;; There is no mention of the "or later" clause.
6129 (license license:gpl2)))
6130
a714c30f
CB
6131(define-public ruby-terraform
6132 (package
6133 (name "ruby-terraform")
6134 (version "0.22.0")
6135 (source
6136 (origin
6137 (method url-fetch)
6138 (uri (rubygems-uri "ruby-terraform" version))
6139 (sha256
6140 (base32
6141 "13zjkp71cd19j2ds2h9rqwcfr1zdg5nsh63p89l6qcsc9z39z324"))))
6142 (build-system ruby-build-system)
6143 (arguments
6144 '(#:tests? #f)) ; No included tests
6145 (propagated-inputs
6146 `(("ruby-lino" ,ruby-lino)))
6147 (synopsis "Ruby wrapper around the Terraform command line interface")
6148 (description
6149 "This package provides a Ruby wrapper around the Terraform command line
6150interface so that Terraform can be more easily invoked from Ruby code.")
6151 (home-page "https://github.com/infrablocks/ruby_terraform")
6152 (license license:expat)))
6153
6e376ca4
RW
6154(define-public ruby-pstree
6155 (package
6156 (name "ruby-pstree")
6157 (version "0.1.0")
6158 (source (origin
6159 (method url-fetch)
6160 (uri (rubygems-uri "pstree" version))
6161 (sha256
6162 (base32
6163 "1mig1sv5qx1cdyhjaipy8jlh9j8pnja04vprrzihyfr54x0215p1"))))
6164 (build-system ruby-build-system)
6165 (native-inputs
6166 `(("ruby-gem-hadar" ,ruby-gem-hadar)
6167 ("bundler" ,bundler)))
6168 (synopsis "Create a process tree data structure")
6169 (description
6170 "This library uses the output of the @code{ps} command to create a
6171process tree data structure for the current host.")
2f3800e5 6172 (home-page "https://github.com/flori/pstree")
6e376ca4
RW
6173 ;; There is no mention of the "or later" clause.
6174 (license license:gpl2)))
6175
53239b5f
RW
6176(define-public ruby-utils
6177 (package
6178 (name "ruby-utils")
cd698b6e 6179 (version "0.9.0")
53239b5f
RW
6180 (source (origin
6181 (method url-fetch)
6182 (uri (rubygems-uri "utils" version))
6183 (sha256
6184 (base32
cd698b6e 6185 "196zhgcygrnx09bb9mh22qas03rl9avzx8qs0wnxznpin4pffwcl"))))
53239b5f
RW
6186 (build-system ruby-build-system)
6187 (propagated-inputs
6188 `(("ruby-tins" ,ruby-tins)
6189 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
6190 ("ruby-pstree" ,ruby-pstree)
6191 ("ruby-pry-editline" ,ruby-pry-editline)))
6192 (native-inputs
6193 `(("ruby-gem-hadar" ,ruby-gem-hadar)
6194 ("bundler" ,bundler)))
6195 (synopsis "Command line tools for working with Ruby")
6196 (description
6197 "This package provides assorted command line tools that may be useful
6198when working with Ruby code.")
6199 (home-page "https://github.com/flori/utils")
6200 ;; There is no mention of the "or later" clause.
6201 (license license:gpl2)))
6202
433f10b5
CB
6203(define-public ruby-jaro-winkler
6204 (package
6205 (name "ruby-jaro-winkler")
37b23e44 6206 (version "1.5.4")
433f10b5
CB
6207 (source
6208 (origin
6209 (method url-fetch)
6210 (uri (rubygems-uri "jaro_winkler" version))
6211 (sha256
37b23e44 6212 (base32 "1y8l6k34svmdyqxya3iahpwbpvmn3fswhwsvrz0nk1wyb8yfihsh"))))
433f10b5
CB
6213 (build-system ruby-build-system)
6214 (arguments
37b23e44 6215 '(#:tests? #f)) ; no included tests
433f10b5
CB
6216 (synopsis "Ruby implementation of Jaro-Winkler distance algorithm")
6217 (description
6218 "@code{jaro_winkler} is an implementation of Jaro-Winkler distance
6219algorithm. It is written as a C extension and will fallback to a pure Ruby
6220implementation on platforms where this is unsupported.")
6221 (home-page "https://github.com/tonytonyjan/jaro_winkler")
6222 (license license:expat)))
6223
c99e2247
DT
6224(define-public ruby-json
6225 (package
6226 (name "ruby-json")
a281acce 6227 (version "2.1.0")
c99e2247
DT
6228 (source
6229 (origin
6230 (method url-fetch)
6231 (uri (rubygems-uri "json" version))
6232 (sha256
6233 (base32
a281acce 6234 "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp"))))
c99e2247
DT
6235 (build-system ruby-build-system)
6236 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
6237 (synopsis "JSON library for Ruby")
6238 (description "This Ruby library provides a JSON implementation written as
6239a native C extension.")
6240 (home-page "http://json-jruby.rubyforge.org/")
6241 (license (list license:ruby license:gpl2)))) ; GPL2 only
5ff89a1b 6242
763624f5
RW
6243(define-public ruby-json-pure
6244 (package
6245 (name "ruby-json-pure")
1c65d99f 6246 (version "2.2.0")
763624f5
RW
6247 (source (origin
6248 (method url-fetch)
6249 (uri (rubygems-uri "json_pure" version))
6250 (sha256
6251 (base32
1c65d99f 6252 "0m0j1mfwv0mvw72kzqisb26xjl236ivqypw1741dkis7s63b8439"))))
763624f5
RW
6253 (build-system ruby-build-system)
6254 (arguments
ac01cb07 6255 `(#:phases
763624f5 6256 (modify-phases %standard-phases
ac01cb07 6257 (add-after 'unpack 'fix-rakefile
763624f5 6258 (lambda _
ac01cb07
BW
6259 (substitute* "Rakefile"
6260 ;; Since this is not a git repository, do not call 'git'.
6261 (("`git ls-files`") "`find . -type f |sort`")
6262 ;; Loosen dependency constraint.
6263 (("'test-unit', '~> 2.0'") "'test-unit', '>= 2.0'"))
6264 #t))
6265 (add-after 'replace-git-ls-files 'regenerate-gemspec
6266 (lambda _
6267 ;; Regenerate gemspec so loosened dependency constraints are
6268 ;; propagated.
17cfb7ae
CB
6269 (invoke "rake" "gemspec")))
6270 (add-after 'regenerate-gemspec 'fix-json-java.gemspec
6271 (lambda _
6272 ;; This gemspec doesn't look to be generated by the above
6273 ;; command, so patch it separately.
6274 (substitute* "json-java.gemspec"
6275 (("%q<test-unit>\\.freeze, \\[\"~> 2\\.0\"\\]")
6276 "%q<test-unit>.freeze, [\">= 2.0\"]"))
6277 #t)))))
763624f5 6278 (native-inputs
ac01cb07 6279 `(("bundler" ,bundler)
0c9f73cd
TGR
6280 ("ragel" ,ragel)
6281 ("ruby-simplecov" ,ruby-simplecov)
6282 ("ruby-test-unit" ,ruby-test-unit)))
763624f5
RW
6283 (synopsis "JSON implementation in pure Ruby")
6284 (description
6285 "This package provides a JSON implementation written in pure Ruby.")
1c65d99f 6286 (home-page "https://flori.github.com/json/")
763624f5
RW
6287 (license license:ruby)))
6288
2a8581ac
CB
6289(define-public ruby-jwt
6290 (package
6291 (name "ruby-jwt")
6292 (version "2.1.0")
6293 (source
6294 (origin
6295 (method url-fetch)
6296 (uri (rubygems-uri "jwt" version))
6297 (sha256
6298 (base32
6299 "1w0kaqrbl71cq9sbnixc20x5lqah3hs2i93xmhlfdg2y3by7yzky"))))
6300 (build-system ruby-build-system)
6301 (arguments
6302 '(#:test-target "test"
6303 #:phases
6304 (modify-phases %standard-phases
6305 (add-after 'unpack 'remove-unnecessary-dependencies
6306 (lambda _
6307 (substitute* "spec/spec_helper.rb"
6308 (("require 'simplecov.*") "\n")
6309 ;; Use [].each to disable running the SimpleCov configuration
6310 ;; block
6311 (("SimpleCov\\.configure") "[].each")
6312 (("require 'codeclimate-test-reporter'") "")
6313 (("require 'codacy-coverage'") "")
6314 (("Codacy::Reporter\\.start") ""))
6315 #t)))))
6316 (native-inputs
6317 `(("bundler" ,bundler)
6318 ("ruby-rspec" ,ruby-rspec)
6319 ("ruby-rbnacl" ,ruby-rbnacl)))
6320 (synopsis "Ruby implementation of the JSON Web Token standard")
6321 (description
6322 "This package provides a pure Ruby implementation of the RFC 7519 OAuth
6323@acronym{JWT, JSON Web Token} standard.")
6324 (home-page "https://github.com/jwt/ruby-jwt")
6325 (license license:expat)))
6326
16b324cd
RW
6327;; Even though this package only provides bindings for a Mac OSX API it is
6328;; required by "ruby-listen" at runtime.
6329(define-public ruby-rb-fsevent
6330 (package
6331 (name "ruby-rb-fsevent")
b0ef15ed 6332 (version "0.10.3")
16b324cd
RW
6333 (source (origin
6334 (method url-fetch)
6335 (uri (rubygems-uri "rb-fsevent" version))
6336 (sha256
6337 (base32
b0ef15ed 6338 "1lm1k7wpz69jx7jrc92w3ggczkjyjbfziq5mg62vjnxmzs383xx8"))))
16b324cd
RW
6339 (build-system ruby-build-system)
6340 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
6341 ;; "listen", which needs "rb-fsevent" at runtime.
6342 (arguments `(#:tests? #f))
6343 (synopsis "FSEvents API with signals catching")
6344 (description
6345 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
6346 (home-page "https://rubygems.org/gems/rb-fsevent")
6347 (license license:expat)))
6348
b86be2ad
RW
6349(define-public ruby-listen
6350 (package
6351 (name "ruby-listen")
12341d34 6352 (version "3.2.0")
b86be2ad
RW
6353 (source
6354 (origin
35602819
CB
6355 ;; The gem does not include a Rakefile, so fetch from the Git
6356 ;; repository.
6357 (method git-fetch)
6358 (uri (git-reference
b0e7b699 6359 (url "https://github.com/guard/listen")
35602819
CB
6360 (commit (string-append "v" version))))
6361 (file-name (git-file-name name version))
b86be2ad
RW
6362 (sha256
6363 (base32
12341d34 6364 "1hkp1g6hk5clsmbd001gkc12ma6s459x820piajyasv61m87if24"))))
b86be2ad 6365 (build-system ruby-build-system)
35602819
CB
6366 (arguments
6367 `(#:test-target "spec"
6368 #:phases
6369 (modify-phases %standard-phases
6370 (add-after 'unpack 'fix-files-in-gemspec
6371 (lambda _
6372 (substitute* "listen.gemspec"
6373 (("`git ls-files -z`") "`find . -type f -printf '%P\\\\0' |sort -z`"))
6374 #t))
6375 (add-before 'check 'remove-unnecessary-dependencies'
6376 (lambda _
6377 (substitute* "Rakefile"
6378 ;; Rubocop is for code linting, and is unnecessary for running
6379 ;; the tests.
6380 ((".*rubocop.*") ""))
6381 #t)))))
6382 (native-inputs
6383 `(("bundler" ,bundler)
6384 ("ruby-rspec" ,ruby-rspec)))
6385 (inputs
6386 `(;; ruby-thor is used for the command line interface, and is referenced
6387 ;; in the wrapper, and therefore just needs to be an input.
6388 ("ruby-thor" ,ruby-thor)))
b86be2ad 6389 (propagated-inputs
35602819
CB
6390 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
6391 ("ruby-rb-inotify" ,ruby-rb-inotify)
6392 ("ruby-dep" ,ruby-dep)))
b86be2ad
RW
6393 (synopsis "Listen to file modifications")
6394 (description "The Listen gem listens to file modifications and notifies
6395you about the changes.")
6396 (home-page "https://github.com/guard/listen")
6397 (license license:expat)))
6398
8d3c5ff6
CB
6399(define-public ruby-loofah
6400 (package
6401 (name "ruby-loofah")
8bb7ebc3 6402 (version "2.3.1")
8d3c5ff6
CB
6403 (source
6404 (origin
6405 (method url-fetch)
6406 (uri (rubygems-uri "loofah" version))
6407 (sha256
6408 (base32
8bb7ebc3 6409 "0npqav026zd7r4qdidq9x5nxcp2dzg71bnp421xxx7sngbxf2xbd"))))
8d3c5ff6
CB
6410 (build-system ruby-build-system)
6411 (arguments
6412 '(#:phases
6413 (modify-phases %standard-phases
6414 (add-after 'unpack 'remove-unnecessary-dependencies
6415 (lambda _
6416 ;; concourse is a development tool which is unused, so remove it
6417 ;; so it's not required.
8d3c5ff6 6418 (substitute* "Rakefile"
8bb7ebc3
EF
6419 (("require \"concourse\"") "")
6420 (("Concourse\\.new.*") "task :concourse do\n"))
8d3c5ff6
CB
6421 #t)))))
6422 (native-inputs
6423 `(("ruby-hoe" ,ruby-hoe)
6424 ("ruby-rr" ,ruby-rr)))
6425 (propagated-inputs
6426 `(("ruby-nokogiri" ,ruby-nokogiri)
6427 ("ruby-crass" ,ruby-crass)))
6428 (synopsis "Ruby library for manipulating and transforming HTML/XML")
6429 (description
6430 "Loofah is a general library for manipulating and transforming HTML/XML
6431documents and fragments. It's built on top of Nokogiri and libxml2.")
6432 (home-page "https://github.com/flavorjones/loofah")
6433 (license license:expat)))
6434
5ff89a1b
DT
6435(define-public ruby-activesupport
6436 (package
6437 (name "ruby-activesupport")
bcf1fe5b 6438 (version "5.2.2.1")
5ff89a1b
DT
6439 (source
6440 (origin
6441 (method url-fetch)
6442 (uri (rubygems-uri "activesupport" version))
6443 (sha256
6444 (base32
bcf1fe5b 6445 "161bp4p01v1a1lvszrhd1a02zf9x1p1l1yhw79a3rix1kvzkkdqb"))))
5ff89a1b
DT
6446 (build-system ruby-build-system)
6447 (arguments
2af45e50
BW
6448 `(#:phases
6449 (modify-phases %standard-phases
6450 (replace 'check
6451 (lambda _
9923d5a4
TGR
6452 ;; There are no tests, instead attempt to load the library.
6453 (invoke "ruby" "-Ilib" "-r" "active_support"))))))
5ff89a1b 6454 (propagated-inputs
2af45e50
BW
6455 `(("ruby-concurrent" ,ruby-concurrent)
6456 ("ruby-i18n" ,ruby-i18n)
5ff89a1b 6457 ("ruby-minitest" ,ruby-minitest)
606ee9a1
BW
6458 ("ruby-tzinfo" ,ruby-tzinfo)
6459 ("ruby-tzinfo-data" ,ruby-tzinfo-data)))
5ff89a1b
DT
6460 (synopsis "Ruby on Rails utility library")
6461 (description "ActiveSupport is a toolkit of support libraries and Ruby
6462core extensions extracted from the Rails framework. It includes support for
6463multibyte strings, internationalization, time zones, and testing.")
6464 (home-page "http://www.rubyonrails.org")
6465 (license license:expat)))
f847ad7b 6466
3996f0aa
RW
6467(define-public ruby-crass
6468 (package
6469 (name "ruby-crass")
a84a185a
MB
6470 (version "1.0.6")
6471 (home-page "https://github.com/rgrove/crass")
3996f0aa 6472 (source (origin
a84a185a
MB
6473 ;; The gem does not contain tests, so pull from git.
6474 (method git-fetch)
6475 (uri (git-reference
6476 (url home-page)
6477 (commit (string-append "v" version))))
6478 (file-name (git-file-name name version))
3996f0aa
RW
6479 (sha256
6480 (base32
a84a185a 6481 "1gbsb81psgb6xhnwpx4s409jc0mk0gijh039sy5xyi8jpaaadp40"))))
3996f0aa 6482 (build-system ruby-build-system)
3996f0aa
RW
6483 (synopsis "Pure Ruby CSS parser")
6484 (description
6485 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
3996f0aa
RW
6486 (license license:expat)))
6487
c2c4e5b2 6488(define-public ruby-nokogumbo
2e366b0a
MB
6489 (package
6490 (name "ruby-nokogumbo")
6491 (version "2.0.2")
6492 (source (origin
6493 ;; We use the git reference, because there's no Rakefile in the
6494 ;; published gem and the tarball on Github is outdated.
6495 (method git-fetch)
6496 (uri (git-reference
b0e7b699 6497 (url "https://github.com/rubys/nokogumbo")
2e366b0a
MB
6498 (commit (string-append "v" version))))
6499 (file-name (string-append name "-" version "-checkout"))
6500 (sha256
6501 (base32
6502 "1qg0iyw450lw6d0j1ghzg79a6l60nm1m4qmrzwzybi585861jxcx"))))
6503 (build-system ruby-build-system)
6504 (native-inputs
6505 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
6506 (inputs
6507 `(("gumbo-parser" ,gumbo-parser)))
6508 (propagated-inputs
6509 `(("ruby-nokogiri" ,ruby-nokogiri)))
6510 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
6511 (description
6512 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
c2c4e5b2 6513access the result as a Nokogiri parsed document.")
2e366b0a
MB
6514 (home-page "https://github.com/rubys/nokogumbo/")
6515 (license license:asl2.0)))
c2c4e5b2 6516
d56ff88b
RW
6517(define-public ruby-sanitize
6518 (package
6519 (name "ruby-sanitize")
f362b53c
MB
6520 (version "5.1.0")
6521 (home-page "https://github.com/rgrove/sanitize")
d56ff88b 6522 (source (origin
f362b53c 6523 (method git-fetch)
d56ff88b 6524 ;; The gem does not include the Rakefile, so we download the
f362b53c
MB
6525 ;; source from Github.
6526 (uri (git-reference
6527 (url home-page)
6528 (commit (string-append "v" version))))
6529 (file-name (git-file-name name version))
6530 (patches (search-patches "ruby-sanitize-system-libxml.patch"))
d56ff88b
RW
6531 (sha256
6532 (base32
f362b53c 6533 "0lj0q9yhjp0q0in5majkshnki07mw8m2vxgndx4m5na6232aszl0"))))
d56ff88b
RW
6534 (build-system ruby-build-system)
6535 (propagated-inputs
6536 `(("ruby-crass" ,ruby-crass)
6537 ("ruby-nokogiri" ,ruby-nokogiri)
6538 ("ruby-nokogumbo" ,ruby-nokogumbo)))
6539 (native-inputs
f362b53c 6540 `(("ruby-minitest" ,ruby-minitest)))
d56ff88b
RW
6541 (synopsis "Whitelist-based HTML and CSS sanitizer")
6542 (description
6543 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
6544acceptable elements, attributes, and CSS properties, Sanitize will remove all
6545unacceptable HTML and/or CSS from a string.")
d56ff88b
RW
6546 (license license:expat)))
6547
ed4b6b18
BW
6548(define-public ruby-oj
6549 (package
6550 (name "ruby-oj")
93dfdec5 6551 (version "3.10.1")
ed4b6b18
BW
6552 (source
6553 (origin
b09ef660 6554 (method git-fetch)
ed4b6b18
BW
6555 ;; Version on rubygems.org does not contain Rakefile, so download from
6556 ;; GitHub instead.
b09ef660
EF
6557 (uri (git-reference
6558 (url "https://github.com/ohler55/oj")
6559 (commit (string-append "v" version))))
6560 (file-name (git-file-name name version))
ed4b6b18
BW
6561 (sha256
6562 (base32
93dfdec5 6563 "0i5xjx4sh816zx2c1a4d1q67k7vllg5jnnc4jy6zhbmwi1dvp5vw"))))
ed4b6b18
BW
6564 (build-system ruby-build-system)
6565 (arguments
6566 '(#:test-target "test_all"
6567 #:phases
6568 (modify-phases %standard-phases
6569 (add-before 'check 'disable-bundler
6570 (lambda _
6571 (substitute* "Rakefile"
6572 (("Bundler\\.with_clean_env") "1.times")
6573 (("bundle exec ") "")))))))
6574 (native-inputs
6575 `(("bundler" ,bundler)
6576 ("ruby-rspec" ,ruby-rspec)
6577 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6578 (synopsis "JSON parser for Ruby optimized for speed")
6579 (description
6580 "Oj is a JSON parser and generator for Ruby, where the encoding and
6581decoding of JSON is implemented as a C extension to Ruby.")
b09ef660 6582 (home-page "http://www.ohler.com/oj/")
ed4b6b18
BW
6583 (license (list license:expat ; Ruby code
6584 license:bsd-3)))) ; extension code
6585
f847ad7b
DT
6586(define-public ruby-ox
6587 (package
6588 (name "ruby-ox")
263c0dbf 6589 (version "2.6.0")
f847ad7b
DT
6590 (source
6591 (origin
6592 (method url-fetch)
6593 (uri (rubygems-uri "ox" version))
6594 (sha256
6595 (base32
263c0dbf 6596 "0fmk62b1h2i79dfzjj8wmf8qid1rv5nhwfc17l489ywnga91xl83"))))
f847ad7b
DT
6597 (build-system ruby-build-system)
6598 (arguments
6599 '(#:tests? #f)) ; no tests
6600 (synopsis "Optimized XML library for Ruby")
6601 (description
6602 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
6603written as a native C extension. It was designed to be an alternative to
6604Nokogiri and other Ruby XML parsers for generic XML parsing and as an
6605alternative to Marshal for Object serialization. ")
6606 (home-page "http://www.ohler.com/ox")
6607 (license license:expat)))
4a9e0585 6608
0c4e7625
RW
6609(define-public ruby-redcloth
6610 (package
6611 (name "ruby-redcloth")
2a91494e 6612 (version "4.3.2")
0c4e7625
RW
6613 (source (origin
6614 (method url-fetch)
6615 (uri (rubygems-uri "RedCloth" version))
6616 (sha256
6617 (base32
2a91494e 6618 "0m9dv7ya9q93r8x1pg2gi15rxlbck8m178j1fz7r5v6wr1avrrqy"))))
0c4e7625
RW
6619 (build-system ruby-build-system)
6620 (arguments
6621 `(#:tests? #f ; no tests
6622 #:phases
6623 (modify-phases %standard-phases
6624 ;; Redcloth has complicated rake tasks to build various versions for
6625 ;; multiple targets using RVM. We don't want this so we just use the
6626 ;; existing gemspec.
6627 (replace 'build
6628 (lambda _
9923d5a4 6629 (invoke "gem" "build" "redcloth.gemspec"))))))
0c4e7625
RW
6630 (native-inputs
6631 `(("bundler" ,bundler)
6632 ("ruby-diff-lcs" ,ruby-diff-lcs)
6633 ("ruby-rspec-2" ,ruby-rspec-2)))
6634 (synopsis "Textile markup language parser for Ruby")
6635 (description
6636 "RedCloth is a Ruby parser for the Textile markup language.")
6637 (home-page "http://redcloth.org")
6638 (license license:expat)))
6639
4a9e0585
DT
6640(define-public ruby-pg
6641 (package
6642 (name "ruby-pg")
ab40e861 6643 (version "1.2.3")
4a9e0585
DT
6644 (source
6645 (origin
6646 (method url-fetch)
6647 (uri (rubygems-uri "pg" version))
6648 (sha256
6649 (base32
ab40e861 6650 "13mfrysrdrh8cka1d96zm0lnfs59i5x2g6ps49r2kz5p3q81xrzj"))))
4a9e0585
DT
6651 (build-system ruby-build-system)
6652 (arguments
6653 '(#:test-target "spec"))
6654 (native-inputs
6655 `(("ruby-rake-compiler" ,ruby-rake-compiler)
6656 ("ruby-hoe" ,ruby-hoe)
6657 ("ruby-rspec" ,ruby-rspec)))
6658 (inputs
ffc4869e 6659 `(("postgresql" ,postgresql)))
4a9e0585
DT
6660 (synopsis "Ruby interface to PostgreSQL")
6661 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
4db80f8b 6662with PostgreSQL 9.0 and later.")
4a9e0585
DT
6663 (home-page "https://bitbucket.org/ged/ruby-pg")
6664 (license license:ruby)))
468e5657
DT
6665
6666(define-public ruby-byebug
6667 (package
6668 (name "ruby-byebug")
d5489a61 6669 (version "9.0.6")
468e5657
DT
6670 (source
6671 (origin
6672 (method url-fetch)
6673 (uri (rubygems-uri "byebug" version))
6674 (sha256
6675 (base32
d5489a61 6676 "1kbfcn65rgdhi72n8x9l393b89rvi5z542459k7d1ggchpb0idb0"))))
468e5657
DT
6677 (build-system ruby-build-system)
6678 (arguments
6679 '(#:tests? #f)) ; no tests
6680 (synopsis "Debugger for Ruby 2")
6681 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
6682TracePoint C API for execution control and the Debug Inspector C API for call
6683stack navigation. The core component provides support that front-ends can
6684build on. It provides breakpoint handling and bindings for stack frames among
6685other things and it comes with a command line interface.")
7bf837fd 6686 (home-page "https://github.com/deivid-rodriguez/byebug")
468e5657 6687 (license license:bsd-2)))
64b6ccc3 6688
7aa00628
MC
6689;;; TODO: Make it the default byebug in core-updates.
6690(define-public ruby-byebug-11
6691 (package
6692 (inherit ruby-byebug)
6693 (name "ruby-byebug")
6694 (version "11.1.3")
6695 (source
6696 (origin
6697 (method git-fetch)
6698 (uri (git-reference
b0e7b699 6699 (url "https://github.com/deivid-rodriguez/byebug")
7aa00628
MC
6700 (commit (string-append "v" version))))
6701 (file-name (git-file-name name version))
6702 (sha256
6703 (base32
6704 "0vyy3k2s7dcndngj6m8kxhs1vxc2c93dw8b3yyand3srsg9ffpij"))
6705 (modules '((guix build utils)))
6706 (snippet
6707 '(begin
6708 ;; Remove wrappers that try to setup a bundle environment.
6709 (with-directory-excursion "bin"
6710 (for-each delete-file '("bundle" "rake" "rubocop"))
6711 ;; ruby-minitest doesn't come with a launcher, so fix the one
6712 ;; provided.
6713 (substitute* "minitest"
6714 (("load File\\.expand_path\\(\"bundle\".*") "")
6715 (("require \"bundler/setup\".*") "")))
6716 #t))))
6717 (arguments
6718 `(#:tests? #t
6719 #:phases
6720 (modify-phases %standard-phases
6721 (add-after 'unpack 'skip-tmp-path-sensitive-test
6722 (lambda _
6723 (substitute* "test/commands/where_test.rb"
6724 (("unless /cygwin\\|mswin\\|mingw\\|darwin/.*")
6725 "unless true\n"))
6726 #t))
6727 (add-before 'build 'compile
6728 (lambda _
6729 (invoke "rake" "compile")))
6730 (add-before 'check 'set-home
6731 (lambda _
6732 (setenv "HOME" (getcwd))
6733 #t)))))
6734 (native-inputs
6735 `(("bundler" ,bundler)
6736 ("ruby-chandler" ,ruby-chandler)
6737 ("ruby-minitest" ,ruby-minitest)
6738 ("ruby-pry" ,ruby-pry)
6739 ("ruby-rake-compiler" ,ruby-rake-compiler)
6740 ("ruby-rubocop" ,ruby-rubocop)
6741 ("ruby-yard" ,ruby-yard)))))
6742
5799bc2b
RW
6743(define-public ruby-netrc
6744 (package
6745 (name "ruby-netrc")
6746 (version "0.11.0")
6747 (source (origin
6748 (method url-fetch)
6749 (uri (rubygems-uri "netrc" version))
6750 (sha256
6751 (base32
6752 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
6753 (build-system ruby-build-system)
6754 (arguments
6755 `(#:phases
6756 (modify-phases %standard-phases
6757 (replace 'check
6758 ;; There is no Rakefile and minitest can only run one file at once,
6759 ;; so we have to iterate over all test files.
6760 (lambda _
b23c1f50
MW
6761 (for-each (lambda (file)
6762 (invoke "ruby" "-Itest" file))
6763 (find-files "./test" "test_.*\\.rb"))
6764 #t)))))
5799bc2b
RW
6765 (native-inputs
6766 `(("ruby-minitest" ,ruby-minitest)))
6767 (synopsis "Library to read and update netrc files")
6768 (description
6769 "This library can read and update netrc files, preserving formatting
6770including comments and whitespace.")
6771 (home-page "https://github.com/geemus/netrc")
6772 (license license:expat)))
6773
3a6989ce
RW
6774(define-public ruby-unf-ext
6775 (package
6776 (name "ruby-unf-ext")
14db8f19 6777 (version "0.0.7.6")
3a6989ce
RW
6778 (source (origin
6779 (method url-fetch)
6780 (uri (rubygems-uri "unf_ext" version))
6781 (sha256
6782 (base32
14db8f19 6783 "1ll6w64ibh81qwvjx19h8nj7mngxgffg7aigjx11klvf5k2g4nxf"))))
3a6989ce 6784 (build-system ruby-build-system)
b809cc9a
RW
6785 (arguments
6786 `(#:phases
6787 (modify-phases %standard-phases
6788 (add-after 'build 'build-ext
14db8f19
MB
6789 (lambda _ (invoke "rake" "compile:unf_ext")))
6790 (add-before 'check 'lose-rake-compiler-dock-dependency
6791 (lambda _
6792 ;; rake-compiler-dock is listed in the gemspec, but only
6793 ;; required when cross-compiling.
6794 (substitute* "unf_ext.gemspec"
6795 ((".*rake-compiler-dock.*") ""))
6796 #t)))))
3a6989ce
RW
6797 (native-inputs
6798 `(("bundler" ,bundler)
6799 ("ruby-rake-compiler" ,ruby-rake-compiler)
6800 ("ruby-test-unit" ,ruby-test-unit)))
6801 (synopsis "Unicode normalization form support library")
6802 (description
6803 "This package provides unicode normalization form support for Ruby.")
6804 (home-page "https://github.com/knu/ruby-unf_ext")
6805 (license license:expat)))
6806
2632a067 6807(define-public ruby-tdiff
5071f17b
BW
6808 ;; Use a newer than released snapshot so that rspec-2 is not required.
6809 (let ((commit "b662a6048f08abc45c1a834e5f34dd1c662935e2"))
6810 (package
6811 (name "ruby-tdiff")
6812 (version (string-append "0.3.3-1." (string-take commit 8)))
6813 (source (origin
6814 (method git-fetch)
6815 (uri (git-reference
b0e7b699 6816 (url "https://github.com/postmodern/tdiff")
5071f17b
BW
6817 (commit commit)))
6818 (file-name (string-append name "-" version "-checkout"))
6819 (sha256
6820 (base32
6821 "0n3gq8rx49f7ln6zqlshqfg2mgqyy30rsdjlnki5mv307ykc7ad4"))))
6822 (build-system ruby-build-system)
6823 (native-inputs
6824 `(("ruby-rspec" ,ruby-rspec)
6825 ("ruby-yard" ,ruby-yard)
6826 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
6827 (synopsis "Calculate the differences between two tree-like structures")
6828 (description
6829 "This library provides functions to calculate the differences between two
2632a067 6830tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
5071f17b
BW
6831 (home-page "https://github.com/postmodern/tdiff")
6832 (license license:expat))))
2632a067 6833
f60f5002 6834(define-public ruby-nokogiri-diff
5b0c223a
BW
6835 ;; Use a newer than released snapshot so that rspec-2 is not required.
6836 (let ((commit "a38491e4d8709b7406f2cae11a50226d927d06f5"))
6837 (package
6838 (name "ruby-nokogiri-diff")
6839 (version (string-append "0.2.0-1." (string-take commit 8)))
6840 (source (origin
6841 (method git-fetch)
6842 (uri (git-reference
b0e7b699 6843 (url "https://github.com/postmodern/nokogiri-diff")
5b0c223a
BW
6844 (commit commit)))
6845 (file-name (string-append name "-" version "-checkout"))
6846 (sha256
6847 (base32
6848 "1ah2sfjh9n1p0ln2wkqzfl448ml7j4zfy6dhp1qgzq2m41php6rf"))))
6849 (build-system ruby-build-system)
6850 (propagated-inputs
6851 `(("ruby-tdiff" ,ruby-tdiff)
6852 ("ruby-nokogiri" ,ruby-nokogiri)))
6853 (native-inputs
6854 `(("ruby-rspec" ,ruby-rspec)
6855 ("ruby-yard" ,ruby-yard)
6856 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
6857 (synopsis "Calculate the differences between two XML/HTML documents")
6858 (description
6859 "@code{Nokogiri::Diff} adds the ability to calculate the
f60f5002 6860differences (added or removed nodes) between two XML/HTML documents.")
5b0c223a
BW
6861 (home-page "https://github.com/postmodern/nokogiri-diff")
6862 (license license:expat))))
f60f5002 6863
6dc21310
CB
6864(define-public ruby-racc
6865 (package
6866 (name "ruby-racc")
6867 (version "1.4.14")
6868 (source
6869 (origin
6870 (method url-fetch)
6871 (uri (rubygems-uri "racc" version))
6872 (sha256
6873 (base32
6874 "00yhs2ag7yy5v83mqvkbnhk9bvsh6mx3808k53n61ddzx446v1zl"))))
6875 (build-system ruby-build-system)
6876 (native-inputs
6877 `(("ruby-hoe" ,ruby-hoe)
6878 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6879 (synopsis "LALR(1) parser generator for Ruby")
6880 (description
6881 "Racc is a LALR(1) parser generator. It is written in Ruby itself, and
6882generates Ruby program.")
6883 (home-page "http://i.loveruby.net/en/projects/racc/")
6884 (license (list
6885 ;; Generally licensed under the LGPL2.1, and some files also
6886 ;; available under the same license as Ruby.
6887 license:lgpl2.1
6888 license:ruby))))
6889
64b6ccc3
DT
6890(define-public ruby-rack
6891 (package
6892 (name "ruby-rack")
288d2480 6893 (version "2.0.6")
64b6ccc3
DT
6894 (source
6895 (origin
83870c32 6896 (method git-fetch)
1db791d5 6897 ;; Download from GitHub so that the patch can be applied.
83870c32
EF
6898 (uri (git-reference
6899 (url "https://github.com/rack/rack")
6900 (commit version)))
6901 (file-name (git-file-name name version))
64b6ccc3
DT
6902 (sha256
6903 (base32
83870c32 6904 "1n7z4g1x6yxip096cdc04wq7yk7ywpinq28g2xjb46r4nlv5h0j6"))
1db791d5
BW
6905 ;; Ignore test which fails inside the build environment but works
6906 ;; outside.
6907 (patches (search-patches "ruby-rack-ignore-failing-test.patch"))))
64b6ccc3
DT
6908 (build-system ruby-build-system)
6909 (arguments
6910 '(#:phases
6911 (modify-phases %standard-phases
6912 (add-before 'check 'fix-tests
6913 (lambda _
6914 ;; A few of the tests use the length of a file on disk for
6915 ;; Content-Length and Content-Range headers. However, this file
6916 ;; has a shebang in it which an earlier phase patches, growing
6917 ;; the file size from 193 to 239 bytes when the store prefix is
6918 ;; "/gnu/store".
6919 (let ((size-diff (- (string-length (which "ruby"))
6920 (string-length "/usr/bin/env ruby"))))
6921 (substitute* '("test/spec_file.rb")
6922 (("193")
6923 (number->string (+ 193 size-diff)))
6924 (("bytes(.)22-33" all delimiter)
6925 (string-append "bytes"
6926 delimiter
6927 (number->string (+ 22 size-diff))
6928 "-"
6929 (number->string (+ 33 size-diff))))))
83870c32
EF
6930 #t))
6931 (add-before 'reset-gzip-timestamps 'make-files-writable
6932 (lambda* (#:key outputs #:allow-other-keys)
6933 ;; Make sure .gz files are writable so that the
6934 ;; 'reset-gzip-timestamps' phase can do its work.
6935 (let ((out (assoc-ref outputs "out")))
6936 (for-each make-file-writable
6937 (find-files out "\\.gz$"))
6938 #t))))))
64b6ccc3 6939 (native-inputs
1db791d5
BW
6940 `(("ruby-minitest" ,ruby-minitest)
6941 ("ruby-minitest-sprint" ,ruby-minitest-sprint)
6942 ("which" ,which)))
6943 (propagated-inputs
6944 `(("ruby-concurrent" ,ruby-concurrent)))
64b6ccc3
DT
6945 (synopsis "Unified web application interface for Ruby")
6946 (description "Rack provides a minimal, modular and adaptable interface for
6947developing web applications in Ruby. By wrapping HTTP requests and responses,
6948it unifies the API for web servers, web frameworks, and software in between
6949into a single method call.")
2f3800e5 6950 (home-page "https://rack.github.io/")
64b6ccc3 6951 (license license:expat)))
62e4cc5a 6952
20a0f804
BW
6953(define-public ruby-rack-test
6954 (package
6955 (name "ruby-rack-test")
6956 (version "0.8.3")
6957 (source
6958 (origin
6959 (method url-fetch)
6960 (uri (rubygems-uri "rack-test" version))
6961 (sha256
6962 (base32
6963 "14ij39zywvr1i9f6jsixfg4zxi2q1m1n1nydvf47f0b6sfc9mv1g"))))
6964 (build-system ruby-build-system)
6965 (arguments
6966 ;; Disable tests because of circular dependencies: requires sinatra,
6967 ;; which requires rack-protection, which requires rack-test. Instead
6968 ;; simply require the library.
6969 `(#:phases
6970 (modify-phases %standard-phases
6971 (replace 'check
6972 (lambda _
6973 (invoke "ruby" "-Ilib" "-r" "rack/test"))))))
6974 (propagated-inputs
6975 `(("ruby-rack" ,ruby-rack)))
6976 (synopsis "Testing API for Rack applications")
6977 (description
6978 "Rack::Test is a small, simple testing API for Rack applications. It can
6979be used on its own or as a reusable starting point for Web frameworks and
6980testing libraries to build on.")
6981 (home-page "https://github.com/rack-test/rack-test")
6982 (license license:expat)))
6983
a0a7e690
BW
6984(define-public ruby-rack-protection
6985 (package
6986 (name "ruby-rack-protection")
d51c11fe 6987 (version "2.0.8.1")
a0a7e690
BW
6988 (source
6989 (origin
6990 (method url-fetch)
6991 (uri (rubygems-uri "rack-protection" version))
6992 (sha256
6993 (base32
d51c11fe 6994 "1zyj97bfr1shfgwk4ddmdbw0mdkm4qdyh9s1hl0k7accf3kxx1yi"))))
a0a7e690
BW
6995 (build-system ruby-build-system)
6996 (arguments
fafeeaa2 6997 '(;; Tests missing from the gem.
a0a7e690
BW
6998 #:tests? #f))
6999 (propagated-inputs
7000 `(("ruby-rack" ,ruby-rack)))
7001 (native-inputs
7002 `(("bundler" ,bundler)
7003 ("ruby-rspec" ,ruby-rspec-2)
7004 ("ruby-rack-test" ,ruby-rack-test)))
7005 (synopsis "Rack middleware that protects against typical web attacks")
7006 (description "Rack middleware that can be used to protect against typical
7007web attacks. It can protect all Rack apps, including Rails. For instance, it
7008protects against cross site request forgery, cross site scripting,
7009clickjacking, directory traversal, session hijacking and IP spoofing.")
7010 (home-page "https://github.com/sinatra/sinatra/tree/master/rack-protection")
7011 (license license:expat)))
7012
6edabcb2
CB
7013(define-public ruby-rainbow
7014 (package
7015 (name "ruby-rainbow")
7016 (version "3.0.0")
7017 (source
7018 (origin
7019 (method url-fetch)
7020 (uri (rubygems-uri "rainbow" version))
7021 (sha256
7022 (base32
7023 "0bb2fpjspydr6x0s8pn1pqkzmxszvkfapv0p4627mywl7ky4zkhk"))))
7024 (build-system ruby-build-system)
7025 (arguments
7026 '(#:phases
7027 (modify-phases %standard-phases
7028 ;; Run rspec directly, to avoid requiring Rubocop which is used from
7029 ;; the Rakefile.
7030 (replace 'check
7031 (lambda* (#:key tests? #:allow-other-keys)
7032 (when tests?
7033 (invoke "rspec"))
7034 #t)))))
7035 (native-inputs
7036 `(("bundler" ,bundler)
7037 ("ruby-rspec" ,ruby-rspec)))
7038 (synopsis "Colorize printed text on ANSI terminals")
7039 (description
7040 "@code{rainbow} provides a string presenter object to colorize strings by
7041wrapping them in ANSI escape codes.")
7042 (home-page "https://github.com/sickill/rainbow")
79193b20
CB
7043 (license license:expat)))
7044
6188d643
CB
7045(define-public ruby-rr
7046 (package
7047 (name "ruby-rr")
7048 (version "1.2.1")
7049 (source
7050 (origin
7051 (method url-fetch)
7052 (uri (rubygems-uri "rr" version))
7053 (sha256
7054 (base32
7055 "1n9g78ba4c2zzmz8cdb97c38h1xm0clircag00vbcxwqs4dq0ymp"))))
7056 (build-system ruby-build-system)
7057 (arguments
7058 '(#:tests? #f)) ; test files not included
7059 (native-inputs
7060 `(("bundler" ,bundler)
7061 ("ruby-rspec" ,ruby-rspec)))
7062 (synopsis "Ruby test double framework")
7063 (description
7064 "RR is a test double framework that features a rich selection of double
7065techniques and a terse syntax.")
7066 (home-page "https://rr.github.io/rr/")
7067 (license license:expat)))
7068
79193b20
CB
7069(define-public ruby-rest-client
7070 (package
7071 (name "ruby-rest-client")
7072 (version "2.0.2")
7073 (source
7074 (origin
7075 (method url-fetch)
7076 (uri (rubygems-uri "rest-client" version))
7077 (sha256
7078 (base32
7079 "1hzcs2r7b5bjkf2x2z3n8z6082maz0j8vqjiciwgg3hzb63f958j"))))
7080 (build-system ruby-build-system)
7081 (arguments
7082 '(#:phases
7083 (modify-phases %standard-phases
7084 (add-before 'check 'remove-unnecessary-development-dependencies
7085 (lambda _
7086 (substitute* "rest-client.gemspec"
7087 ;; Remove rubocop as it's unused. Rubocop also indirectly
7088 ;; depends on this package through ruby-parser and ruby-ast so
7089 ;; this avoids a dependency loop.
7090 ((".*rubocop.*") "\n")
7091 ;; Remove pry as it's unused, it's a debugging tool
7092 ((".*pry.*") "\n")
7093 ;; Remove an unnecessarily strict rdoc dependency
7094 ((".*rdoc.*") "\n"))
7095 #t))
7096 (add-before 'check 'delete-network-dependent-tests
7097 (lambda _
7098 (delete-file "spec/integration/request_spec.rb")
7099 (delete-file "spec/integration/httpbin_spec.rb")
7100 #t)))))
7101 (propagated-inputs
7102 `(("ruby-http-cookie" ,ruby-http-cookie)
7103 ("ruby-mime-types" ,ruby-mime-types)
7104 ("ruby-netrc" ,ruby-netrc)))
7105 (native-inputs
7106 `(("bundler" ,bundler)
eea094cc
TGR
7107 ("ruby-webmock" ,ruby-webmock-2)
7108 ("ruby-rspec" ,ruby-rspec)))
79193b20
CB
7109 (synopsis "Simple HTTP and REST client for Ruby")
7110 (description
7111 "@code{rest-client} provides a simple HTTP and REST client for Ruby,
7112inspired by the Sinatra microframework style of specifying actions:
7113@code{get}, @code{put}, @code{post}, @code{delete}.")
7114 (home-page "https://github.com/rest-client/rest-client")
6edabcb2
CB
7115 (license license:expat)))
7116
5c4c28f8
MC
7117(define-public ruby-rubocop-ast
7118 (package
7119 (name "ruby-rubocop-ast")
6e3a8519 7120 (version "1.4.1")
5c4c28f8
MC
7121 (source
7122 (origin
7123 (method git-fetch) ;no test suite in distributed gem
7124 (uri (git-reference
8ed4c468 7125 (url "https://github.com/rubocop-hq/rubocop-ast")
5c4c28f8
MC
7126 (commit (string-append "v" version))))
7127 (file-name (git-file-name name version))
7128 (sha256
7129 (base32
6e3a8519 7130 "1x2m7k4bn4zvvwmj7imzmv0dav6xnrbcvssad1m5lkprx7h5lzkq"))))
5c4c28f8
MC
7131 (build-system ruby-build-system)
7132 (arguments
7133 `(#:test-target "spec"
7134 #:phases (modify-phases %standard-phases
6e3a8519 7135 (add-before 'build 'generate-lexer
5c4c28f8 7136 (lambda _
6e3a8519
EF
7137 (setenv "RUBOCOP_VERSION" "none")
7138 (invoke "rake" "generate")))
5c4c28f8
MC
7139 (replace 'replace-git-ls-files
7140 (lambda _
7141 (substitute* "rubocop-ast.gemspec"
7142 (("`git ls-files(.*)`" _ files)
7143 (format #f "`find ~a -type f| sort`" files)))
7144 #t)))))
7145 (native-inputs
7146 `(("ruby-bump" ,ruby-bump)
6e3a8519
EF
7147 ("ruby-oedipus-lex" ,ruby-oedipus-lex)
7148 ("ruby-pry" ,ruby-pry)
7149 ("ruby-racc" ,ruby-racc)
7150 ("ruby-rake" ,ruby-rake)
7151 ("ruby-rspec" ,ruby-rspec)
7152 ("ruby-simplecov" ,ruby-simplecov)))
5c4c28f8
MC
7153 (propagated-inputs
7154 `(("ruby-parser" ,ruby-parser)))
7155 (synopsis "RuboCop's AST extensions and NodePattern functionality")
7156 (description "Rubocop::AST extends @code{ruby-parser} with classes used
7157by RuboCop to deal with Ruby's Abstract Syntax Tree (AST), in particular:
7158@itemize
7159@item @code{RuboCop::AST::Node}
7160@item @code{RuboCop::AST::NodePattern}
7161@end itemize")
7162 (home-page "https://rubocop.org/")
7163 (license license:expat)))
7164
e098bdae
MC
7165(define-public ruby-rexml
7166 (package
7167 (name "ruby-rexml")
7168 (version "3.2.4")
7169 (source
7170 (origin
7171 (method git-fetch) ;no tests in distributed gem
7172 (uri (git-reference
8ed4c468 7173 (url "https://github.com/ruby/rexml")
e098bdae
MC
7174 (commit (string-append "v" version))))
7175 (file-name (git-file-name name version))
7176 (sha256
7177 (base32
7178 "0rhjjbkaq2f2cs8hyr2i4yjqpcyl8m0wmr2cypa401m3fvz4221i"))))
7179 (build-system ruby-build-system)
7180 (synopsis "XML toolkit for Ruby")
7181 (description "Inspired by Electric XML library for Java, REXML aims to be
7182easy-to-use API, small and fast. It supports both tree and stream document
7183parsing.")
7184 (home-page "https://github.com/ruby/rexml")
7185 (license license:bsd-2)))
7186
93ec41c6
MC
7187(define-public ruby-character-set
7188 (package
7189 (name "ruby-character-set")
7190 (version "1.4.0")
7191 (source
7192 (origin
7193 (method url-fetch)
7194 (uri (rubygems-uri "character_set" version))
7195 (sha256
7196 (base32
7197 "0affq9n77vwy897ri2zhmfinfagf37hcwwimrccy1bcxan9mj3h3"))))
7198 (build-system ruby-build-system)
7199 (arguments '(#:tests? #f)) ;avoid a cycle with ruby-regexp-parser
7200 (synopsis "Ruby library to manipulate Unicode")
7201 (description "CharacterSet is a C-extended Ruby library to work with sets
7202of Unicode code points. It can read and write these sets in various formats
7203and implements the @code{stdlib} @code{Set} interface for them. It also
7204offers an alternate paradigm of @code{String} processing which grants much
7205better performance than @code{Regexp} and @code{String} methods from the
7206@code{stdlib} where applicable. Many parts can be used independently, e.g.:
7207@itemize
7208@item @code{CharacterSet::Character}
7209@item @code{CharacterSet::Parser}
7210@item @code{CharacterSet::Writer}
7211@item @code{RangeCompressor}
7212@end itemize")
7213 (home-page "https://github.com/jaynetics/character_set")
7214 (license license:expat)))
7215
ac75f1df
MC
7216(define-public ruby-range-compressor
7217 (package
7218 (name "ruby-range-compressor")
7219 (version "1.0.0")
7220 (source
7221 (origin
7222 (method git-fetch)
7223 (uri (git-reference
8ed4c468 7224 (url "https://github.com/janosch-x/range_compressor")
ac75f1df
MC
7225 (commit (string-append "v" version))))
7226 (file-name (git-file-name name version))
7227 (sha256
7228 (base32
7229 "0y8slri2msyyg2szgwgriqd6qw9hkxycssdrcl5lk2dbcq5zvn54"))))
7230 (build-system ruby-build-system)
7231 (arguments
7232 `(#:test-target "spec"
7233 #:phases (modify-phases %standard-phases
7234 (add-after 'extract-gemspec 'strip-version-requirements
7235 (lambda _
7236 (substitute* "range_compressor.gemspec"
7237 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
7238 (string-append stripped "\n")))
7239 #t)))))
7240 (native-inputs
7241 `(("ruby-rspec" ,ruby-rspec)))
7242 (synopsis "Simple arrays of objects to arrays of ranges compressor")
7243 (description "RangeCompresses is a tiny library that allows compressing
7244arrays of objects into arrays of ranges. For example, it can turn the
7245following: @code{[1, 2, 3, 4, 6, 8, 9, 10]} into @code{[1..4, 6..6, 8..10]}.")
7246 (home-page "https://github.com/janosch-x/range_compressor")
7247 (license license:expat)))
7248
8aba0333
MC
7249(define-public ruby-regexp-property-values
7250 (package
7251 (name "ruby-regexp-property-values")
7252 (version "1.0.0")
7253 (source
7254 (origin
7255 (method git-fetch)
7256 (uri (git-reference ;no test suite in distributed gem
8ed4c468 7257 (url "https://github.com/jaynetics/regexp_property_values")
8aba0333
MC
7258 (commit (string-append "v" version))))
7259 (file-name (git-file-name name version))
7260 (sha256
7261 (base32
7262 "0l3fjmscg1wxn7kc6bl022cc6k5d91pwb7daq1b5w36kvsx52w1j"))))
7263 (build-system ruby-build-system)
7264 (arguments
7265 '(#:test-target "default"))
7266 (native-inputs
7267 `(("ruby-character-set" ,ruby-character-set)
7268 ("ruby-rake-compiler" ,ruby-rake-compiler)
7269 ("ruby-range-compressor" ,ruby-range-compressor)
7270 ("ruby-rspec" ,ruby-rspec)))
7271 (synopsis "Inspect Ruby's regex engine property values")
7272 (description "This small library lets you see which property values are
7273supported by the regular expression engine of the Ruby version you are running
7274and can directly read out their code point ranges. In other words, it
7275determines all supported values for @code{\\p{value}} expressions and what
7276they match.")
7277 (home-page "https://github.com/jaynetics/regexp_property_values")
7278 (license license:expat)))
7279
b6f2a8d1
MC
7280(define-public ruby-regexp-parser
7281 (package
7282 (name "ruby-regexp-parser")
86d635b8 7283 (version "2.0.0")
b6f2a8d1
MC
7284 (source
7285 (origin
7286 (method git-fetch) ;bin/test missing from gem
7287 (uri (git-reference
8ed4c468 7288 (url "https://github.com/ammar/regexp_parser")
b6f2a8d1
MC
7289 (commit (string-append "v" version))))
7290 (file-name (git-file-name name version))
7291 (sha256
7292 (base32
86d635b8 7293 "09ddxdwlml30q6j4rqf06bbjj1mwx00rs0bksnyblhv85anrqz3k"))))
b6f2a8d1
MC
7294 (build-system ruby-build-system)
7295 (arguments
7296 '(#:test-target "default"
7297 #:phases (modify-phases %standard-phases
7298 (add-before 'build 'compile-scanner.rb
7299 (lambda _
7300 (invoke "rake" "build")
7301 ;; XXX: This is needed otherwise the install
7302 ;; phase fails to delete the installed cached
7303 ;; gem file.
7304 (delete-file-recursively "pkg")
7305 #t)))))
7306 (native-inputs
7307 `(("ragel" ,ragel)
7308 ("ruby-regexp-property-values" ,ruby-regexp-property-values)
7309 ("ruby-rspec" ,ruby-rspec)))
7310 (synopsis "A regular expression parser library for Ruby ")
7311 (description "A Ruby gem for tokenizing, parsing, and transforming regular
7312expressions. It comprises the following components:
7313@itemize
7314@item A scanner/tokenizer based on Ragel,
7315@item A lexer that produces a stream of token objects,
7316@item A parser that produces a tree of Expression objects.
7317@end itemize")
7318 (home-page "https://github.com/ammar/regexp_parser")
7319 (license license:expat)))
7320
12ed6da4
MC
7321(define-public ruby-test-queue
7322 (package
7323 (name "ruby-test-queue")
7324 (version "0.4.2")
7325 (source
7326 (origin
7327 (method url-fetch)
7328 (uri (rubygems-uri "test-queue" version))
7329 (sha256
7330 (base32
7331 "0hvm3n1qrqxqilhqk4rjivw3gcrd08zz1i6am9qzg1ppjxv6f36f"))))
7332 (build-system ruby-build-system)
7333 (arguments
7334 '(#:phases
7335 (modify-phases %standard-phases
7336 (replace 'check
7337 (lambda* (#:key tests? #:allow-other-keys)
7338 (when tests?
7339 (invoke "rspec"))
7340 #t)))))
7341 (native-inputs
7342 `(("ruby-rspec" ,ruby-rspec)))
7343 (synopsis "Minitest/RSpec parallel test runner for CI environments")
7344 (description "The test-queue module is a parallel test runner,
7345built using a centralized queue to ensure optimal distribution of
7346tests between workers. It is specifically optimized for Continuous
7347Integration (CI) environments: build statistics from each run are
7348stored locally and used to sort the queue at the beginning of the next
7349run.")
7350 (home-page "https://github.com/tmm1/test-queue")
7351 (license license:expat)))
7352
5d8fe6de
CB
7353(define-public ruby-rubocop
7354 (package
7355 (name "ruby-rubocop")
301d1bac 7356 (version "1.10.0")
5d8fe6de
CB
7357 (source
7358 (origin
c164c402
MC
7359 (method git-fetch) ;no tests in distributed gem
7360 (uri (git-reference
8ed4c468 7361 (url "https://github.com/rubocop-hq/rubocop")
c164c402
MC
7362 (commit (string-append "v" version))))
7363 (file-name (git-file-name name version))
5d8fe6de
CB
7364 (sha256
7365 (base32
301d1bac 7366 "0wjw9vpzr4f3nf1zf010bag71w4hdi0haybdn7r5rlmw45pmim29"))))
5d8fe6de
CB
7367 (build-system ruby-build-system)
7368 (arguments
c164c402
MC
7369 '(#:test-target "default"
7370 #:phases
7371 (modify-phases %standard-phases
c164c402
MC
7372 (add-before 'check 'set-home
7373 (lambda _
7374 (setenv "HOME" (getcwd))
7375 #t))
301d1bac
EF
7376 ;; Rubocop depends on itself for tests, directly and indirectly. By
7377 ;; regenerating the TODO list we test rubocop against itself and
7378 ;; forgo adjusting the test suite to our environment each release.
7379 (replace 'check
7380 (lambda* (#:key tests? #:allow-other-keys)
7381 (when tests?
7382 (make-file-writable ".rubocop_todo.yml")
7383 (invoke "./exe/rubocop" "--auto-gen-config"))
7384 #t))
c164c402
MC
7385 (add-before 'check 'make-adoc-files-writable
7386 (lambda _
7387 (let ((adoc-files (find-files "docs/modules/ROOT/pages"
7388 "\\.adoc$")))
7389 (for-each make-file-writable adoc-files))
7390 #t)))))
7391 (native-inputs
7392 `(("ruby-bump" ,ruby-bump)
301d1bac 7393 ("ruby-memory-profiler" ,ruby-memory-profiler)
c164c402 7394 ("ruby-pry" ,ruby-pry)
301d1bac 7395 ("ruby-rake" ,ruby-rake)
c164c402 7396 ("ruby-rspec" ,ruby-rspec)
301d1bac
EF
7397 ("ruby-rubocop-minimal" ,ruby-rubocop-minimal)
7398 ("ruby-rubocop-performance-minimal" ,ruby-rubocop-performance-minimal)
7399 ("ruby-rubocop-rspec-minimal" ,ruby-rubocop-rspec-minimal)
7400 ("ruby-simplecov" ,ruby-simplecov)
7401 ("ruby-stackprof" ,ruby-stackprof)
c164c402 7402 ("ruby-test-queue" ,ruby-test-queue)
301d1bac 7403 ("ruby-webmock" ,ruby-webmock)
c164c402 7404 ("ruby-yard" ,ruby-yard)))
5d8fe6de 7405 (propagated-inputs
c164c402
MC
7406 `(("ruby-parallel" ,ruby-parallel)
7407 ("ruby-parser" ,ruby-parser)
5d8fe6de 7408 ("ruby-rainbow" ,ruby-rainbow)
c164c402
MC
7409 ("ruby-regexp-parser" ,ruby-regexp-parser)
7410 ("ruby-rexml" ,ruby-rexml)
7411 ("ruby-rubocop-ast" ,ruby-rubocop-ast)
5d8fe6de 7412 ("ruby-progressbar" ,ruby-progressbar)
5d8fe6de
CB
7413 ("ruby-unicode-display-width" ,ruby-unicode-display-width)))
7414 (synopsis "Ruby code style checking tool")
7415 (description
7416 "@code{rubocop} is a Ruby code style checking tool. It aims to enforce
7417the community-driven Ruby Style Guide.")
7418 (home-page "https://github.com/rubocop-hq/rubocop")
7419 (license license:expat)))
7420
301d1bac
EF
7421(define-public ruby-rubocop-minimal
7422 (hidden-package
7423 (package
7424 (inherit ruby-rubocop)
7425 (arguments
7426 (substitute-keyword-arguments (package-arguments ruby-rubocop)
7427 ((#:tests? _ #f) #f)))
7428 (propagated-inputs '())
7429 (native-inputs '()))))
7430
6ef85256
BW
7431(define-public ruby-contest
7432 (package
7433 (name "ruby-contest")
7434 (version "0.1.3")
7435 (source
7436 (origin
7437 (method url-fetch)
7438 (uri (rubygems-uri "contest" version))
7439 (sha256
7440 (base32
7441 "1p9f2292b7b0fbrcjswvj9v01z7ig5ig52328wyqcabgb553qsdf"))))
7442 (build-system ruby-build-system)
7443 (synopsis "Write declarative tests using nested contexts")
7444 (description
7445 "Contest allows writing declarative @code{Test::Unit} tests using nested
7446contexts without performance penalties.")
7447 (home-page "https://github.com/citrusbyte/contest")
7448 (license license:expat)))
7449
c4550f75
BW
7450(define-public ruby-creole
7451 (package
7452 (name "ruby-creole")
7453 (version "0.5.0")
7454 (source
7455 (origin
7456 (method url-fetch)
7457 (uri (rubygems-uri "creole" version))
7458 (sha256
7459 (base32
7460 "00rcscz16idp6dx0dk5yi5i0fz593i3r6anbn5bg2q07v3i025wm"))))
7461 (build-system ruby-build-system)
7462 (native-inputs
7463 `(("ruby-bacon" ,ruby-bacon)))
7464 (synopsis "Creole markup language converter")
7465 (description
7466 "Creole is a lightweight markup language and this library for converting
7467creole to @code{HTML}.")
7468 (home-page "https://github.com/minad/creole")
7469 (license license:ruby)))
7470
6aaa815e
PP
7471(define-public ruby-docile
7472 (package
7473 (name "ruby-docile")
7474 (version "1.1.5")
7475 (source
7476 (origin
7477 (method url-fetch)
7478 (uri (rubygems-uri "docile" version))
7479 (sha256
7480 (base32
7481 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
7482 (build-system ruby-build-system)
7483 (arguments
7484 '(#:tests? #f)) ; needs github-markup, among others
7485 (synopsis "Ruby EDSL helper library")
7486 (description "Docile is a Ruby library that provides an interface for
7487creating embedded domain specific languages (EDSLs) that manipulate existing
7488Ruby classes.")
7489 (home-page "https://ms-ati.github.io/docile/")
7490 (license license:expat)))
7491
fab8fed3
MC
7492(define-public ruby-middleware
7493 (package
7494 (name "ruby-middleware")
7495 (version "0.1.0")
7496 (source
7497 (origin
7498 (method url-fetch)
7499 (uri (rubygems-uri "middleware" version))
7500 (sha256
7501 (base32
7502 "0703nkf2v371wqr41c04x5qid7ww45cxqv3hnlg07if3b3xrm9xl"))))
7503 (build-system ruby-build-system)
7504 (arguments '(#:tests? #f)) ;no test suite
7505 (synopsis "Implementation of a middleware abstraction for Ruby")
7506 (description "Middleware is a generalized implementation of a middleware
7507abstraction for Ruby.")
7508 (home-page "https://github.com/mitchellh/middleware")
7509 (license license:expat)))
7510
1d537c71
MC
7511(define-public ruby-benchmark-ips
7512 (package
7513 (name "ruby-benchmark-ips")
7514 (version "2.8.2")
7515 (source
7516 (origin
7517 (method url-fetch)
7518 (uri (rubygems-uri "benchmark-ips" version))
7519 (sha256
7520 (base32
7521 "1n9397j7kh4vvikfann1467qgksc679imlr50hax3lk1q3af8kdw"))))
7522 (build-system ruby-build-system)
7523 (native-inputs
7524 `(("ruby-hoe" ,ruby-hoe)))
7525 (synopsis "Iterations per second enhancement for the Ruby Benchmark module")
7526 (description "Benchmark-ips enhances the Ruby Benchmark module with the
7527iterations per second count. For short snippets of code, it can automatically
7528figure out how many times to run the code to get interesting data.")
7529 (home-page "https://github.com/evanphx/benchmark-ips")
7530 (license license:expat)))
7531
fc5d1c5a
MC
7532(define-public ruby-ffi-rzmq-core
7533 (package
7534 (name "ruby-ffi-rzmq-core")
7535 (version "1.0.7")
7536 (source
7537 (origin
7538 (method url-fetch)
7539 (uri (rubygems-uri "ffi-rzmq-core" version))
7540 (sha256
7541 (base32
7542 "0amkbvljpjfnv0jpdmz71p1i3mqbhyrnhamjn566w0c01xd64hb5"))))
7543 (build-system ruby-build-system)
7544 (arguments
7545 `(#:phases
7546 (modify-phases %standard-phases
7547 (add-after 'unpack 'patch-libzmq-search-path
7548 (lambda* (#:key inputs #:allow-other-keys)
7549 (let ((zeromq (assoc-ref inputs "zeromq")))
7550 (substitute* "lib/ffi-rzmq-core/libzmq.rb"
7551 (("/usr/local/lib")
7552 (string-append zeromq "/lib")))
7553 #t)))
7554 (replace 'check
7555 (lambda _
7556 (invoke "rspec"))))))
7557 (native-inputs
7558 `(("ruby-rspec" ,ruby-rspec)))
7559 (inputs
7560 `(("zeromq" ,zeromq)))
7561 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
7562 (synopsis "Low-level Ruby FFI wrapper for the ZeroMQ networking library")
7563 (description "This library only provides the FFI wrapper for the ZeroMQ
7564networking library. It can be used to implement a Ruby API for the ZeroMQ
7565library.")
7566 (home-page "https://github.com/chuckremes/ffi-rzmq-core")
7567 (license license:expat)))
7568
7a503516
MC
7569(define-public ruby-ffi-rzmq
7570 (package
7571 (name "ruby-ffi-rzmq")
7572 (version "2.0.7")
7573 (source
7574 (origin
7575 (method url-fetch)
7576 (uri (rubygems-uri "ffi-rzmq" version))
7577 (sha256
7578 (base32
7579 "14a5kxfnf8l3ngyk8hgmk30z07aj1324ll8i48z67ps6pz2kpsrg"))))
7580 (build-system ruby-build-system)
7581 (arguments '(#:tests? #t
7582 #:phases (modify-phases %standard-phases
7583 (replace 'check
7584 (lambda _
7585 (invoke "rspec"))))))
7586 (native-inputs
7587 `(("ruby-rspec" ,ruby-rspec)))
7588 (propagated-inputs
7589 `(("ruby-ffi-rzmq-core" ,ruby-ffi-rzmq-core)))
7590 (synopsis "High-level Ruby wrapper for the ZeroMQ networking library")
7591 (description "This library provides a high-level API that wraps the ZeroMQ
7592networking library using the Ruby foreign function interface (FFI). It is a
7593pure Ruby wrapper, hence is compatible with any Ruby runtime that has support
7594for FFI.")
7595 (home-page "https://github.com/chuckremes/ffi-rzmq")
7596 (license license:expat)))
7597
03a0f98a
MC
7598(define-public ruby-sawyer
7599 (package
7600 (name "ruby-sawyer")
7601 (version "0.8.2")
7602 (source
7603 (origin
7604 (method url-fetch)
7605 (uri (rubygems-uri "sawyer" version))
7606 (sha256
7607 (base32
7608 "0yrdchs3psh583rjapkv33mljdivggqn99wkydkjdckcjn43j3cz"))))
7609 (build-system ruby-build-system)
7610 (propagated-inputs
7611 `(("ruby-addressable" ,ruby-addressable)
7612 ("ruby-faraday" ,ruby-faraday)))
7613 (synopsis "Experimental hypermedia agent for Ruby")
7614 (description "Sawyer is an experimental hypermedia agent for Ruby built on
7615top of Faraday.")
7616 (home-page "https://github.com/lostisland/sawyer")
7617 (license license:expat)))
7618
aa3c76b1
MC
7619(define-public ruby-octokit
7620 (package
7621 (name "ruby-octokit")
7622 (version "4.18.0")
7623 (source
7624 (origin
7625 (method url-fetch)
7626 (uri (rubygems-uri "octokit" version))
7627 (sha256
7628 (base32
7629 "0zvfr9njmj5svi39fcsi2b0g7pcxb0vamw9dlyas8bg814jlzhi6"))))
7630 (build-system ruby-build-system)
7631 (arguments '(#:tests? #f)) ;no test suite in the gem release
7632 (propagated-inputs
7633 `(("ruby-faraday" ,ruby-faraday)
7634 ("ruby-sawyer" ,ruby-sawyer)))
7635 (synopsis "Ruby toolkit for the GitHub API")
7636 (description "Octokit wraps the GitHub API in a flat API client that
7637follows Ruby conventions and requires little knowledge of REST.")
7638 (home-page "https://github.com/octokit/octokit.rb")
7639 (license license:expat)))
7640
1157d2f8
MC
7641(define-public ruby-chandler
7642 (package
7643 (name "ruby-chandler")
7644 (version "0.9.0")
7645 (source
7646 (origin
7647 (method url-fetch)
7648 (uri (rubygems-uri "chandler" version))
7649 (sha256
7650 (base32
7651 "1n8a4mr2jkcz5vaaps45g2rxa2pzy1wb7cylgw85xmmyyp14lnrr"))))
7652 (build-system ruby-build-system)
7653 (native-inputs
7654 `(("ruby-rubocop" ,ruby-rubocop)))
7655 (propagated-inputs
7656 `(("ruby-netrc" ,ruby-netrc)
7657 ("ruby-octokit" ,ruby-octokit)))
7658 (synopsis "Sync CHANGELOG entries to GitHub's release notes")
7659 (description "Chandler syncs a project's CHANGELOG file entries to
7660GitHub's release notes to remove the need of manually entering release
7661notes.")
7662 (home-page "https://github.com/mattbrictson/chandler")
7663 (license license:expat)))
7664
acb28876
MC
7665(define-public ruby-pry-byebug
7666 (package
7667 (name "ruby-pry-byebug")
7668 (version "3.9.0")
7669 (source
7670 (origin
7671 (method git-fetch)
7672 (uri (git-reference
b0e7b699 7673 (url "https://github.com/deivid-rodriguez/pry-byebug")
acb28876
MC
7674 (commit (string-append "v" version))))
7675 (file-name (git-file-name name version))
7676 (sha256
7677 (base32
7678 "1kchrwccai92068p50zyd6mh524ywqnm0jw5g3lks7iwmf0xkmgc"))))
7679 (build-system ruby-build-system)
7680 (arguments
7681 `(#:phases (modify-phases %standard-phases
7682 (add-before 'check 'set-home
7683 (lambda _
7684 (setenv "HOME" (getcwd))
7685 #t)))))
7686 (native-inputs
7687 `(("ruby-chandler" ,ruby-chandler)
7688 ("ruby-rubocop" ,ruby-rubocop)
7689 ("ruby-simplecov" ,ruby-simplecov)))
7690 (propagated-inputs
7691 `(("ruby-byebug" ,ruby-byebug-11)
7692 ("ruby-pry" ,ruby-pry)))
7693 (synopsis "Step-by-step debugging and stack navigation in Pry")
7694 (description "This package adds step-by-step debugging and stack
7695navigation capabilities to @code{pry}, using @code{byebug}.")
7696 (home-page "https://github.com/deivid-rodriguez/pry-byebug")
7697 (license license:expat)))
7698
4f8c551c
EF
7699(define-public ruby-stackprof
7700 (package
7701 (name "ruby-stackprof")
7702 (version "0.2.16")
7703 (source
7704 (origin
7705 (method url-fetch)
7706 (uri (rubygems-uri "stackprof" version))
7707 (sha256
7708 (base32
7709 "147rb66p3n062vc433afqhkd99iazvkrqnghxgh871r62yhha93f"))))
7710 (build-system ruby-build-system)
7711 (native-inputs
7712 `(("ruby-mocha" ,ruby-mocha)
7713 ("ruby-rake-compiler" ,ruby-rake-compiler)))
7714 (synopsis "Sampling profiler for Ruby code")
7715 (description
7716 "@code{stackprof} is a fast sampling profiler for Ruby code, with cpu,
7717wallclock and object allocation samplers.")
7718 (home-page "http://github.com/tmm1/stackprof")
7719 (license license:expat)))
7720
4d31fe6b
MC
7721(define-public ruby-binding-of-caller
7722 (package
7723 (name "ruby-binding-of-caller")
7724 (version "0.8.0")
7725 (source
7726 (origin
7727 (method url-fetch)
7728 (uri (rubygems-uri "binding_of_caller" version))
7729 (sha256
7730 (base32
7731 "05syqlks7463zsy1jdfbbdravdhj9hpj5pv2m74blqpv8bq4vv5g"))))
7732 (build-system ruby-build-system)
7733 ;; Attempting to run the test suite fails with a rake deprecation error
7734 ;; (see: https://github.com/banister/binding_of_caller/issues/76).
7735 (arguments '(#:tests? #f))
7736 (propagated-inputs
7737 `(("ruby-debug-inspector" ,ruby-debug-inspector)))
7738 (synopsis "Retrieve the binding of a method's caller")
7739 (description "The @code{binding_of_caller} module provides the
7740@code{Binding#of_caller} method. It allows accessing bindings from upper
7741frames in the call stack and can evaluate code in that context.")
7742 (home-page "https://github.com/banister/binding_of_caller")
7743 (license license:expat)))
7744
f4699abc
MC
7745(define-public ruby-pry-stack-explorer
7746 (package
7747 (name "ruby-pry-stack-explorer")
7748 (version "0.5.1")
7749 (source
7750 (origin
7751 (method url-fetch)
7752 (uri (rubygems-uri "pry-stack_explorer" version))
7753 (sha256
7754 (base32
7755 "157rd2n9pfvcmmicm0xkq8z4p6famaj13syrpra6b4032qpb1wn0"))))
7756 (build-system ruby-build-system)
7757 (arguments '(#:tests? #f)) ;no test suite in gem release
7758 (propagated-inputs
7759 `(("ruby-binding-of-caller" ,ruby-binding-of-caller)
7760 ("ruby-pry" ,ruby-pry)))
7761 (synopsis "Call-stack navigation plugin for the Pry REPL")
7762 (description "@code{pry-stack_explorer} is a plugin for the Pry REPL that
7763add support to navigate the call-stack.")
7764 (home-page "https://github.com/pry/pry-stack_explorer")
7765 (license license:expat)))
7766
1f014c97
MC
7767(define-public ruby-varint
7768 (package
7769 (name "ruby-varint")
7770 (version "0.1.1")
7771 (source
7772 (origin
7773 (method url-fetch)
7774 (uri (rubygems-uri "varint" version))
7775 (sha256
7776 (base32
7777 "1y0l2qc64cwsyv76ygg9bbjnk86riz2kq73kmn87gdrlmpiyrdac"))))
7778 (build-system ruby-build-system)
7779 (arguments '(#:tests? #f)) ;no test suite
7780 (synopsis "Variable length integers (varint) C extension for Ruby")
7781 (description "This package provides a small C extension to speed up
7782variable length integers (varint) in Ruby Protocol Buffers.")
7783 (home-page "https://github.com/liquidm/varint")
7784 (license license:bsd-3)))
7785
1b214174
MC
7786(define-public ruby-ruby-prof
7787 (package
7788 (name "ruby-ruby-prof")
7789 (version "1.4.1")
7790 (source
7791 (origin
7792 (method url-fetch)
7793 (uri (rubygems-uri "ruby-prof" version))
7794 (sha256
7795 (base32
7796 "12cd91m08ih0imfpy4k87618hd4mhyz291a6bx2hcskza4nf6d27"))))
7797 (build-system ruby-build-system)
7798 (arguments
7799 `(#:phases
7800 (modify-phases %standard-phases
7801 (add-after 'unpack 'patch-rakefile
7802 ;; This fixes the following error: "NameError: uninitialized
7803 ;; constant Bundler::GemHelper" (see:
7804 ;; https://github.com/ruby-prof/ruby-prof/issues/274).
7805 (lambda _
7806 (substitute* "Rakefile"
7807 ((".*require \"bundler/setup\".*" all)
7808 (string-append all " require 'bundler/gem_tasks'\n")))
7809 #t))
661ad8d7
MC
7810 ;; The LineNumbersTest test fails non-deterministically (see:
7811 ;; https://github.com/ruby-prof/ruby-prof/issues/276).
7812 (add-after 'extract-gemspec 'delete-flaky-test
7813 (lambda _
7814 (delete-file "test/line_number_test.rb")
7815 (substitute* "ruby-prof.gemspec"
7816 (("\"test/line_number_test\\.rb\"\\.freeze, ") ""))
7817 #t))
1b214174
MC
7818 (add-before 'check 'compile
7819 (lambda _
7820 (invoke "rake" "compile"))))))
7821 (native-inputs
7822 `(("bundler" ,bundler)
7823 ("ruby-minitest" ,ruby-minitest)
7824 ("ruby-rake-compiler" ,ruby-rake-compiler)
7825 ("ruby-rdoc" ,ruby-rdoc)))
7826 (synopsis "Fast code profiler for Ruby")
7827 (description "RubyProf is a fast code profiler for Ruby. Its features
7828include:
7829@table @asis
7830@item Speed
7831Being a C extension, it is many times faster than the standard Ruby profiler.
7832@item Measurement Modes
7833It can measure program wall time, process time, object allocations and memory
7834usage.
7835@item Reports
7836A variety of text and cross-referenced HTML reports can be generated.
7837@item Threads
7838Profiling multiple threads simultaneously is supported.
7839@end table")
7840 (home-page "https://github.com/ruby-prof/ruby-prof")
7841 (license license:bsd-2)))
7842
f499e124
EF
7843(define-public ruby-memory-profiler
7844 (package
7845 (name "ruby-memory-profiler")
7846 (version "1.0.0")
7847 (source
7848 (origin
7849 (method git-fetch)
7850 (uri (git-reference
7851 (url "https://github.com/SamSaffron/memory_profiler")
7852 (commit (string-append "v" version))))
7853 (file-name (git-file-name name version))
7854 (sha256
7855 (base32
7856 "07yqv11q68xg2fqkrhs6ysngryk8b9zq6qzh24rgx9xqv6qfnj0w"))))
7857 (build-system ruby-build-system)
7858 (native-inputs
7859 `(("ruby-rake" ,ruby-rake)))
7860 (synopsis "Memory profiling routines for Ruby")
7861 (description
7862 "This package provides memory profiling routines for Ruby.")
7863 (home-page "https://github.com/SamSaffron/memory_profiler")
7864 (license license:expat)))
7865
dff5392f
MC
7866(define-public ruby-cucumber-messages
7867 (package
7868 (name "ruby-cucumber-messages")
7869 (version "12.2.0")
7870 (source (origin
7871 (method git-fetch)
7872 (uri (git-reference
b0e7b699 7873 (url "https://github.com/cucumber/messages-ruby")
dff5392f
MC
7874 (commit "12cd07eac87bce7843fd1bb0bf64bc4da09f097c")))
7875 (file-name (git-file-name name version))
7876 (sha256
7877 (base32
7878 "16wwqfpsq7crvxc3q08lphgyh12cl2d83p1c79p312q4jmy9cn5a"))))
7879 (build-system ruby-build-system)
7880 (arguments
7881 `(#:phases (modify-phases %standard-phases
7882 (add-after 'unpack 'patch-protobuf.rb
7883 (lambda _
7884 (substitute* "rake/protobuf.rb"
7885 (("load 'protobuf/tasks/compile.rake'")
7886 "require 'protobuf/tasks'"))
7887 #t))
7888 (add-before 'build 'compile
7889 (lambda _
7890 (substitute* "Makefile"
7891 (("bundle exec ") "")
7892 (("include default.mk.*" all)
7893 (string-append "#" all)))
7894 (invoke "make")))
7895 (replace 'check
7896 (lambda _
7897 (invoke "rspec"))))))
7898 (propagated-inputs
7899 `(("ruby-protobuf" ,ruby-protobuf-cucumber)))
7900 (native-inputs
7901 `(("ruby-rspec" ,ruby-rspec)))
7902 (home-page "https://github.com/cucumber/messages-ruby")
7903 (synopsis "Cucumber Messages for Ruby (Protocol Buffers)")
7904 (description "Cucumber Messages for Ruby is a library which allows
7905serialization and deserialization of the protocol buffer messages used in
7906Cucumber.")
7907 (license license:expat)))
7908
44514637 7909(define-public ruby-gherkin
62e4cc5a 7910 (package
44514637 7911 (name "ruby-gherkin")
cfef316f
MC
7912 (version "14.0.1")
7913 (source (origin
7914 (method git-fetch)
7915 (uri (git-reference
7916 (url "https://github.com/cucumber/gherkin-ruby")
7917 (commit (string-append "v" version))))
7918 (file-name (git-file-name name version))
7919 (sha256
7920 (base32
7921 "1dwa8632nc6kijv8p257jl64rsjmc0fimlaqvxlkdi2h9n1nympb"))))
62e4cc5a
PP
7922 (build-system ruby-build-system)
7923 (native-inputs
cfef316f
MC
7924 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
7925 ("ruby-rspec" ,ruby-rspec)))
62e4cc5a 7926 (arguments
cfef316f 7927 `(#:test-target "spec"))
62e4cc5a 7928 (synopsis "Gherkin parser for Ruby")
44514637 7929 (description "Gherkin is a parser and compiler for the Gherkin language.
aada5f6f
CB
7930It is intended be used by all Cucumber implementations to parse
7931@file{.feature} files.")
cfef316f 7932 (home-page "https://github.com/cucumber/gherkin-ruby")
62e4cc5a 7933 (license license:expat)))
cd89fecb 7934
8f85018d
MB
7935(define-public ruby-gherkin-ruby
7936 (package
7937 (name "ruby-gherkin-ruby")
7938 (version "0.3.2")
702a1012 7939 (home-page "https://github.com/codegram/gherkin-ruby")
8f85018d
MB
7940 (source (origin
7941 (method url-fetch)
7942 (uri (rubygems-uri "gherkin-ruby" version))
7943 (sha256
7944 (base32
7945 "18ay7yiibf4sl9n94k7mbi4k5zj2igl4j71qcmkswv69znyx0sn1"))))
7946 (build-system ruby-build-system)
7947 (synopsis "Pure Ruby Gherkin parser")
7948 (description
7949 "Gherkin-ruby is a Gherkin parser written in pure Ruby and less than
7950200 lines of code.")
7951 ;; XXX: No license information anywhere but Readme.md.
7952 (license license:expat)))
7953
15b16c2c
CB
7954(define-public ruby-aruba
7955 (package
7956 (name "ruby-aruba")
cf7201c4 7957 (version "0.14.14")
15b16c2c
CB
7958 (source
7959 (origin
7960 (method url-fetch)
7961 (uri (rubygems-uri "aruba" version))
7962 (sha256
7963 (base32
cf7201c4 7964 "0l2mfpdxc03gdrbwc2hv4vdhjhqhfcdp6d02j05j64ncpi9srlqn"))))
15b16c2c
CB
7965 (build-system ruby-build-system)
7966 (arguments
7967 '(#:test-target "spec"
7968 #:phases
7969 (modify-phases %standard-phases
7970 (add-after 'unpack 'patch
7971 (lambda _
7972 (substitute* "spec/aruba/api_spec.rb"
7973 ;; This resolves some errors in the specs
7974 ;;
7975 ;; undefined method `parse' for Time:Class
7976 (("require 'spec_helper'")
7977 "require 'spec_helper'\nrequire 'time'"))
7978 ;; Avoid shebang issues in this spec file
7979 (substitute* "spec/aruba/matchers/command_spec.rb"
7980 (("/usr/bin/env bash")
7981 (which "bash")))
7982 #t))
7983 (add-before 'check 'remove-unnecessary-dependencies
7984 (lambda _
7985 (substitute* "Gemfile"
7986 ((".*byebug.*") "\n")
7987 ((".*pry.*") "\n")
7988 ((".*yaml.*") "\n")
7989 ((".*bcat.*") "\n")
7990 ((".*kramdown.*") "\n")
7991 ((".*rubocop.*") "\n")
7992 ((".*cucumber-pro.*") "\n")
7993 ((".*cucumber.*") "\n")
7994 ((".*license_finder.*") "\n")
7995 ((".*rake.*") "gem 'rake'\n")
15b16c2c 7996 ((".*relish.*") "\n"))
15b16c2c
CB
7997 (substitute* "aruba.gemspec"
7998 (("spec\\.add\\_runtime\\_dependency 'cucumber'.*")
7999 "spec.add_runtime_dependency 'cucumber'"))
8000 #t))
8001 (add-before 'check 'set-home
8002 (lambda _ (setenv "HOME" "/tmp") #t)))))
8003 (native-inputs
8004 `(("bundler" ,bundler)
8005 ("ruby-rspec" ,ruby-rspec)
cf7201c4
CB
8006 ("ruby-fuubar" ,ruby-fuubar)
8007 ("ruby-simplecov" ,ruby-simplecov)))
15b16c2c
CB
8008 (propagated-inputs
8009 `(("ruby-childprocess" ,ruby-childprocess)
8010 ("ruby-contracts" ,ruby-contracts)
8011 ("ruby-cucumber" ,ruby-cucumber)
8012 ("ruby-ffi" ,ruby-ffi)
8013 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
8014 ("ruby-thor" ,ruby-thor)
8015 ("ruby-yard" ,ruby-yard)))
8016 (synopsis "Test command-line applications with Cucumber, RSpec or Minitest")
8017 (description
8018 "Aruba is an extension for Cucumber, RSpec and Minitest for testing
8019command-line applications. It supports applications written in any
8020language.")
8021 (home-page "https://github.com/cucumber/aruba")
8022 (license license:expat)))
8023
8024;; A version of ruby-aruba without tests run so that circular dependencies can
8025;; be avoided.
8026(define ruby-aruba-without-tests
8027 (package
8028 (inherit ruby-aruba)
8029 (arguments '(#:tests? #f))
8030 (propagated-inputs
8031 `(("ruby-cucumber" ,ruby-cucumber-without-tests)
8032 ,@(alist-delete "ruby-cucumber"
8033 (package-propagated-inputs ruby-aruba))))
8034 (native-inputs '())))
8035
fd6577b4
MC
8036(define-public ruby-sys-uname
8037 (package
8038 (name "ruby-sys-uname")
8039 (version "1.2.1")
8040 (source
8041 (origin
8042 (method url-fetch)
8043 (uri (rubygems-uri "sys-uname" version))
8044 (sha256
8045 (base32
8046 "00p3wwvkdbg6pl38bchaagncv3i4fq4y0ks470imwykjanpy2ic0"))))
8047 (build-system ruby-build-system)
8048 (arguments
8049 `(#:test-target "spec"))
8050 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
8051 (native-inputs `(("ruby-rspec" ,ruby-rspec)))
8052 (synopsis "Ruby interface for gathering system information")
8053 (description "The sys-uname library provides an interface for gathering
8054information about your current platform. It allows retrieving information
8055such as the OS name, OS version, system name, etc.")
8056 (home-page "https://github.com/djberg96/sys-uname")
8057 (license license:asl2.0)))
8058
ac3ec612
MC
8059(define-public ruby-cucumber-create-meta
8060 (package
8061 (name "ruby-cucumber-create-meta")
8062 (version "1.0.0")
8063 (source
8064 (origin
8065 (method url-fetch)
8066 (uri (rubygems-uri "cucumber-create-meta" version))
8067 (sha256
8068 (base32
8069 "0i0i3arymjrnjk72mg79w1a11607x4d0lrqafm9sz2gq9l52zasw"))))
8070 (build-system ruby-build-system)
8071 (arguments
8072 `(#:phases (modify-phases %standard-phases
8073 (add-after 'extract-gemspec 'relax-version-requirements
8074 (lambda _
8075 (substitute* ".gemspec"
8076 ((" 12\\.2")
8077 " 12.1"))
8078 #t))
8079 (replace 'check
8080 (lambda _
8081 (invoke "rspec"))))))
8082 (native-inputs
8083 `(("ruby-rspec" ,ruby-rspec)))
8084 (propagated-inputs
8085 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
8086 ("ruby-sys-uname" ,ruby-sys-uname)))
8087 (synopsis "Function to create @code{Meta} messages for Cucumber Ruby")
8088 (description "The @code{createMeta} utility function allows generating
8089system-specific @code{Meta} messages for Cucumber Ruby.")
8090 (home-page "https://github.com/cucumber/cucumber/tree/master/create-meta/ruby")
8091 (license license:expat)))
8092
f3574624
MC
8093(define-public ruby-cucumber-html-formatter
8094 (package
8095 (name "ruby-cucumber-html-formatter")
8096 (version "7.0.0")
8097 (source
8098 (origin
8099 (method url-fetch)
8100 (uri (rubygems-uri "cucumber-html-formatter" version))
8101 (sha256
8102 (base32
8103 "0lshj4sw9jw7687wrhknyb9kffblai3l843zgrznyqij3ga0bc62"))))
8104 (build-system ruby-build-system)
8105 (arguments
8106 `(#:phases (modify-phases %standard-phases
8107 (replace 'check
8108 (lambda _
8109 (invoke "rspec"))))))
8110 (native-inputs
8111 `(("ruby-rspec" ,ruby-rspec)))
8112 (propagated-inputs
8113 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)))
8114 (synopsis "HTML formatter for Cucumber")
8115 (description "Cucumber HTML Formatter produces a HTML report for Cucumber
8116runs. It is built on top of cucumber-react and works with any Cucumber
8117implementation with a protocol buffer formatter that outputs Cucumber
8118messages.")
8119 (home-page "https://github.com/cucumber/cucumber/tree/\
8120master/html-formatter/ruby")
8121 (license license:expat)))
8122
15b16c2c
CB
8123(define-public ruby-cucumber
8124 (package
8125 (name "ruby-cucumber")
92ebbaad 8126 (version "4.1.0")
15b16c2c
CB
8127 (source
8128 (origin
8129 (method git-fetch)
8130 (uri (git-reference
b0e7b699 8131 (url "https://github.com/cucumber/cucumber-ruby")
15b16c2c
CB
8132 (commit (string-append "v" version))))
8133 (file-name (git-file-name name version))
8134 (sha256
8135 (base32
92ebbaad 8136 "0g9rqfslbzkkrq2kvl14fgknrhfbji3bjjpjxff5nc9wzd3hd549"))))
15b16c2c
CB
8137 (build-system ruby-build-system)
8138 (arguments
fa8e4dbf 8139 '(#:test-target "default"
15b16c2c
CB
8140 #:phases
8141 (modify-phases %standard-phases
fa8e4dbf
MC
8142 (add-after 'unpack 'disable-rubocop
8143 ;; Rubocop lint check fails with our more recent version.
8144 (lambda _
8145 (substitute* "Rakefile"
8146 (("spec cucumber rubocop")
8147 "spec cucumber"))
8148 #t))
92ebbaad 8149 (add-after 'extract-gemspec 'strip-version-requirements
15b16c2c 8150 (lambda _
fa8e4dbf 8151 (delete-file "Gemfile") ;do not use Bundler
92ebbaad
MC
8152 (substitute* "cucumber.gemspec"
8153 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
8154 (string-append stripped "\n")))
fa8e4dbf
MC
8155 #t))
8156 (add-before 'check 'set-home
8157 (lambda _
8158 (setenv "HOME" (getcwd))
15b16c2c
CB
8159 #t)))))
8160 (propagated-inputs
8161 `(("ruby-builder" ,ruby-builder)
8162 ("ruby-cucumber-core" ,ruby-cucumber-core)
92ebbaad
MC
8163 ("ruby-cucumber-create-meta" ,ruby-cucumber-create-meta)
8164 ("ruby-cucumber-html-formatter" ,ruby-cucumber-html-formatter)
8165 ("ruby-cucumber-messages" ,ruby-cucumber-messages)
15b16c2c 8166 ("ruby-cucumber-wire" ,ruby-cucumber-wire)
15b16c2c
CB
8167 ("ruby-diff-lcs" ,ruby-diff-lcs)
8168 ("ruby-gherkin" ,ruby-gherkin)
8169 ("ruby-multi-json" ,ruby-multi-json)
8170 ("ruby-multi-test" ,ruby-multi-test)))
8171 (native-inputs
92ebbaad 8172 `(;; Use a untested version of aruba, to avoid a circular dependency, as
15b16c2c 8173 ;; ruby-aruba depends on ruby-cucumber.
1628d57b 8174 ("ruby-aruba" ,ruby-aruba-without-tests)
15b16c2c
CB
8175 ("ruby-rspec" ,ruby-rspec)
8176 ("ruby-pry" ,ruby-pry)
92ebbaad
MC
8177 ("ruby-nokogiri" ,ruby-nokogiri)
8178 ("ruby-rubocop" ,ruby-rubocop)))
15b16c2c 8179 (synopsis "Describe automated tests in plain language")
92ebbaad
MC
8180 (description "Cucumber is a tool for running automated tests written in
8181plain language. It's designed to support a Behaviour Driven Development (BDD)
15b16c2c
CB
8182software development workflow.")
8183 (home-page "https://cucumber.io/")
8184 (license license:expat)))
8185
8186(define ruby-cucumber-without-tests
8187 (package (inherit ruby-cucumber)
8188 (arguments
8189 '(#:tests? #f))
8190 (native-inputs
8191 '())))
8192
f048ef52
MC
8193(define-public ruby-coveralls
8194 (package
8195 (name "ruby-coveralls")
8196 (version "0.8.23")
8197 (source
8198 (origin
8199 (method url-fetch)
8200 (uri (rubygems-uri "coveralls" version))
8201 (sha256
8202 (base32
8203 "1mv4fn5lfxhy7bc2f1lpnc5yp9mvv97az77j4r7jgrxcqwn8fqxc"))))
8204 (build-system ruby-build-system)
8205 ;; The test suite depends on ruby-vcr, which cannot be included in Guix
fe9993b1
MC
8206 ;; because of its nonfree, Hippocratic-derived license.
8207 (arguments
8208 `(#:tests? #f
8209 #:phases (modify-phases %standard-phases
8210 (add-after 'extract-gemspec 'strip-version-requirements
8211 ;; Keeping strict version requirements can cause problems
8212 ;; to users of the library, such as: Gem::ConflictError:
8213 ;; Unable to activate coveralls-0.8.23, because
8214 ;; simplecov-0.17.1 conflicts with simplecov (~> 0.16.1).
8215 (lambda _
8216 (substitute* "coveralls-ruby.gemspec"
8217 (("(.*add_.*dependency\\([^,]+), .*" _ stripped)
8218 (string-append stripped ")\n")))
8219 #t)))))
f048ef52
MC
8220 (propagated-inputs
8221 `(("ruby-json" ,ruby-json)
8222 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
8223 ("ruby-thor" ,ruby-thor)
8224 ("ruby-tins" ,ruby-tins)))
8225 (synopsis "Ruby implementation of the Coveralls API")
8226 (description "This package provides a Ruby implementation of the Coveralls
8227API.")
8228 (home-page "https://coveralls.io")
8229 (license license:expat)))
f2a1b7fa
MC
8230
8231(define-public ruby-unindent
8232 (package
8233 (name "ruby-unindent")
8234 (version "1.0")
8235 (source
8236 (origin
8237 (method url-fetch)
8238 (uri (rubygems-uri "unindent" version))
8239 (sha256
8240 (base32
8241 "1wqh3rzv8589yzibigminxx3qpmj2nqj28f90xy1sczk1pijmcrd"))))
8242 (build-system ruby-build-system)
8243 (synopsis "Ruby method to unindent strings")
8244 (description "This module provides a @code{String#unindent} Ruby method to
8245unindent strings, which can be useful to unindent multiline strings embedded
8246in already-indented code.")
8247 (home-page "https://github.com/mynyml/unindent")
8248 (license license:expat)))
f048ef52 8249
cd89fecb
PP
8250(define-public ruby-cucumber-core
8251 (package
8252 (name "ruby-cucumber-core")
95a5d992 8253 (version "7.1.0")
cd89fecb
PP
8254 (source
8255 (origin
95a5d992
MC
8256 (method git-fetch)
8257 (uri (git-reference
b0e7b699 8258 (url "https://github.com/cucumber/cucumber-ruby-core")
95a5d992
MC
8259 (commit (string-append "v" version))))
8260 (file-name (git-file-name name version))
cd89fecb
PP
8261 (sha256
8262 (base32
95a5d992 8263 "1p5wb6wbggbw37ariyag4kxpiczznvgm3c8cnz1744dmbj79q1rn"))))
cd89fecb 8264 (build-system ruby-build-system)
95a5d992
MC
8265 (arguments
8266 `(#:test-target "spec"
8267 #:phases
8268 (modify-phases %standard-phases
8269 (add-after 'extract-gemspec 'relax-version-requirements
8270 (lambda _
8271 (substitute* "cucumber-core.gemspec"
8272 (("'cucumber-tag-expressions',.*")
8273 "'cucumber-tag-expressions', '>=2.0.0'\n"))
8274 #t)))))
8275 (native-inputs
8276 `(("ruby-rspec" ,ruby-rspec)
8277 ("ruby-coveralls" ,ruby-coveralls)
8278 ("ruby-rubocop" ,ruby-rubocop)
8279 ("ruby-simplecov" ,ruby-simplecov)
8280 ("ruby-unindent" ,ruby-unindent)))
cd89fecb 8281 (propagated-inputs
95a5d992 8282 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
5cd047e8
CB
8283 ("ruby-gherkin" ,ruby-gherkin)
8284 ("ruby-cucumber-tag-expressions" ,ruby-cucumber-tag-expressions)))
cd89fecb
PP
8285 (synopsis "Core library for the Cucumber BDD app")
8286 (description "Cucumber is a tool for running automated tests
8287written in plain language. Because they're written in plain language,
8288they can be read by anyone on your team. Because they can be read by
8289anyone, you can use them to help improve communication, collaboration
8290and trust on your team.")
8291 (home-page "https://cucumber.io/")
8292 (license license:expat)))
212d563d 8293
fb1a8954
CB
8294(define-public ruby-cucumber-expressions
8295 (package
8296 (name "ruby-cucumber-expressions")
4ada4a42 8297 (version "10.2.0")
fb1a8954
CB
8298 (source
8299 (origin
4ada4a42
MC
8300 (method git-fetch)
8301 (uri (git-reference
b0e7b699 8302 (url "https://github.com/cucumber/cucumber-expressions-ruby")
4ada4a42
MC
8303 (commit (string-append "v" version))))
8304 (file-name (git-file-name name version))
fb1a8954
CB
8305 (sha256
8306 (base32
4ada4a42 8307 "1aivhcpjrmbvp9bg0y7g6zxh2swfvylvg0sapq5jc4i1y74k8npd"))))
fb1a8954
CB
8308 (build-system ruby-build-system)
8309 (arguments
8310 '(#:test-target "spec"))
8311 (native-inputs
4ada4a42 8312 `(("ruby-rspec" ,ruby-rspec)
fb1a8954
CB
8313 ("ruby-simplecov" ,ruby-simplecov)))
8314 (synopsis "Simpler alternative to Regular Expressions")
8315 (description "Cucumber Expressions offer similar functionality to Regular
8316Expressions, with a syntax that is easier to read and write. Cucumber
8317Expressions are extensible with parameter types.")
8318 (home-page "https://github.com/cucumber/cucumber-expressions-ruby")
8319 (license license:expat)))
8320
ce872770
CB
8321(define-public ruby-cucumber-wire
8322 (package
8323 (name "ruby-cucumber-wire")
6516827e 8324 (version "3.1.0")
ce872770
CB
8325 (source
8326 (origin
8327 (method url-fetch)
8328 (uri (rubygems-uri "cucumber-wire" version))
8329 (sha256
8330 (base32
6516827e 8331 "0z1n13lqv70zb2lcrvs2263lm0gsb3gz8gbv890kxzwp8cvd433k"))))
ce872770
CB
8332 (build-system ruby-build-system)
8333 (arguments
6516827e 8334 '(#:tests? #f ;tests use cucumber, causing a cycle
ce872770
CB
8335 #:phases
8336 (modify-phases %standard-phases
6516827e 8337 (add-after 'extract-gemspec 'relax-version-requirements
ce872770 8338 (lambda _
6516827e
MC
8339 (substitute* ".gemspec"
8340 ((" 10\\.1") " 10.2"))
ce872770 8341 #t)))))
6516827e
MC
8342 (propagated-inputs
8343 `(("ruby-cucumber-core" ,ruby-cucumber-core)
8344 ("ruby-cucumber-expressions" ,ruby-cucumber-expressions)
8345 ("ruby-cucumber-messages" ,ruby-cucumber-messages)))
ce872770 8346 (synopsis "Cucumber wire protocol plugin")
6516827e
MC
8347 (description "Cucumber's wire protocol allows step definitions to be
8348implemented and invoked on any platform.")
ce872770
CB
8349 (home-page "https://github.com/cucumber/cucumber-ruby-wire")
8350 (license license:expat)))
8351
0ce8f344
CB
8352(define-public ruby-cucumber-tag-expressions
8353 (package
8354 (name "ruby-cucumber-tag-expressions")
0d2c45ce 8355 (version "3.0.0")
0ce8f344
CB
8356 (source
8357 (origin
0d2c45ce
MC
8358 (method git-fetch)
8359 (uri (git-reference
b0e7b699 8360 (url "https://github.com/cucumber/tag-expressions-ruby")
0d2c45ce
MC
8361 (commit (string-append "v" version))))
8362 (file-name (git-file-name name version))
0ce8f344
CB
8363 (sha256
8364 (base32
0d2c45ce 8365 "15dw4w0npd4m6aw7zhqkjxxzngp42kswrkwfygxkxcxnhy5zl1vx"))))
0ce8f344
CB
8366 (build-system ruby-build-system)
8367 (arguments
0d2c45ce 8368 `(#:test-target "spec"))
0ce8f344
CB
8369 (native-inputs
8370 `(("ruby-rspec" ,ruby-rspec)))
8371 (synopsis "Cucumber tag expressions for Ruby")
0d2c45ce
MC
8372 (description "Cucumber tag expression parser for Ruby. A tag expression
8373is an infix boolean expression used by Cucumber.")
0ce8f344
CB
8374 (home-page "https://github.com/cucumber/tag-expressions-ruby")
8375 (license license:expat)))
8376
73a5aff7
CB
8377(define-public ruby-bindex
8378 (package
8379 (name "ruby-bindex")
8380 (version "0.5.0")
8381 (source
8382 (origin
8383 (method url-fetch)
8384 (uri (rubygems-uri "bindex" version))
8385 (sha256
8386 (base32
8387 "1wvhf4v8sk5x8li03pcc0v0wglmyv7ikvvg05bnms83dfy7s4k8i"))))
8388 (build-system ruby-build-system)
8389 (arguments
8390 '(#:test-target "default"))
8391 (native-inputs
8392 `(("bundler" ,bundler)
8393 ("ruby-rake-compiler" ,ruby-rake-compiler)))
8394 (synopsis "Provides access for bindings relating to Ruby exceptions")
8395 (description
8396 "@code{bindex} provides a way to access the bindings that relate to
8397exceptions in Ruby, providing more information about the context in which the
8398exception occurred.")
8399 (home-page "https://github.com/gsamokovarov/bindex")
8400 (license license:expat)))
8401
212d563d
PP
8402(define-public ruby-bio-logger
8403 (package
8404 (name "ruby-bio-logger")
8405 (version "1.0.1")
8406 (source
8407 (origin
8408 (method url-fetch)
8409 (uri (rubygems-uri "bio-logger" version))
8410 (sha256
8411 (base32
8412 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
8413 (build-system ruby-build-system)
8414 (arguments
8415 `(#:tests? #f)) ; rake errors, missing shoulda
8416 (propagated-inputs
8417 `(("ruby-log4r" ,ruby-log4r)))
8418 (synopsis "Log4r wrapper for Ruby")
8419 (description "Bio-logger is a wrapper around Log4r adding extra logging
8420features such as filtering and fine grained logging.")
8421 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
8422 (license license:expat)))
07f61cb2 8423
2db0f9c8
BW
8424(define-public ruby-yajl-ruby
8425 (package
8426 (name "ruby-yajl-ruby")
8427 (version "1.4.1")
8428 (source
8429 (origin
8430 (method url-fetch)
8431 (uri (rubygems-uri "yajl-ruby" version))
8432 (sha256
8433 (base32
8434 "16v0w5749qjp13xhjgr2gcsvjv6mf35br7iqwycix1n2h7kfcckf"))))
8435 (build-system ruby-build-system)
8436 (arguments
8437 '(#:test-target "spec"
8438 #:phases
8439 (modify-phases %standard-phases
8440 (add-before 'check 'patch-test-to-update-load-path
8441 (lambda _
8442 (substitute* "spec/parsing/large_number_spec.rb"
8443 (("require \"yajl\"")
8444 "$LOAD_PATH << 'lib'; require 'yajl'"))
8445 #t)))))
8446 (native-inputs
8447 `(("ruby-rake-compiler" ,ruby-rake-compiler)
8448 ("ruby-rspec" ,ruby-rspec)))
8449 (synopsis "Streaming JSON parsing and encoding library for Ruby")
8450 (description
8451 "Ruby C bindings to the Yajl JSON stream-based parser library. The API
8452is compatible with the JSON gem, so yajl-ruby can act as a drop in
8453replacement.
8454
8455A modified copy of yajl is used, and included in the package.")
8456 (home-page "https://github.com/brianmario/yajl-ruby")
8457 (license (list license:expat ; Ruby code, yajl_ext.c and yajl_ext.h
8458 license:bsd-3)))) ; Included, modified copy of yajl
8459
07f61cb2 8460(define-public ruby-yard
6499893e
BW
8461 (package
8462 (name "ruby-yard")
7eb8ff0b 8463 (version "0.9.25")
6499893e
BW
8464 (source
8465 (origin
f3fd70c0 8466 (method git-fetch)
6499893e 8467 ;; Tests do not pass if we build from the distributed gem.
f3fd70c0 8468 (uri (git-reference
65a61239
MC
8469 (url "https://github.com/lsegal/yard")
8470 (commit (string-append "v" version))))
f3fd70c0 8471 (file-name (git-file-name name version))
6499893e
BW
8472 (sha256
8473 (base32
7eb8ff0b 8474 "1x7y4s557hrnq439lih7nqg1y7ximardw75jx9i92x3yzpviqqwa"))))
6499893e
BW
8475 (build-system ruby-build-system)
8476 (arguments
65a61239
MC
8477 ;; Note: Tests are willfully disabled to alleviate dependency cycle
8478 ;; problems.
479c0324
MC
8479 `(#:tests? #f
8480 #:phases (modify-phases %standard-phases
8481 (add-after 'unpack 'do-not-set-date-in-gemspec
8482 ;; Fix a reproducibility issue (see:
8483 ;; https://github.com/lsegal/yard/issues/1343).
8484 (lambda _
8485 (substitute* "yard.gemspec"
8486 ((".*s\\.date.*") ""))
8487 #t)))))
6499893e 8488 (synopsis "Documentation generation tool for Ruby")
65a61239
MC
8489 (description "YARD is a documentation generation tool for the Ruby
8490programming language. It enables the user to generate consistent, usable
8491documentation that can be exported to a number of formats very easily, and
8492also supports extending for custom Ruby constructs such as custom class level
8493definitions.")
2f3800e5 8494 (home-page "https://yardoc.org")
6499893e 8495 (license license:expat)))
2cbcd23a 8496
df32ab11
MC
8497(define-public ruby-yard-with-tests
8498 (package
8499 (inherit ruby-yard)
8500 (name "ruby-yard-with-tests")
8501 (arguments
8502 (substitute-keyword-arguments (package-arguments ruby-yard)
8503 ((#:tests? _ #t) #t)
8504 ((#:test-target _ "default") "default")
8505 ((#:phases phases '%standard-phases)
8506 `(modify-phases ,phases
8507 (add-before 'check 'prepare-for-tests
8508 (lambda* (#:key tests? #:allow-other-keys)
8509 (when tests?
8510 (substitute* "Rakefile"
8511 ((".*[Ss]amus.*") ""))
8512 ;; Delete the Gemfile to avoid errors relating to it.
8513 (delete-file "Gemfile")
8514 ;; $HOME needs to be set to somewhere writeable for tests to
8515 ;; run.
8516 (setenv "HOME" "/tmp"))
8517 #t))))))
8518 (native-inputs
8519 `(("ruby-rspec" ,ruby-rspec)
8520 ("ruby-rack" ,ruby-rack)
8521 ("ruby-redcloth" ,ruby-redcloth)
8522 ("ruby-asciidoc" ,ruby-asciidoctor)))))
8523
908df675
MC
8524(define-public ruby-spectroscope
8525 (package
8526 (name "ruby-spectroscope")
8527 (version "0.1.0")
8528 (source
8529 (origin
8530 (method url-fetch)
8531 (uri (rubygems-uri "spectroscope" version))
8532 (sha256
8533 (base32
8534 "0iiid9sm110qhx0i1zkds710cvsnmhd308wbqa7slkzbq2akrb3y"))))
8535 (build-system ruby-build-system)
8536 (arguments
8537 `(#:phases
8538 (modify-phases %standard-phases
8539 (replace 'check
8540 (lambda _
8541 (with-output-to-file ".test"
8542 (lambda _
8543 (display
8544 "\
8545require 'ae/should'
8546require 'rspec'
8547
8548include RSpec
8549
8550Test.run :default do |run|
8551 run.files << 'spec/*_spec.rb'
8552end")))
8553 (invoke "ruby" "-Ilib" "-rrubytest" ".test"))))))
8554 (native-inputs
8555 `(("ruby-ae" ,ruby-ae)
8556 ("ruby-rspec" ,ruby-rspec)))
8557 (propagated-inputs
8558 `(("ruby-rubytest" ,ruby-rubytest)))
8559 (synopsis "Behavior-Driven Development (BDD) framework built on RubyTest")
8560 (description "Spectroscope is a Behavior-Driven Development (BDD)
8561framework built on RubyTest, designed to emulate RSpec in most respects. It
8562is assertion framework independent so any number of assertion systems can be
8563used, such as Assay or AE.")
8564 (home-page "http://rubyworks.github.com/spectroscope/")
8565 (license license:bsd-2)))
8566
24ffd91b
MC
8567(define-public ruby-tomparse
8568 (package
8569 (name "ruby-tomparse")
8570 (version "0.4.2")
8571 (source
8572 (origin
8573 (method url-fetch)
8574 (uri (rubygems-uri "tomparse" version))
8575 (sha256
8576 (base32
8577 "06xakk41f1kgj6j1ahkwn4r6cvidixvm4phhlrvmwb7c3pr8ygc8"))))
8578 (build-system ruby-build-system)
8579 ;; TODO: Tests require citron and rulebow, not yet packaged.
8580 (arguments '(#:tests? #f))
8581 (synopsis "TomDoc parser for Ruby")
8582 (description "TomParse is a TomDoc parser for Ruby. It takes a code
8583comment as input and parses it into a convenient object-oriented structure in
8584accordance with the TomDoc standard. See
8585@url{https://github.com/mojombo/tomdoc, TomDoc} for more information about the
8586TomDoc format.")
8587 (home-page "http://rubyworks.github.com/tomparse/")
8588 (license license:bsd-2)))
8589
257dee50
MC
8590(define-public ruby-yard-tomdoc
8591 (package
8592 (name "ruby-yard-tomdoc")
8593 (version "0.7.1")
8594 (source
8595 (origin
8596 (method url-fetch)
8597 (uri (rubygems-uri "yard-tomdoc" version))
8598 (sha256
8599 (base32
8600 "1725gs8b8klpwhrvnf2wwp7dw3zxs9vz2la983l2d8c4r4fn1j2z"))))
8601 (build-system ruby-build-system)
8602 (arguments
8603 `(#:phases (modify-phases %standard-phases
8604 (replace 'check
8605 (lambda _
8606 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
8607 (native-inputs
8608 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
8609 ("ruby-spectroscope" ,ruby-spectroscope)
8610 ("ruby-ae" ,ruby-ae)))
8611 (propagated-inputs
8612 `(("ruby-tomparse" ,ruby-tomparse)
8613 ("ruby-yard" ,ruby-yard)))
8614 (synopsis "TomDoc syntax for YARD")
8615 (description "This module adds support for the TomDoc documentation format
8616to YARD, a documentation generation tool for Ruby.")
8617 (home-page "http://rubyworks.github.com/yard-tomdoc/")
8618 (license license:expat)))
8619
ad686ef3
RW
8620(define-public ruby-clap
8621 (package
8622 (name "ruby-clap")
8623 (version "1.0.0")
8624 (source (origin
8625 (method url-fetch)
8626 (uri (rubygems-uri "clap" version))
8627 (sha256
8628 (base32
8629 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
8630 (build-system ruby-build-system)
8631 ;; Clap needs cutest for running tests, but cutest needs clap.
8632 (arguments `(#:tests? #f))
8633 (synopsis "Command line argument parsing for simple applications")
8634 (description
8635 "Clap provides command line argument parsing features. It covers the
8636simple case of executing code based on the flags or parameters passed.")
8637 (home-page "https://github.com/djanowski/cutest")
0c80451e
RW
8638 (license license:expat)))
8639
8640(define-public ruby-cutest
8641 (package
8642 (name "ruby-cutest")
8643 (version "1.2.2")
8644 (source (origin
8645 (method url-fetch)
8646 (uri (rubygems-uri "cutest" version))
8647 (sha256
8648 (base32
8649 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
8650 (build-system ruby-build-system)
8651 (propagated-inputs
8652 `(("ruby-clap" ,ruby-clap)))
8653 (synopsis "Run tests in separate processes")
8654 (description
8655 "Cutest runs tests in separate processes to avoid shared state.")
8656 (home-page "https://github.com/djanowski/cutest")
ad686ef3
RW
8657 (license license:expat)))
8658
ac09beba
RW
8659(define-public ruby-pygmentize
8660 (package
8661 (name "ruby-pygmentize")
8662 (version "0.0.3")
8663 (source (origin
8664 (method url-fetch)
8665 (uri (rubygems-uri "pygmentize" version))
8666 (sha256
8667 (base32
8668 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
8669 (build-system ruby-build-system)
8670 (arguments
8671 `(#:phases
8672 (modify-phases %standard-phases
8673 (add-after 'unpack 'fix-pygmentize-path
8674 (lambda _
8675 (substitute* "lib/pygmentize.rb"
8676 (("\"/usr/bin/env python.*")
8677 (string-append "\"" (which "pygmentize") "\"\n")))
8678 #t))
8679 (add-after 'build 'do-not-use-vendor-directory
8680 (lambda _
8681 ;; Remove bundled pygments sources
8682 ;; FIXME: ruby-build-system does not support snippets.
8683 (delete-file-recursively "vendor")
8684 (substitute* "pygmentize.gemspec"
8685 (("\"vendor/\\*\\*/\\*\",") ""))
8686 #t)))))
8687 (inputs
8688 `(("pygments" ,python-pygments)))
8689 (native-inputs
8690 `(("ruby-cutest" ,ruby-cutest)
8691 ("ruby-nokogiri" ,ruby-nokogiri)))
8692 (synopsis "Thin Ruby wrapper around pygmentize")
8693 (description
8694 "Pygmentize provides a simple way to call pygmentize from within a Ruby
8695application.")
8696 (home-page "https://github.com/djanowski/pygmentize")
8697 (license license:expat)))
8698
2cbcd23a
DT
8699(define-public ruby-eventmachine
8700 (package
8701 (name "ruby-eventmachine")
c207fa5e 8702 (version "1.2.7")
2cbcd23a
DT
8703 (source
8704 (origin
8705 (method url-fetch)
8706 (uri (rubygems-uri "eventmachine" version))
8707 (sha256
8708 (base32
c207fa5e 8709 "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"))))
2cbcd23a
DT
8710 (build-system ruby-build-system)
8711 (arguments
c5d269fb 8712 '(#:tests? #f)) ; test suite tries to connect to google.com
2cbcd23a
DT
8713 (native-inputs
8714 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
8715 (synopsis "Single-threaded network event framework for Ruby")
8716 (description
8717 "EventMachine implements a single-threaded engine for arbitrary network
8718communications. EventMachine wraps all interactions with sockets, allowing
8719programs to concentrate on the implementation of network protocols. It can be
8720used to create both network servers and clients.")
24a26227
TGR
8721 ;; The ‘official’ rubyeventmachine.com domain is now registrar-squatted.
8722 (home-page "https://github.com/eventmachine/eventmachine")
2cbcd23a 8723 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
7d3a1a2d 8724
e218b0c8
BW
8725(define-public ruby-ruby-engine
8726 (package
8727 (name "ruby-ruby-engine")
77d098bf 8728 (version "2.0.0")
e218b0c8
BW
8729 (source
8730 (origin
8731 (method url-fetch)
8732 (uri (rubygems-uri "ruby_engine" version))
8733 (sha256
8734 (base32
77d098bf 8735 "0wqdcv8gxybp1y7kjhh18g3r9dczacs62d4ahcvyhz32bih8c9fm"))))
e218b0c8
BW
8736 (build-system ruby-build-system)
8737 (arguments
8738 `(#:phases
8739 (modify-phases %standard-phases
77d098bf 8740 (add-after 'extract-gemspec 'clean-up
e218b0c8
BW
8741 (lambda _
8742 (delete-file "Gemfile.lock")
8743 (substitute* "ruby_engine.gemspec"
8744 ;; Remove unnecessary imports that would entail further
8745 ;; dependencies.
8746 ((".*<rdoc.*") "")
8747 ((".*<rubygems-tasks.*") "")
8748 ;; Remove extraneous .gem file
77d098bf
MC
8749 (("\"pkg/ruby_engine-[0-9.]+\\.gem\".freeze, ") "")
8750 (("\"Gemfile.lock\".freeze, ") "")
e218b0c8 8751 ;; Soften rake dependency
77d098bf 8752 (("%q<rake>.freeze, \\[\"~> 10.0\"\\]")
e218b0c8
BW
8753 "%q<rake>.freeze, [\">= 10.0\"]")
8754 ;; Soften the rspec dependency
77d098bf 8755 (("%q<rspec>.freeze, \\[\"~> 2.4\"\\]")
e218b0c8
BW
8756 "%q<rspec>.freeze, [\">= 2.4\"]"))
8757 (substitute* "Rakefile"
8758 (("require 'rubygems/tasks'") "")
8759 (("Gem::Tasks.new") ""))
8760 ;; Remove extraneous .gem file that otherwise gets installed.
77d098bf 8761 (delete-file-recursively "pkg")
e218b0c8
BW
8762 #t)))))
8763 (native-inputs
8764 `(("bundler" ,bundler)
8765 ("ruby-rake" ,ruby-rake)
8766 ("ruby-rspec" ,ruby-rspec)))
8767 (synopsis "Simplifies checking for Ruby implementation")
8768 (description
8769 "@code{ruby_engine} provides an RubyEngine class that can be used to
8770check which implementation of Ruby is in use. It can provide the interpreter
8771name and provides query methods such as @{RubyEngine.mri?}.")
8772 (home-page "https://github.com/janlelis/ruby_engine")
8773 (license license:expat)))
8774
8092e333
BW
8775(define-public ruby-turn
8776 (package
8777 (name "ruby-turn")
8778 (version "0.9.7")
8779 (source
8780 (origin
8781 (method url-fetch)
8782 (uri (rubygems-uri "turn" version))
8783 (sha256
8784 (base32
8785 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
8786 (build-system ruby-build-system)
8787 (arguments
8788 `(#:phases
8789 (modify-phases %standard-phases
8790 ;; Tests fail because turn changes its environment so can no longer
8791 ;; find test/unit. Instead simply test if the executable runs
8792 ;; without issue.
8793 (replace 'check
8794 (lambda _
9923d5a4 8795 (invoke "ruby" "-Ilib" "bin/turn" "-h"))))))
8092e333
BW
8796 (propagated-inputs
8797 `(("ruby-ansi" ,ruby-ansi)
8798 ("ruby-minitest" ,ruby-minitest-4)))
8799 (synopsis "Alternate set of alternative runners for MiniTest")
8800 (description
8801 "TURN provides a set of alternative runners for MiniTest which are both
8802colorful and informative. TURN displays each test on a separate line with
8803failures being displayed immediately instead of at the end of the tests. Note
8804that TURN is no longer being maintained.")
f433b662 8805 (home-page "https://rubygems.org/gems/turn")
8092e333
BW
8806 (license license:expat)))
8807
8279b1d3
CB
8808(define-public ruby-mimemagic
8809 (package
8810 (name "ruby-mimemagic")
60bc8952 8811 (version "0.3.3")
8279b1d3
CB
8812 (source
8813 (origin
8814 (method url-fetch)
8815 (uri (rubygems-uri "mimemagic" version))
8816 (sha256
60bc8952 8817 (base32 "04cp5sfbh1qx82yqxn0q75c7hlcx8y1dr5g3kyzwm4mx6wi2gifw"))))
8279b1d3
CB
8818 (build-system ruby-build-system)
8819 (arguments
8820 '(#:phases
8821 (modify-phases %standard-phases
8822 ;; This phase breaks the tests, as it patches some of the test data.
8823 (delete 'patch-source-shebangs))))
8824 (native-inputs
8825 `(("ruby-bacon" ,ruby-bacon)))
8826 (synopsis "Ruby library for MIME detection by extension or content")
8827 (description
8828 "@acronym{MIME, Multipurpose Internet Mail Extensions} detection by
8829extension or content, using the freedesktop.org.xml shared-mime-info
8830database.")
8831 (home-page "https://github.com/minad/mimemagic")
8832 (license license:expat)))
8833
32d1c06f
BW
8834(define-public ruby-mime-types-data
8835 (package
8836 (name "ruby-mime-types-data")
f49511db 8837 (version "3.2016.0521")
32d1c06f
BW
8838 (source
8839 (origin
8840 (method url-fetch)
8841 (uri (rubygems-uri "mime-types-data" version))
8842 (sha256
8843 (base32
f49511db 8844 "04my3746hwa4yvbx1ranhfaqkgf6vavi1kyijjnw8w3dy37vqhkm"))))
32d1c06f
BW
8845 (build-system ruby-build-system)
8846 (native-inputs
8847 `(("ruby-hoe" ,ruby-hoe)))
8848 (synopsis "Registry for information about MIME media type definitions")
8849 (description
8850 "@code{mime-types-data} provides a registry for information about
8851Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
8852be used with the Ruby mime-types library or other software to determine
8853defined filename extensions for MIME types, or to use filename extensions to
8854look up the likely MIME type definitions.")
8855 (home-page "https://github.com/mime-types/mime-types-data/")
8856 (license license:expat)))
8857
d39b606c
BW
8858(define-public ruby-mime-types
8859 (package
8860 (name "ruby-mime-types")
803bcc81 8861 (version "3.1")
d39b606c
BW
8862 (source
8863 (origin
8864 (method url-fetch)
8865 (uri (rubygems-uri "mime-types" version))
8866 (sha256
8867 (base32
803bcc81 8868 "0087z9kbnlqhci7fxh9f6il63hj1k02icq2rs0c6cppmqchr753m"))))
d39b606c
BW
8869 (build-system ruby-build-system)
8870 (propagated-inputs
8871 `(("ruby-mime-types-data" ,ruby-mime-types-data)))
8872 (native-inputs
8873 `(("ruby-hoe" ,ruby-hoe)
8874 ("ruby-fivemat" ,ruby-fivemat)
8875 ("ruby-minitest-focus" ,ruby-minitest-focus)
8876 ("ruby-minitest-rg" ,ruby-minitest-rg)
803bcc81
BW
8877 ("ruby-minitest-bonus-assertions" ,ruby-minitest-bonus-assertions)
8878 ("ruby-minitest-hooks" ,ruby-minitest-hooks)))
d39b606c
BW
8879 (synopsis "Library and registry for MIME content type definitions")
8880 (description "The mime-types library provides a library and registry for
8881information about Multipurpose Internet Mail Extensions (MIME) content type
8882definitions. It can be used to determine defined filename extensions for MIME
8883types, or to use filename extensions to look up the likely MIME type
8884definitions.")
8885 (home-page "https://github.com/mime-types/ruby-mime-types")
8886 (license license:expat)))
8887
ae17c6c3
EF
8888(define-public ruby-mini-mime
8889 (package
8890 (name "ruby-mini-mime")
8891 (version "1.0.2")
8892 (source
8893 (origin
8894 (method url-fetch)
8895 (uri (rubygems-uri "mini_mime" version))
8896 (sha256
8897 (base32
8898 "1axm0rxyx3ss93wbmfkm78a6x03l8y4qy60rhkkiq0aza0vwq3ha"))))
8899 (build-system ruby-build-system)
8900 (synopsis "Lightweight mime type lookup toy")
8901 (description "This package provides a lightweight mime type lookup toy.")
8902 (home-page "https://github.com/discourse/mini_mime")
8903 (license license:expat)))
8904
eb5e0bd9
BW
8905(define-public ruby-fivemat
8906 (package
8907 (name "ruby-fivemat")
c664ebcc 8908 (version "1.3.7")
eb5e0bd9
BW
8909 (source
8910 (origin
8911 (method url-fetch)
8912 (uri (rubygems-uri "fivemat" version))
8913 (sha256
8914 (base32
c664ebcc 8915 "0pzlycasvwmg4bbx7plllpqnhd9zlmmff8l2w3yii86nrm2nvf9n"))))
eb5e0bd9
BW
8916 (build-system ruby-build-system)
8917 (arguments
8918 `(#:tests? #f)) ; no tests
8919 (synopsis "Each test file given its own line of dots")
8920 (description
8921 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
8922its own line of dots during testing. It aims to provide test output that is
8923neither too verbose nor too minimal.")
8924 (home-page "https://github.com/tpope/fivemat")
8925 (license license:expat)))
8926
4fea500b
BW
8927(define-public ruby-sqlite3
8928 (package
8929 (name "ruby-sqlite3")
e7cdba61 8930 (version "1.4.2")
4fea500b
BW
8931 (source
8932 (origin
8933 (method url-fetch)
8934 (uri (rubygems-uri "sqlite3" version))
8935 (sha256
8936 (base32
e7cdba61 8937 "0lja01cp9xd5m6vmx99zwn4r7s97r1w5cb76gqd8xhbm1wxyzf78"))))
4fea500b
BW
8938 (build-system ruby-build-system)
8939 (arguments
8940 `(#:phases
8941 (modify-phases %standard-phases
8942 (add-before 'check 'add-gemtest-file
8943 ;; This file exists in the repository but is not distributed.
9923d5a4 8944 (lambda _ (invoke "touch" ".gemtest"))))))
4fea500b
BW
8945 (inputs
8946 `(("sqlite" ,sqlite)))
8947 (native-inputs
8948 `(("ruby-hoe" ,ruby-hoe)
8949 ("ruby-rake-compiler" ,ruby-rake-compiler)
8950 ("ruby-mini-portile" ,ruby-mini-portile)))
8951 (synopsis "Interface with SQLite3 databases")
8952 (description
8953 "This module allows Ruby programs to interface with the SQLite3 database
8954engine.")
8955 (home-page
8956 "https://github.com/sparklemotion/sqlite3-ruby")
8957 (license license:bsd-3)))
8958
4dfa39cc
BW
8959(define-public ruby-shoulda-context
8960 (package
8961 (name "ruby-shoulda-context")
e7d1d472 8962 (version "1.2.2")
4dfa39cc
BW
8963 (source
8964 (origin
8965 (method url-fetch)
8966 (uri (rubygems-uri "shoulda-context" version))
8967 (sha256
8968 (base32
e7d1d472 8969 "1l0ncsxycb4s8n47dml97kdnixw4mizljbkwqc3rh05r70csq9bc"))))
4dfa39cc
BW
8970 (build-system ruby-build-system)
8971 (arguments
8972 `(#:phases
8973 (modify-phases %standard-phases
8974 (replace 'check
8975 (lambda _
8976 ;; Do not run tests to avoid circular dependence with rails.
8977 ;; Instead just import the library to test.
9923d5a4 8978 (invoke "ruby" "-Ilib" "-r" "shoulda-context"))))))
4dfa39cc
BW
8979 (synopsis "Test::Unit context framework extracted from Shoulda")
8980 (description
8981 "@code{shoulda-context} is the context framework extracted from Shoulda.
8982Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
8983context, setup, and should blocks combine to produce natural test method
8984names.")
8985 (home-page "https://github.com/thoughtbot/shoulda-context")
8986 (license license:expat)))
8987
e4fea008
BW
8988(define-public ruby-shoulda-matchers
8989 (package
8990 (name "ruby-shoulda-matchers")
d1c1f368 8991 (version "3.1.2")
e4fea008
BW
8992 (source
8993 (origin
8994 (method url-fetch)
8995 (uri (rubygems-uri "shoulda-matchers" version))
8996 (sha256
8997 (base32
d1c1f368 8998 "1zvv94pqk5b5my3w1shdz7h34xf2ldhg5k4qfdpbwi2iy0j9zw2a"))))
e4fea008
BW
8999 (build-system ruby-build-system)
9000 (arguments
9001 `(#:phases
9002 (modify-phases %standard-phases
e4fea008
BW
9003 (replace 'check
9004 (lambda _
9005 ;; Do not run tests to avoid circular dependence with rails. Instead
9006 ;; just import the library to test.
9923d5a4 9007 (invoke "ruby" "-Ilib" "-r" "shoulda-matchers"))))))
e4fea008
BW
9008 (propagated-inputs
9009 `(("ruby-activesupport" ,ruby-activesupport)))
9010 (synopsis "Collection of testing matchers extracted from Shoulda")
9011 (description
9012 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
9013test common Rails functionality. These tests would otherwise be much longer,
9014more complex, and error-prone.")
9015 (home-page "https://github.com/thoughtbot/shoulda-matchers")
9016 (license license:expat)))
9017
3885c58b
BW
9018(define-public ruby-shoulda-matchers-2
9019 (package
9020 (inherit ruby-shoulda-matchers)
9021 (version "2.8.0")
9022 (source (origin
9023 (method url-fetch)
9024 (uri (rubygems-uri "shoulda-matchers" version))
9025 (sha256
9026 (base32
9027 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
9028
6f390716
BW
9029(define-public ruby-shoulda
9030 (package
9031 (name "ruby-shoulda")
9032 (version "3.5.0")
9033 (source
9034 (origin
9035 (method url-fetch)
9036 (uri (rubygems-uri "shoulda" version))
9037 (sha256
9038 (base32
9039 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
9040 (build-system ruby-build-system)
9041 (arguments
9042 `(#:phases
9043 (modify-phases %standard-phases
9044 (replace 'check
9045 ;; Don't run tests to avoid circular dependence with rails. Instead
9046 ;; just import the library to test.
9923d5a4 9047 (lambda _ (invoke "ruby" "-Ilib" "-r" "shoulda"))))))
6f390716
BW
9048 (propagated-inputs
9049 `(("ruby-shoulda-context" ,ruby-shoulda-context)
9050 ("ruby-shoulda-matchers" ,ruby-shoulda-matchers-2)))
9051 (synopsis "Context framework and matchers for testing")
9052 (description
9053 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
9054@code{shoulda-matchers} providing tools for writing tests.")
9055 (home-page "https://github.com/thoughtbot/shoulda")
9056 (license license:expat)))
9057
3b44bcdf
BW
9058(define-public ruby-unf
9059 (package
9060 (name "ruby-unf")
9061 (version "0.1.4")
9062 (source
9063 (origin
9064 (method url-fetch)
9065 (uri (rubygems-uri "unf" version))
9066 (sha256
9067 (base32
9068 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
9069 (build-system ruby-build-system)
9070 (arguments
9071 `(#:phases
9072 (modify-phases %standard-phases
9073 (add-before 'check 'add-dependency-to-bundler
9074 (lambda _
9075 ;; test-unit is required but not provided by the bundler
9076 ;; environment. This is fixed in the upstream repository but fix
9077 ;; has not been released.
9078 (substitute* "Gemfile"
9079 (("^gemspec") "gem 'test-unit'\ngemspec"))
9080 #t)))))
9081 (propagated-inputs
9082 `(("ruby-unf-ext" ,ruby-unf-ext)))
9083 (native-inputs
9084 `(("ruby-shoulda" ,ruby-shoulda)
9085 ("bundler" ,bundler)
9086 ("ruby-test-unit" ,ruby-test-unit)))
9087 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
9088 (description
9089 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
9090support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
9091@code{java.text.Normalizer} on JRuby.")
9092 (home-page "https://github.com/knu/ruby-unf")
9093 (license license:bsd-2)))
9094
e32c99d2
CB
9095(define-public ruby-warden
9096 (package
9097 (name "ruby-warden")
9098 (version "1.2.8")
9099 (source
9100 (origin
9101 (method url-fetch)
9102 (uri (rubygems-uri "warden" version))
9103 (sha256
9104 (base32
9105 "1fr9n9i9r82xb6i61fdw4xgc7zjv7fsdrr4k0njchy87iw9fl454"))))
9106 (build-system ruby-build-system)
9107 (arguments
9108 '(#:tests? #f)) ; No included tests
9109 (propagated-inputs
9110 `(("ruby-rack" ,ruby-rack)))
9111 (synopsis "Rack middleware providing authentication")
9112 (description
9113 "Warden is a Rack-based middleware that provides a mechanism for
9114authentication in Ruby web applications.")
9115 (home-page "https://github.com/wardencommunity/warden")
9116 (license license:expat)))
9117
e42eecdb
CB
9118(define-public ruby-warden-oauth2
9119 (package
9120 (name "ruby-warden-oauth2")
9121 (version "0.0.1")
9122 (source
9123 (origin
9124 (method url-fetch)
9125 (uri (rubygems-uri "warden-oauth2" version))
9126 (sha256
9127 (base32
9128 "1z9154lvzrnnfjbjkmirh4n811nygp6pm2fa6ikr7y1ysa4zv3cz"))))
9129 (build-system ruby-build-system)
9130 (arguments
9131 '(#:test-target "spec"
9132 #:phases
9133 (modify-phases %standard-phases
9134 (add-after 'unpack 'remove-unnecessary-dependencies
9135 (lambda _
9136 (substitute* "Gemfile"
9137 ;; All of these gems relate to development, and are unnecessary
9138 ;; when running the tests
9139 (("gem 'guard-bundler'") "")
9140 (("gem 'guard'") "")
9141 (("gem 'guard-rspec'") "")
9142 (("gem 'rb-fsevent'") "")
9143 (("gem 'pry'") "")
9144 (("gem 'growl'") ""))
9145 #t))
9146 ;; The test suite doesn't work with rspec@2, and this is incompatible
9147 ;; with the current version of Rake, so invoke Rspec directly
9148 (replace 'check
9149 (lambda* (#:key tests? #:allow-other-keys)
9150 (when tests?
9151 (invoke "bundle" "exec" "rspec"))
9152 #t)))))
9153 (propagated-inputs
9154 `(("ruby-warden" ,ruby-warden)))
9155 (native-inputs
9156 `(("bundler" ,bundler)
9157 ("ruby-rspec" ,ruby-rspec-2)
9158 ("ruby-rack-test" ,ruby-rack-test)))
9159 (synopsis "OAuth 2.0 strategies for Warden")
9160 (description
9161 "This library extends Warden to support OAuth 2.0 authorized API
9162requests.")
9163 (home-page "https://github.com/opperator/warden-oauth2")
9164 (license license:expat)))
9165
a4d61297 9166(define-public ruby-webmock
8c7ae384
CB
9167 (package
9168 (name "ruby-webmock")
a4d61297 9169 (version "3.11.2")
8c7ae384
CB
9170 (source
9171 (origin
9172 (method url-fetch)
9173 (uri (rubygems-uri "webmock" version))
9174 (sha256
9175 (base32
a4d61297 9176 "1hdlbvfw316lkz251qnfk79drmaay7l51kidvicz41nhvw12xz8v"))))
8c7ae384
CB
9177 (build-system ruby-build-system)
9178 (native-inputs
9179 `(("bundler" ,bundler)
9180 ("ruby-rspec" ,ruby-rspec)))
9181 (propagated-inputs
9182 `(("ruby-addressable" ,ruby-addressable)
9183 ("ruby-crack" ,ruby-crack)
9184 ("ruby-hashdiff" ,ruby-hashdiff)))
9185 (synopsis "Allows stubbing and setting expectations on HTTP requests")
9186 (description
9187 "WebMock allows stubbing HTTP requests and setting expectations on HTTP
9188requests. This is useful when testing software.")
9189 (home-page "https://github.com/bblimke/webmock")
9190 (license license:expat)))
9191
a4d61297
EF
9192(define-public ruby-webmock-2
9193 (package
9194 (inherit ruby-webmock)
9195 (name "ruby-webmock")
9196 (version "2.3.2")
9197 (source
9198 (origin
9199 (method url-fetch)
9200 (uri (rubygems-uri "webmock" version))
9201 (sha256
9202 (base32
9203 "04hkcqsmbfnp8g237pisnc834vpgildklicbjbyikqg0bg1rwcy5"))))))
9204
d8c189ed
CB
9205(define-public ruby-unicode-display-width
9206 (package
9207 (name "ruby-unicode-display-width")
216ccced 9208 (version "1.6.0")
d8c189ed
CB
9209 (source
9210 (origin
9211 (method url-fetch)
9212 (uri (rubygems-uri "unicode-display_width" version))
9213 (sha256
9214 (base32
216ccced 9215 "08kfiniak1pvg3gn5k6snpigzvhvhyg7slmm0s2qx5zkj62c1z2w"))))
d8c189ed
CB
9216 (build-system ruby-build-system)
9217 (arguments
9218 '(;; Test data not included.
9219 #:tests? #f))
9220 (synopsis "Determine the monospace display width of Ruby strings")
9221 (description
9222 "@code{Unicode::DisplayWidth} is a Ruby library which can determine the
9223display width of strings in Ruby.")
9224 (home-page "https://github.com/janlelis/unicode-display_width")
9225 (license license:expat)))
9226
6120589f
CB
9227;; There is another gem called 'ruby-version' so we use an underscore in this
9228;; name
9229(define-public ruby_version
9230 (package
9231 (name "ruby_version")
1097fdbe 9232 (version "1.0.2")
6120589f
CB
9233 (source
9234 (origin
9235 (method url-fetch)
9236 (uri (rubygems-uri "ruby_version" version))
9237 (sha256
9238 (base32
1097fdbe 9239 "0lvc7bd5ps3w2vq2wb02i0pi3vfcx2rnckx2ix4rjym1qf52kb2j"))))
6120589f
CB
9240 (build-system ruby-build-system)
9241 (arguments
1097fdbe 9242 `(#:phases
6120589f
CB
9243 (modify-phases %standard-phases
9244 (add-before 'check 'fix-dependencies
9245 (lambda _
9246 ;; Remove the Gemfile.lock, as we want to use Guix packages at
9247 ;; whatever versions.
9248 (delete-file "Gemfile.lock")
1097fdbe
MC
9249 ;; Remove the included gem files as they unnecessary.
9250 (delete-file-recursively "pkg/")
9251 ;; Accept any version of rake, rdoc and rspec
6120589f 9252 (substitute* "ruby_version.gemspec"
6120589f 9253 (("%q<rake.*") "%q<rake>)\n")
1097fdbe 9254 (("%q<rdoc.*") "%q<rdoc>)\n")
6120589f 9255 (("%q<rspec.*") "%q<rspec>)\n"))
1097fdbe 9256 ;; Do not use bundler.
6120589f 9257 (substitute* "Rakefile"
1097fdbe 9258 (("Bundler\\.setup.*") "nil\n"))
6120589f
CB
9259 #t)))))
9260 (native-inputs
1097fdbe
MC
9261 `(("ruby-rdoc" ,ruby-rdoc)
9262 ("ruby-rspec" ,ruby-rspec)
1628d57b 9263 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
6120589f 9264 (synopsis "Ruby library to help check the Ruby version")
1097fdbe 9265 (description "@code{ruby_version} provides a @code{RubyVersion} module to simplify
6120589f
CB
9266checking for the right Ruby version in software.")
9267 (home-page "https://github.com/janlelis/ruby_version")
9268 (license license:expat)))
9269
a229acff
CB
9270(define-public ruby-websocket-driver
9271 (package
9272 (name "ruby-websocket-driver")
9d1cf6d4 9273 (version "0.7.1")
a229acff
CB
9274 (source
9275 (origin
9276 (method url-fetch)
9277 (uri (rubygems-uri "websocket-driver" version))
9278 (sha256
9d1cf6d4 9279 (base32 "1bxamwqldmy98hxs5pqby3andws14hl36ch78g0s81gaz9b91nj2"))))
a229acff
CB
9280 (build-system ruby-build-system)
9281 (arguments
9d1cf6d4 9282 '(#:tests? #f)) ; no included tests
a229acff
CB
9283 (propagated-inputs
9284 `(("ruby-websocket-extensions" ,ruby-websocket-extensions)))
9285 (synopsis "WebSocket protocol handler with pluggable I/O")
9286 (description
9287 "@code{websocket-driver} provides a complete implementation of the
9288WebSocket protocols that can be hooked up to any TCP library")
9289 (home-page "https://github.com/faye/websocket-driver-ruby")
9290 (license license:expat)))
9291
52b015a9
CB
9292(define-public ruby-websocket-extensions
9293 (package
9294 (name "ruby-websocket-extensions")
9295 (version "0.1.3")
9296 (source
9297 (origin
9298 (method url-fetch)
9299 (uri (rubygems-uri "websocket-extensions" version))
9300 (sha256
9301 (base32
9302 "034sdr7fd34yag5l6y156rkbhiqgmy395m231dwhlpcswhs6d270"))))
9303 (build-system ruby-build-system)
9304 (arguments
9305 '(;; No included tests
9306 #:tests? #f))
9307 (synopsis "Generic extension manager for WebSocket connections")
9308 (description
9309 "@code{websocket-extensions} provides a container for registering
9310extension plugins.")
9311 (home-page "https://github.com/faye/websocket-extensions-ruby")
9312 (license license:expat)))
9313
5799aadd
BW
9314(define-public ruby-domain-name
9315 (package
9316 (name "ruby-domain-name")
cce2988d 9317 (version "0.5.20190701")
5799aadd
BW
9318 (source
9319 (origin
9320 (method url-fetch)
9321 (uri (rubygems-uri "domain_name" version))
9322 (sha256
cce2988d 9323 (base32 "0lcqjsmixjp52bnlgzh4lg9ppsk52x9hpwdjd53k8jnbah2602h0"))))
5799aadd
BW
9324 (build-system ruby-build-system)
9325 (arguments
9326 `(#:phases
9327 (modify-phases %standard-phases
9328 (add-before 'check 'fix-versions
9329 (lambda _
9330 ;; Fix NameError that appears to already be fixed upstream.
9331 (substitute* "Rakefile"
9332 (("DomainName::VERSION")
9333 "Bundler::GemHelper.gemspec.version"))
9334 ;; Loosen unnecessarily strict test-unit version specification.
9335 (substitute* "domain_name.gemspec"
71596c3c 9336 (("<test-unit>.freeze, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
5799aadd
BW
9337 #t)))))
9338 (propagated-inputs
9339 `(("ruby-unf" ,ruby-unf)))
9340 (native-inputs
9341 `(("ruby-shoulda" ,ruby-shoulda)
9342 ("bundler" ,bundler)
9343 ("ruby-test-unit" ,ruby-test-unit)))
9344 (synopsis "Domain name manipulation library")
9345 (description
9346 "@code{domain_name} is a Domain name manipulation library. It parses a
9347domain name ready for extracting the registered domain and TLD (Top Level
9348Domain). It can also be used for cookie domain validation based on the Public
9349Suffix List.")
9350 (home-page "https://github.com/knu/ruby-domain_name")
9351 (license license:bsd-2)))
9352
d114ceeb
BW
9353(define-public ruby-http-cookie
9354 (package
9355 (name "ruby-http-cookie")
2a2eb07d 9356 (version "1.0.3")
d114ceeb
BW
9357 (source
9358 (origin
9359 (method url-fetch)
9360 (uri (rubygems-uri "http-cookie" version))
9361 (sha256
9362 (base32
2a2eb07d 9363 "004cgs4xg5n6byjs7qld0xhsjq3n6ydfh897myr2mibvh6fjc49g"))))
d114ceeb
BW
9364 (build-system ruby-build-system)
9365 (arguments
9366 `(#:phases
9367 (modify-phases %standard-phases
9368 (add-before 'check 'add-dependency-to-bundler
9369 (lambda _
9370 ;; Fix NameError
9371 (substitute* "Rakefile"
9372 (("HTTP::Cookie::VERSION")
9373 "Bundler::GemHelper.gemspec.version"))
9374 #t)))))
9375 (propagated-inputs
9376 `(("ruby-domain-name" ,ruby-domain-name)))
9377 (native-inputs
9378 `(("rubysimplecov" ,ruby-simplecov)
9379 ("bundler" ,bundler)
9380 ("ruby-sqlite3" ,ruby-sqlite3)
9381 ("ruby-test-unit" ,ruby-test-unit)))
9382 (synopsis "Handle HTTP Cookies based on RFC 6265")
9383 (description
9384 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
9385RFC 6265. It has been designed with security, standards compliance and
9386compatibility in mind, to behave just the same as today's major web browsers.
9387It has built-in support for the legacy @code{cookies.txt} and
9388@code{cookies.sqlite} formats of Mozilla Firefox.")
9389 (home-page "https://github.com/sparklemotion/http-cookie")
9390 (license license:expat)))
9391
1c8e6fd3
CB
9392(define-public ruby-httpclient
9393 (package
9394 (name "ruby-httpclient")
9395 (version "2.8.3")
9396 (source
9397 (origin
9398 (method url-fetch)
9399 (uri (rubygems-uri "httpclient" version))
9400 (sha256
9401 (base32
9402 "19mxmvghp7ki3klsxwrlwr431li7hm1lczhhj8z4qihl2acy8l99"))))
9403 (build-system ruby-build-system)
9404 (arguments
9405 '(;; TODO: Some tests currently fail
9406 ;; ------
9407 ;; 211 tests, 729 assertions, 13 failures, 4 errors, 0 pendings,
9408 ;; 2 omissions, 0 notifications
9409 ;; 91.866% passed
9410 ;; ------
9411 ;; 6.49 tests/s, 22.41 assertions/s
9412 #:tests? #f
9413 #:phases
9414 (modify-phases %standard-phases
9415 (replace 'check
9416 (lambda* (#:key tests? #:allow-other-keys)
9417 (if tests?
9923d5a4
TGR
9418 (invoke "ruby"
9419 "-Ilib"
9420 "test/runner.rb")
0076f5a9 9421 #t))))))
1c8e6fd3
CB
9422 (native-inputs
9423 `(("ruby-rack" ,ruby-rack)))
9424 (synopsis
9425 "Make HTTP requests with support for HTTPS, Cookies, authentication and more")
9426 (description
9427 "The @code{httpclient} ruby library provides functionality related to
9428HTTP. Compared to the @code{net/http} library, @{httpclient} also provides
9429Cookie, multithreading and authentication (digest, NTLM) support.
9430
9431Also provided is a @command{httpclient} command, which can perform HTTP
9432requests either using arguments or with an interactive prompt.")
9433 (home-page "https://github.com/nahi/httpclient")
9434 (license license:ruby)))
9435
7d3a1a2d
BW
9436(define-public ruby-ansi
9437 (package
9438 (name "ruby-ansi")
9439 (version "1.5.0")
9440 (source
9441 (origin
3d30c332 9442 (method git-fetch)
7d3a1a2d 9443 ;; Fetch from GitHub as the gem does not contain testing code.
3d30c332
EF
9444 (uri (git-reference
9445 (url "https://github.com/rubyworks/ansi")
9446 (commit version)))
9447 (file-name (git-file-name name version))
7d3a1a2d
BW
9448 (sha256
9449 (base32
3d30c332 9450 "1wsz7xxwl3vkh277jb7fd7akqnqqgbvalxzpjwniiqk8ghfprbi5"))))
7d3a1a2d
BW
9451 (build-system ruby-build-system)
9452 (arguments
9453 `(#:phases
9454 (modify-phases %standard-phases
9455 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
9456 ;; cycle ansi, qed, ansi. Instead simply test that the library can
9457 ;; be require'd.
9458 (replace 'check
9459 (lambda _
9923d5a4 9460 (invoke "ruby" "-Ilib" "-r" "ansi")))
0899352f
MB
9461 (add-before 'validate-runpath 'replace-broken-symlink
9462 (lambda* (#:key outputs #:allow-other-keys)
9463 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
9464 (file (string-append
9465 out "/lib/ruby/vendor_ruby/gems/ansi-"
9466 ,version "/lib/ansi.yml")))
0899352f
MB
9467 ;; XXX: This symlink is broken since ruby 2.4.
9468 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9469 (delete-file file)
9470 (symlink "../.index" file)
9471 #t))))))
7d3a1a2d
BW
9472 (synopsis "ANSI escape code related libraries")
9473 (description
9474 "This package is a collection of ANSI escape code related libraries
9475enabling ANSI colorization and stylization of console output. Included in the
9476library are the @code{Code} module, which defines ANSI codes as constants and
9477methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
9478@code{ProgressBar}, and a @code{String} subclass. The library also includes a
9479@code{Terminal} module which provides information about the current output
9480device.")
3d30c332 9481 (home-page "https://rubyworks.github.io/ansi/")
7d3a1a2d 9482 (license license:bsd-2)))
7c033c46
BW
9483
9484(define-public ruby-systemu
9485 (package
9486 (name "ruby-systemu")
9487 (version "2.6.5")
9488 (source
9489 (origin
9490 (method url-fetch)
9491 (uri (rubygems-uri "systemu" version))
9492 (sha256
9493 (base32
9494 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
9495 (build-system ruby-build-system)
9496 (arguments
9497 `(#:phases
9498 (modify-phases %standard-phases
9499 (add-before 'check 'set-version
9500 (lambda _
9501 (setenv "VERSION" ,version)
9502 #t)))))
9503 (synopsis "Capture of stdout/stderr and handling of child processes")
9504 (description
9505 "Systemu can be used on any platform to return status, stdout, and stderr
9506of any command. Unlike other methods like @code{open3} and @code{popen4}
9507there is no danger of full pipes or threading issues hanging your process or
9508subprocess.")
9509 (home-page "https://github.com/ahoward/systemu")
9510 (license license:ruby)))
3d84a99e
BW
9511
9512(define-public ruby-bio-commandeer
9513 (package
9514 (name "ruby-bio-commandeer")
37b08547 9515 (version "0.4.0")
3d84a99e
BW
9516 (source
9517 (origin
9518 (method url-fetch)
9519 (uri (rubygems-uri "bio-commandeer" version))
9520 (sha256
9521 (base32
37b08547 9522 "0khpfw1yl5l3d2m8nxpkk32ybc4c3pa5hic3agd160jdfjjjnlni"))))
3d84a99e
BW
9523 (build-system ruby-build-system)
9524 (arguments
9525 `(#:phases
9526 (modify-phases %standard-phases
9527 (replace 'check
9528 ;; Run test without calling 'rake' so that jeweler is
9529 ;; not required as an input.
9530 (lambda _
9923d5a4 9531 (invoke "rspec" "spec/bio-commandeer_spec.rb"))))))
3d84a99e
BW
9532 (propagated-inputs
9533 `(("ruby-bio-logger" ,ruby-bio-logger)
9534 ("ruby-systemu" ,ruby-systemu)))
9535 (native-inputs
9536 `(("bundler" ,bundler)
9537 ("ruby-rspec" ,ruby-rspec)))
9538 (synopsis "Simplified running of shell commands from within Ruby")
9539 (description
9540 "Bio-commandeer provides an opinionated method of running shell commands
9541from within Ruby. The advantage of bio-commandeer over other methods of
9542running external commands is that when something goes wrong, messages printed
9543to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
9544detail to ease debugging.")
7bf837fd 9545 (home-page "https://github.com/wwood/bioruby-commandeer")
3d84a99e 9546 (license license:expat)))
7c8131c7
BW
9547
9548(define-public ruby-rubytest
9549 (package
9550 (name "ruby-rubytest")
9551 (version "0.8.1")
9552 (source
9553 (origin
9554 (method url-fetch)
9555 (uri (rubygems-uri "rubytest" version))
9556 (sha256
9557 (base32
9558 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
9559 (build-system ruby-build-system)
9560 (arguments
9561 ;; Disable regular testing to break the cycle rubytest, qed, brass,
9562 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
9563 ;; simply test that the library can be require'd.
9564 `(#:phases
9565 (modify-phases %standard-phases
9566 (replace 'check
9567 (lambda _
9923d5a4 9568 (invoke "ruby" "-Ilib" "-r" "rubytest"))))))
7c8131c7
BW
9569 (propagated-inputs
9570 `(("ruby-ansi" ,ruby-ansi)))
9571 (synopsis "Universal test harness for Ruby")
9572 (description
9573 "Rubytest is a testing meta-framework for Ruby. It can handle any
9574compliant test framework and can run tests from multiple frameworks in a
9575single pass.")
2f3800e5 9576 (home-page "https://rubyworks.github.io/rubytest")
7c8131c7 9577 (license license:bsd-2)))
90fcedf2
BW
9578
9579(define-public ruby-brass
9580 (package
9581 (name "ruby-brass")
9582 (version "1.2.1")
9583 (source
9584 (origin
9585 (method url-fetch)
9586 (uri (rubygems-uri "brass" version))
9587 (sha256
9588 (base32
9589 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
9590 (build-system ruby-build-system)
9591 (arguments
9592 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
9593 ;; Instead simply test that the library can be require'd.
9594 `(#:phases
9595 (modify-phases %standard-phases
9596 (replace 'check
9597 (lambda _
9923d5a4 9598 (invoke "ruby" "-Ilib" "-r" "brass"))))))
90fcedf2
BW
9599 (synopsis "Basic foundational assertions framework")
9600 (description
9601 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
9602foundational assertions framework for other assertion and test frameworks to
9603make use of.")
2f3800e5 9604 (home-page "https://rubyworks.github.io/brass")
90fcedf2 9605 (license license:bsd-2)))
120fc74b
BW
9606
9607(define-public ruby-qed
9608 (package
9609 (name "ruby-qed")
9610 (version "2.9.2")
9611 (source
9612 (origin
9613 (method url-fetch)
9614 (uri (rubygems-uri "qed" version))
9615 (sha256
9616 (base32
9617 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
9618 (build-system ruby-build-system)
9619 (arguments
9620 ;; Disable testing to break the cycle qed, ansi, qed, among others.
9621 ;; Instead simply test that the executable runs using --copyright.
9622 `(#:phases
9623 (modify-phases %standard-phases
9624 (replace 'check
9625 (lambda _
9923d5a4 9626 (invoke "ruby" "-Ilib" "bin/qed" "--copyright"))))))
120fc74b
BW
9627 (propagated-inputs
9628 `(("ruby-ansi" ,ruby-ansi)
9629 ("ruby-brass" ,ruby-brass)))
9630 (synopsis "Test framework utilizing literate programming techniques")
9631 (description
9632 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
9633@dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
9634Development} (BDD) utilizing Literate Programming techniques. QED sits
9635somewhere between lower-level testing tools like @code{Test::Unit} and
9636requirement specifications systems like Cucumber.")
2f3800e5 9637 (home-page "https://rubyworks.github.io/qed")
120fc74b 9638 (license license:bsd-2)))
9273ee8f 9639
dbbe88d3
CB
9640(define-public ruby-que
9641 (package
9642 (name "ruby-que")
9643 (version "1.0.0.beta3")
9644 (source
9645 (origin
9646 (method url-fetch)
9647 (uri (rubygems-uri "que" version))
9648 (sha256
9649 (base32
9650 "0gr9pb814d4qj3ds98g6cjrdk7wv0yg8aqbm7c1lmgl87jkg8q04"))))
9651 (build-system ruby-build-system)
9652 (arguments
9653 '(#:tests? #f)) ; No included tests
9654 (synopsis "Job queue using PostgreSQL written in Ruby")
9655 (description
9656 "This package provides a job queue that uses PostgreSQL for storing jobs
9657and locking between worker processes.")
9658 (home-page "https://github.com/chanks/que")
9659 (license license:expat)))
9660
9273ee8f
BW
9661(define-public ruby-ae
9662 (package
9663 (name "ruby-ae")
9664 (version "1.8.2")
9665 (source
9666 (origin
11d1b318 9667 (method git-fetch)
9273ee8f 9668 ;; Fetch from github so tests are included.
11d1b318
EF
9669 (uri (git-reference
9670 (url "https://github.com/rubyworks/ae")
9671 (commit version)))
9672 (file-name (git-file-name name version))
9273ee8f
BW
9673 (sha256
9674 (base32
11d1b318 9675 "11299jj5ma8mi7b4majkyjy70y6zlqpgl8aql1c5lvfjavlpwmlp"))))
9273ee8f
BW
9676 (build-system ruby-build-system)
9677 (arguments
9678 `(#:phases
9679 (modify-phases %standard-phases
9680 (replace 'check
9923d5a4 9681 (lambda _ (invoke "qed")))
de6f6efd
MB
9682 (add-before 'validate-runpath 'replace-broken-symlink
9683 (lambda* (#:key outputs #:allow-other-keys)
9684 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
9685 (file (string-append
9686 out "/lib/ruby/vendor_ruby/gems/ae-"
9687 ,version "/lib/ae.yml")))
de6f6efd
MB
9688 ;; XXX: This symlink is broken since ruby 2.4.
9689 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9690 (delete-file file)
9691 (symlink "../.index" file)
9692 #t))))))
9273ee8f
BW
9693 (propagated-inputs
9694 `(("ruby-ansi" ,ruby-ansi)))
9695 (native-inputs
9696 `(("ruby-qed" ,ruby-qed)))
9697 (synopsis "Assertions library")
9698 (description
9699 "Assertive Expressive (AE) is an assertions library specifically designed
9700for reuse by other test frameworks.")
11d1b318 9701 (home-page "https://rubyworks.github.io/ae/")
9273ee8f 9702 (license license:bsd-2)))
78bb471f
BW
9703
9704(define-public ruby-lemon
9705 (package
9706 (name "ruby-lemon")
9707 (version "0.9.1")
9708 (source
9709 (origin
9710 (method url-fetch)
9711 (uri (rubygems-uri "lemon" version))
9712 (sha256
9713 (base32
9714 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
9715 (build-system ruby-build-system)
9716 (arguments
9717 `(#:phases
9718 (modify-phases %standard-phases
9923d5a4 9719 (replace 'check (lambda _ (invoke "qed"))))))
78bb471f
BW
9720 (propagated-inputs
9721 `(("ruby-ae" ,ruby-ae)
9722 ("ruby-ansi" ,ruby-ansi)
9723 ("ruby-rubytest" ,ruby-rubytest)))
9724 (native-inputs
9725 `(("ruby-qed" ,ruby-qed)))
9726 (synopsis "Test framework correlating code structure and test unit")
9727 (description
9728 "Lemon is a unit testing framework that enforces highly formal
9729case-to-class and unit-to-method test construction. This enforcement can help
9730focus concern on individual units of behavior.")
2f3800e5 9731 (home-page "https://rubyworks.github.io/lemon")
78bb471f 9732 (license license:bsd-2)))
0832804e
BW
9733
9734(define-public ruby-rubytest-cli
9735 (package
9736 (name "ruby-rubytest-cli")
9737 (version "0.2.0")
9738 (source
9739 (origin
9740 (method url-fetch)
9741 (uri (rubygems-uri "rubytest-cli" version))
9742 (sha256
9743 (base32
9744 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
9745 (build-system ruby-build-system)
9746 (arguments
9747 `(#:tests? #f)) ; no tests
9748 (propagated-inputs
9749 `(("ruby-ansi" ,ruby-ansi)
9750 ("ruby-rubytest" ,ruby-rubytest)))
9751 (synopsis "Command-line interface for rubytest")
9752 (description
9753 "Rubytest CLI is a command-line interface for running tests for
9754Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
2f3800e5 9755 (home-page "https://rubyworks.github.io/rubytest-cli")
0832804e 9756 (license license:bsd-2)))
72ccbfe3
BW
9757
9758(define-public ruby-hashery
9759 (package
9760 (name "ruby-hashery")
cba96208 9761 (version "2.1.2")
72ccbfe3
BW
9762 (source
9763 (origin
9764 (method url-fetch)
9765 (uri (rubygems-uri "hashery" version))
9766 (sha256
9767 (base32
cba96208 9768 "0qj8815bf7q6q7llm5rzdz279gzmpqmqqicxnzv066a020iwqffj"))))
72ccbfe3
BW
9769 (build-system ruby-build-system)
9770 (arguments
9771 `(#:phases
9772 (modify-phases %standard-phases
9773 (replace 'check
9774 (lambda _
9923d5a4
TGR
9775 (invoke "qed")
9776 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
72ccbfe3
BW
9777 (native-inputs
9778 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
9779 ("ruby-qed" ,ruby-qed)
9780 ("ruby-lemon" ,ruby-lemon)))
9781 (synopsis "Hash-like classes with extra features")
9782 (description
9783 "The Hashery is a tight collection of @code{Hash}-like classes.
9784Included are the auto-sorting @code{Dictionary} class, the efficient
9785@code{LRUHash}, the flexible @code{OpenHash} and the convenient
9786@code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
9787defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
9788standard @code{Hash} making it possible to subclass and augment to fit any
9789specific use case.")
2f3800e5 9790 (home-page "https://rubyworks.github.io/hashery")
72ccbfe3 9791 (license license:bsd-2)))
1f1d71e0
BW
9792
9793(define-public ruby-rc4
9794 (package
9795 (name "ruby-rc4")
9796 (version "0.1.5")
9797 (source
9798 (origin
9799 (method url-fetch)
9800 (uri (rubygems-uri "ruby-rc4" version))
9801 (sha256
9802 (base32
9803 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
9804 (build-system ruby-build-system)
9805 (arguments
9806 `(#:phases
9807 (modify-phases %standard-phases
9808 (replace 'check
9809 (lambda _
9923d5a4 9810 (invoke "rspec" "spec/rc4_spec.rb"))))))
1f1d71e0
BW
9811 (native-inputs
9812 `(("ruby-rspec" ,ruby-rspec-2)))
9813 (synopsis "Implementation of the RC4 algorithm")
9814 (description
9815 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
9816 (home-page "https://github.com/caiges/Ruby-RC4")
9817 (license license:expat)))
f3e085a8
BW
9818
9819(define-public ruby-afm
9820 (package
9821 (name "ruby-afm")
9822 (version "0.2.2")
9823 (source
9824 (origin
9825 (method url-fetch)
9826 (uri (rubygems-uri "afm" version))
9827 (sha256
9828 (base32
9829 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
9830 (build-system ruby-build-system)
9831 (native-inputs
9832 `(("bundler" ,bundler)))
9833 (synopsis "Read Adobe Font Metrics (afm) files")
9834 (description
9835 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
9836files and use the data therein.")
7bf837fd 9837 (home-page "https://github.com/halfbyte/afm")
f3e085a8 9838 (license license:expat)))
acb6be42
BW
9839
9840(define-public ruby-ascii85
9841 (package
9842 (name "ruby-ascii85")
5854082a 9843 (version "1.0.3")
acb6be42
BW
9844 (source
9845 (origin
9846 (method url-fetch)
9847 (uri (rubygems-uri "Ascii85" version))
9848 (sha256
9849 (base32
5854082a 9850 "0658m37jjjn6drzqg1gk4p6c205mgp7g1jh2d00n4ngghgmz5qvs"))))
acb6be42
BW
9851 (build-system ruby-build-system)
9852 (native-inputs
9853 `(("bundler" ,bundler)))
9854 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
9855 (description
9856 "This library provides methods to encode and decode Ascii85
9857binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
9858@dfn{Portable Document Format} (PDF) file formats.")
9859 (home-page "https://github.com/datawraith/ascii85gem")
9860 (license license:expat)))
edf8caae
BW
9861
9862(define-public ruby-ttfunk
9863 (package
9864 (name "ruby-ttfunk")
4179ed93 9865 (version "1.6.2.1")
edf8caae
BW
9866 (source
9867 (origin
4e110825 9868 (method git-fetch)
edf8caae 9869 ;; fetch from github as the gem does not contain testing code
4e110825
EF
9870 (uri (git-reference
9871 (url "https://github.com/prawnpdf/ttfunk")
9872 (commit version)))
9873 (file-name (git-file-name name version))
edf8caae
BW
9874 (sha256
9875 (base32
4179ed93 9876 "0rsf4j6s97wbcnjbvmmh6xrc7imw4g9lrlcvn945wh400lc8r53z"))))
edf8caae
BW
9877 (build-system ruby-build-system)
9878 (arguments
9879 `(#:test-target "spec"
9880 #:phases
9881 (modify-phases %standard-phases
afb7a3e8
JL
9882 (add-before 'build 'remove-ssh
9883 (lambda _
9884 ;; remove dependency on an ssh key pair that doesn't exist
9885 (substitute* "ttfunk.gemspec"
9886 (("spec.signing_key.*") ""))
9887 #t))
edf8caae
BW
9888 (add-before 'check 'remove-rubocop
9889 (lambda _
9890 ;; remove rubocop as a dependency as not needed for testing
9891 (substitute* "ttfunk.gemspec"
9892 (("spec.add_development_dependency\\('rubocop'.*") ""))
9893 (substitute* "Rakefile"
9894 (("require 'rubocop/rake_task'") "")
afb7a3e8 9895 (("RuboCop::RakeTask.new") ""))
edf8caae
BW
9896 #t)))))
9897 (native-inputs
9898 `(("ruby-rspec" ,ruby-rspec)
afb7a3e8 9899 ("ruby-yard" ,ruby-yard)
edf8caae
BW
9900 ("bundler" ,bundler)))
9901 (synopsis "Font metrics parser for the Prawn PDF generator")
9902 (description
9903 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
9904part of the Prawn PDF generator.")
9905 (home-page "https://github.com/prawnpdf/ttfunk")
9906 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
9907 ;; for details."
4179ed93 9908 (license %prawn-project-licenses)))
cbdd428c 9909
9270298f
BW
9910(define-public ruby-puma
9911 (package
9912 (name "ruby-puma")
63755fcd 9913 (version "3.9.1")
9270298f
BW
9914 (source
9915 (origin
a6cffe6e 9916 (method git-fetch)
9270298f 9917 ;; Fetch from GitHub because distributed gem does not contain tests.
a6cffe6e
EF
9918 (uri (git-reference
9919 (url "https://github.com/puma/puma")
9920 (commit (string-append "v" version))))
9921 (file-name (git-file-name name version))
9270298f
BW
9922 (sha256
9923 (base32
a6cffe6e 9924 "1kj75k81iik3aj73pkc9ixj9rwf95ipkyma65n28m64dgw02qi1f"))))
9270298f
BW
9925 (build-system ruby-build-system)
9926 (arguments
63755fcd
BW
9927 `(#:tests? #f ; Tests require an out-dated version of minitest.
9928 #:phases
9270298f
BW
9929 (modify-phases %standard-phases
9930 (add-before 'build 'fix-gemspec
9931 (lambda _
9932 (substitute* "puma.gemspec"
9933 (("git ls-files") "find * |sort"))
9934 #t)))))
9270298f
BW
9935 (synopsis "Simple, concurrent HTTP server for Ruby/Rack")
9936 (description
9937 "Puma is a simple, fast, threaded, and highly concurrent HTTP 1.1 server
9938for Ruby/Rack applications. Puma is intended for use in both development and
9939production environments. In order to get the best throughput, it is highly
9940recommended that you use a Ruby implementation with real threads like Rubinius
9941or JRuby.")
a6cffe6e 9942 (home-page "https://puma.io/")
9270298f
BW
9943 (license license:expat)))
9944
b0813490
BW
9945(define-public ruby-hoe-git
9946 (package
9947 (name "ruby-hoe-git")
9948 (version "1.6.0")
9949 (source
9950 (origin
9951 (method url-fetch)
9952 (uri (rubygems-uri "hoe-git" version))
9953 (sha256
9954 (base32
9955 "10jmmbjm0lkglwxbn4rpqghgg1ipjxrswm117n50adhmy8yij650"))))
9956 (build-system ruby-build-system)
9957 (propagated-inputs
07095a30 9958 `(("ruby-hoe" ,ruby-hoe)))
b0813490
BW
9959 (synopsis "Hoe plugins for tighter Git integration")
9960 (description
9961 "This package provides a set of Hoe plugins for tighter Git integration.
9962It provides tasks to automate release tagging and pushing and changelog
9963generation.")
7bf837fd 9964 (home-page "https://github.com/jbarnette/hoe-git")
b0813490
BW
9965 (license license:expat)))
9966
cbdd428c
BW
9967(define-public ruby-sequel
9968 (package
9969 (name "ruby-sequel")
65a7f09c 9970 (version "4.49.0")
cbdd428c
BW
9971 (source
9972 (origin
9973 (method url-fetch)
9974 (uri (rubygems-uri "sequel" version))
9975 (sha256
9976 (base32
65a7f09c 9977 "010p4a60npppvgbyw7pq5xia8aydpgxdlhh3qjm2615kwjsw3fl8"))))
cbdd428c
BW
9978 (build-system ruby-build-system)
9979 (arguments
9980 '(#:tests? #f)) ; Avoid dependency loop with ruby-minitest-hooks.
9981 (synopsis "Database toolkit for Ruby")
9982 (description "Sequel provides thread safety, connection pooling and a
9983concise DSL for constructing SQL queries and table schemas. It includes a
9984comprehensive ORM layer for mapping records to Ruby objects and handling
9985associated records.")
e2b70d90 9986 (home-page "https://sequel.jeremyevans.net")
cbdd428c 9987 (license license:expat)))
3cc78097
BW
9988
9989(define-public ruby-timecop
9990 (package
9991 (name "ruby-timecop")
3d4a5eb5 9992 (version "0.9.1")
3cc78097
BW
9993 (source
9994 (origin
9995 (method url-fetch)
9996 (uri (rubygems-uri "timecop" version))
9997 (sha256
9998 (base32
3d4a5eb5 9999 "0d7mm786180v4kzvn1f77rhfppsg5n0sq2bdx63x9nv114zm8jrp"))))
3cc78097
BW
10000 (build-system ruby-build-system)
10001 (arguments
10002 `(#:phases
10003 (modify-phases %standard-phases
10004 (add-before 'check 'set-check-rubylib
10005 (lambda _
10006 ;; Set RUBYLIB so timecop tests finds its own lib.
10007 (setenv "RUBYLIB" "lib")
10008 #t)))))
10009 (native-inputs
10010 `(("bundler" ,bundler)
10011 ("ruby-minitest-rg" ,ruby-minitest-rg)
10012 ("ruby-mocha" ,ruby-mocha)
10013 ("ruby-activesupport" ,ruby-activesupport)))
66e07664 10014 (synopsis "Test mocks for time-dependent functions")
3cc78097
BW
10015 (description
10016 "Timecop provides \"time travel\" and \"time freezing\" capabilities,
10017making it easier to test time-dependent code. It provides a unified method to
10018mock @code{Time.now}, @code{Date.today}, and @code{DateTime.now} in a single
10019call.")
10020 (home-page "https://github.com/travisjeffery/timecop")
10021 (license license:expat)))
10022
dae620b8
BW
10023(define-public ruby-concurrent
10024 (package
10025 (name "ruby-concurrent")
1007640a 10026 (version "1.1.5")
dae620b8
BW
10027 (source
10028 (origin
8fcba3be 10029 (method git-fetch)
dae620b8
BW
10030 ;; Download from GitHub because the rubygems version does not contain
10031 ;; Rakefile.
8fcba3be
MB
10032 (uri (git-reference
10033 (url "https://github.com/ruby-concurrency/concurrent-ruby")
10034 (commit (string-append "v" version))))
10035 (file-name (git-file-name name version))
dae620b8
BW
10036 (sha256
10037 (base32
1007640a 10038 "193q2k47vk7qdvv9hlhmmdxgy91xl4imapyk1ijdg9vgf46knyzj"))))
dae620b8
BW
10039 (build-system ruby-build-system)
10040 (arguments
1007640a 10041 `(#:test-target "ci"
dae620b8
BW
10042 #:phases
10043 (modify-phases %standard-phases
520e89eb 10044 (add-before 'replace-git-ls-files 'remove-extra-gemspecs
dae620b8
BW
10045 (lambda _
10046 ;; Delete extra gemspec files so 'first-gemspec' chooses the
10047 ;; correct one.
10048 (delete-file "concurrent-ruby-edge.gemspec")
10049 (delete-file "concurrent-ruby-ext.gemspec")
10050 #t))
1007640a 10051 (replace 'replace-git-ls-files
520e89eb 10052 (lambda _
1007640a
MB
10053 ;; XXX: The default substitution made by this phase is not fully
10054 ;; compatible with "git ls-files". The latter produces file names
10055 ;; such as "lib/foo", whereas ruby-build-system uses "find . [...]"
10056 ;; which gives "./lib/foo". That difference in turn breaks the
10057 ;; comparison against a glob pattern in this script.
10058 (substitute* "concurrent-ruby.gemspec"
10059 (("git ls-files") "find * -type f | sort"))
10060 #t))
10061 (add-before 'build 'remove-jar-from-gemspec
520e89eb 10062 (lambda _
1007640a
MB
10063 ;; The gemspec wants to include a JAR file that we do not build
10064 ;; nor need.
10065 (substitute* "concurrent-ruby.gemspec"
10066 (("'lib/concurrent/concurrent_ruby.jar'")
10067 ""))
10068 #t))
10069 (add-before 'build 'remove-rake_compiler_dock-dependency
10070 (lambda _
10071 ;; This library is only used when building for non-MRI targets.
10072 (substitute* "Rakefile"
10073 (("require 'rake_compiler_dock'")
10074 ""))
520e89eb 10075 #t))
9019b37f
BW
10076 (add-before 'check 'remove-timecop-dependency
10077 ;; Remove timecop-dependent tests as having timecop as a depedency
10078 ;; causes circular depedencies.
10079 (lambda _
10080 (delete-file "spec/concurrent/executor/timer_set_spec.rb")
10081 (delete-file "spec/concurrent/scheduled_task_spec.rb")
10082 #t)))))
dae620b8
BW
10083 (native-inputs
10084 `(("ruby-rake-compiler" ,ruby-rake-compiler)
9019b37f 10085 ("ruby-rspec" ,ruby-rspec)))
dae620b8
BW
10086 (synopsis "Concurrency tools for Ruby")
10087 (description
10088 "This library provides modern concurrency tools including agents,
10089futures, promises, thread pools, actors, supervisors, and more. It is
10090inspired by Erlang, Clojure, Go, JavaScript, actors and classic concurrency
10091patterns.")
10092 (home-page "http://www.concurrent-ruby.com")
10093 (license license:expat)))
2de61e34
BW
10094
10095(define-public ruby-pkg-config
10096 (package
10097 (name "ruby-pkg-config")
884a80dd 10098 (version "1.2.5")
2de61e34
BW
10099 (source
10100 (origin
10101 (method url-fetch)
10102 (uri (rubygems-uri "pkg-config" version))
10103 (sha256
10104 (base32
884a80dd 10105 "056mzqdh4yjznsg36fi0xiq76f24vxlhzh2n4az919l3x5k318ar"))))
2de61e34
BW
10106 (build-system ruby-build-system)
10107 (arguments
10108 ;; Tests require extra files not included in the gem.
10109 `(#:tests? #f))
10110 (synopsis "Detect libraries for compiling Ruby native extensions")
10111 (description
10112 "@code{pkg-config} can be used in your extconf.rb to properly detect need
10113libraries for compiling Ruby native extensions.")
10114 (home-page "https://github.com/ruby-gnome2/pkg-config")
10115 (license license:lgpl2.0+)))
6689c636
MFM
10116
10117(define-public ruby-net-http-digest-auth
10118 (package
10119 (name "ruby-net-http-digest-auth")
ba074a85 10120 (version "1.4.1")
6689c636
MFM
10121 (source
10122 (origin
10123 (method url-fetch)
10124 (uri (rubygems-uri "net-http-digest_auth" version))
10125 (sha256
10126 (base32
ba074a85 10127 "1nq859b0gh2vjhvl1qh1zrk09pc7p54r9i6nnn6sb06iv07db2jb"))))
6689c636
MFM
10128 (build-system ruby-build-system)
10129 (native-inputs
10130 `(("ruby-hoe" ,ruby-hoe)))
10131 (synopsis "RFC 2617 HTTP digest authentication library")
10132 (description
10133 "This library implements HTTP's digest authentication scheme based on
10134RFC 2617. This enables the use of the digest authentication scheme instead
10135of the more insecure basic authentication scheme.")
7bf837fd 10136 (home-page "https://github.com/drbrain/net-http-digest_auth")
6689c636 10137 (license license:expat)))
06116573 10138
10139(define-public ruby-mail
10140 (package
10141 (name "ruby-mail")
ab4b6ae6 10142 (version "2.7.1")
06116573 10143 (source
10144 (origin
10145 (method url-fetch)
10146 (uri (rubygems-uri "mail" version))
10147 (sha256
10148 (base32
ab4b6ae6 10149 "00wwz6ys0502dpk8xprwcqfwyf3hmnx6lgxaiq6vj43mkx43sapc"))))
06116573 10150 (build-system ruby-build-system)
10151 (propagated-inputs
ab4b6ae6 10152 `(("ruby-mini-mime" ,ruby-mini-mime)))
06116573 10153 (arguments
ab4b6ae6 10154 '(#:tests? #f)) ; no rakefile
06116573 10155 (synopsis "Mail library for Ruby")
10156 (description
10157 "Mail is an internet library for Ruby that is designed to handle email
10158generation, parsing and sending. The purpose of this library is to provide
10159a single point of access to handle all email functions, including sending
10160and receiving emails. All network type actions are done through proxy
10161methods to @code{Net::SMTP}, @code{Net::POP3} etc.
10162
10163Mail has been designed with a very simple object oriented system that
10164really opens up the email messages you are parsing, if you know what you
10165are doing, you can fiddle with every last bit of your email directly.")
10166 (home-page "https://github.com/mikel/mail")
10167 (license license:expat)))
9b4c8e1b 10168
4d372cb9
CB
10169(define-public ruby-mathn
10170 (package
10171 (name "ruby-mathn")
10172 (version "0.1.0")
10173 (source
10174 (origin
10175 (method url-fetch)
10176 (uri (rubygems-uri "mathn" version))
10177 (sha256
10178 (base32
10179 "1wn812llln9jzgybz2d7536q39z3gi99i6fi0j1dapcpzvhgrr0p"))))
10180 (build-system ruby-build-system)
10181 (native-inputs
10182 `(("bundler" ,bundler)
10183 ("ruby-rake-compiler" ,ruby-rake-compiler)))
10184 (synopsis "Extends math operations for increased precision")
10185 (description
10186 "This gem makes mathematical operations more precise in Ruby and
10187integrates other mathematical standard libraries. Prior to Ruby 2.5,
10188@code{mathn} was part of the Ruby standard library.")
10189 (home-page "https://github.com/ruby/mathn")
10190 (license license:bsd-2)))
10191
9b4c8e1b
BW
10192(define-public ruby-code-statistics
10193 (package
10194 (name "ruby-code-statistics")
10195 (version "0.2.13")
10196 (source
10197 (origin
10198 (method url-fetch)
10199 (uri (rubygems-uri "code_statistics" version))
10200 (sha256
10201 (base32
10202 "07rdpsbwbmh4vp8nxyh308cj7am2pbrfhv9v5xr2d5gq8hnnsm93"))))
10203 (build-system ruby-build-system)
10204 (arguments
10205 `(#:tests? #f)) ; Not all test code is included in gem.
10206 (synopsis "Port of the rails 'rake stats' method")
10207 (description
10208 "This gem is a port of the rails 'rake stats' method so it can be made
10209more robust and work for non rails projects.")
702a1012 10210 (home-page "https://github.com/danmayer/code_statistics")
9b4c8e1b 10211 (license license:expat)))
f90c25c1
CL
10212
10213(define-public ruby-rubypants
10214 (package
10215 (name "ruby-rubypants")
10216 (version "0.6.0")
10217 (source (origin
10218 (method url-fetch)
10219 (uri (rubygems-uri "rubypants" version))
10220 (sha256
10221 (base32
10222 "0xpqkslan2wkyal2h9qhplkr5d4sdn7q6csigrhnljjpp8j4qfsh"))))
10223 (build-system ruby-build-system)
10224 (arguments
10225 '(#:tests? #f)) ; need Codecov
10226 (synopsis "Port of the smart-quotes library SmartyPants")
10227 (description
10228 "RubyPants is a Ruby port of the smart-quotes library SmartyPants. The
10229original SmartyPants is a web publishing plug-in for Movable Type, Blosxom,
10230and BBEdit that easily translates plain ASCII punctuation characters into
10231smart typographic punctuation HTML entities.")
10232 (home-page "https://github.com/jmcnevin/rubypants")
10233 (license license:bsd-2)))
beb34835
CL
10234
10235(define-public ruby-org-ruby
10236 (package
10237 (name "ruby-org-ruby")
10238 (version "0.9.12")
10239 (source (origin
10240 (method url-fetch)
10241 (uri (rubygems-uri "org-ruby" version))
10242 (sha256
10243 (base32
10244 "0x69s7aysfiwlcpd9hkvksfyld34d8kxr62adb59vjvh8hxfrjwk"))))
10245 (build-system ruby-build-system)
10246 (arguments
10247 '(#:tests? #f)) ; no rakefile
10248 (propagated-inputs
10249 `(("ruby-rubypants" ,ruby-rubypants)))
10250 (synopsis "Org-mode parser written in Ruby")
10251 (description
10252 "Org-ruby is an org-mode parser written in Ruby. The most significant
10253thing this library does today is convert org-mode files to HTML or Textile or
10254Markdown.")
10255 (home-page "https://github.com/wallyqs/org-ruby")
10256 (license license:expat)))
670ee20a
BW
10257
10258(define-public ruby-rake
10259 (package
10260 (name "ruby-rake")
c997403a 10261 (version "13.0.1")
670ee20a
BW
10262 (source
10263 (origin
10264 (method url-fetch)
10265 (uri (rubygems-uri "rake" version))
10266 (sha256
10267 (base32
c997403a 10268 "0w6qza25bq1s825faaglkx1k6d59aiyjjk3yw3ip5sb463mhhai9"))))
670ee20a
BW
10269 (build-system ruby-build-system)
10270 (native-inputs
10271 `(("bundler" ,bundler)))
10272 (synopsis "Rake is a Make-like program implemented in Ruby")
10273 (description
10274 "Rake is a Make-like program where tasks and dependencies are specified
10275in standard Ruby syntax.")
10276 (home-page "https://github.com/ruby/rake")
10277 (license license:expat)))
45498f51 10278
51420124 10279(define-public ruby-childprocess
45498f51
DM
10280 (package
10281 (name "ruby-childprocess")
459e4a1a 10282 (version "3.0.0")
45498f51
DM
10283 (source
10284 (origin
10285 (method url-fetch)
10286 (uri (rubygems-uri "childprocess" version))
10287 (sha256
10288 (base32
459e4a1a 10289 "1ic028k8xgm2dds9mqnvwwx3ibaz32j8455zxr9f4bcnviyahya5"))))
45498f51
DM
10290 (build-system ruby-build-system)
10291 (arguments
10292 `(#:tests? #f))
10293 (native-inputs
10294 `(("bundler" ,bundler)
10295 ("ruby-rspec" ,ruby-rspec)))
10296 (propagated-inputs
10297 `(("ruby-ffi" ,ruby-ffi)))
10298 (synopsis "Control external programs running in the background, in Ruby")
10299 (description "@code{childprocess} provides a gem to control external
10300programs running in the background, in Ruby.")
459e4a1a 10301 (home-page "https://github.com/enkessler/childprocess")
45498f51 10302 (license license:expat)))
1f10e28d 10303
0d16905b
JL
10304(define-public ruby-public-suffix
10305 (package
10306 (name "ruby-public-suffix")
70e4fcfe 10307 (version "4.0.5")
0d16905b
JL
10308 (source (origin
10309 (method url-fetch)
10310 (uri (rubygems-uri "public_suffix" version))
10311 (sha256
10312 (base32
70e4fcfe 10313 "0vywld400fzi17cszwrchrzcqys4qm6sshbv73wy5mwcixmrgg7g"))))
0d16905b
JL
10314 (build-system ruby-build-system)
10315 (arguments
1f4fc125
CB
10316 '(#:phases
10317 (modify-phases %standard-phases
10318 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
10319 ;; including it as an input can lead to circular dependencies.
10320 (add-after 'unpack 'remove-rubocop-from-Rakefile
10321 (lambda _
10322 (substitute* "Rakefile"
10323 (("require \"rubocop/rake\\_task\"") "")
10324 (("RuboCop::RakeTask\\.new") ""))
10325 #t)))))
10326 (native-inputs
10327 `(("bundler" ,bundler)
10328 ("ruby-yard" ,ruby-yard)
10329 ("ruby-mocha" ,ruby-mocha)
10330 ("ruby-minitest-reporters" ,ruby-minitest-reporters)))
0d16905b
JL
10331 (home-page "https://simonecarletti.com/code/publicsuffix-ruby/")
10332 (synopsis "Domain name parser")
10333 (description "The gem @code{public_suffix} is a domain name parser,
10334written in Ruby, and based on the @dfn{Public Suffix List}. A public suffix
10335is one under which Internet users can (or historically could) directly
10336register names. Some examples of public suffixes are @code{.com},
10337@code{.co.uk} and @code{pvt.k12.ma.us}. The Public Suffix List is a list of
10338all known public suffixes.")
10339 (license license:expat)))
6f2c4efb
JL
10340
10341(define-public ruby-addressable
10342 (package
10343 (name "ruby-addressable")
91f7ee87 10344 (version "2.7.0")
6f2c4efb
JL
10345 (source (origin
10346 (method url-fetch)
10347 (uri (rubygems-uri "addressable" version))
10348 (sha256
10349 (base32
91f7ee87 10350 "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy"))))
6f2c4efb 10351 (build-system ruby-build-system)
0a794b30
CB
10352 (arguments
10353 '(#:test-target "spec"
10354 #:phases
10355 (modify-phases %standard-phases
10356 (add-after 'unpack 'remove-unnecessary-dependencies-from-Gemfile
10357 (lambda _
10358 (substitute* "Gemfile"
10359 (("git: 'https://github.com/sporkmonger/rack-mount.git',") "")
10360 ((".*launchy.*") "")
10361 ((".*rake.*") "gem 'rake'\n")
10362 ((".*redcarpet.*") ""))
10363 #t))
10364 (add-before 'check 'delete-network-dependent-test
10365 (lambda _
10366 (delete-file "spec/addressable/net_http_compat_spec.rb")
10367 #t)))))
10368 (native-inputs
10369 `(("ruby-rspec" ,ruby-rspec)
10370 ("bundler" ,bundler)
10371 ("ruby-idn-ruby" ,ruby-idn-ruby)
10372 ("ruby-sporkmonger-rack-mount" ,ruby-sporkmonger-rack-mount)
1628d57b 10373 ("ruby-rspec-its" ,ruby-rspec-its-minimal)
0a794b30
CB
10374 ("ruby-yard" ,ruby-yard)
10375 ("ruby-simplecov" ,ruby-simplecov)))
6f2c4efb
JL
10376 (propagated-inputs
10377 `(("ruby-public-suffix" ,ruby-public-suffix)))
6f2c4efb
JL
10378 (home-page "https://github.com/sporkmonger/addressable")
10379 (synopsis "Alternative URI implementation")
10380 (description "Addressable is a replacement for the URI implementation that
10381is part of Ruby's standard library. It more closely conforms to RFC 3986,
10382RFC 3987, and RFC 6570 (level 4), providing support for IRIs and URI templates.")
10383 (license license:asl2.0)))
9c7f15c0 10384
305e9b33
MB
10385(define-public ruby-colorize
10386 (package
10387 (name "ruby-colorize")
10388 (version "0.8.1")
10389 (source (origin
10390 (method url-fetch)
10391 (uri (rubygems-uri "colorize" version))
10392 (sha256
10393 (base32
10394 "133rqj85n400qk6g3dhf2bmfws34mak1wqihvh3bgy9jhajw580b"))))
10395 (build-system ruby-build-system)
10396 (arguments
10397 '(#:phases (modify-phases %standard-phases
10398 (add-before 'check 'remove-codeclimate-dependency
10399 (lambda _
10400 (substitute* "test/test_colorize.rb"
10401 ;; Do not hook the tests into the online CodeClimate
10402 ;; service which is unnecessary for these tests.
10403 (("require 'codeclimate-test-reporter'")
10404 "")
10405 (("CodeClimate.*") ""))
10406 #t)))))
10407 (synopsis "Add color effects to the @code{String} class")
10408 (description
10409 "This package extends the @code{String} class and adds a
10410@code{ColorizedString} with methods to set text color, background color,
10411and text effects.")
702a1012 10412 (home-page "https://github.com/fazibear/colorize")
305e9b33
MB
10413 (license license:gpl2+)))
10414
9c7f15c0
JL
10415(define-public ruby-colorator
10416 (package
10417 (name "ruby-colorator")
10418 (version "1.1.0")
10419 (source (origin
10420 (method url-fetch)
10421 (uri (rubygems-uri "colorator" version))
10422 (sha256
10423 (base32
10424 "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"))))
10425 (build-system ruby-build-system)
10426 (arguments
10427 ;; No test target
10428 `(#:tests? #f))
10429 (home-page "http://octopress.org/colorator/")
10430 (synopsis "Terminal color library")
10431 (description "Colorator is a Ruby gem that helps you colorize your text
10432for the terminal.")
10433 (license license:expat)))
78b9c291
JL
10434
10435(define-public ruby-command-line-reporter
10436 (package
10437 (name "ruby-command-line-reporter")
b448e408 10438 (version "4.0.1")
78b9c291
JL
10439 (source (origin
10440 (method url-fetch)
10441 (uri (rubygems-uri "command_line_reporter" version))
10442 (sha256
10443 (base32
b448e408 10444 "1l0zxkh5n9dxfw46lpkg416ljpldlq1bgdhqh0d118dk338nz4ll"))))
78b9c291
JL
10445 (build-system ruby-build-system)
10446 (arguments
10447 ;; No Rakefile
10448 `(#:tests? #f
10449 #:phases
10450 (modify-phases %standard-phases
10451 (add-before 'build 'fix-dependencies
10452 (lambda _
10453 (substitute* ".gemspec"
10454 ;; colored is unmaintained
10455 (("colored") "colorator")
10456 ;; colorator version
10457 (("= 1.2") "= 1.1"))
10458 #t)))))
10459 (propagated-inputs `(("ruby-colorator" ,ruby-colorator)))
10460 (home-page "https://github.com/wbailey/command_line_reporter")
10461 (synopsis "Report production while executing Ruby scripts")
10462 (description "This gem provides a DSL that makes it easy to write reports
10463of various types in ruby. It eliminates the need to litter your source with
10464puts statements, instead providing a more readable, expressive interface to
10465your application.")
10466 (license license:asl2.0)))
f22c0387
JL
10467
10468(define-public ruby-command-line-reporter-3
10469 (package
10470 (inherit ruby-command-line-reporter)
10471 (version "3.3.6")
10472 (source (origin
10473 (method url-fetch)
10474 (uri (rubygems-uri "command_line_reporter" version))
10475 (sha256
10476 (base32
10477 "1h39zqqxp3k4qk49ajpx0jps1vmvxgkh43mqkb6znk583bl0fv71"))))))
6bba8ecf 10478
439d47cd
MC
10479(define-public ruby-kpeg
10480 (package
10481 (name "ruby-kpeg")
10482 (version "1.1.0")
10483 (source
10484 (origin
10485 (method url-fetch)
10486 (uri (rubygems-uri "kpeg" version))
10487 (sha256
10488 (base32
10489 "0x2kpfrcagj931masm5y1kwbnc6nxl60cqdcd3lyd1d2hz7kzlia"))))
10490 (build-system ruby-build-system)
10491 (native-inputs
10492 `(("ruby-hoe" ,ruby-hoe)))
10493 (synopsis "PEG library for Ruby")
10494 (description "KPeg is a simple PEG library for Ruby. It provides an API as
10495well as native grammar to build the grammar. KPeg supports direct left
10496recursion of rules via the
10497@uref{http://www.vpri.org/pdf/tr2008003_experimenting.pdf,OMeta memoization}
10498technique.")
10499 (home-page "https://github.com/evanphx/kpeg")
10500 (license license:expat)))
10501
6bba8ecf
JL
10502(define-public ruby-rdoc
10503 (package
10504 (name "ruby-rdoc")
9304f989 10505 (version "6.2.0")
6bba8ecf 10506 (source
9304f989
MC
10507 (origin
10508 (method git-fetch)
10509 (uri (git-reference
b0e7b699 10510 (url "https://github.com/ruby/rdoc")
9304f989
MC
10511 (commit (string-append "v" version))))
10512 (file-name (git-file-name name version))
10513 (sha256
10514 (base32
10515 "0dhk29nidv93b5vnjvlm9gcixgn4i0jcyzrgxdk6pdg019bw4cj6"))))
6bba8ecf 10516 (build-system ruby-build-system)
9304f989
MC
10517 (arguments
10518 `(#:phases
10519 (modify-phases %standard-phases
10520 (add-after 'unpack 'patch-gemspec
10521 ;; TODO: Remove after next release is tagged.
10522 (lambda _
10523 (substitute* "rdoc.gemspec"
10524 (("\"lib/rdoc/generator/template/darkfish/js/\
10525jquery\\.js\", ") ""))
10526 #t))
10527 (add-before 'build 'generate
10528 ;; 'gem build' doesn't honor Rakefile dependencies (see:
10529 ;; https://github.com/ruby/rdoc/issues/432#issuecomment-650808977).
10530 (lambda _
10531 (invoke "rake" "generate"))))))
6bba8ecf 10532 (native-inputs
9304f989
MC
10533 `(("bundler" ,bundler)
10534 ("ruby-kpeg" ,ruby-kpeg)
10535 ("ruby-racc" ,ruby-racc)
10536 ("ruby-rubocop" ,ruby-rubocop)))
6bba8ecf
JL
10537 (home-page "https://ruby.github.io/rdoc/")
10538 (synopsis "HTML and command-line documentation utility")
10539 (description "RDoc produces HTML and command-line documentation for Ruby
10540projects. RDoc includes the +rdoc+ and +ri+ tools for generating and displaying
10541documentation from the command-line.")
10542 (license license:gpl2+)))
18077ffc
JL
10543
10544(define-public ruby-sass-listen
10545 (package
10546 (name "ruby-sass-listen")
10547 (version "4.0.0")
10548 (source (origin
10549 (method url-fetch)
10550 (uri (rubygems-uri "sass-listen" version))
10551 (sha256
10552 (base32
10553 "0xw3q46cmahkgyldid5hwyiwacp590zj2vmswlll68ryvmvcp7df"))))
10554 (build-system ruby-build-system)
10555 (arguments
10556 ;; No test target
10557 `(#:tests? #f))
10558 (propagated-inputs
10559 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
10560 ("ruby-rb-inotify" ,ruby-rb-inotify)))
10561 (home-page "https://github.com/sass/listen")
10562 (synopsis "File modification notification library")
10563 (description "The Listen gem listens to file modifications and notifies you
10564about the changes.")
10565 (license license:expat)))
0c8eedc1
JL
10566
10567(define-public ruby-terminfo
10568 (package
10569 (name "ruby-terminfo")
10570 (version "0.1.1")
10571 (source
10572 (origin
10573 (method url-fetch)
10574 (uri (rubygems-uri "ruby-terminfo" version))
10575 (sha256
10576 (base32
10577 "0rl4ic5pzvrpgd42z0c1s2n3j39c9znksblxxvmhkzrc0ckyg2cm"))))
10578 (build-system ruby-build-system)
10579 (arguments
10580 `(#:test-target "test"
10581 ;; Rakefile requires old packages and would need modification to
10582 ;; work with current software.
10583 #:tests? #f))
10584 (inputs
10585 `(("ncurses" ,ncurses)))
10586 (native-inputs
10587 `(("ruby-rubygems-tasks" ,ruby-rubygems-tasks)
10588 ("ruby-rdoc" ,ruby-rdoc)))
10589 (home-page "http://www.a-k-r.org/ruby-terminfo/")
10590 (synopsis "Terminfo binding for Ruby")
10591 (description "Ruby-terminfo provides terminfo binding for Ruby.")
10592 (license license:bsd-3)))
ddc3a667
JL
10593
10594(define-public ruby-diffy
10595 (package
10596 (name "ruby-diffy")
10597 (version "3.2.1")
10598 (source
10599 (origin
10600 (method url-fetch)
10601 (uri (rubygems-uri "diffy" version))
10602 (sha256
10603 (base32
10604 "119imrkn01agwhx5raxhknsi331y5i4yda7r0ws0an6905ximzjg"))))
10605 (build-system ruby-build-system)
10606 (arguments
10607 ;; No tests
10608 `(#:tests? #f))
10609 (native-inputs
10610 `(("ruby-rspec" ,ruby-rspec)))
10611 (home-page "https://github.com/samg/diffy")
10612 (synopsis "Convenient diffing in ruby")
10613 (description "Diffy provides a convenient way to generate a diff from two
10614strings or files.")
10615 (license license:expat)))
6456beef
JL
10616
10617(define-public ruby-sass-spec
10618 (package
10619 (name "ruby-sass-spec")
10620 (version "3.5.4")
11df8321
TGR
10621 (source
10622 (origin
10623 (method git-fetch)
10624 (uri (git-reference
b0e7b699 10625 (url "https://github.com/sass/sass-spec")
11df8321
TGR
10626 (commit (string-append "v" version))))
10627 (file-name (git-file-name name version))
10628 (sha256
10629 (base32 "1zsw66830w0xlc7kxz6fm4b5nyb44vdsdgm9mgy06s5aixx83pwr"))))
6456beef
JL
10630 (build-system ruby-build-system)
10631 (propagated-inputs
10632 `(("ruby-command-line-reporter-3" ,ruby-command-line-reporter-3)
10633 ("ruby-diffy" ,ruby-diffy)
10634 ("ruby-terminfo" ,ruby-terminfo)))
10635 (arguments
2c7cb711
CB
10636 `(;; This package contains tests for a sass implementation, and the to
10637 ;; avoid any circular dependencies, the tests are not run here
10638 #:tests? #f
10639 #:phases
10640 (modify-phases %standard-phases
10641 (add-after 'unpack 'patch-test
10642 (lambda _
10643 (delete-file "spec/values/colors/alpha_hex-3.5/error")
10644 (substitute* "spec/values/colors/alpha_hex-3.5/expected_output.css"
10645 (("string") "color")))))))
6456beef
JL
10646 (home-page "https://github.com/sass/sass-spec")
10647 (synopsis "Test suite for Sass")
10648 (description "Sass Spec is a test suite for Sass. Test cases are all in
10649the @file{spec} directory.")
10650 (license license:expat)))
f00f4492
JL
10651
10652(define-public ruby-sass
10653 (package
10654 (name "ruby-sass")
11ff2adc 10655 (version "3.6.0")
f00f4492
JL
10656 (source (origin
10657 (method url-fetch)
10658 (uri (rubygems-uri "sass" version))
10659 (sha256
10660 (base32
11ff2adc 10661 "18c6prbw9wl8bqhb2435pd9s0lzarl3g7xf8pmyla28zblvwxmyh"))))
f00f4492
JL
10662 (build-system ruby-build-system)
10663 (propagated-inputs
10664 `(("ruby-sass-listen" ,ruby-sass-listen)))
10665 (native-inputs
11ff2adc
CB
10666 `(("ruby-sass-spec" ,ruby-sass-spec)
10667 ("ruby-mathn" ,ruby-mathn)))
3497086b 10668 (home-page "https://sass-lang.com/")
f00f4492
JL
10669 (synopsis "CSS extension language")
10670 (description "Sass is a CSS extension language. It extends CSS with
10671features that don't exist yet like variables, nesting, mixins and inheritance.")
10672 (license license:expat)))
5e242cb4 10673
9efc888d
CB
10674(define-public ruby-sassc
10675 (package
10676 (name "ruby-sassc")
c7358514 10677 (version "2.4.0")
9efc888d
CB
10678 (source
10679 (origin
10680 (method url-fetch)
10681 (uri (rubygems-uri "sassc" version))
10682 (sha256
10683 (base32
c7358514 10684 "0gpqv48xhl8mb8qqhcifcp0pixn206a7imc07g48armklfqa4q2c"))))
9efc888d
CB
10685 (build-system ruby-build-system)
10686 (arguments
3e776b44
CB
10687 '(#:modules ((guix build ruby-build-system)
10688 (guix build utils)
10689 (ice-9 textual-ports))
10690 #:phases
9efc888d
CB
10691 (modify-phases %standard-phases
10692 ;; TODO: This would be better as a snippet, but the ruby-build-system
10693 ;; doesn't seem to support that
10694 (add-after 'unpack 'remove-libsass
10695 (lambda _
10696 (delete-file-recursively "ext")
3e776b44
CB
10697 (with-atomic-file-replacement "sassc.gemspec"
10698 (lambda (in out)
10699 (let* ((gemspec (get-string-all in))
10700 (index (string-contains gemspec "libsass_dir")))
10701 (display (string-append
10702 (string-take gemspec index)
10703 "\nend\n")
10704 out))))
9efc888d
CB
10705 #t))
10706 (add-after 'unpack 'dont-check-the-libsass-version
10707 (lambda _
10708 (substitute* "test/native_test.rb"
10709 (("assert_equal.*Native\\.version") ""))
10710 #t))
10711 (add-after 'unpack 'remove-git-from-gemspec
10712 (lambda _
10713 (substitute* "sassc.gemspec"
3e776b44 10714 (("`git ls-files -z`") "`find . -type f -print0 |sort -z`"))
9efc888d
CB
10715 #t))
10716 (add-after 'unpack 'remove-extensions-from-gemspec
10717 (lambda _
10718 (substitute* "sassc.gemspec"
3e776b44 10719 (("\\[\"ext/extconf.rb\"\\]") "[]"))
9efc888d
CB
10720 #t))
10721 (add-after 'unpack 'fix-Rakefile
10722 (lambda _
10723 (substitute* "Rakefile"
3e776b44 10724 (("test: 'compile:libsass'") ":test"))
9efc888d
CB
10725 #t))
10726 (add-after 'unpack 'remove-unnecessary-dependencies
10727 (lambda _
10728 (substitute* "test/test_helper.rb"
10729 (("require \"pry\"") ""))
10730 #t))
10731 (add-before 'build 'patch-native.rb
10732 (lambda* (#:key inputs #:allow-other-keys)
10733 (substitute* "lib/sassc/native.rb"
10734 ((".*gem_root = spec.gem_dir") "")
10735 (("ffi_lib .*\n")
10736 (string-append
10737 "ffi_lib '" (assoc-ref inputs "libsass") "/lib/libsass.so'")))
10738 #t))
10739 ;; The gemspec still references the libsass files, so just keep the
10740 ;; one in the gem.
10741 (delete 'extract-gemspec))))
10742 (propagated-inputs
10743 `(("ruby-ffi" ,ruby-ffi)
10744 ("ruby-rake" ,ruby-rake)))
10745 (inputs
10746 `(("libsass" ,libsass)))
10747 (native-inputs
10748 `(("bundler" ,bundler)
3e776b44 10749 ("ruby-rake-compiler" ,ruby-rake-compiler)
9efc888d
CB
10750 ("ruby-minitest-around" ,ruby-minitest-around)
10751 ("ruby-test-construct" ,ruby-test-construct)))
10752 (synopsis "Use libsss from Ruby")
10753 (description
10754 "This library provides Ruby q@acronym{FFI, Foreign Function Interface}
10755bindings to the libsass library. This enables rendering
10756@acronym{SASS,Syntactically awesome style sheets} from Ruby code.")
10757 (home-page "https://github.com/sass/sassc-ruby")
10758 (license license:expat)))
10759
5e242cb4
JL
10760(define-public ruby-jekyll-sass-converter
10761 (package
10762 (name "ruby-jekyll-sass-converter")
d603db90 10763 (version "2.1.0")
5e242cb4
JL
10764 (source (origin
10765 (method url-fetch)
10766 (uri (rubygems-uri "jekyll-sass-converter" version))
10767 (sha256
10768 (base32
d603db90 10769 "04ncr44wrilz26ayqwlg7379yjnkb29mvx4j04i62b7czmdrc9dv"))))
5e242cb4
JL
10770 (build-system ruby-build-system)
10771 (propagated-inputs
10772 `(("ruby-sass" ,ruby-sass)))
10773 (arguments
10774 ;; No rakefile
10775 `(#:tests? #f))
10776 (home-page "https://github.com/jekyll/jekyll-sass-converter")
10777 (synopsis "Sass converter for Jekyll")
10778 (description "This gem provide built-in support for the Sass converter
10779in Jekyll.")
10780 (license license:expat)))
ceac6f6f
JL
10781
10782(define-public ruby-jekyll-watch
10783 (package
10784 (name "ruby-jekyll-watch")
6cbba8a3 10785 (version "2.1.2")
ceac6f6f
JL
10786 (source (origin
10787 (method url-fetch)
10788 (uri (rubygems-uri "jekyll-watch" version))
10789 (sha256
10790 (base32
6cbba8a3 10791 "1s9ly83sp8albvgdff12xy2h4xd8lm6z2fah4lzmk2yvp85jzdzv"))))
ceac6f6f
JL
10792 (build-system ruby-build-system)
10793 (propagated-inputs
6cbba8a3 10794 `(("ruby-listen" ,ruby-listen)))
ceac6f6f
JL
10795 (arguments
10796 ;; No rakefile
10797 `(#:tests? #f))
10798 (home-page "https://github.com/jekyll/jekyll-watch")
10799 (synopsis "Jekyll auto-rebuild support")
10800 (description "This gems add the @code{--watch} switch to the jekyll CLI
10801interface. It allows Jekyll to rebuild your site when a file changes.")
10802 (license license:expat)))
3224a5a8
JL
10803
10804(define-public ruby-parallel
10805 (package
10806 (name "ruby-parallel")
c41fba01
CB
10807 (version "1.13.0")
10808 (source
10809 (origin
10810 (method git-fetch)
10811 (uri (git-reference
b0e7b699 10812 (url "https://github.com/grosser/parallel")
c41fba01
CB
10813 (commit (string-append "v" version))))
10814 (file-name (git-file-name name version))
10815 (sha256
10816 (base32
10817 "1isqzbqxz2ndad4i5z3lb9ldrhaijfncj8bmffv04sq44sv87ikv"))))
3224a5a8 10818 (build-system ruby-build-system)
c41fba01
CB
10819 (arguments
10820 `(;; TODO 3 test failures
10821 ;; rspec ./spec/parallel_spec.rb:190 # Parallel.in_processes does not
10822 ;; open unnecessary pipes
10823 ;; rspec './spec/parallel_spec.rb[1:9:7]' # Parallel.each works with
10824 ;; SQLite in processes
10825 ;; rspec './spec/parallel_spec.rb[1:9:16]' # Parallel.each works with
10826 ;; SQLite in threads
10827 #:tests? #f
10828 #:test-target "rspec-rerun:spec"
10829 #:phases
10830 (modify-phases %standard-phases
10831 (add-after 'unpack 'patch-Gemfile
10832 (lambda _
10833 (substitute* "Gemfile"
10834 (("gem 'rspec-legacy_formatters'") "")
10835 (("gem 'activerecord.*$") "gem 'activerecord'\n"))))
10836 (add-before 'check 'delete-Gemfile.lock
10837 (lambda _
10838 ;; Bundler isn't being used for fetching dependendencies, so
10839 ;; delete the Gemfile.lock
10840 (delete-file "Gemfile.lock")
10841 #t))
10842 (add-before 'build 'patch-gemspec
10843 (lambda _
10844 (substitute* "parallel.gemspec"
10845 (("git ls-files") "find"))
10846 #t)))))
10847 (native-inputs
10848 `(("ruby-rspec" ,ruby-rspec)
10849 ("ruby-rspec-rerun" ,ruby-rspec-rerun)
10850 ("bundler" ,bundler)
10851 ("ruby-activerecord" ,ruby-activerecord)
10852 ("ruby-progressbar" ,ruby-progressbar)
10853 ("ruby-bump" ,ruby-bump)
10854 ("procps" ,procps)
10855 ("lsof" ,lsof)
10856 ("ruby-mysql2" ,ruby-mysql2)
10857 ("ruby-sqlite3" ,ruby-sqlite3)
10858 ("ruby-i18n" ,ruby-i18n)))
3224a5a8
JL
10859 (home-page "https://github.com/grosser/parallel")
10860 (synopsis "Parallel processing in Ruby")
10861 (description "Parallel allows you to run any code in parallel Processes
10862(to use all CPUs) or Threads(to speedup blocking operations). It is best
10863suited for map-reduce or e.g. parallel downloads/uploads.")
10864 (license license:expat)))
83d9f672
JL
10865
10866(define-public ruby-cane
10867 (package
10868 (name "ruby-cane")
10869 (version "3.0.0")
10870 (source (origin
10871 (method url-fetch)
10872 (uri (rubygems-uri "cane" version))
10873 (sha256
10874 (base32
10875 "0yf5za3l7lhrqa3g56sah73wh33lbxy5y3cb7ij0a2bp1b4kwhih"))))
10876 (build-system ruby-build-system)
10877 (arguments `(#:tests? #f)); No rakefile
10878 (home-page "https://github.com/square/cane")
10879 (propagated-inputs
10880 `(("ruby-parallel" ,ruby-parallel)))
10881 (synopsis "Code quality threshold checking")
10882 (description "Cane fails your build if code quality thresholds are not met.")
10883 (license license:asl2.0)))
00d71efc
JL
10884
10885(define-public ruby-morecane
10886 (package
10887 (name "ruby-morecane")
10888 (version "0.2.0")
10889 (source (origin
10890 (method url-fetch)
10891 (uri (rubygems-uri "morecane" version))
10892 (sha256
10893 (base32
10894 "0w70vb8z5bdhvr21h660aa43m5948pv0bd27z7ngai2iwdvqd771"))))
10895 (build-system ruby-build-system)
10896 (home-page "https://github.com/yob/morecane")
10897 (arguments `(#:tests? #f)); No rakefile
10898 (propagated-inputs
10899 `(("ruby-parallel" ,ruby-parallel)))
10900 (synopsis "Extra checks for cane")
10901 (description "The cane gem provides a great framework for running quality
10902checks over your ruby project as part of continuous integration build. It
10903comes with a few checks out of the box, but also provides an API for loading
10904custom checks. This gem provides a set of additional checks.")
10905 (license license:expat)))
abbe629c
JL
10906
10907(define-public ruby-pdf-reader
10908 (package
10909 (name "ruby-pdf-reader")
b377dd95 10910 (version "2.4.0")
abbe629c 10911 (source (origin
34796d7a
MC
10912 (method git-fetch) ;no test in distributed gem archive
10913 (uri (git-reference
8ed4c468 10914 (url "https://github.com/yob/pdf-reader")
34796d7a
MC
10915 (commit (string-append "v" version))))
10916 (file-name (git-file-name name version))
abbe629c
JL
10917 (sha256
10918 (base32
34796d7a 10919 "1yh8yrlssf5ppnkvk4m78vmh5r5vqwdcd0gm3lqipw162llz0rai"))))
abbe629c 10920 (build-system ruby-build-system)
34796d7a
MC
10921 (arguments `(#:test-target "spec"
10922 #:phases (modify-phases %standard-phases
10923 (add-after 'unpack 'do-not-use-bundler
10924 (lambda _
10925 (substitute* "spec/spec_helper.rb"
10926 ((".*[Bb]undler.*") ""))
10927 #t)))))
abbe629c 10928 (native-inputs
34796d7a 10929 `(("ruby-rspec" ,ruby-rspec)
abbe629c
JL
10930 ("ruby-cane" ,ruby-cane)
10931 ("ruby-morecane" ,ruby-morecane)))
10932 (propagated-inputs
10933 `(("ruby-afm" ,ruby-afm)
10934 ("ruby-ascii85" ,ruby-ascii85)
10935 ("ruby-hashery" ,ruby-hashery)
10936 ("ruby-rc4" ,ruby-rc4)
10937 ("ruby-ttfunk" ,ruby-ttfunk)))
10938 (home-page "https://github.com/yob/pdf-reader")
10939 (synopsis "PDF parser in Ruby")
10940 (description "The PDF::Reader library implements a PDF parser conforming as
10941much as possible to the PDF specification from Adobe. It provides programmatic
10942access to the contents of a PDF file with a high degree of flexibility.")
10943 (license license:gpl3+)))
461fb859
JL
10944
10945(define-public ruby-pdf-inspector
ed2f26f8
MC
10946 (let ((revision "1")
10947 (commit "00ee4c92ff917118785ebec188e81effc968abeb"))
10948 (package
10949 (name "ruby-pdf-inspector")
10950 (version (git-version "1.3.0" revision commit))
10951 (source (origin
10952 (method git-fetch)
10953 (uri (git-reference
8ed4c468 10954 (url "https://github.com/prawnpdf/pdf-inspector")
ed2f26f8
MC
10955 (commit commit)))
10956 (file-name (git-file-name name version))
10957 (sha256
10958 (base32
10959 "0h9w81ddd0gvkh5n2cvny9ddb5qiac1si0dhinkk0xxh5382qs0m"))))
10960 (build-system ruby-build-system)
10961 (arguments
10962 `(#:test-target "spec"
10963 #:phases (modify-phases %standard-phases
10964 (add-before 'build 'drop-signing-key-requirement
10965 (lambda _
10966 (substitute* "pdf-inspector.gemspec"
10967 (("spec.signing_key =.*")
10968 "spec.signing_key = nil"))
10969 #t))
10970 (replace 'check
10971 (lambda _
10972 (substitute* "pdf-inspector.gemspec"
10973 ((".*rubocop.*") "")
10974 ((".*yard.*") ""))
10975 (invoke "rspec"))))))
10976 (native-inputs
10977 `(("ruby-rspec" ,ruby-rspec)))
10978 (propagated-inputs
10979 `(("ruby-pdf-reader" ,ruby-pdf-reader)))
10980 (home-page "https://github.com/prawnpdf/pdf-inspector")
10981 (synopsis "Analysis classes for inspecting PDF output")
10982 (description "This library provides a number of PDF::Reader based tools for
461fb859
JL
10983use in testing PDF output. Presently, the primary purpose of this tool is to
10984support the tests found in Prawn, a pure Ruby PDF generation library.")
ed2f26f8 10985 (license %prawn-project-licenses))))
770e3b53
JL
10986
10987(define-public ruby-pdf-core
10988 (package
10989 (name "ruby-pdf-core")
10990 (version "0.8.1")
10991 (source (origin
10992 (method url-fetch)
10993 (uri (rubygems-uri "pdf-core" version))
10994 (sha256
10995 (base32
10996 "15d6m99bc8bbzlkcg13qfpjjzphfg5x905pjbfygvpcxsm8gnsvg"))))
10997 (build-system ruby-build-system)
10998 (arguments
10999 ; No test target
11000 `(#:tests? #f))
11001 (home-page "https://github.com/prawnpdf/pdf-core")
11002 (synopsis "Low level PDF features for Prawn")
11003 (description "This is an experimental gem that extracts low-level PDF
11004functionality from Prawn.")
11005 (license license:gpl3+)))
37fbced7 11006
7ad8dd08 11007(define-public ruby-prawn
e6c7a601
MC
11008 ;; There hasn't been a new release since 2017/03/17.
11009 (let ((revision "1")
11010 (commit "d980247be8a00e7c59cd4e5785e3aa98f9856db1"))
11011 (package
11012 (name "ruby-prawn")
11013 (version (git-version "2.2.2" revision commit))
11014 (source (origin
11015 (method git-fetch)
11016 (uri (git-reference
8ed4c468 11017 (url "https://github.com/prawnpdf/prawn")
e6c7a601
MC
11018 (commit commit)))
11019 (file-name (git-file-name name version))
11020 (sha256
11021 (base32
11022 "0mcmvf22h8il93yq48v9f31qpy27pvjxgv9172p0f4x9lqy0imwr"))))
11023 (build-system ruby-build-system)
11024 (arguments
11025 `(#:phases
11026 (modify-phases %standard-phases
11027 (add-before 'build 'drop-signing-key-requirement
11028 (lambda _
11029 (substitute* "prawn.gemspec"
11030 (("spec.signing_key =.*")
11031 "spec.signing_key = nil"))
11032 #t))
11033 (replace 'check
11034 (lambda* (#:key tests? #:allow-other-keys)
11035 (when tests?
11036 ;; The Prawn manual test fails (see:
11037 ;; https://github.com/prawnpdf/prawn/issues/1163), so exclude
11038 ;; it.
11039 (invoke "rspec" "--exclude-pattern" "prawn_manual_spec.rb"))
11040 #t)))))
11041 (propagated-inputs
11042 `(("ruby-pdf-core" ,ruby-pdf-core)
11043 ("ruby-ttfunk" ,ruby-ttfunk)))
11044 (native-inputs
11045 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
11046 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
11047 ("ruby-rspec" ,ruby-rspec)
11048 ("ruby-simplecov" ,ruby-simplecov)
11049 ("ruby-yard" ,ruby-yard)))
11050 (home-page "https://prawnpdf.org/api-docs/2.0/")
11051 (synopsis "PDF generation for Ruby")
11052 (description "Prawn is a pure Ruby PDF generation library.")
11053 (license %prawn-project-licenses))))
197ca8ec
JL
11054
11055(define-public ruby-prawn-table
11056 (package
11057 (name "ruby-prawn-table")
11058 (version "0.2.2")
11059 (source (origin
11060 (method url-fetch)
11061 (uri (rubygems-uri "prawn-table" version))
11062 (sha256
11063 (base32
11064 "1nxd6qmxqwl850icp18wjh5k0s3amxcajdrkjyzpfgq0kvilcv9k"))))
11065 (build-system ruby-build-system)
197ca8ec 11066 (propagated-inputs
0927b039
CB
11067 `(("ruby-prawn" ,ruby-prawn)
11068 ("ruby-pdf-inspector" ,ruby-pdf-inspector)))
11069 (native-inputs
11070 `(("bundler" ,bundler)
11071 ("ruby-yard" ,ruby-yard)
11072 ("ruby-mocha" ,ruby-mocha)
11073 ("ruby-coderay" ,ruby-coderay)
11074 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
11075 ("ruby-simplecov" ,ruby-simplecov)
11076 ("ruby-rspec-2" ,ruby-rspec-2)))
11077 (arguments
11078 '(;; TODO: 1 test fails
11079 ;; Failure/Error: pdf.page_count.should == 1
11080 ;; expected: 1
11081 ;; got: 2 (using ==)
11082 ;; # ./spec/table_spec.rb:1308
11083 ;;
11084 ;; 225 examples, 1 failure
11085 #:tests? #f
11086 #:phases
11087 (modify-phases %standard-phases
11088 (add-before 'check 'patch-gemspec
11089 (lambda _
11090 (substitute* "prawn-table.gemspec"
11091 ;; Loosen the requirement for pdf-inspector
11092 (("~> 1\\.1\\.0") ">= 0")
11093 ;; Loosen the requirement for pdf-reader
11094 (("~> 1\\.2") ">= 0"))))
11095 (replace 'check
11096 (lambda* (#:key tests? #:allow-other-keys)
11097 (when tests?
11098 (invoke "rspec"))
11099 #t)))))
197ca8ec
JL
11100 (home-page "https://github.com/prawnpdf/prawn-table")
11101 (synopsis "Tables support for Prawn")
11102 (description "This gem provides tables support for Prawn.")
11103 (license license:gpl3+)))
03127069
JL
11104
11105(define-public ruby-kramdown
11106 (package
11107 (name "ruby-kramdown")
2b5b7809 11108 (version "2.3.0")
03127069
JL
11109 (source (origin
11110 (method url-fetch)
11111 (uri (rubygems-uri "kramdown" version))
11112 (sha256
11113 (base32
2b5b7809 11114 "1vmw752c26ny2jwl0npn0gbyqwgz4hdmlpxnsld9qi9xhk5b1qh7"))))
03127069
JL
11115 (build-system ruby-build-system)
11116 (arguments `(#:tests? #f)); FIXME: some test failures
11117 (native-inputs
11118 `(("ruby-prawn" ,ruby-prawn)
11119 ("ruby-prawn-table" ,ruby-prawn-table)))
11120 (home-page "https://kramdown.gettalong.org/")
11121 (synopsis "Markdown parsing and converting library")
11122 (description "Kramdown is a library for parsing and converting a superset
11123of Markdown. It is completely written in Ruby, supports standard Markdown
11124(with some minor modifications) and various extensions that have been made
11125popular by the PHP @code{Markdown Extra} package and @code{Maruku}.")
11126 (license license:expat)))
fa0063bc 11127
e1cab74a
MR
11128(define-public ruby-kramdown-parser-gfm
11129 (package
11130 (name "ruby-kramdown-parser-gfm")
11131 (version "1.1.0")
11132 (source
11133 (origin
11134 (method url-fetch)
11135 (uri (rubygems-uri "kramdown-parser-gfm" version))
11136 (sha256
11137 (base32 "0a8pb3v951f4x7h968rqfsa19c8arz21zw1vaj42jza22rap8fgv"))))
11138 (build-system ruby-build-system)
11139 (arguments
11140 `(#:tests? #f)) ;no rakefile
11141 (propagated-inputs
11142 `(("ruby-kramdown" ,ruby-kramdown)))
11143 (synopsis "Kramdown parser for the GFM dialect of Markdown")
11144 (description
11145 "This is a parser for kramdown that converts Markdown documents in the
11146GFM dialect to HTML.")
11147 (home-page "https://github.com/kramdown/parser-gfm")
11148 (license license:expat)))
11149
fa0063bc
JL
11150(define-public ruby-http-parser.rb
11151 (package
11152 (name "ruby-http-parser.rb")
11153 (version "0.6.0")
11154 (source
11155 (origin
11156 (method url-fetch)
11157 (uri (rubygems-uri "http_parser.rb" version))
11158 (sha256
11159 (base32
11160 "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"))))
11161 (build-system ruby-build-system)
11162 (arguments
11163 ;; No tests
11164 `(#:tests? #f))
11165 (native-inputs
11166 `(("ruby-rake-compiler" ,ruby-rake-compiler)
11167 ("ruby-rspec" ,ruby-rspec)))
11168 (home-page "https://github.com/tmm1/http_parser.rb")
11169 (synopsis "HTTP parser un Ruby")
11170 (description "This gem is a simple callback-based HTTP request/response
11171parser for writing http servers, clients and proxies.")
11172 (license license:expat)))
5e2f74bd
JL
11173
11174(define-public ruby-em-websocket
11175 (package
11176 (name "ruby-em-websocket")
11177 (version "0.5.1")
11178 (source
11179 (origin
11180 (method url-fetch)
11181 (uri (rubygems-uri "em-websocket" version))
11182 (sha256
11183 (base32
11184 "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"))))
11185 (build-system ruby-build-system)
11186 (arguments
11187 ;; No tests
11188 `(#:tests? #f))
11189 (propagated-inputs
11190 `(("ruby-eventmachine" ,ruby-eventmachine)
11191 ("ruby-http-parser.rb" ,ruby-http-parser.rb)))
11192 (native-inputs
11193 `(("bundler" ,bundler)
11194 ("ruby-rspec" ,ruby-rspec)))
11195 (home-page "https://github.com/igrigorik/em-websocket")
11196 (synopsis "EventMachine based WebSocket server")
11197 (description "Em-websocket is an EventMachine based WebSocket server
11198implementation.")
11199 (license license:expat)))
4ce0414b
JL
11200
11201(define-public ruby-rouge
11202 (package
11203 (name "ruby-rouge")
22d6b534 11204 (version "3.21.0")
4ce0414b
JL
11205 (source (origin
11206 (method url-fetch)
11207 (uri (rubygems-uri "rouge" version))
11208 (sha256
11209 (base32
22d6b534 11210 "1agrrmj88k9jkk36ra1ml2c1jffpp595pkxmcla74ac9ia09vn3s"))))
4ce0414b
JL
11211 (build-system ruby-build-system)
11212 (arguments `(#:tests? #f)); No rakefile
11213 (home-page "http://rouge.jneen.net/")
11214 (synopsis "Code highlighter")
11215 (description "Rouge is a code highlighter written in Ruby. It supports more
11216than 100 languages and outputs HTML or ANSI 256-color text. Its HTML output
11217is compatible with stylesheets designed for pygments.")
11218 (license (list
11219 ;; rouge is licensed under expat
11220 license:expat
11221 ;; pygments is licensed under bsd-2
11222 license:bsd-2))))
2c5028bd 11223
2e072e37
JL
11224(define-public ruby-hashie
11225 (package
11226 (name "ruby-hashie")
11227 (version "3.6.0")
11228 (source (origin
11229 (method url-fetch)
11230 (uri (rubygems-uri "hashie" version))
11231 (sha256
11232 (base32
11233 "13bdzfp25c8k51ayzxqkbzag3wj5gc1jd8h7d985nsq6pn57g5xh"))))
11234 (build-system ruby-build-system)
11235 (native-inputs
11236 `(("bundler" ,bundler)))
11237 (arguments `(#:tests? #f)); FIXME: Could not locate Gemfile or .bundle/ directory
11238 (home-page "https://github.com/intridea/hashie")
11239 (synopsis "Extensions to Ruby Hashes")
11240 (description "Hashie is a collection of classes and mixins that make Ruby
11241hashes more powerful.")
11242 (license license:expat)))
73bfc125
JL
11243
11244(define-public ruby-heredoc-unindent
11245 (package
11246 (name "ruby-heredoc-unindent")
11247 (version "1.2.0")
11248 (source (origin
11249 (method url-fetch)
11250 (uri (rubygems-uri "heredoc_unindent" version))
11251 (sha256
11252 (base32
11253 "14ijr2fsjwhrkjkcaz81d5xnfa4vvgvcflrff83avqw9klm011yw"))))
11254 (build-system ruby-build-system)
11255 (native-inputs
11256 `(("ruby-hoe" ,ruby-hoe)))
11257 (home-page "https://github.com/adrianomitre/heredoc_unindent")
11258 (synopsis "Heredoc indentation cleaner")
11259 (description "This gem removes common margin from indented strings, such
11260as the ones produced by indented heredocs. In other words, it strips out
4f66ae28 11261leading whitespace chars at the beginning of each line, but only as much as
73bfc125
JL
11262the line with the smallest margin.
11263
11264It is acknowledged that many strings defined by heredocs are just code and
11265fact is that most parsers are insensitive to indentation. If, however, the
11266strings are to be used otherwise, be it for printing or testing, the extra
11267indentation will probably be an issue and hence this gem.")
11268 (license license:expat)))
f8ae2ee5
JL
11269
11270(define-public ruby-safe-yaml
11271 (package
11272 (name "ruby-safe-yaml")
7fa83fa8 11273 (version "1.0.5")
28cf8dab
CB
11274 (source
11275 (origin
28cf8dab
CB
11276 (method git-fetch)
11277 (uri (git-reference
b0e7b699 11278 (url "https://github.com/dtao/safe_yaml")
28cf8dab
CB
11279 (commit version)))
11280 (file-name (git-file-name name version))
11281 (sha256
11282 (base32
7fa83fa8 11283 "1a0wh7y3va2m7bjza95na2snw0vrdh9syz40mpjvjphbc4ph3pzg"))))
f8ae2ee5
JL
11284 (build-system ruby-build-system)
11285 (native-inputs
11286 `(("ruby-rspec" ,ruby-rspec)
11287 ("ruby-hashie" ,ruby-hashie)
11288 ("ruby-heredoc-unindent" ,ruby-heredoc-unindent)))
28cf8dab
CB
11289 (arguments
11290 '(#:test-target "spec"
11291 #:phases
11292 (modify-phases %standard-phases
11293 (add-before 'check 'set-TZ
11294 (lambda _
11295 ;; This test is dependent on the timezone
11296 ;; spec/transform/to_date_spec.rb:35
11297 ;; # SafeYAML::Transform::ToDate converts times to the local
11298 ;; timezone
11299 (setenv "TZ" "UTC-11")
11300 #t)))))
f8ae2ee5
JL
11301 (home-page "https://github.com/dtao/safe_yaml")
11302 (synopsis "YAML parser")
11303 (description "The SafeYAML gem provides an alternative implementation of
11304YAML.load suitable for accepting user input in Ruby applications.")
11305 (license license:expat)))
f1ec4d76
JL
11306
11307(define-public ruby-mercenary
11308 (package
11309 (name "ruby-mercenary")
8367ab5d 11310 (version "0.4.0")
f1ec4d76
JL
11311 (source (origin
11312 (method url-fetch)
11313 (uri (rubygems-uri "mercenary" version))
11314 (sha256
11315 (base32
8367ab5d 11316 "0f2i827w4lmsizrxixsrv2ssa3gk1b7lmqh8brk8ijmdb551wnmj"))))
f1ec4d76
JL
11317 (build-system ruby-build-system)
11318 (arguments `(#:test-target "spec"))
11319 (native-inputs
11320 `(("bundler" ,bundler)))
11321 (home-page "https://github.com/jekyll/mercenary")
11322 (synopsis "Command-line apps library in Ruby")
11323 (description "Mercenary is a lightweight and flexible library for writing
11324command-line apps in Ruby.")
11325 (license license:expat)))
a13d451e
JL
11326
11327(define-public ruby-liquid
11328 (package
11329 (name "ruby-liquid")
11330 (version "4.0.0")
11331 (source (origin
11332 (method url-fetch)
11333 (uri (rubygems-uri "liquid" version))
11334 (sha256
11335 (base32
11336 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))
11337 (build-system ruby-build-system)
11338 (arguments `(#:tests? #f)); No rakefile
11339 (home-page "https://shopify.github.io/liquid/")
11340 (synopsis "Template language")
11341 (description "Liquid is a template language written in Ruby. It is used
11342to load dynamic content on storefronts.")
11343 (license license:expat)))
49395112
JL
11344
11345(define-public ruby-forwardable-extended
11346 (package
11347 (name "ruby-forwardable-extended")
11348 (version "2.6.0")
11349 (source (origin
11350 (method url-fetch)
11351 (uri (rubygems-uri "forwardable-extended" version))
11352 (sha256
11353 (base32
11354 "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"))))
11355 (build-system ruby-build-system)
11356 (arguments `(#:tests? #f)); Cyclic dependency on luna-rspec-formatters
11357 (home-page "https://github.com/envygeeks/forwardable-extended")
11358 (synopsis "Delegation to hashes and instance variables in Forwardable")
11359 (description "Forwardable Extended provides more @code{Forwardable}
11360methods for your source as @code{Forwardable::Extended}.")
11361 (license license:expat)))
37296113
JL
11362
11363(define-public ruby-pathutil
11364 (package
11365 (name "ruby-pathutil")
feaaa603 11366 (version "0.16.2")
37296113
JL
11367 (source (origin
11368 (method url-fetch)
11369 (uri (rubygems-uri "pathutil" version))
11370 (sha256
11371 (base32
feaaa603 11372 "12fm93ljw9fbxmv2krki5k5wkvr7560qy8p4spvb9jiiaqv78fz4"))))
37296113
JL
11373 (build-system ruby-build-system)
11374 (propagated-inputs
11375 `(("ruby-forwardable-extended" ,ruby-forwardable-extended)))
11376 (native-inputs
11377 `(("bundler" ,bundler)
11378 ("ruby-rspec" ,ruby-rspec)))
11379 ;; Fails with: cannot load such file --
11380 ;; /tmp/guix-build-ruby-pathutil-0.16.0.drv-0/gem/benchmark/support/task
11381 (arguments `(#:tests? #f))
11382 (home-page "https://github.com/envygeeks/pathutil")
11383 (synopsis "Extended implementation of Pathname")
11384 (description "Pathutil tries to be a faster pure Ruby implementation of
11385Pathname.")
11386 (license license:expat)))
49e1dde5 11387
d4be9f84
E
11388(define-public ruby-terminal-table
11389 (package
11390 (name "ruby-terminal-table")
11391 (version "2.0.0")
11392 (source
11393 (origin
11394 (method url-fetch)
11395 (uri (rubygems-uri "terminal-table" version))
11396 (sha256
11397 (base32
11398 "18rbrh464ysqbdv53iwj0r8frshn65566kyj044cp3x9c2754jwh"))))
11399 (arguments
11400 '(#:phases
11401 (modify-phases %standard-phases
11402 (add-before 'check 'remove-gemfile-lock
11403 (lambda _
11404 (delete-file "Gemfile.lock")))
11405 (add-before 'check 'remove-unnecessary-dependencies
11406 (lambda _
11407 (substitute* "terminal-table.gemspec"
11408 (("s.add_runtime_dependency.*") "\n")
11409 (("s.add_development_dependency.*") "\n"))
11410 (substitute* "Gemfile"
11411 ((".*tins.*") "\n"))))
11412 (replace 'check
11413 (lambda* (#:key tests? #:allow-other-keys)
11414 (when tests?
11415 (invoke "rspec")))))))
11416 (build-system ruby-build-system)
11417 (propagated-inputs
11418 `(("ruby-unicode-display-width" ,ruby-unicode-display-width)))
11419 (native-inputs
11420 `(("ruby-rspec" ,ruby-rspec)))
11421 (home-page "https://github.com/tj/terminal-table")
11422 (synopsis "Simple, feature rich ASCII table generation library")
11423 (description
11424 "Terminal Table is a fast and simple, yet feature rich
11425table generator written in Ruby. It supports ASCII and
11426Unicode formatted tables.")
11427 (license license:expat)))
11428
49e1dde5
JL
11429(define-public jekyll
11430 (package
11431 (name "jekyll")
53e2d815 11432 (version "4.2.0")
49e1dde5
JL
11433 (source (origin
11434 (method url-fetch)
11435 (uri (rubygems-uri "jekyll" version))
11436 (sha256
11437 (base32
53e2d815 11438 "0cqkh78jw8scrajyx5nla0vwm9fvp2qql3kdcvvplcq9mazy8snq"))))
49e1dde5
JL
11439 (build-system ruby-build-system)
11440 (arguments
fcf82fd3 11441 ;; No rakefile, but a test subdirectory.
49e1dde5
JL
11442 `(#:tests? #f
11443 #:phases
11444 (modify-phases %standard-phases
11445 (add-before 'build 'fix-i18n
11446 (lambda _
11447 (substitute* ".gemspec"
b7e76699
MR
11448 (("~> 0.7") ">= 0.7")
11449 (("~> 1.14") ">= 1.14"))
49e1dde5
JL
11450 #t)))))
11451 (propagated-inputs
11452 `(("ruby-addressable" ,ruby-addressable)
11453 ("ruby-colorator" ,ruby-colorator)
11454 ("ruby-em-websocket" ,ruby-em-websocket)
11455 ("ruby-i18n" ,ruby-i18n)
11456 ("ruby-jekyll-sass-converter" ,ruby-jekyll-sass-converter)
11457 ("ruby-jekyll-watch" ,ruby-jekyll-watch)
7df90fd5 11458 ("ruby-kramdown" ,ruby-kramdown-parser-gfm)
49e1dde5
JL
11459 ("ruby-liquid" ,ruby-liquid)
11460 ("ruby-mercenary" ,ruby-mercenary)
11461 ("ruby-pathutil" ,ruby-pathutil)
53e2d815
E
11462 ("ruby-rouge" ,ruby-rouge)
11463 ("ruby-safe-yaml" ,ruby-safe-yaml)
11464 ("ruby-sassc" ,ruby-sassc)
11465 ("ruby-terminal-table" ,ruby-terminal-table)))
49e1dde5
JL
11466 (home-page "https://jekyllrb.com/")
11467 (synopsis "Static site generator")
11468 (description "Jekyll is a simple, blog aware, static site generator.")
11469 (license license:expat)))
37a0f470
JL
11470
11471(define-public ruby-jekyll-paginate-v2
11472 (package
11473 (name "ruby-jekyll-paginate-v2")
ed9142a6 11474 (version "3.0.0")
37a0f470
JL
11475 (source (origin
11476 (method url-fetch)
11477 (uri (rubygems-uri "jekyll-paginate-v2" version))
11478 (sha256
11479 (base32
ed9142a6 11480 "1qzlqhpiqz28624fp0ak76hfy7908w6kpx62v7z43aiwjv0yc6q0"))))
37a0f470
JL
11481 (build-system ruby-build-system)
11482 (propagated-inputs
11483 `(("jekyll" ,jekyll)))
11484 (home-page "https://github.com/sverrirs/jekyll-paginate-v2")
11485 (synopsis "Pagination Generator for Jekyll 3")
11486 (description "The Pagination Generator forms the core of the pagination
11487logic in Jekyll. It calculates and generates the pagination pages.")
11488 (license license:expat)))
909eae21
CB
11489
11490(define-public ruby-faraday
11491 (package
11492 (name "ruby-faraday")
11493 (version "0.15.4")
11494 (source
11495 (origin
11496 (method url-fetch)
11497 (uri (rubygems-uri "faraday" version))
11498 (sha256
11499 (base32
11500 "0s72m05jvzc1pd6cw1i289chas399q0a14xrwg4rvkdwy7bgzrh0"))))
11501 (build-system ruby-build-system)
11502 (arguments
11503 '(#:tests? #f))
11504 (propagated-inputs
11505 `(("ruby-multipart-post" ,ruby-multipart-post)))
11506 (synopsis "Ruby HTTP/REST API client library")
11507 (description
11508 "Faraday is a HTTP/REST API client library which provides a common
11509interface over different adapters.")
11510 (home-page "https://github.com/lostisland/faraday")
11511 (license license:expat)))
a058cbfd
CB
11512
11513(define-public ruby-nio4r
11514 (package
11515 (name "ruby-nio4r")
7923b9bf 11516 (version "2.5.2")
a058cbfd
CB
11517 (source
11518 (origin
11519 (method url-fetch)
11520 (uri (rubygems-uri "nio4r" version))
11521 (sha256
11522 (base32
7923b9bf 11523 "0gnmvbryr521r135yz5bv8354m7xn6miiapfgpg1bnwsvxz8xj6c"))))
a058cbfd
CB
11524 (build-system ruby-build-system)
11525 (arguments
11526 '(#:phases
11527 (modify-phases %standard-phases
11528 (add-after 'unpack 'remove-unnecessary-dependencies
11529 (lambda _
11530 (substitute* "spec/spec_helper.rb"
11531 ;; Coveralls is for uploading test coverage information to an
11532 ;; online service, and thus unnecessary for building the Guix
11533 ;; package
11534 (("require \"coveralls\"") "")
11535 (("Coveralls\\.wear!") "")
11536 ;; Remove rspec/retry as we are not retrying the tests
11537 (("require \"rspec/retry\"") "")
11538 (("config\\.display_try_failure_messages = true") "")
11539 (("config\\.verbose_retry = true") ""))
11540 #t))
11541 (add-before 'check 'compile
11542 (lambda _
11543 (invoke "rake" "compile")
11544 #t))
11545 (replace 'check
11546 (lambda* (#:key tests? #:allow-other-keys)
11547 (when tests?
11548 (invoke "rspec"))
11549 #t)))))
11550 (native-inputs
11551 `(("bundler" ,bundler)
11552 ("ruby-rake-compiler" ,ruby-rake-compiler)
11553 ("ruby-rspec" ,ruby-rspec)
11554 ("ruby-rubocop" ,ruby-rubocop)))
11555 (synopsis "New I/O for Ruby")
11556 (description
11557 "@code{nio} provides cross-platform asynchronous I/O primitives in Ruby
11558for scalable network clients and servers.")
11559 (home-page "https://github.com/socketry/nio4r")
11560 (license license:expat)))
f9da1ada
CB
11561
11562(define-public ruby-globalid
11563 (package
11564 (name "ruby-globalid")
11565 (version "0.4.2")
11566 (source
11567 (origin
11568 (method url-fetch)
11569 (uri (rubygems-uri "globalid" version))
11570 (sha256
11571 (base32
11572 "1zkxndvck72bfw235bd9nl2ii0lvs5z88q14706cmn702ww2mxv1"))))
11573 (build-system ruby-build-system)
11574 (arguments
11575 '(;; No included tests
11576 #:tests? #f))
11577 (propagated-inputs
11578 `(("ruby-activesupport" ,ruby-activesupport)))
11579 (synopsis "Generate URIs idenfitying model instances in Ruby")
11580 (description
11581 "@code{GlobalID} provides a way to generate URIs from a model in Ruby that
11582uniquely identify it.")
11583 (home-page "https://rubyonrails.org/")
11584 (license license:expat)))
15606d98
CB
11585
11586(define-public ruby-sprockets
11587 (package
11588 (name "ruby-sprockets")
11589 (version "3.7.2")
11590 (source
11591 (origin
11592 (method url-fetch)
11593 (uri (rubygems-uri "sprockets" version))
11594 (sha256
11595 (base32
11596 "182jw5a0fbqah5w9jancvfmjbk88h8bxdbwnl4d3q809rpxdg8ay"))))
11597 (build-system ruby-build-system)
11598 (arguments
11599 '(;; No included tests
11600 #:tests? #f))
11601 (propagated-inputs
11602 `(("ruby-concurrent" ,ruby-concurrent)
11603 ("ruby-rack" ,ruby-rack)))
11604 (synopsis "Sprockets is a Rack-based asset packaging system")
11605 (description
11606 "Sprockets is a Rack-based asset packaging system that concatenates and
11607serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.")
11608 (home-page "https://github.com/rails/sprockets")
11609 (license license:expat)))
acb9e3d8 11610
49994222
NG
11611(define-public ruby-mustache
11612 (package
11613 (name "ruby-mustache")
11614 (version "1.1.1")
11615 (source
11616 (origin
11617 (method url-fetch)
11618 (uri (rubygems-uri "mustache" version))
11619 (sha256
11620 (base32 "1l0p4wx15mi3wnamfv92ipkia4nsx8qi132c6g51jfdma3fiz2ch"))))
11621 (build-system ruby-build-system)
11622 (native-inputs
11623 `(("ruby-simplecov" ,ruby-simplecov)))
11624 (synopsis "framework-agnostic way to render logic-free views")
11625 (description
11626 "Mustache is a framework-agnostic way to render logic-free views.
11627Think of Mustache as a replacement for your views. Instead of views
11628consisting of ERB or HAML with random helpers and arbitrary logic,
11629your views are broken into two parts: a Ruby class and an HTML
11630template.")
11631 (home-page "https://github.com/mustache/mustache")
11632 (license license:expat)))
11633
acb9e3d8
PN
11634(define-public ruby-mustermann
11635 (package
11636 (name "ruby-mustermann")
11637 (version "1.0.3")
11638 (source
11639 (origin
11640 (method url-fetch)
11641 (uri (rubygems-uri "mustermann" version))
11642 (sha256
11643 (base32
11644 "0lycgkmnyy0bf29nnd2zql5a6pcf8sp69g9v4xw0gcfcxgpwp7i1"))))
11645 (build-system ruby-build-system)
11646 (arguments
11647 ;; No tests.
11648 '(#:tests? #f))
11649 (synopsis "Library implementing patterns that behave like regular expressions")
11650 (description "Given a string pattern, Mustermann will turn it into an
11651object that behaves like a regular expression and has comparable performance
11652characteristics.")
11653 (home-page "https://github.com/sinatra/mustermann")
11654 (license license:expat)))
3bb094e2 11655
9539d6bd
GL
11656(define-public ruby-html-proofer
11657 (package
11658 (name "ruby-html-proofer")
11659 (version "3.18.5")
11660 (source
11661 (origin
11662 (method git-fetch)
11663 (uri (git-reference
11664 (url "https://github.com/gjtorikian/html-proofer")
11665 (commit (string-append "v" version))))
11666 (file-name (git-file-name name version))
11667 (sha256
11668 (base32
11669 "1pxb0fajb3l3lm7sqj548qwl7vx6sx3jy7n4cns9d4lqx7s9r9xb"))))
11670 (build-system ruby-build-system)
11671 (arguments
11672 `(;; FIXME: Tests depend on rubocop-standard.
11673 #:tests? #f))
11674 (native-inputs
11675 `(("ruby-awesome-print" ,ruby-awesome-print)
11676 ("ruby-redcarpet" ,ruby-redcarpet)
11677 ("ruby-rspec" ,ruby-rspec)
11678 ("ruby-rubocop" ,ruby-rubocop)
11679 ("ruby-rubocop-performance" ,ruby-rubocop-performance)
11680 ("ruby-pry-byebug" ,ruby-pry-byebug)))
11681 (propagated-inputs
11682 `(("ruby-addressable" ,ruby-addressable)
11683 ("ruby-mercenary" ,ruby-mercenary)
11684 ("ruby-nokogumbo" ,ruby-nokogumbo)
11685 ("ruby-parallel" ,ruby-parallel)
11686 ("ruby-rainbow" ,ruby-rainbow)
11687 ("ruby-typhoeus" ,ruby-typhoeus)
11688 ("ruby-yell" ,ruby-yell)))
11689 (synopsis "Test your rendered HTML files to make sure they're accurate")
11690 (description
11691 "HTMLProofer is a set of tests to validate your HTML output. These
11692tests check if your image references are legitimate, if they have alt tags,
11693if your internal links are working, and so on. It's intended to be an
11694all-in-one checker for your output.")
11695 (home-page "https://github.com/gjtorikian/html-proofer")
11696 (license license:expat)))
11697
7bddb6aa
BL
11698(define-public ruby-htmlentities
11699 (package
11700 (name "ruby-htmlentities")
11701 (version "4.3.4")
11702 (source
11703 (origin
11704 (method url-fetch)
11705 (uri (rubygems-uri "htmlentities" version))
11706 (sha256
11707 (base32
11708 "1nkklqsn8ir8wizzlakncfv42i32wc0w9hxp00hvdlgjr7376nhj"))))
11709 (build-system ruby-build-system)
11710 (arguments
11711 `(#:phases
11712 (modify-phases %standard-phases
11713 (replace 'check
11714 (lambda _
11715 (map (lambda (file)
11716 (invoke "ruby" "-Itest" file))
11717 (find-files "./test" ".*_test\\.rb")))))))
11718 (synopsis "Encode and decode (X)HTML entities")
11719 (description
11720 "This package provides a module for encoding and decoding (X)HTML
11721entities.")
11722 (home-page "https://github.com/threedaymonk/htmlentities")
11723 (license license:expat)))
11724
3bb094e2
PN
11725(define-public ruby-sinatra
11726 (package
11727 (name "ruby-sinatra")
7af92924 11728 (version "2.0.8.1")
3bb094e2
PN
11729 (source
11730 (origin
11731 (method url-fetch)
11732 (uri (rubygems-uri "sinatra" version))
11733 (sha256
11734 (base32
7af92924 11735 "0riy3hwjab1mr73jcqx3brmbmwspnw3d193j06a5f0fy1w35z15q"))))
3bb094e2 11736 (build-system ruby-build-system)
7af92924
MC
11737 (arguments
11738 `(#:phases
11739 (modify-phases %standard-phases
11740 ;; See: https://github.com/sinatra/sinatra/issues/1578.
11741 (add-after 'extract-gemspec 'fix-slow-doc-generation
11742 (lambda _
11743 (substitute* "sinatra.gemspec"
11744 (("\"README.rdoc\"\\.freeze," all)
11745 (string-append all " \"--exclude=.*\\.md\".freeze,")))
11746 #t)))))
3bb094e2
PN
11747 (propagated-inputs
11748 `(("ruby-mustermann" ,ruby-mustermann)
11749 ("ruby-rack" ,ruby-rack)
11750 ("ruby-rack-protection" ,ruby-rack-protection)
11751 ("ruby-tilt" ,ruby-tilt)))
11752 (synopsis "DSL for quick web applications creation in Ruby")
11753 (description
11754 "Sinatra is a DSL for quickly creating web applications in Ruby with
11755minimal effort.")
11756 (home-page "http://sinatrarb.com/")
11757 (license license:expat)))
6e87695b
PN
11758
11759(define-public ruby-thin
11760 (package
11761 (name "ruby-thin")
11762 (version "1.7.2")
11763 (source
11764 (origin
11765 (method url-fetch)
11766 (uri (rubygems-uri "thin" version))
11767 (sha256
11768 (base32
11769 "0nagbf9pwy1vg09k6j4xqhbjjzrg5dwzvkn4ffvlj76fsn6vv61f"))))
11770 (build-system ruby-build-system)
11771 (arguments
11772 ;; No tests.
11773 '(#:tests? #f))
11774 (propagated-inputs
11775 `(("ruby-daemons" ,ruby-daemons)
11776 ("ruby-eventmachine" ,ruby-eventmachine)
11777 ("ruby-rack" ,ruby-rack)))
11778 (synopsis "Thin and fast web server for Ruby")
11779 (description "Thin is a Ruby web server that glues together 3 Ruby libraries:
11780@itemize
11781@item the Mongrel parser,
11782@item Event Machine, a network I/O library with high scalability, performance
11783and stability,
11784@item Rack, a minimal interface between webservers and Ruby frameworks.
11785@end itemize\n")
60783303 11786 (home-page "https://github.com/macournoyer/thin")
6e87695b 11787 (license license:ruby)))
be6016db
PN
11788
11789(define-public ruby-skinny
11790 (package
11791 (name "ruby-skinny")
11792 (version "0.2.4")
11793 (source
11794 (origin
11795 (method url-fetch)
11796 (uri (rubygems-uri "skinny" version))
11797 (sha256
11798 (base32
11799 "1y3yvx88ylgz4d2s1wskjk5rkmrcr15q3ibzp1q88qwzr5y493a9"))))
11800 (build-system ruby-build-system)
11801 (arguments
11802 '(#:tests? #f ; No included tests
11803 #:phases
11804 (modify-phases %standard-phases
11805 (add-before 'build 'patch-gemspec
11806 (lambda _
11807 (substitute* ".gemspec"
11808 (("<eventmachine>.freeze, \\[\\\"~> 1.0.0\"")
11809 "<eventmachine>, [\">= 1.0.0\"")
11810 (("<thin>.freeze, \\[\\\"< 1.7\", ") "<thin>, ["))
11811 #t)))))
11812 (propagated-inputs
11813 `(("ruby-eventmachine" ,ruby-eventmachine)
11814 ("ruby-thin" ,ruby-thin)))
11815 (synopsis "Simple, upgradable WebSockets for Ruby Thin")
11816 (description "Skinny is a simple, upgradable WebSockets for Ruby, using
11817the Thin library.")
11818 (home-page "https://github.com/sj26/skinny")
11819 (license license:expat)))
df747c8d 11820
9c566d1b
MB
11821(define-public ruby-sys-filesystem
11822 (package
11823 (name "ruby-sys-filesystem")
11824 (version "1.3.4")
11825 (source (origin
11826 (method url-fetch)
11827 (uri (rubygems-uri "sys-filesystem" version))
11828 (sha256
11829 (base32
11830 "0mizqnsiagagmracadr16s5na2ks2j3ih1w0f3gp4ssrda6szl01"))))
11831 (build-system ruby-build-system)
11832 (arguments
11833 '(#:phases (modify-phases %standard-phases
11834 (add-before 'check 'set-HOME
11835 (lambda _
11836 ;; Some tests attempt to stat $HOME. Let them.
11837 (setenv "HOME" "/tmp")
11838 #t)))))
11839 (propagated-inputs
11840 `(("ruby-ffi" ,ruby-ffi)))
11841 (native-inputs
11842 `(("ruby-mkmf-lite" ,ruby-mkmf-lite)))
11843 (synopsis "Gather file system information")
11844 (description
11845 "The @code{sys-filesystem} library provides a cross-platform interface
11846for gathering file system information, such as disk space and mount points.")
11847 (home-page "https://github.com/djberg96/sys-filesystem")
11848 (license license:asl2.0)))
11849
df747c8d
PN
11850(define-public mailcatcher
11851 (package
11852 (name "mailcatcher")
11853 (version "0.7.1")
11854 (source
11855 (origin
11856 (method url-fetch)
11857 (uri (rubygems-uri "mailcatcher" version))
11858 (sha256
11859 (base32
11860 "02w1ycyfv7x0sh9799lz7xa65p5qvl5z4pa8a7prb68h2zwkfq0n"))))
11861 (build-system ruby-build-system)
11862 (arguments
11863 ;; Tests require web/assets which is not included in the output. We
11864 ;; might be able to fix this by adding the Git repository to the GEM_PATH
11865 ;; of the tests. See ruby-mysql2.
11866 '(#:tests? #f
11867 #:phases
11868 (modify-phases %standard-phases
11869 (add-before 'build 'patch-gemspec
11870 (lambda _
11871 (substitute* ".gemspec"
11872 (("<eventmachine>.freeze, \\[\\\"= 1.0.9.1")
11873 "<eventmachine>, [\">= 1.0.9.1")
11874 (("<rack>.freeze, \\[\\\"~> 1.5") "<rack>, [\">= 1.5")
11875 (("<thin>.freeze, \\[\\\"~> 1.5.0") "<thin>, [\">= 1.5.0")
11876 (("<sinatra>.freeze, \\[\\\"~> 1.2") "<sinatra>, [\">= 1.2"))
11877 #t))
11878 (add-before 'build 'loosen-dependency-contraint
11879 (lambda _
11880 (substitute* "lib/mail_catcher.rb"
11881 (("\"eventmachine\", \"1.0.9.1\"") "\"eventmachine\", \">= 1.0.9.1\"")
11882 (("\"rack\", \"~> 1.5\"") "\"rack\", \">= 1.5\"")
11883 (("\"thin\", \"~> 1.5.0\"") "\"thin\", \">= 1.5.0\"")
11884 (("\"sinatra\", \"~> 1.2\"") "\"sinatra\", \">= 1.2\""))
11885 #t)))))
11886 (inputs
11887 `(("ruby-eventmachine" ,ruby-eventmachine)
11888 ("ruby-mail" ,ruby-mail)
11889 ("ruby-rack" ,ruby-rack)
11890 ("ruby-sinatra" ,ruby-sinatra)
11891 ("ruby-skinny" ,ruby-skinny)
11892 ("ruby-sqlite3" ,ruby-sqlite3)
11893 ("ruby-thin" ,ruby-thin)))
11894 (synopsis "SMTP server which catches messages to display them a browser")
11895 (description
11896 "MailCatcher runs a super simple SMTP server which catches any message
11897sent to it to display in a web interface. Run mailcatcher, set your favourite
11898app to deliver to smtp://127.0.0.1:1025 instead of your default SMTP server,
11899then check out http://127.0.0.1:1080 to see the mail.")
11900 (home-page "https://mailcatcher.me")
11901 (license license:expat)))
fc4f7c45
MK
11902
11903(define-public ruby-backport
11904 (package
11905 (name "ruby-backport")
b62863b8 11906 (version "1.1.2")
fc4f7c45
MK
11907 (source
11908 (origin
b62863b8 11909 ;; The gem does not include test code, so fetch from the Git repository.
fc4f7c45
MK
11910 (method git-fetch)
11911 (uri (git-reference
b0e7b699 11912 (url "https://github.com/castwide/backport")
fc4f7c45
MK
11913 (commit (string-append "v" version))))
11914 (file-name (git-file-name name version))
11915 (sha256
b62863b8 11916 (base32 "18fpg1n7n2z02ykz9v1x1q0cqa2lvivf8ygka768s01q1r9wfwv2"))))
fc4f7c45
MK
11917 (build-system ruby-build-system)
11918 (arguments
11919 `(#:test-target "spec"))
11920 (native-inputs
11921 `(("bundler" ,bundler)
11922 ("ruby-rspec" ,ruby-rspec)))
11923 (inputs
11924 `(("ruby-simplecov" ,ruby-simplecov)))
11925 (synopsis "Pure Ruby library for event-driven IO")
11926 (description
11927 "This package provides a pure Ruby library for event-driven IO.")
11928 (home-page "https://github.com/castwide/backport")
11929 (license license:expat)))
369faa59
JL
11930
11931(define-public ruby-json-schema
11932 (package
11933 (name "ruby-json-schema")
11934 (version "2.8.1")
11935 (source
11936 (origin
11937 (method url-fetch)
11938 (uri (rubygems-uri "json-schema" version))
11939 (sha256
11940 (base32
11941 "1yv5lfmr2nzd14af498xqd5p89f3g080q8wk0klr3vxgypsikkb5"))))
11942 (build-system ruby-build-system)
11943 (arguments
11944 `(#:tests? #f ; no tests
11945 #:phases
11946 (modify-phases %standard-phases
11947 (replace 'build
11948 (lambda _
11949 (invoke "gem" "build" ".gemspec"))))))
11950 (propagated-inputs
11951 `(("ruby-addressable" ,ruby-addressable)))
11952 (synopsis "Ruby JSON Schema Validator")
11953 (description "This library provides Ruby with an interface for validating
11954JSON objects against a JSON schema conforming to JSON Schema Draft 4. Legacy
11955support for JSON Schema Draft 3, JSON Schema Draft 2, and JSON Schema Draft 1
11956is also included.")
11957 (home-page "https://github.com/ruby-json-schema/json-schema")
11958 (license license:expat)))
44881cad
JL
11959
11960(define-public swagger-diff
11961 (package
11962 (name "swagger-diff")
11963 (version "1.1.2")
11964 (source
11965 (origin
11966 (method url-fetch)
11967 (uri (rubygems-uri "swagger-diff" version))
11968 (sha256
11969 (base32
11970 "1hxx50nga1bqn254iqjcdwkc9c72364ks9lyjyw10ajz0l0ly7sn"))))
11971 (build-system ruby-build-system)
11972 (arguments
11973 `(#:test-target "spec"
11974 #:phases
11975 (modify-phases %standard-phases
11976 ;; Don't run or require rubocop, the code linting tool, as this is a
11977 ;; bit unnecessary.
11978 (add-after 'unpack 'dont-run-rubocop
11979 (lambda _
11980 (substitute* "Rakefile"
11981 ((".*rubocop.*") "")
11982 ((".*RuboCop.*") ""))
11983 #t)))))
11984 (propagated-inputs
11985 `(("ruby-json-schema" ,ruby-json-schema)))
11986 (native-inputs
11987 `(("bundler" ,bundler)
11988 ("ruby-rspec-core" ,ruby-rspec-core)
11989 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
11990 (synopsis
11991 "Compare Open API Initiative specification files")
11992 (description
11993 "Swagger::Diff is a utility for comparing two different Open API
11994Initiative (OAI) specifications (formerly known as Swagger specifications).
11995It is intended to determine whether a newer API specification is
11996backwards-compatible with an older API specification.")
11997 (home-page "https://github.com/civisanalytics/swagger-diff")
11998 (license license:bsd-3)))
9e065a8a
BL
11999
12000(define-public ruby-reverse-markdown
12001 (package
12002 (name "ruby-reverse-markdown")
12003 (version "1.1.0")
12004 (source
12005 (origin
12006 (method url-fetch)
12007 (uri (rubygems-uri "reverse_markdown" version))
12008 (sha256
12009 (base32
12010 "0w7y5n74daajvl9gixr91nh8670d7mkgspkk3ql71m8azq3nffbg"))))
12011 (build-system ruby-build-system)
12012 (propagated-inputs
12013 `(("ruby-nokogiri" ,ruby-nokogiri)))
12014 (native-inputs
12015 `(("bundler" ,bundler)
12016 ("ruby-rspec" ,ruby-rspec)
12017 ("ruby-kramdown" ,ruby-kramdown)
12018 ("ruby-simplecov" ,ruby-simplecov)))
12019 (arguments
12020 `(#:phases
12021 (modify-phases %standard-phases
12022 (replace 'check
12023 (lambda* (#:key tests? #:allow-other-keys)
12024 (when tests?
12025 (invoke "rspec"))
12026 #t)))))
12027 (synopsis "Convert HTML into Markdown")
12028 (description
12029 "This Ruby module allows you to map simple HTML back into
12030Markdown---e.g., if you want to import existing HTML data in your
12031application.")
12032 (home-page "https://github.com/xijo/reverse_markdown")
12033 (license license:wtfpl2)))
12034
a9e2de7e
BL
12035(define-public ruby-solargraph
12036 (package
12037 (name "ruby-solargraph")
12038 (version "0.36.0")
12039 (source
12040 (origin
12041 (method url-fetch)
12042 (uri (rubygems-uri "solargraph" version))
12043 (sha256
12044 (base32
12045 "0b93xzkgd1h06da9gdnwivj1mzbil8lc072y2838dy6i7bxgpy9i"))))
12046 (build-system ruby-build-system)
12047 (propagated-inputs
12048 `(("ruby-backport" ,ruby-backport)
12049 ("bundler" ,bundler)
12050 ("ruby-htmlentities" ,ruby-htmlentities)
12051 ("ruby-jaro-winkler" ,ruby-jaro-winkler)
12052 ("ruby-maruku" ,ruby-maruku)
12053 ("ruby-nokogiri" ,ruby-nokogiri)
12054 ("ruby-parser" ,ruby-parser)
12055 ("ruby-reverse-markdown" ,ruby-reverse-markdown)
12056 ("ruby-rubocop" ,ruby-rubocop)
12057 ("ruby-thor" ,ruby-thor)
12058 ("ruby-tilt" ,ruby-tilt)
12059 ("ruby-yard" ,ruby-yard)))
12060 (native-inputs
12061 `(("ruby-rspec" ,ruby-rspec)
12062 ("ruby-pry" ,ruby-pry)
12063 ("ruby-simplecov" ,ruby-simplecov)
a4d61297 12064 ("ruby-webmock" ,ruby-webmock)))
a9e2de7e
BL
12065 ;; FIXME: can't figure out how to run the tests properly:
12066
12067 ;; An error occurred while loading spec_helper.
12068 ;; Failure/Error: return gem_original_require(path)
12069 ;; LoadError:
12070 ;; cannot load such file -- spec_helper
12071 (arguments
12072 '(#:tests? #f
12073 #:phases
12074 (modify-phases %standard-phases
12075 (replace 'check
12076 (lambda* (#:key tests? #:allow-other-keys)
12077 (when tests?
12078 (invoke "rspec"))
12079 #t)))))
12080 (synopsis
12081 "IDE tools for code completion, inline documentation, and static analysis")
12082 (description
12083 "Solargraph provides a comprehensive suite of tools for Ruby
12084programming: intellisense, diagnostics, inline documentation, and type
12085checking.")
12086 (home-page "https://solargraph.org/")
12087 (license license:expat)))
0c558aa9
DNB
12088
12089(define-public ruby-wayback-machine-downloader
12090 (package
12091 (name "ruby-wayback-machine-downloader")
12092 (version "2.2.1")
12093 (source
12094 (origin
12095 (method url-fetch)
12096 (uri (rubygems-uri
12097 "wayback_machine_downloader"
12098 version))
12099 (sha256
12100 (base32
12101 "12kb1qmvmmsaihqab1prn6cmynkn6cgb4vf41mgv22wkcgv5wgk2"))))
12102 (build-system ruby-build-system)
12103 (arguments
12104 '(#:tests? #f)) ; no tests
12105 (synopsis "Download archived websites from the Wayback Machine")
12106 (description
12107 "Wayback Machine Downloader is a command line tool for downloading
12108websites from the Internet Archive's Wayback Machine (archive.org).
12109It allows fine grained control over what to download by specifying
12110which snapshots to consider and what files to include.")
12111 (home-page
12112 "https://github.com/hartator/wayback-machine-downloader")
12113 (license license:expat)))
e6483f8c 12114
8bad3c8d
EF
12115(define-public ruby-zeitwerk
12116 (package
12117 (name "ruby-zeitwerk")
12118 (version "2.4.2")
12119 (source
12120 (origin
12121 (method git-fetch)
12122 (uri (git-reference
12123 ;; No tests in the released gem.
12124 (url "https://github.com/fxn/zeitwerk")
12125 (commit (string-append "v" version))))
12126 (file-name (git-file-name name version))
12127 (sha256
12128 (base32
12129 "119fgdyb57gmss2yvfwfr47wcy8nny38sai72446krpihyavpizw"))))
12130 (build-system ruby-build-system)
12131 (native-inputs
12132 `(("ruby-minitest" ,ruby-minitest)
12133 ("ruby-minitest-focus" ,ruby-minitest-focus)
12134 ("ruby-minitest-reporters" ,ruby-minitest-reporters)))
12135 (synopsis "Efficient and thread-safe code loader for Ruby")
12136 (description
12137 "Zeitwerk implements constant autoloading with Ruby semantics. Each gem
12138and application may have their own independent autoloader, with its own
12139configuration, inflector, and logger. Supports autoloading, reloading, and
12140eager loading.")
12141 (home-page "https://github.com/fxn/zeitwerk")
12142 (license license:expat)))
12143
e6483f8c
MB
12144(define-public ruby-wwtd
12145 (package
12146 (name "ruby-wwtd")
12147 (version "1.4.1")
702a1012 12148 (home-page "https://github.com/grosser/wwtd")
e6483f8c
MB
12149 (source (origin
12150 (method git-fetch)
12151 (uri (git-reference
12152 (url home-page)
12153 (commit (string-append "v" version))))
12154 (file-name (git-file-name name version))
12155 (sha256
12156 (base32
12157 "0gw7vfnbb41cy67yw82zji3jkhfsgmzcgzaszm99ax77y18wclf2"))
12158 (modules '((guix build utils)))
12159 (snippet
12160 '(begin
12161 ;; Remove bundled library.
12162 (delete-file "spec/rake-12.3.0.gem")
12163 #t))))
12164 (build-system ruby-build-system)
12165 (arguments
12166 '(;; XXX: Tests need multiple versions of ruby, wants to run
12167 ;; `bundle install`, etc.
12168 #:tests? #f
12169 #:phases (modify-phases %standard-phases
12170 (replace 'replace-git-ls-files
12171 (lambda _
12172 (substitute* "wwtd.gemspec"
12173 (("git ls-files lib/ bin/`")
12174 "find lib/ bin/ -type f |sort`"))
12175 #t))
12176 (add-before 'check 'remove-version-constraints
12177 (lambda _
12178 (delete-file "Gemfile.lock")
12179 #t))
12180 (replace 'check
12181 (lambda* (#:key tests? #:allow-other-keys)
12182 (if tests?
12183 (invoke "rspec" "spec/")
12184 (format #t "test suite not run~%"))
12185 #t)))))
12186 (native-inputs
12187 `(("ruby-bump" ,ruby-bump)
12188 ("ruby-rspec" ,ruby-rspec)))
12189 (synopsis "Run @file{.travis.yml} files locally")
12190 (description
12191 "WWTD is a @dfn{Travis Simulator} that lets you run test matrices
12192defined in @file{.travis.yml} on your local machine, using @code{rvm},
12193@code{rbenv}, or @code{chruby} to test different versions of Ruby.")
12194 (license license:expat)))
40afc2f4
HP
12195
12196(define-public ruby-rugged
12197 (package
12198 (name "ruby-rugged")
12199 (version "1.1.0")
12200 (home-page "https://www.rubydoc.info/gems/rugged")
12201 (source
12202 (origin
12203 (method url-fetch)
12204 (uri (rubygems-uri "rugged" version))
12205 (sha256
12206 (base32 "04aq913plcxjw71l5r62qgz3bx3466p0wvgyfqahg5n3nybmcwqy"))))
12207 (build-system ruby-build-system)
12208 (arguments
12209 `(#:tests? #f
12210 #:gem-flags (list "--" "--use-system-libraries")))
12211 (inputs
12212 `(("libgit2" ,libgit2)))
12213 (native-inputs
12214 `(("ruby-minitest" ,ruby-minitest)
12215 ("ruby-pry" ,ruby-pry)
12216 ("ruby-rake-compiler" ,ruby-rake-compiler)))
12217 (synopsis "Ruby bindings to the libgit2 linkable C Git library")
12218 (description "Rugged is a library for accessing libgit2 in Ruby. It gives
12219you the speed and portability of libgit2 with the beauty of the Ruby
12220language.")
12221 (license license:expat)))
dbe02ce5
GL
12222
12223(define-public ruby-yell
12224 (package
12225 (name "ruby-yell")
12226 (version "2.2.2")
12227 (source
12228 (origin
12229 (method url-fetch)
12230 (uri (rubygems-uri "yell" version))
12231 (sha256
12232 (base32
12233 "1g16kcdhdfvczn7x81jiq6afg3bdxmb73skqjyjlkp5nqcy6y5hx"))))
12234 (build-system ruby-build-system)
12235 (arguments
12236 `(#:phases
12237 (modify-phases %standard-phases
12238 (replace 'check
12239 (lambda _
12240 (invoke "rake" "examples")))))) ; there is no test target.
12241 (synopsis
12242 "Extensible logging library for Ruby")
12243 (description
12244 "Yell is a comprehensive logging replacement for Ruby. It defines
12245multiple adapters, various log level combinations and message formatting
12246options.")
12247 (home-page "https://github.com/rudionrails/yell")
12248 (license license:expat)))