gnu: Add ruby-asciidoctor-pdf.
[jackhill/guix/guix.git] / gnu / packages / ruby.scm
CommitLineData
6ef8c59a 1;;; GNU Guix --- Functional package management for GNU
37ab3aba 2;;; Copyright © 2014, 2015 Pjotr Prins <pjotr.guix@thebird.nl>
402b03e6 3;;; Copyright © 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
f586c877 4;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
37ab3aba 5;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org>
6742c6f6 6;;; Copyright © 2015, 2019 Ricardo Wurmus <rekado@elephly.net>
cba53c60 7;;; Copyright © 2015, 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
3c986a7d 8;;; Copyright © 2017 Nikita <nikita@n0.is>
3cc8e029 9;;; Copyright © 2017, 2019, 2020 Marius Bakke <mbakke@fastmail.com>
b872b47b 10;;; Copyright © 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il>
a7b7817d 11;;; Copyright © 2017, 2018, 2020 Tobias Geerinckx-Rice <me@tobias.gr>
6a9d2266 12;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
433e3154 13;;; Copyright © 2017, 2018, 2019 Christopher Baines <mail@cbaines.net>
4db80f8b 14;;; Copyright © 2018 Vasile Dumitrascu <va511e@yahoo.com>
8ef06557 15;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
3355e49c 16;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz>
fc4f7c45 17;;; Copyright © 2019 Mikhail Kirillov <w96k.ru@gmail.com>
369faa59 18;;; Copyright © 2019 Jelle Licht <jlicht@fsfe.org>
9e065a8a 19;;; Copyright © 2019 Brian Leung <bkleung89@gmail.com>
9c4cb1ef 20;;; Copyright © 2019 Collin J. Doering <collin@rekahsoft.ca>
0c558aa9 21;;; Copyright © 2019 Diego N. Barbato <dnbarbato@posteo.de>
fd248cb8 22;;; Copyright © 2019 Brett Gilio <brettg@posteo.de>
a8cdfd53 23;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
6ef8c59a
PP
24;;;
25;;; This file is part of GNU Guix.
26;;;
27;;; GNU Guix is free software; you can redistribute it and/or modify it
28;;; under the terms of the GNU General Public License as published by
29;;; the Free Software Foundation; either version 3 of the License, or (at
30;;; your option) any later version.
31;;;
32;;; GNU Guix is distributed in the hope that it will be useful, but
33;;; WITHOUT ANY WARRANTY; without even the implied warranty of
34;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
35;;; GNU General Public License for more details.
36;;;
37;;; You should have received a copy of the GNU General Public License
38;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
39
40(define-module (gnu packages ruby)
41 #:use-module ((guix licenses) #:prefix license:)
42 #:use-module (gnu packages)
1db791d5 43 #:use-module (gnu packages base)
933dad91 44 #:use-module (gnu packages bison)
24be6751 45 #:use-module (gnu packages c)
15b16c2c 46 #:use-module (gnu packages check)
6ef8c59a 47 #:use-module (gnu packages compression)
2a9ce5cb 48 #:use-module (gnu packages crypto)
4a9e0585 49 #:use-module (gnu packages databases)
255d1bbe 50 #:use-module (gnu packages dbm)
c41fba01 51 #:use-module (gnu packages rails)
6ef8c59a 52 #:use-module (gnu packages readline)
6ef8c59a 53 #:use-module (gnu packages autotools)
c84dd8d4 54 #:use-module (gnu packages haskell-xyz)
ad79eb55 55 #:use-module (gnu packages java)
6ef8c59a 56 #:use-module (gnu packages libffi)
f3d7bb93 57 #:use-module (gnu packages libidn)
c41fba01
CB
58 #:use-module (gnu packages linux)
59 #:use-module (gnu packages lsof)
34138e42 60 #:use-module (gnu packages maths)
0c8eedc1 61 #:use-module (gnu packages ncurses)
fe5dd5f4 62 #:use-module (gnu packages networking)
3ca43524 63 #:use-module (gnu packages node)
dff5392f 64 #:use-module (gnu packages protobuf)
ac09beba 65 #:use-module (gnu packages python)
44d10b1f 66 #:use-module (gnu packages python-xyz)
763624f5 67 #:use-module (gnu packages ragel)
30f08487 68 #:use-module (gnu packages rsync)
cd0322a3 69 #:use-module (gnu packages sqlite)
cc2b77df 70 #:use-module (gnu packages tls)
66e20863 71 #:use-module (gnu packages version-control)
6ef8c59a
PP
72 #:use-module (guix packages)
73 #:use-module (guix download)
bda0c139 74 #:use-module (guix git-download)
6ef8c59a 75 #:use-module (guix utils)
acf735f2 76 #:use-module (guix build-system gnu)
e920bfca 77 #:use-module (gnu packages xml)
c2c4e5b2 78 #:use-module (gnu packages web)
15b16c2c
CB
79 #:use-module (guix build-system ruby)
80 #:use-module ((srfi srfi-1) #:select (alist-delete)))
6ef8c59a 81
9622928d
MC
82(define %prawn-project-licenses
83 ;; This set of licenses applies to most (all?) components of the Prawn
84 ;; project (it is triple licensed).
85 (list license:ruby
86 license:gpl2+
87 license:gpl3+))
88
6ef8c59a
PP
89(define-public ruby
90 (package
91 (name "ruby")
4914c157 92 (version "2.6.5")
6ef8c59a
PP
93 (source
94 (origin
95 (method url-fetch)
6becfdff
MW
96 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
97 (version-major+minor version)
12d39eb5 98 "/ruby-" version ".tar.xz"))
6ef8c59a
PP
99 (sha256
100 (base32
4914c157 101 "0qhsw2mr04f3lqinkh557msr35pb5rdaqy4vdxcj91flgxqxmmnm"))
65e84e31
BW
102 (modules '((guix build utils)))
103 (snippet `(begin
104 ;; Remove bundled libffi
c033c195 105 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
65e84e31 106 #t))))
6ef8c59a
PP
107 (build-system gnu-build-system)
108 (arguments
109 `(#:test-target "test"
fd248cb8 110 #:configure-flags '("--enable-shared") ; dynamic linking
6ef8c59a 111 #:phases
9656b8be 112 (modify-phases %standard-phases
65e84e31 113 (add-before 'configure 'replace-bin-sh-and-remove-libffi
9656b8be
BW
114 (lambda _
115 (substitute* '("Makefile.in"
116 "ext/pty/pty.c"
117 "io.c"
118 "lib/mkmf.rb"
119 "process.c"
120 "test/rubygems/test_gem_ext_configure_builder.rb"
121 "test/rdoc/test_rdoc_parser.rb"
122 "test/ruby/test_rubyoptions.rb"
123 "test/ruby/test_process.rb"
124 "test/ruby/test_system.rb"
125 "tool/rbinstall.rb")
126 (("/bin/sh") (which "sh")))
127 #t)))))
6ef8c59a
PP
128 (inputs
129 `(("readline" ,readline)
6ef8c59a
PP
130 ("openssl" ,openssl)
131 ("libffi" ,libffi)
4914c157
CB
132 ("gdbm" ,gdbm)))
133 (propagated-inputs
134 `(("zlib" ,zlib)))
6ef8c59a
PP
135 (native-search-paths
136 (list (search-path-specification
137 (variable "GEM_PATH")
3cb3fa67 138 (files (list (string-append "lib/ruby/vendor_ruby"))))))
6becfdff 139 (synopsis "Programming language interpreter")
6ef8c59a
PP
140 (description "Ruby is a dynamic object-oriented programming language with
141a focus on simplicity and productivity.")
bf3be6a5 142 (home-page "https://www.ruby-lang.org")
6ef8c59a
PP
143 (license license:ruby)))
144
1cc7d340
RP
145(define-public ruby-2.7
146 (package
147 (inherit ruby)
148 (version "2.7.1")
149 (source
150 (origin
151 (method url-fetch)
152 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
153 (version-major+minor version)
154 "/ruby-" version ".tar.gz"))
155 (sha256
156 (base32
157 "0674x98f542y02r7n2yv2qhmh97blqhi2mvh2dn5f000vlxlh66l"))
158 (modules '((guix build utils)))
159 (snippet `(begin
160 ;; Remove bundled libffi
161 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
162 #t))))
163 (arguments
164 `(#:test-target "test"
165 #:configure-flags '("--enable-shared") ; dynamic linking
166 #:phases
167 (modify-phases %standard-phases
168 (add-before 'configure 'replace-bin-sh-and-remove-libffi
169 (lambda _
170 (substitute* '("configure.ac"
171 "template/Makefile.in"
172 "lib/rubygems/installer.rb"
173 "ext/pty/pty.c"
174 "io.c"
175 "lib/mkmf.rb"
176 "process.c"
177 "test/rubygems/test_gem_ext_configure_builder.rb"
178 "test/rdoc/test_rdoc_parser.rb"
179 "test/ruby/test_rubyoptions.rb"
180 "test/ruby/test_process.rb"
181 "test/ruby/test_system.rb"
182 "tool/rbinstall.rb")
183 (("/bin/sh") (which "sh")))
184 #t)))))
185 (native-inputs
186 `(("autoconf" ,autoconf)))))
187
227fab3e
CB
188(define-public ruby-2.5
189 (package
190 (inherit ruby)
a09ff632 191 (version "2.5.8")
227fab3e
CB
192 (source
193 (origin
194 (method url-fetch)
195 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
196 (version-major+minor version)
197 "/ruby-" version ".tar.xz"))
198 (sha256
199 (base32
a09ff632 200 "0vad5ah1lrdhxsyqr5iqc8c7r7qczpmm76cz8rsf4crimpzv5483"))
227fab3e
CB
201 (modules '((guix build utils)))
202 (snippet `(begin
203 ;; Remove bundled libffi
204 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
205 #t))))))
206
93cae02f
CB
207(define-public ruby-2.4
208 (package
209 (inherit ruby)
dfe211f9 210 (version "2.4.10")
93cae02f
CB
211 (source
212 (origin
213 (method url-fetch)
214 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
215 (version-major+minor version)
216 "/ruby-" version ".tar.xz"))
217 (sha256
218 (base32
dfe211f9 219 "1prhqlgik1zmw9lakl6hkriqslspw48pvhxff17h7ns42p8qwrnm"))
93cae02f
CB
220 (modules '((guix build utils)))
221 (snippet `(begin
222 ;; Remove bundled libffi
223 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
224 #t))))))
225
933dad91
RW
226(define-public mruby
227 (package
228 (name "mruby")
229 (version "2.0.0")
230 (source
231 (origin
232 (method git-fetch)
233 (uri (git-reference
b0e7b699 234 (url "https://github.com/mruby/mruby")
933dad91
RW
235 (commit version)))
236 (file-name (git-file-name name version))
237 (sha256
238 (base32
239 "1r6w1asjshff43ymdwa6xmrkggza99mi2kw88k7ic6ag2j81hcj5"))))
240 (build-system gnu-build-system)
241 (arguments
242 `(#:test-target "test"
243 #:phases
244 (modify-phases %standard-phases
245 (delete 'configure)
246 (add-after 'unpack 'enable-verbose-tests
247 (lambda _
248 (substitute* "Makefile"
249 (("ruby ./minirake" m)
250 (string-append m " --verbose")))
251 #t))
252 (add-after 'unpack 'disable-broken-tests
253 (lambda _
254 (substitute* "mrbgems/mruby-io/test/io.rb"
255 (("assert\\('IO.popen.+$" m)
256 (string-append m "skip \"Hangs in the Guix build environment\"\n"))
257 (("assert\\('IO#isatty.+$" m)
258 (string-append m "skip \"Disable for Guix; there is no /dev/tty\"\n"))
259 ;; This one is really weird. The *expected* output is all wrong.
260 (("assert\\('`cmd`.*" m)
261 (string-append m "skip \"Disable for Guix\"\n"))
262 (("echo foo")
263 (string-append (which "echo") " foo")))
264 #t))
265 ;; There is no install target
266 (replace 'install
267 (lambda* (#:key outputs #:allow-other-keys)
268 (let* ((out (assoc-ref outputs "out"))
269 (bin (string-append out "/bin"))
270 (lib (string-append out "/lib")))
271 (mkdir-p bin)
272 (copy-recursively "build/host/bin" bin)
273 (mkdir-p lib)
274 (copy-recursively "build/host/lib" lib))
275 #t)))))
276 (native-inputs
277 `(("ruby" ,ruby)
278 ("bison" ,bison)))
279 (home-page "https://github.com/mruby/mruby")
280 (synopsis "Lightweight Ruby")
281 (description "mruby is the lightweight implementation of the Ruby
282language. Its syntax is Ruby 1.9 compatible. mruby can be linked and
283embedded within your application.")
284 (license license:expat)))
285
34372d39
RW
286(define-public ruby-commander
287 (package
288 (name "ruby-commander")
289 (version "4.4.7")
290 (source
291 (origin
292 (method url-fetch)
293 (uri (rubygems-uri "commander" version))
294 (sha256
295 (base32
296 "1pxakz596fjqak3cdbha6iva1dlqis86i3kjrgg6lf3sp8i5vhwg"))))
297 (build-system ruby-build-system)
298 (arguments
299 `(#:test-target "spec"
300 #:phases
301 (modify-phases %standard-phases
302 ;; Don't run or require rubocop, the code linting tool, as this is a
303 ;; bit unnecessary.
304 (add-after 'unpack 'dont-run-rubocop
305 (lambda _
306 (substitute* "Rakefile"
307 ((".*rubocop.*") "")
308 ((".*RuboCop.*") ""))
309 #t)))))
310 (propagated-inputs
311 `(("ruby-highline" ,ruby-highline)))
312 (native-inputs
313 `(("bundler" ,bundler)
314 ("ruby-rspec-core" ,ruby-rspec-core)
315 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
316 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
317 ("ruby-simplecov" ,ruby-simplecov)))
318 (home-page "https://github.com/commander-rb/commander")
319 (synopsis "Library for building Ruby command-line executables")
320 (description
321 "Commander aims to be a complete solution for Ruby command-line
322executables. Commander bridges the gap between other terminal related
323libraries (OptionParser, HighLine), while providing many new features, and an
324elegant API.")
325 (license license:expat)))
326
823ed097
CB
327(define-public ruby-highline
328 (package
329 (name "ruby-highline")
6742c6f6 330 (version "2.0.1")
823ed097
CB
331 (source
332 (origin
333 (method url-fetch)
334 (uri (rubygems-uri "highline" version))
335 (sha256
336 (base32
6742c6f6 337 "0gr6pckj2jayxw1gdgh9193j5jag5zrrqqlrnl4jvcwpyd3sn2zc"))))
823ed097
CB
338 (build-system ruby-build-system)
339 (arguments
340 `(#:tests? #f)) ;; TODO: NameError: uninitialized constant SPEC
341 (native-inputs
342 `(("bundler" ,bundler)
343 ("ruby-code-statistics" ,ruby-code-statistics)))
344 (synopsis
345 "HighLine helps you build command-line interfaces")
346 (description
347 "HighLine provides a high-level IO library that provides validation,
348type conversion, and more for command-line interfaces. HighLine also includes
349a menu system for providing multiple options to the user.")
350 (home-page "https://github.com/JEG2/highline")
351 (license (list license:gpl2 license:ruby))))
352
bda0c139
DT
353(define-public ruby-hoe
354 (package
355 (name "ruby-hoe")
d0d2dd24 356 (version "3.21.0")
bda0c139 357 (source (origin
e83c6d00
DT
358 (method url-fetch)
359 (uri (rubygems-uri "hoe" version))
bda0c139
DT
360 (sha256
361 (base32
d0d2dd24 362 "0qid0n56mgsjvq5ksxajv0gb92akky8imwgvw22ajms5g4fd6nf4"))))
bda0c139 363 (build-system ruby-build-system)
d0d2dd24
CB
364 (arguments
365 '(#:phases
366 (modify-phases %standard-phases
367 ;; One of the tests fails if the SOURCE_DATE_EPOCH environment
368 ;; variable is set, so unset it for the duration of the tests.
369 ;;
370 ;; TestHoe#test_possibly_better
371 ;; [/tmp/guix-build-ruby-hoe-3.20.0.drv-0/gem/test/test_hoe.rb:250]:
372 ;; Expected: 2019-11-12 00:00:00 UTC
373 ;; Actual: 1970-01-01 00:00:00 UTC
374 (add-before 'check 'unset-SOURCE-DATE-EPOCH
375 (lambda _
376 (unsetenv "SOURCE_DATE_EPOCH")
377 #t))
378 (add-after 'check 'set-SOURCE-DATE-EPOCH-again
379 (lambda _
380 (setenv "SOURCE_DATE_EPOCH" "1")
381 #t)))))
bda0c139
DT
382 (synopsis "Ruby project management helper")
383 (description
384 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
385maintain, and release projects and includes a dynamic plug-in system allowing
386for easy extensibility. Hoe ships with plug-ins for all the usual project
387tasks including rdoc generation, testing, packaging, deployment, and
388announcement.")
2f3800e5 389 (home-page "https://www.zenspider.com/projects/hoe.html")
bda0c139
DT
390 (license license:expat)))
391
022170dc
PP
392(define-public ruby-rake-compiler
393 (package
394 (name "ruby-rake-compiler")
7ac6bd00 395 (version "1.1.0")
022170dc
PP
396 (source (origin
397 (method url-fetch)
e83c6d00 398 (uri (rubygems-uri "rake-compiler" version))
022170dc
PP
399 (sha256
400 (base32
7ac6bd00 401 "0l4hg21v0phfrfsc2hilgmwvn2imxr0byqh8dv16bya1s5d3km0q"))))
022170dc
PP
402 (build-system ruby-build-system)
403 (arguments
e83c6d00 404 '(#:tests? #f)) ; needs cucumber
022170dc 405 (synopsis "Building and packaging helper for Ruby native extensions")
e881752c 406 (description "Rake-compiler provides a framework for building and
022170dc
PP
407packaging native C and Java extensions in Ruby.")
408 (home-page "https://github.com/rake-compiler/rake-compiler")
409 (license license:expat)))
410
30f08487
RW
411(define-public ruby-rsync
412 (package
413 (name "ruby-rsync")
414 (version "1.0.9")
415 (source
416 (origin
417 (method url-fetch)
418 (uri (rubygems-uri "rsync" version))
419 (sha256
420 (base32
421 "0p8b27q1gvxilqfq2528xpwglzcm2myikkjxpqk7mwbwg9r6knxv"))))
422 (build-system ruby-build-system)
423 (arguments
424 '(#:test-target "spec"
425 #:phases
426 (modify-phases %standard-phases
427 (add-after 'unpack 'remove-coveralls-requirement
428 (lambda _
429 (substitute* "spec/spec_helper.rb"
430 (("require 'coveralls'") "")
431 (("Coveralls.wear!") ""))
432 #t)))))
433 (native-inputs
434 `(("bundler" ,bundler)
435 ("rsync" ,rsync)
436 ("ruby-rspec-core" ,ruby-rspec-core)
437 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
438 ("ruby-rspec-mocks" ,ruby-rspec-mocks)))
439 (home-page "https://github.com/jbussdieker/ruby-rsync")
440 (synopsis "Ruby wrapper around rsync")
441 (description
442 "Ruby Rsync is a Ruby library that can synchronize files between remote
443hosts by wrapping the @file{rsync} binary.")
444 (license license:expat)))
445
acf735f2
DT
446(define-public ruby-i18n
447 (package
448 (name "ruby-i18n")
92dddf6b 449 (version "1.7.0")
acf735f2
DT
450 (source (origin
451 (method url-fetch)
e83c6d00 452 (uri (rubygems-uri "i18n" version))
acf735f2
DT
453 (sha256
454 (base32
92dddf6b 455 "0hmypvx9iyc0b4hski7aic2xzm09cg1c7q1qlpnk3k8s5acxzyhl"))))
acf735f2
DT
456 (build-system ruby-build-system)
457 (arguments
0bfdfd37 458 '(#:tests? #f)) ; no tests
cbb50182 459 (propagated-inputs `(("concurrent-ruby" ,ruby-concurrent)))
acf735f2
DT
460 (synopsis "Internationalization library for Ruby")
461 (description "Ruby i18n is an internationalization and localization
462solution for Ruby programs. It features translation and localization,
463interpolation of values to translations, pluralization, customizable
464transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
465translation data, custom key/scope separator, custom exception handlers, and
466an extensible architecture with a swappable backend.")
92dddf6b 467 (home-page "https://github.com/ruby-i18n/i18n")
acf735f2 468 (license license:expat)))
eb0c2dd6 469
62b138ca
CB
470(define-public ruby-iruby
471 (package
472 (name "ruby-iruby")
473 (version "0.3")
474 (source
475 (origin
476 (method url-fetch)
477 (uri (rubygems-uri "iruby" version))
478 (sha256
479 (base32
480 "1wdf2c0x8y6cya0n3y0p3p7b1sxkb2fdavdn2k58rf4rs37s7rzn"))))
481 (build-system ruby-build-system)
482 (arguments
483 ;; TODO: Tests currently fail.
484 ;;
485 ;; Finished in 1.764405s, 1.1335 runs/s, 5.1009 assertions/s.
486 ;;
487 ;; 1) Failure:
488 ;; IntegrationTest#test_interaction [/tmp/guix-build-ruby-iruby-0.3.drv-0/gem/test/integration_test.rb:25]:
489 ;; In [ expected
490 ;;
491 ;; 2 runs, 9 assertions, 1 failures, 0 errors, 0 skips
492 '(#:tests? #f
493 #:phases
494 (modify-phases %standard-phases
495 (add-after 'unpack 'patch-ipython
496 (lambda* (#:key inputs #:allow-other-keys)
497 (substitute* "lib/iruby/command.rb"
498 (("version = `")
499 (string-append
500 "version = `"
501 (assoc-ref inputs "python-ipython")
502 "/bin/"))
503 (("Kernel\\.exec\\('")
504 (string-append
505 "Kernel.exec('"
506 (assoc-ref inputs "python-ipython")
507 "/bin/")))
508 #t)))))
509 (inputs
510 `(("python-ipython" ,python-ipython)))
511 (propagated-inputs
512 `(("ruby-bond" ,ruby-bond)
513 ("ruby-data_uri" ,ruby-data_uri)
514 ("ruby-mimemagic" ,ruby-mimemagic)
515 ("ruby-multi-json" ,ruby-multi-json)
516 ("ruby-cztop" ,ruby-cztop)
517 ;; Optional inputs
518 ("ruby-pry" ,ruby-pry)))
519 (synopsis "Ruby kernel for Jupyter/IPython")
520 (description
521 "This package provides a Ruby kernel for Jupyter/IPython frontends (e.g.
522notebook).")
523 (home-page "https://github.com/SciRuby/iruby")
524 (license license:expat)))
525
eb0c2dd6
DT
526;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
527;; dependencies use RSpec for their test suites! To avoid these circular
528;; dependencies, we disable tests for all of the RSpec-related packages.
87688ff3 529(define-public ruby-rspec-support
eb0c2dd6
DT
530 (package
531 (name "ruby-rspec-support")
bee67d18 532 (version "3.8.0")
eb0c2dd6
DT
533 (source (origin
534 (method url-fetch)
e83c6d00 535 (uri (rubygems-uri "rspec-support" version))
eb0c2dd6
DT
536 (sha256
537 (base32
bee67d18 538 "0p3m7drixrlhvj2zpc38b11x145bvm311x6f33jjcxmvcm0wq609"))))
eb0c2dd6
DT
539 (build-system ruby-build-system)
540 (arguments
541 '(#:tests? #f)) ; avoid dependency cycles
542 (synopsis "RSpec support library")
543 (description "Support utilities for RSpec gems.")
544 (home-page "https://github.com/rspec/rspec-support")
545 (license license:expat)))
546
547(define-public ruby-rspec-core
548 (package
549 (name "ruby-rspec-core")
bee67d18 550 (version "3.8.0")
eb0c2dd6
DT
551 (source (origin
552 (method url-fetch)
e83c6d00 553 (uri (rubygems-uri "rspec-core" version))
eb0c2dd6
DT
554 (sha256
555 (base32
bee67d18 556 "1p1s5bnbqp3sxk67y0fh0x884jjym527r0vgmhbm81w7aq6b7l4p"))))
eb0c2dd6
DT
557 (build-system ruby-build-system)
558 (arguments
559 '(#:tests? #f)) ; avoid dependency cycles
560 (propagated-inputs
561 `(("ruby-rspec-support" ,ruby-rspec-support)))
562 (synopsis "RSpec core library")
563 (description "Rspec-core provides the RSpec test runner and example
564groups.")
565 (home-page "https://github.com/rspec/rspec-core")
566 (license license:expat)))
e6962009 567
64c318f2
BW
568(define-public ruby-rspec-core-2
569 (package (inherit ruby-rspec-core)
570 (version "2.14.8")
571 (source (origin
572 (method url-fetch)
573 (uri (rubygems-uri "rspec-core" version))
574 (sha256
575 (base32
576 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
577 (propagated-inputs `())))
578
20c05ea9 579(define-public ruby-diff-lcs
e6962009
DT
580 (package
581 (name "ruby-diff-lcs")
e2fcef39 582 (version "1.3")
e6962009
DT
583 (source (origin
584 (method url-fetch)
e83c6d00 585 (uri (rubygems-uri "diff-lcs" version))
e6962009
DT
586 (sha256
587 (base32
e2fcef39 588 "18w22bjz424gzafv6nzv98h0aqkwz3d9xhm7cbr1wfbyas8zayza"))))
e6962009
DT
589 (build-system ruby-build-system)
590 (arguments
591 '(#:tests? #f)) ; avoid dependency cycles
592 (synopsis "Compute the difference between two Enumerable sequences")
593 (description "Diff::LCS computes the difference between two Enumerable
594sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
595It includes utilities to create a simple HTML diff output format and a
596standard diff-like tool.")
597 (home-page "https://github.com/halostatue/diff-lcs")
598 (license license:expat)))
599
600(define-public ruby-rspec-expectations
601 (package
602 (name "ruby-rspec-expectations")
bee67d18 603 (version "3.8.2")
e6962009
DT
604 (source (origin
605 (method url-fetch)
e83c6d00 606 (uri (rubygems-uri "rspec-expectations" version))
e6962009
DT
607 (sha256
608 (base32
bee67d18 609 "18l21hy1zdc2pgc2yb17k3n2al1khpfr0z6pijlm852iz6vj0dkm"))))
e6962009
DT
610 (build-system ruby-build-system)
611 (arguments
612 '(#:tests? #f)) ; avoid dependency cycles
613 (propagated-inputs
614 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 615 ("ruby-diff-lcs" ,ruby-diff-lcs)))
e881752c 616 (synopsis "RSpec expectations library")
e6962009
DT
617 (description "Rspec-expectations provides a simple API to express expected
618outcomes of a code example.")
619 (home-page "https://github.com/rspec/rspec-expectations")
620 (license license:expat)))
4f2a0cac 621
fb157f25
BW
622(define-public ruby-rspec-expectations-2
623 (package (inherit ruby-rspec-expectations)
624 (version "2.14.5")
625 (source (origin
626 (method url-fetch)
627 (uri (rubygems-uri "rspec-expectations" version))
628 (sha256
629 (base32
630 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
631 (propagated-inputs
632 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
633
818b402c
MC
634(define-public ruby-sorcerer
635 (package
636 (name "ruby-sorcerer")
637 (version "2.0.1")
638 (source
639 (origin
640 (method url-fetch)
641 (uri (rubygems-uri "sorcerer" version))
642 (sha256
643 (base32
644 "0d32ha9pp9slpmsm027pkdpbr9vc5jn2m8rl6hwwx6a87m8cr58h"))))
645 (build-system ruby-build-system)
646 (synopsis "Ripper-style abstract syntax tree to Ruby source generator")
647 (description "Sorcerer generates Ruby code from a Ripper-like abstract
648syntax tree (i.e. S-Expressions). Sorcerer is targeted mainly at small
649snippets of Ruby code, expressable in a single line. Longer examples may be
650re-sourced, but they will be rendered in a single line format.")
651 (home-page "https://github.com/rspec-given/sorcerer")
652 (license license:expat)))
653
906b9a14
MC
654(define-public ruby-given-core
655 (package
656 (name "ruby-given-core")
657 (version "3.8.0")
658 (source
659 (origin
660 (method url-fetch)
661 (uri (rubygems-uri "given_core" version))
662 (sha256
663 (base32
664 "1lzyqllbbv6as3qgwz2007mvy7wy247bgkch9adnmh1zfa73bkrg"))))
665 (build-system ruby-build-system)
666 (arguments '(#:tests? #f)) ;no test suite for the core package
667 (propagated-inputs
668 `(("ruby-sorcerer" ,ruby-sorcerer)))
669 (synopsis "Core abstractions used by rspec-given and minitest-given")
670 (description "Given_core is the basic functionality behind rspec-given and
671minitest-given, extensions that allow the use of Given/When/Then terminology
672when defining specifications.")
673 (home-page "https://github.com/rspec-given/rspec-given")
674 (license license:expat)))
675
9c171558
MC
676(define-public ruby-rspec-given
677 (package
678 (name "ruby-rspec-given")
679 (version "3.8.0")
680 (source
681 (origin
682 (method url-fetch)
683 (uri (rubygems-uri "rspec-given" version))
684 (sha256
685 (base32
686 "1783bazja10kbha8hk15khvybsq88siyax02cpkk688604h54nji"))))
687 (build-system ruby-build-system)
688 (arguments
689 `(#:test-target "rs"
690 #:phases
691 (modify-phases %standard-phases
692 (add-after 'unpack 'fix-rakefile
693 (lambda _
694 (substitute* '("Rakefile" "rakelib/gemspec.rake")
695 (("require '\\./lib/given/.*") "")
696 (("Given::VERSION") (format #f "~s" ,version))
697 ;; Fix the error: "cannot load such file -- example_helper"
698 (("sh \"rspec")
699 "sh \"rspec -Ilib:examples"))
700 #t))
701 (add-after 'extract-gemspec 'delete-failing-tests
702 ;; See: https://github.com/jimweirich/rspec-given/issues/57.
703 (lambda _
704 (substitute* ".gemspec"
705 (("\"spec/lib/given/natural_assertion_spec.rb\".freeze, ")
706 "")
707 (("\"examples/integration/failing_messages_spec.rb\".freeze, ")
708 ""))
709 (delete-file "spec/lib/given/natural_assertion_spec.rb")
710 (delete-file "examples/integration/failing_messages_spec.rb")
711 #t)))))
712 (native-inputs
713 `(("ruby-rspec" ,ruby-rspec)
714 ("ruby-minitest" ,ruby-minitest)))
715 (propagated-inputs
716 `(("ruby-given-core" ,ruby-given-core)
717 ("ruby-rspec" ,ruby-rspec)))
718 (synopsis "Given/When/Then for RSpec and Minitest")
719 (description "Given is an RSpec extension that allows the use of
720Given/When/Then terminology when defining specifications, in a way similar to
721the Cucumber Gherkin language.")
722 (home-page "https://github.com/rspec-given/rspec-given")
723 (license license:expat)))
724
999ffb26
DM
725(define-public ruby-rspec-its
726 (package
727 (name "ruby-rspec-its")
b2244c68 728 (version "1.3.0")
999ffb26
DM
729 (source
730 (origin
3306f02a
CB
731 (method git-fetch)
732 (uri (git-reference
b0e7b699 733 (url "https://github.com/rspec/rspec-its")
3306f02a
CB
734 (commit (string-append "v" version))))
735 (file-name (git-file-name name version))
999ffb26
DM
736 (sha256
737 (base32
b2244c68 738 "02mlsc9d4d1cjj5vahi8v3q8hyn9fyiv8nnlidhgfh186qp20g1p"))))
999ffb26
DM
739 (build-system ruby-build-system)
740 (arguments
3306f02a
CB
741 `(#:test-target "spec"
742 #:phases
743 (modify-phases %standard-phases
744 (add-after 'unpack 'dont-install-gems-from-gemfile
745 (lambda _
746 (substitute* "Gemfile"
747 (("rspec rspec-core rspec-expectations rspec-mocks rspec-support")
748 ""))
749 #t))
7c8eb479 750 (add-before 'build 'loosen-ffi-requirement
b2244c68 751 (lambda _
7c8eb479 752 ;; Accept any version of ruby-ffi.
b2244c68 753 (substitute* "Gemfile"
7c8eb479
MB
754 ((" gem 'ffi', '~> 1\\.9\\.25'")
755 " gem 'ffi'"))
b2244c68 756 #t))
3306f02a
CB
757 (add-before 'build 'remove-unnecessary-dependency-versions-from-gemfile
758 (lambda _
759 (substitute* "rspec-its.gemspec"
760 (("rake.*") "rake'\n")
b2244c68
BH
761 (("spec.add_development_dependency 'cucumber'.*")
762 "spec.add_development_dependency 'cucumber'\n")
3306f02a 763 (("bundler.*") "bundler'\n")
b2244c68 764 (("\"aruba.*") "'aruba'\n"))
3306f02a 765 #t)))))
999ffb26
DM
766 (propagated-inputs
767 `(("ruby-rspec-core" ,ruby-rspec-core)
768 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
3306f02a
CB
769 (native-inputs
770 `(("bundler" ,bundler)
771 ("ruby-cucumber" ,ruby-cucumber)
b2244c68 772 ("ruby-ffi" ,ruby-ffi)
3306f02a
CB
773 ("ruby-aruba" ,ruby-aruba)))
774 (synopsis "RSpec extension that provides the @code{its} method")
775 (description
776 "RSpec::Its provides the its method as a short-hand to specify the expected
777value of an attribute. For example, one can use @code{its(:size)\\{should
778eq(1)\\}}.")
999ffb26
DM
779 (home-page "https://github.com/rspec/rspec-its")
780 (license license:expat)))
781
d7bd7016
MC
782;;; This variant is used to break a cycle with ruby-protobuf.
783(define-public ruby-rspec-its-minimal
784 (hidden-package
785 (package
786 (inherit ruby-rspec-its)
787 (arguments
788 (substitute-keyword-arguments (package-arguments ruby-rspec-its)
789 ((#:tests? _ #f) #f)))
790 (native-inputs '()))))
791
4f2a0cac
DT
792(define-public ruby-rspec-mocks
793 (package
794 (name "ruby-rspec-mocks")
bee67d18 795 (version "3.8.0")
4f2a0cac
DT
796 (source (origin
797 (method url-fetch)
e83c6d00 798 (uri (rubygems-uri "rspec-mocks" version))
4f2a0cac
DT
799 (sha256
800 (base32
bee67d18 801 "06y508cjqycb4yfhxmb3nxn0v9xqf17qbd46l1dh4xhncinr4fyp"))))
4f2a0cac
DT
802 (build-system ruby-build-system)
803 (arguments
804 '(#:tests? #f)) ; avoid dependency cycles
805 (propagated-inputs
806 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 807 ("ruby-diff-lcs" ,ruby-diff-lcs)))
4f2a0cac
DT
808 (synopsis "RSpec stubbing and mocking library")
809 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
810support for stubbing and mocking.")
811 (home-page "https://github.com/rspec/rspec-mocks")
812 (license license:expat)))
d4fde1f2 813
6da9adeb
BW
814(define-public ruby-rspec-mocks-2
815 (package (inherit ruby-rspec-mocks)
816 (version "2.14.6")
817 (source (origin
818 (method url-fetch)
819 (uri (rubygems-uri "rspec-mocks" version))
820 (sha256
821 (base32
822 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
823 (propagated-inputs
824 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
825
198bc648
CB
826(define-public ruby-rspec-rerun
827 (package
828 (name "ruby-rspec-rerun")
829 (version "1.1.0")
830 (source
831 (origin
832 (method url-fetch)
833 (uri (rubygems-uri "rspec-rerun" version))
834 (sha256
835 (base32
836 "1gy7znkcaqhpccfnk2nvaqbsvgxy3q57cmjwkl9fi1zabaq5lbkj"))))
837 (build-system ruby-build-system)
838 (arguments
839 '(;; No included tests
840 #:tests? #f))
841 (propagated-inputs `(("ruby-rspec" ,ruby-rspec)))
842 (synopsis "Track failed RSpec tests to re-run them")
843 (description
844 "This package provides an automated way to track, and then re-run failed
845RSpec tests.")
846 (home-page "https://github.com/dblock/rspec-rerun")
847 (license license:expat)))
848
9c4cb1ef
CD
849(define-public ruby-rspec-wait
850 (package
851 (name "ruby-rspec-wait")
852 (version "0.0.9")
853 (source
854 (origin
855 (method url-fetch)
856 (uri (rubygems-uri "rspec-wait" version))
857 (sha256
858 (base32
859 "0gvj1bp5ccx001dyvcgk2j49s5sl6vs9fdaqqb08z3bd1554hsww"))))
860 (build-system ruby-build-system)
861 (arguments
862 '(#:phases
863 (modify-phases %standard-phases
864 (replace 'check
865 (lambda _
866 (invoke "rake" "spec"))))))
867 (native-inputs
868 `(("bundler" ,bundler)))
869 (propagated-inputs
870 `(("ruby-rspec" ,ruby-rspec)))
871 (home-page "https://github.com/laserlemon/rspec-wait")
872 (synopsis "Wait for conditions in RSpec")
873 (description
874 "RSpec::Wait strives to make it easier to test asynchronous or slow
875interactions.")
876 (license license:expat)))
877
d4fde1f2
DT
878(define-public ruby-rspec
879 (package
880 (name "ruby-rspec")
bee67d18 881 (version "3.8.0")
d4fde1f2
DT
882 (source (origin
883 (method url-fetch)
e83c6d00 884 (uri (rubygems-uri "rspec" version))
d4fde1f2
DT
885 (sha256
886 (base32
bee67d18 887 "15ppasvb9qrscwlyjz67ppw1lnxiqnkzx5vkx1bd8x5n3dhikxc3"))))
d4fde1f2
DT
888 (build-system ruby-build-system)
889 (arguments
890 '(#:tests? #f)) ; avoid dependency cycles
891 (propagated-inputs
892 `(("ruby-rspec-core" ,ruby-rspec-core)
893 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
894 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
895 (synopsis "Behavior-driven development framework for Ruby")
896 (description "RSpec is a behavior-driven development (BDD) framework for
897Ruby. This meta-package includes the RSpec test runner, along with the
898expectations and mocks frameworks.")
35739712 899 (home-page "https://rspec.info/")
d4fde1f2 900 (license license:expat)))
2cbc105b 901
5ac984b3
BW
902(define-public ruby-rspec-2
903 (package (inherit ruby-rspec)
904 (version "2.14.1")
905 (source (origin
906 (method url-fetch)
907 (uri (rubygems-uri "rspec" version))
908 (sha256
909 (base32
910 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
911 (propagated-inputs
912 `(("ruby-rspec-core" ,ruby-rspec-core-2)
913 ("ruby-rspec-mocks" ,ruby-rspec-mocks-2)
914 ("ruby-rspec-expectations" ,ruby-rspec-expectations-2)))))
915
2cbc105b
DT
916;; Bundler is yet another source of circular dependencies, so we must disable
917;; its test suite as well.
918(define-public bundler
919 (package
920 (name "bundler")
cbee8e31 921 (version "2.1.4")
2cbc105b
DT
922 (source (origin
923 (method url-fetch)
e83c6d00 924 (uri (rubygems-uri "bundler" version))
2cbc105b
DT
925 (sha256
926 (base32
cbee8e31 927 "12glbb1357x91fvd004jgkw7ihlkpc9dwr349pd7j83isqhls0ah"))))
2cbc105b
DT
928 (build-system ruby-build-system)
929 (arguments
930 '(#:tests? #f)) ; avoid dependency cycles
931 (synopsis "Ruby gem bundler")
932 (description "Bundler automatically downloads and installs a list of gems
933specified in a \"Gemfile\", as well as their dependencies.")
2f3800e5 934 (home-page "https://bundler.io/")
2cbc105b 935 (license license:expat)))
98b87b82 936
cf36174f
RW
937(define-public ruby-builder
938 (package
939 (name "ruby-builder")
42b48db2 940 (version "3.2.3")
cf36174f
RW
941 (source (origin
942 (method url-fetch)
943 (uri (rubygems-uri "builder" version))
944 (sha256
945 (base32
42b48db2 946 "0qibi5s67lpdv1wgcj66wcymcr04q6j4mzws6a479n0mlrmh5wr1"))))
cf36174f
RW
947 (build-system ruby-build-system)
948 (arguments
949 `(#:phases
950 (modify-phases %standard-phases
951 (add-after 'unpack 'do-not-use-rvm
952 (lambda _
953 (substitute* "rakelib/tags.rake"
954 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
955 #t)))))
956 (synopsis "Ruby library to create structured data")
957 (description "Builder provides a number of builder objects that make it
958easy to create structured data. Currently the following builder objects are
959supported: XML Markup and XML Events.")
960 (home-page "https://github.com/jimweirich/builder")
961 (license license:expat)))
962
566f71f8
CB
963(define-public ruby-bump
964 (package
965 (name "ruby-bump")
966 (version "0.7.0")
967 (source
968 (origin
969 (method url-fetch)
970 (uri (rubygems-uri "bump" version))
971 (sha256
972 (base32
973 "1xinbr9rzh6cj75x24niwgqcnbhdxc68a8bc41lk8xv6fd906fym"))))
974 (build-system ruby-build-system)
975 (arguments
976 '(;; No included tests
977 #:tests? #f))
978 (synopsis "Tool for working with Rubygems")
979 (description
980 "Bump provides commands to manage Rubygem versioning, updating to the
981next patch version for example.")
982 (home-page "https://github.com/gregorym/bump")
983 (license license:expat)))
984
ad79eb55
RW
985(define-public ruby-rjb
986 (package
987 (name "ruby-rjb")
aeb4e61e 988 (version "1.5.5")
ad79eb55
RW
989 (source (origin
990 (method url-fetch)
991 (uri (rubygems-uri "rjb" version))
992 (sha256
993 (base32
aeb4e61e 994 "1ppj8rbicj3w0nhh7f73mflq19yd7pzdzkh2a91hcvphriy5b0ca"))))
ad79eb55
RW
995 (build-system ruby-build-system)
996 (arguments
997 `(#:tests? #f ; no rakefile
998 #:phases
999 (modify-phases %standard-phases
1000 (add-before 'build 'set-java-home
1001 (lambda* (#:key inputs #:allow-other-keys)
1002 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
1003 #t)))))
1004 (native-inputs
d2540f80 1005 `(("jdk" ,icedtea "jdk")))
ad79eb55
RW
1006 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
1007 (description "RJB is a bridge program that connects Ruby and Java via the
1008Java Native Interface.")
2f3800e5 1009 (home-page "https://www.artonx.org/collabo/backyard/?RubyJavaBridge")
ad79eb55
RW
1010 (license license:lgpl2.1+)))
1011
f9ae2c06
PP
1012(define-public ruby-log4r
1013 (package
1014 (name "ruby-log4r")
1015 (version "1.1.10")
1016 (source
1017 (origin
1018 (method url-fetch)
1019 (uri (rubygems-uri "log4r" version))
1020 (sha256
1021 (base32
1022 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
1023 (build-system ruby-build-system)
1024 (arguments
1025 '(#:tests? #f)) ; no Rakefile in gem
1026 (synopsis "Flexible logging library for Ruby")
1027 (description "Comprehensive and flexible logging library written
1028in Ruby for use in Ruby programs. It features a hierarchical logging
1029system of any number of levels, custom level names, logger
1030inheritance, multiple output destinations per log event, execution
1031tracing, custom formatting, thread safteyness, XML and YAML
1032configuration, and more.")
1033 (home-page "http://log4r.rubyforge.org/")
1034 (license license:bsd-3)))
1035
71a03c29
RW
1036(define-public ruby-atoulme-antwrap
1037 (package
1038 (name "ruby-atoulme-antwrap")
1039 (version "0.7.5")
1040 (source (origin
1041 (method url-fetch)
1042 (uri (rubygems-uri "atoulme-Antwrap" version))
1043 (sha256
1044 (base32
1045 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
1046 (build-system ruby-build-system)
1047 ;; Test data required for most of the tests are not included.
1048 (arguments `(#:tests? #f))
1049 (native-inputs
1050 `(("ruby-hoe" ,ruby-hoe)))
1051 (inputs
1052 `(("ruby-rjb" ,ruby-rjb)))
1053 (synopsis "Ruby wrapper for the Ant build tool")
1054 (description "Antwrap is a Ruby module that wraps the Apache Ant build
1055tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
1056script.")
1057 (home-page "http://rubyforge.org/projects/antwrap/")
1058 (license license:expat)))
1059
fe1ddad5
RW
1060(define-public ruby-atoulme-saikuro
1061 (package
1062 (name "ruby-atoulme-saikuro")
1063 (version "1.2.1")
1064 (source (origin
1065 (method url-fetch)
1066 (uri (rubygems-uri "atoulme-Saikuro" version))
1067 (sha256
1068 (base32
1069 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
1070 (build-system ruby-build-system)
1071 ;; FIXME: There are no unit tests. The tests are demonstrations of the
1072 ;; "saikuro" tool.
1073 (arguments `(#:tests? #f))
1074 (synopsis "Cyclomatic complexity analyzer")
1075 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
1076given Ruby source code Saikuro will generate a report listing the cyclomatic
1077complexity of each method found. In addition, Saikuro counts the number of
1078lines per method and can generate a listing of the number of tokens on each
1079line of code.")
1080 (home-page "http://www.github.com/atoulme/Saikuro")
1081 ;; File headers contain the BSD-3 license and the README.rdoc says that
1082 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
1083 ;; of the Expat license.
1084 (license license:bsd-3)))
1085
c84dd8d4
MC
1086(define-public ruby-pandoc-ruby
1087 (package
1088 (name "ruby-pandoc-ruby")
1089 (version "2.1.4")
1090 (source
1091 (origin
1092 (method git-fetch) ;the gem lacks many test files
1093 (uri (git-reference
b0e7b699 1094 (url "https://github.com/xwmx/pandoc-ruby")
c84dd8d4
MC
1095 (commit version)))
1096 (file-name (git-file-name name version))
1097 (sha256
1098 (base32
1099 "03a11clhycyn0jhc7g9davpqd83sn60jqwjy1y145ag9sq6sp935"))))
1100 (build-system ruby-build-system)
1101 (arguments
1102 `(#:phases
1103 (modify-phases %standard-phases
1104 (add-after 'unpack 'disable-failing-tests
1105 ;; TODO: Remove this phase after ghc-pandoc gets upgraded to 2.9.2+
1106 ;; (see: https://github.com/xwmx/pandoc-ruby/issues/39).
1107 (lambda _
1108 (substitute* "test/test_conversions.rb"
1109 (("next if from == to.*" all)
1110 (string-append
1111 all
1112 " next if ['plain', 'beamer'].include? to\n")))
1113 #t))
1114 (add-after 'unpack 'patch-pandoc-path
1115 (lambda* (#:key inputs #:allow-other-keys)
1116 (let ((pandoc (string-append (assoc-ref inputs "ghc-pandoc")
1117 "/bin/pandoc")))
1118 (substitute* "lib/pandoc-ruby.rb"
1119 (("@@pandoc_path = 'pandoc'")
1120 (format #f "@@pandoc_path = '~a'" pandoc)))
1121 (substitute* "test/test_pandoc_ruby.rb"
1122 (("('|\")pandoc" _ quote)
1123 (string-append quote pandoc))
1124 (("\\^pandoc")
1125 ".*pandoc"))
1126 #t)))
1127 (add-after 'extract-gemspec 'remove-Gemfile.lock
1128 (lambda _
1129 (delete-file "Gemfile.lock")
1130 (substitute* "pandoc-ruby.gemspec"
1131 (("Gemfile\\.lock") ""))
1132 #t)))))
1133 (native-inputs
1134 `(("ruby-mocha" ,ruby-mocha)))
1135 (inputs
1136 `(("ghc-pandoc" ,ghc-pandoc)))
1137 (synopsis "Ruby wrapper for Pandoc")
1138 (description "PandocRuby is a wrapper for Pandoc, a Haskell library with
1139command line tools for converting one markup format to another. Pandoc can
1140convert documents from a variety of formats including markdown,
1141reStructuredText, textile, HTML, DocBook, LaTeX, and MediaWiki markup to a
1142variety of other formats, including markdown, reStructuredText, HTML, LaTeX,
1143ConTeXt, PDF, RTF, DocBook XML, OpenDocument XML, ODT, GNU Texinfo, MediaWiki
1144markup, groff man pages, HTML slide shows, EPUB, Microsoft Word docx, and
1145more.")
1146 (home-page "https://github.com/xwmx/pandoc-ruby")
1147 (license license:expat)))
1148
fef0564c
MC
1149(define-public ruby-slim
1150 (package
1151 (name "ruby-slim")
1152 (version "4.1.0")
1153 (source
1154 (origin
1155 (method url-fetch)
1156 (uri (rubygems-uri "slim" version))
1157 (sha256
1158 (base32
1159 "0gjx30g84c82qzg32bd7giscvb4206v7mvg56kc839w9wjagn36n"))))
1160 (build-system ruby-build-system)
1161 (arguments
1162 `(#:phases
1163 (modify-phases %standard-phases
1164 ;; See: https://github.com/slim-template/slim/issues/857 and
1165 ;; https://github.com/slim-template/slim/issues/858.
1166 (add-after 'unpack 'skip-broken-tests
1167 (lambda _
1168 (substitute* "test/core/test_embedded_engines.rb"
1169 (("def test_render_with_markdown")
1170 "def skipped_test_render_with_markdown"))
1171 (substitute* "test/translator/test_translator.rb"
1172 (("raise (\"Missing test for.*)" _ tail)
1173 (string-append "print " tail)))
1174 #t))
1175 ;; See: https://salsa.debian.org/ruby-team/ruby-slim/-/commit/
1176 ;; 824862bd99d1675bc699d8fc71ba965a785c1f44.
1177 (add-after 'unpack 'prevent-bundler-interference
1178 (lambda _
1179 (substitute* "Rakefile"
1180 (("require 'bundler/setup'") "nil")
1181 (("Bundler::GemHelper\\.install_tasks") "nil"))
1182 #t)))))
1183 (native-inputs
1184 `(("ruby-rack-test" ,ruby-rack-test)
1185 ("ruby-sinatra" ,ruby-sinatra)))
1186 (propagated-inputs
1187 `(("ruby-temple" ,ruby-temple)
1188 ("ruby-tilt" ,ruby-tilt)))
1189 (synopsis "Minimalist template language for Ruby")
1190 (description "Slim is a template language for Ruby that aims to reduce the
1191syntax to the minimum while remaining clear.")
1192 (home-page "http://slim-lang.com/")
1193 (license license:expat)))
1194
34138e42
BW
1195(define-public ruby-asciidoctor
1196 (package
751bf33d 1197 (name "ruby-asciidoctor")
5df1126c 1198 (version "2.0.10")
751bf33d
MC
1199 (source
1200 (origin
5df1126c
MC
1201 (method git-fetch) ;the gem release lacks a Rakefile
1202 (uri (git-reference
b0e7b699 1203 (url "https://github.com/asciidoctor/asciidoctor")
5df1126c
MC
1204 (commit (string-append "v" version))))
1205 (file-name (git-file-name name version))
751bf33d 1206 (sha256
34138e42 1207 (base32
5df1126c 1208 "0jaxpnsdnx3qyjw5p2lsx1swny12q1i2vxw2kgdp4vlsyjv95z95"))))
751bf33d
MC
1209 (build-system ruby-build-system)
1210 (arguments
1211 `(#:test-target "test:all"
1212 #:phases
1213 (modify-phases %standard-phases
5df1126c 1214 (replace 'replace-git-ls-files
751bf33d 1215 (lambda _
5df1126c
MC
1216 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1217 ;; git ls-files output is merged in ruby-build-system.
1218 (substitute* "asciidoctor.gemspec"
1219 (("`git ls-files -z`")
1220 "`find . -type f -print0 |sort -z|cut -zc3-`"))
1221 #t))
1222 (add-after 'extract-gemspec 'strip-version-requirements
1223 (lambda _
1224 (delete-file "Gemfile")
1225 (substitute* "asciidoctor.gemspec"
1226 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1227 (string-append stripped "\n")))
751bf33d
MC
1228 #t)))))
1229 (native-inputs
5df1126c
MC
1230 `(("ruby-erubis" ,ruby-erubis)
1231 ("ruby-minitest" ,ruby-minitest)
751bf33d
MC
1232 ("ruby-nokogiri" ,ruby-nokogiri)
1233 ("ruby-asciimath" ,ruby-asciimath)
5df1126c
MC
1234 ("ruby-coderay" ,ruby-coderay)
1235 ("ruby-cucumber" ,ruby-cucumber)
1236 ("ruby-haml" ,ruby-haml)
1237 ("ruby-rouge" ,ruby-rouge)
1238 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
1239 ("ruby-simplecov" ,ruby-simplecov)
1240 ("ruby-slim" ,ruby-slim)
1241 ("ruby-tilt" ,ruby-tilt)))
751bf33d
MC
1242 (synopsis "Converter from AsciiDoc content to other formats")
1243 (description "Asciidoctor is a text processor and publishing toolchain for
1244converting AsciiDoc content to HTML5, DocBook 5 (or 4.5), PDF, and other
1245formats.")
1246 (home-page "https://asciidoctor.org")
1247 (license license:expat)))
34138e42 1248
15b188c3
MC
1249(define-public ruby-prawn-icon
1250 (package
1251 (name "ruby-prawn-icon")
1252 (version "2.5.0")
1253 (source
1254 (origin
1255 (method url-fetch)
1256 (uri (rubygems-uri "prawn-icon" version))
1257 (sha256
1258 (base32
1259 "1ivkdf8rdf92hhy97vbmc2a4w97vcvqd58jcj4z9hz3hfsb1526w"))))
1260 (build-system ruby-build-system)
1261 (arguments
1262 `(#:test-target "spec"
1263 #:phases (modify-phases %standard-phases
1264 (add-after 'unpack 'remove-unnecessary-dependencies
1265 (lambda _
1266 (substitute* '("Rakefile" "spec/spec_helper.rb")
1267 ((".*[Bb]undler.*") "")
1268 (("^require 'rubocop.*") "")
1269 (("^RuboCop.*") ""))
1270 #t)))))
1271 (native-inputs
1272 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
1273 ("ruby-pdf-reader" ,ruby-pdf-reader)
1274 ("ruby-rspec" ,ruby-rspec)
1275 ("ruby-simplecov" ,ruby-simplecov)))
1276 (propagated-inputs
1277 `(("ruby-prawn" ,ruby-prawn)))
1278 (synopsis "Icon fonts for use with the Prawn PDF toolkit")
1279 (description "@code{Prawn::Icon} provides various icon fonts including
1280FontAwesome, PaymentFont and Foundation Icons for use with the Prawn PDF
1281toolkit.")
1282 (home-page "https://github.com/jessedoyle/prawn-icon/")
1283 (license %prawn-project-licenses)))
1284
2d877f6e
MC
1285(define-public ruby-css-parser
1286 (package
1287 (name "ruby-css-parser")
1288 (version "1.7.1")
1289 (source
1290 (origin
1291 (method url-fetch)
1292 (uri (rubygems-uri "css_parser" version))
1293 (sha256
1294 (base32
1295 "04c4dl8cm5rjr50k9qa6yl9r05fk9zcb1zxh0y0cdahxlsgcydfw"))))
1296 (build-system ruby-build-system)
1297 (arguments `(#:tests? #f)) ;gem doesn't ship with test suite
1298 (propagated-inputs
1299 `(("ruby-addressable" ,ruby-addressable)))
1300 (synopsis "Ruby Cascading Style Sheets (CSS) parser")
1301 (description "This package allows loading, parsing and cascading Cascading
1302Style Sheets (CSS) rule sets in Ruby.")
1303 (home-page "https://github.com/premailer/css_parser")
1304 (license license:expat)))
1305
95692655
MC
1306(define-public ruby-prawn-svg
1307 (package
1308 (name "ruby-prawn-svg")
1309 (version "0.30.0")
1310 (source
1311 (origin
1312 (method url-fetch)
1313 (uri (rubygems-uri "prawn-svg" version))
1314 (sha256
1315 (base32
1316 "0df3l49cy3xpwi0b73hmi2ykbjg9kjwrvhk0k3z7qhh5ghmmrn77"))))
1317 (build-system ruby-build-system)
1318 (arguments
1319 `(#:phases (modify-phases %standard-phases
1320 (add-after 'unpack 'do-not-use-bundler
1321 (lambda _
1322 (substitute* "spec/spec_helper.rb"
1323 ((".*[Bb]undler.*") ""))
1324 #t))
1325 (replace 'check
1326 (lambda* (#:key tests? #:allow-other-keys)
1327 (when tests?
1328 (invoke "rspec" "-Ilib" "-rprawn-svg"))
1329 #t)))))
1330 (native-inputs
1331 `(("ruby-rspec" ,ruby-rspec)))
1332 (propagated-inputs
1333 `(("ruby-css-parser" ,ruby-css-parser)
1334 ("ruby-prawn" ,ruby-prawn)))
1335 (synopsis "SVG renderer for the Prawn PDF library")
1336 (description "This library allows rendering Scalable Vector Graphics (SVG)
1337graphics directly into a Portable Document Format (PDF) document using the
1338Prawn module.")
1339 (home-page "https://github.com/mogest/prawn-svg")
1340 (license license:expat)))
1341
ce52f2b1
MC
1342(define-public ruby-prawn-templates
1343 (package
1344 (name "ruby-prawn-templates")
1345 (version "0.1.2")
1346 (source
1347 (origin
1348 (method git-fetch)
1349 (uri (git-reference
1350 (url "https://github.com/prawnpdf/prawn-templates.git")
1351 (commit version)))
1352 (file-name (git-file-name name version))
1353 (sha256
1354 (base32
1355 "0wll54wxxwixpwazfn4ffbqvqbfrl01cfsv8y11vnlzy7isx5xvl"))))
1356 (build-system ruby-build-system)
1357 (arguments
1358 `(#:phases (modify-phases %standard-phases
1359 (add-after 'unpack 'do-not-use-bundler
1360 (lambda _
1361 (substitute* "spec/spec_helper.rb"
1362 ((".*[Bb]undler.*") ""))
1363 #t))
1364 (replace 'check
1365 (lambda* (#:key tests? #:allow-other-keys)
1366 (when tests?
1367 (invoke "rspec"))
1368 #t)))))
1369 (native-inputs
1370 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
1371 ("ruby-rspec" ,ruby-rspec)))
1372 (propagated-inputs
1373 `(("ruby-pdf-reader" ,ruby-pdf-reader)
1374 ("ruby-prawn" ,ruby-prawn)))
1375 (synopsis "Prawn extension to include or combine PDF documents")
1376 (description "This @strong{unmaintained} package provides a Prawn
1377extension that allows including other Portable Document Format (PDF) documents
1378as background or combining several PDF documents into one. This functionality
1379used to be part of Prawn itself, but was extracted from Prawn 0.15.0 because
1380of its many longstanding issues.")
1381 (home-page "https://github.com/prawnpdf/prawn-templates")
1382 (license %prawn-project-licenses)))
1383
f949b60e
MC
1384(define-public ruby-polyglot
1385 (package
1386 (name "ruby-polyglot")
1387 (version "0.3.5")
1388 (source
1389 (origin
1390 (method url-fetch)
1391 (uri (rubygems-uri "polyglot" version))
1392 (sha256
1393 (base32
1394 "1bqnxwyip623d8pr29rg6m8r0hdg08fpr2yb74f46rn1wgsnxmjr"))))
1395 (build-system ruby-build-system)
1396 (arguments `(#:tests? #f)) ;no test suite
1397 (synopsis "Augment @code{require} to load non-Ruby file types")
1398 (description "The Polyglot library allows a Ruby module to register a
1399loader for the file type associated with a filename extension, and it augments
1400@code{require} to find and load matching files.")
1401 (home-page "https://github.com/cjheath/polyglot")
1402 (license license:expat)))
1403
1f183ca0
MC
1404(define-public ruby-treetop
1405 (package
1406 (name "ruby-treetop")
1407 (version "1.6.10")
1408 (source
1409 (origin
1410 (method git-fetch) ;no test suite in distributed gem
1411 (uri (git-reference
1412 (url "https://github.com/cjheath/treetop.git")
1413 (commit (string-append "v" version))))
1414 (file-name (git-file-name name version))
1415 (sha256
1416 (base32
1417 "1dmk94z6ivhrz5hsq68vl5vgydhkz89n394rha1ymddw3rymbfcv"))))
1418 (build-system ruby-build-system)
1419 (arguments
1420 `(#:test-target "spec"
1421 #:phases
1422 (modify-phases %standard-phases
1423 (replace 'replace-git-ls-files
1424 (lambda _
1425 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1426 ;; git ls-files output is merged in ruby-build-system.
1427 (substitute* "treetop.gemspec"
1428 (("`git ls-files -z`")
1429 "`find . -type f -print0 |sort -z|cut -zc3-`"))
1430 #t)))))
1431 (native-inputs
1432 `(("ruby-activesupport" ,ruby-activesupport)
1433 ("ruby-rr" ,ruby-rr)
1434 ("ruby-rspec" ,ruby-rspec)))
1435 (propagated-inputs
1436 `(("ruby-polyglot" ,ruby-polyglot)))
1437 (synopsis "Ruby-based parsing DSL based on parsing expression grammars")
1438 (description "This package provides a Ruby-based Parsing Expression
1439Grammar (PEG) parser generator Domain Specific Language (DSL).")
1440 (home-page "https://github.com/cjheath/treetop")
1441 (license license:expat)))
1442
66861792
MC
1443(define-public ruby-rubocop-performance
1444 (package
1445 (name "ruby-rubocop-performance")
1446 (version "1.7.1")
1447 (source
1448 (origin
1449 (method url-fetch)
1450 (uri (rubygems-uri "rubocop-performance" version))
1451 (sha256
1452 (base32
1453 "04r8d4x62ygv17spvz9yyfxbmbf8qxwhijs0xycfvzr0q4pyg9sw"))))
1454 (build-system ruby-build-system)
1455 (arguments
1456 `(#:tests? #f)) ;no test suite in the distributed gem
1457 (propagated-inputs
1458 `(("ruby-rubocop" ,ruby-rubocop)))
1459 (synopsis "Performance optimizations checkers for Ruby code")
1460 (description "This package provides a collection of RuboCop cops to check
1461for performance optimizations in Ruby code.")
1462 (home-page "https://docs.rubocop.org/rubocop-performance/")
1463 (license license:expat)))
1464
c7ab342a
MC
1465(define-public ruby-gimme
1466 (let ((revision "1")
1467 (commit "4e71f0236f1271871916dd403261d26533db34c0"))
1468 (package
1469 (name "ruby-gimme")
1470 (version (git-version "0.5.0" revision commit))
1471 (source
1472 (origin
1473 (method git-fetch)
1474 (uri (git-reference
1475 (url "https://github.com/searls/gimme.git")
1476 (commit commit)))
1477 (file-name (git-file-name name version))
1478 (sha256
1479 (base32
1480 "0hrd32ygvf3i7h47ak8f623cz8ns9q7g60nnnvvlnywbggjaz3h6"))))
1481 (build-system ruby-build-system)
1482 (native-inputs
1483 `(("ruby-coveralls" ,ruby-coveralls)
1484 ("ruby-cucumber" ,ruby-cucumber)
1485 ("ruby-pry" ,ruby-pry)
1486 ("ruby-simplecov" ,ruby-simplecov)
1487 ("ruby-rspec-given" ,ruby-rspec-given)))
1488 (arguments
1489 `(;; The cucumber task fails with error: "index 3 out of matches
1490 ;; (IndexError)", apparently due to our newer Cucumber version.
1491 ;; TODO: Try the "default" task with a future release.
1492 #:test-target "spec"
1493 #:phases
1494 (modify-phases %standard-phases
1495 (add-after 'extract-gemspec 'prepare-for-tests
1496 (lambda _
1497 ;; Delete failing tests (possibly due to our newer rspec
1498 ;; version).
1499 (delete-file "spec/gimme/gives_class_methods_spec.rb")
1500 (delete-file "spec/gimme/rspec_adapter_spec.rb")
1501 (delete-file "spec/gimme/verifies_class_methods_spec.rb")
1502 ;; Fix duplicate version requirements and de-register files.
1503 (delete-file "Gemfile")
1504 (delete-file "Gemfile.lock")
1505 (substitute* "gimme.gemspec"
1506 ((".*\"Gemfile\".*") "")
1507 ((".*\"Gemfile\\.lock\",.*") "")
1508 ((".*(rspec|cucumber).*\">= 0\".*") "")
1509 (("\"spec/gimme/gives_class_methods_spec.rb\",") "")
1510 (("\"spec/gimme/rspec_adapter_spec.rb\",") "")
1511 (("\"spec/gimme/verifies_class_methods_spec.rb\",") "")
1512 ;; All of these gems relate to development, and are
1513 ;; unnecessary when running the tests.
1514 ((".*(add|gem).*guard-.*") "")
1515 ((".*(add|gem).*jeweler.*") "")
1516 ((".*(add|gem).*pry.*") "")
1517 ((".*(add|gem).*growl.*") "")
1518 ((".*(add|gem).*rb-fsevent.*") ""))
1519 #t)))))
1520 (synopsis "Lightweight test double library for Ruby")
1521 (description "Gimme is a very lightweight test double library for Ruby,
1522based on Mockito (a mocking framework for Java). It is an opinionated (but
1523not noisy) means to facilitate test-driving by enabling the authors to specify
1524only what they care about.")
1525 (home-page "https://github.com/searls/gimme")
1526 (license license:expat))))
1527
97295c2a
MC
1528(define-public ruby-standard
1529 (package
1530 (name "ruby-standard")
1531 (version "0.4.7")
1532 (source
1533 (origin
1534 (method git-fetch) ;no test suite in distributed gem
1535 (uri (git-reference
1536 (url "https://github.com/testdouble/standard.git")
1537 (commit (string-append "v" version))))
1538 (file-name (git-file-name name version))
1539 (sha256
1540 (base32
1541 "0ylx0lm2pbbgr5h7fban592w96bl3wxmvfcpcdfrhkxnpg5kiwgv"))))
1542 (build-system ruby-build-system)
1543 (arguments
1544 ;; TODO: the tests are currently broken due to using a newer Rubocop.
1545 `(#:tests? #f
1546 #:phases
1547 (modify-phases %standard-phases
1548 (add-after 'unpack 'relax-version-requiremens
1549 (lambda _
1550 (delete-file "Gemfile")
1551 (delete-file "Gemfile.lock")
1552 #t))
1553 (replace 'replace-git-ls-files
1554 (lambda _
1555 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1556 ;; git ls-files output is merged in ruby-build-system.
1557 (substitute* "standard.gemspec"
1558 (("`git ls-files -z`")
1559 "`find . -type f -not -regex '.*\\.gem$' -print0 \
1560|sort -z|cut -zc3-`"))
1561 #t)))))
1562 (native-inputs
1563 `(("ruby-gimme" ,ruby-gimme)
1564 ("ruby-pry" ,ruby-pry)
1565 ("ruby-simplecov" ,ruby-simplecov)))
1566 (propagated-inputs
1567 `(("ruby-rubocop" ,ruby-rubocop)
1568 ("ruby-rubocop-performance" ,ruby-rubocop-performance)))
1569 (synopsis "Ruby Style Guide, with linter & automatic code fixer")
1570 (description "Standard is a port of StandardJS. Like StandardJS, it aims
1571to save time in the following ways:
1572@itemize
1573@item No configuration.
1574@item Automatically format code.
1575@item Catch style issues and programmer errors early.
1576@end itemize")
1577 (home-page "https://github.com/testdouble/standard")
1578 (license license:expat)))
1579
db9f951b
MC
1580(define-public ruby-chunky-png
1581 ;; There hasn't been a release since 2018/11/21 and there are test failures
1582 ;; in that release, so use the latest commit.
1583 (let ((revision "1")
1584 (commit "143b9cd1412e49edd4f8b661c7cd9b22941f43c0"))
1585 (package
1586 (name "ruby-chunky-png")
1587 (version (git-version "1.3.11" revision commit))
1588 (source
1589 (origin
1590 (method git-fetch)
1591 (uri (git-reference
1592 (url "https://github.com/wvanbergen/chunky_png.git")
1593 (commit commit)))
1594 (file-name (git-file-name name version))
1595 (sha256
1596 (base32
1597 "0wbcgfzymbpmmxsb04arc49a2icki6f2fc6d6sqgg8369mc67g9z"))))
1598 (build-system ruby-build-system)
1599 (arguments
1600 `(#:test-target "spec"
1601 #:phases
1602 (modify-phases %standard-phases
1603 (add-after 'unpack 'disable-bundler
1604 (lambda _
1605 (substitute* (find-files "." "\\.rb$")
1606 (("require.*bundler/setup.*") ""))
1607 #t))
1608 (replace 'replace-git-ls-files
1609 (lambda _
1610 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1611 ;; git ls-files output is merged in ruby-build-system.
1612 (substitute* "chunky_png.gemspec"
1613 (("`git ls-files`")
1614 "`find . -type f -not -regex '.*\\.gem$' |sort |cut -c3-`"))
1615 #t)))))
1616 (native-inputs
1617 `(("bundler" ,bundler)
1618 ("ruby-rspec" ,ruby-rspec)
1619 ("ruby-standard" ,ruby-standard)
1620 ("ruby-yard" ,ruby-yard)))
1621 (synopsis "Ruby library to handle PNG images")
1622 (description "ChunkyPNG is a pure Ruby library that can read and write
1623Portable Network Graphics (PNG) images without depending on an external image
1624library. It tries to be memory efficient and reasonably fast. It has
1625features such as:
1626@itemize
1627@item
1628Decoding support for any image that the PNG standard allows. This includes all
1629standard color modes, all bit depths, all transparency, and interlacing and
1630filtering options.
1631@item
1632Encoding support for images of all color modes (true color, grayscale, and
1633indexed) and transparency for all these color modes. The best color mode is
1634chosen automatically, based on the amount of used colors.
1635@item Read/write access to the image's pixels.
1636@item Read/write access to all image metadata that is stored in chunks.
1637@item
1638Memory efficiency: @code{fixnum} are used, i.e. 4 or 8 bytes of memory per
1639pixel, depending on the hardware).
1640@item
1641Performance: ChunkyPNG is reasonably fast for Ruby standards, by only using
1642integer math and a highly optimized saving routine.
1643@item Interoperability with RMagick.
1644@end itemize")
1645 (home-page "https://github.com/wvanbergen/chunky_png/wiki")
1646 (license license:expat))))
1647
f421785b
MC
1648(define-public ruby-text-hyphen
1649 (package
1650 (name "ruby-text-hyphen")
1651 (version "1.4.1")
1652 (source
1653 (origin
1654 (method url-fetch)
1655 (uri (rubygems-uri "text-hyphen" version))
1656 (sha256
1657 (base32
1658 "1gj4awvs9ryf960m0iawg43jyjmfwcqgfwrbcfp890a57b9ag7q1"))))
1659 (build-system ruby-build-system)
1660 (native-inputs
1661 `(("ruby-hoe" ,ruby-hoe)))
1662 (synopsis "Ruby library to hyphenate words in various languages")
1663 (description "Text::Hyphen is a Ruby library to hyphenate words in various
1664languages using Ruby-fied versions of TeX hyphenation patterns. It will
1665properly hyphenate various words according to the rules of the language the
1666word is written in. The algorithm is based on that of the TeX typesetting
1667system by Donald E. Knuth.")
1668 (home-page "https://github.com/halostatue/text-hyphen")
1669 ;; The whole is licensed under the Expat license, but parts use various
1670 ;; versions of the LaTeX Project Public License.
1671 (license license:expat)))
1672
7d94616d
MC
1673(define-public ruby-open-uri-cached
1674 (package
1675 (name "ruby-open-uri-cached")
1676 (version "0.0.5")
1677 (source
1678 (origin
1679 (method url-fetch)
1680 (uri (rubygems-uri "open-uri-cached" version))
1681 (sha256
1682 (base32
1683 "13xy2vhrgz9mdxhklw5fszhamsdxh8ysf3l40g92hqm4hm288wap"))))
1684 (build-system ruby-build-system)
1685 (arguments
1686 `(#:tests? #f)) ;no test suite
1687 (synopsis "OpenURI with transparent disk caching")
1688 (description "OpenURI with transparent disk caching, which is
1689useful to avoid making excessive queries, for example when scraping
1690web pages.")
1691 (home-page "https://github.com/tigris/open-uri-cached")
1692 (license license:expat)))
1693
9c5a7d00
MC
1694(define-public ruby-asciidoctor-pdf
1695 ;; Use the latest commit, as the last tag doesn't build with the
1696 ;; latest Ruby dependencies in Guix.
1697 (let ((revision "1")
1698 (commit "d257440df895d1595a3825ef58b32e4b290ba1c3"))
1699 (package
1700 (name "ruby-asciidoctor-pdf")
1701 (version (git-version "1.5.3" revision commit))
1702 (source
1703 (origin
1704 (method git-fetch) ;no test suite in the distributed gem
1705 (uri (git-reference
1706 (url "https://github.com/asciidoctor/asciidoctor-pdf.git")
1707 (commit commit)))
1708 (file-name (git-file-name name version))
1709 (sha256
1710 (base32
1711 "1563d11ghzsrsg4inwfwj6b9hb5sk5b429f49fwq5qg3sq76kgjj"))))
1712 (build-system ruby-build-system)
1713 (arguments
1714 `(#:test-target "spec"
1715 #:phases
1716 (modify-phases %standard-phases
1717 (add-after 'unpack 'remove-failing-tests
1718 ;; Two tests module fail for unknown reasons, *only* when
1719 ;; ran in the build container (see:
1720 ;; https://github.com/asciidoctor/asciidoctor-pdf/issues/1725#issuecomment-658777965).
1721 (lambda _
1722 (delete-file "spec/audio_spec.rb")
1723 (delete-file "spec/video_spec.rb")
1724 #t))
1725 (add-after 'extract-gemspec 'strip-version-requirements
1726 (lambda _
1727 (substitute* "asciidoctor-pdf.gemspec"
1728 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1729 (string-append stripped "\n")))
1730 #t))
1731 (replace 'replace-git-ls-files
1732 ;; TODO: Remove after the fix of using 'cut' to better mimic the
1733 ;; git ls-files output is merged in ruby-build-system.
1734 (lambda _
1735 (substitute* "asciidoctor-pdf.gemspec"
1736 (("`git ls-files -z`")
1737 "`find . -type f -not -regex '.*\\.gem$' -print0 \
1738|sort -z|cut -zc3-`"))
1739 #t))
1740 ;; The tests rely on the Gem being installed, so move the check phase
1741 ;; after the install phase.
1742 (delete 'check)
1743 (add-after 'install 'check
1744 (lambda* (#:key outputs tests? #:allow-other-keys)
1745 (let ((new-gem (string-append (assoc-ref outputs "out")
1746 "/lib/ruby/vendor_ruby")))
1747 (setenv "GEM_PATH"
1748 (string-append (getenv "GEM_PATH") ":" new-gem))
1749 (when tests?
1750 (invoke "rspec" "-t" "~visual" "-t" "~cli" "-t" "~network"))
1751 #t))))))
1752 (native-inputs
1753 `(("ruby-chunky-png" ,ruby-chunky-png)
1754 ("ruby-coderay" ,ruby-coderay)
1755 ("ruby-pdf-inspector" ,ruby-pdf-inspector)
1756 ("ruby-rouge" ,ruby-rouge)
1757 ("ruby-rspec" ,ruby-rspec)))
1758 (propagated-inputs
1759 `(("ruby-asciidoctor" ,ruby-asciidoctor)
1760 ("ruby-concurrent-ruby" ,ruby-concurrent)
1761 ("ruby-open-uri-cached" ,ruby-open-uri-cached)
1762 ("ruby-prawn" ,ruby-prawn)
1763 ("ruby-prawn-icon" ,ruby-prawn-icon)
1764 ("ruby-prawn-svg" ,ruby-prawn-svg)
1765 ("ruby-prawn-table" ,ruby-prawn-table)
1766 ("ruby-prawn-templates" ,ruby-prawn-templates)
1767 ("ruby-safe-yaml" ,ruby-safe-yaml)
1768 ("ruby-text-hyphen" ,ruby-text-hyphen)
1769 ("ruby-thread-safe" ,ruby-thread-safe)
1770 ("ruby-treetop" ,ruby-treetop)
1771 ("ruby-ttfunk" ,ruby-ttfunk)))
1772 (synopsis"AsciiDoc to Portable Document Format (PDF)} converter")
1773 (description "Asciidoctor PDF is an extension for Asciidoctor that
1774converts AsciiDoc documents to Portable Document Format (PDF) using the Prawn
1775PDF library. It has features such as:
1776@itemize
1777@item Direct AsciiDoc to PDF conversion
1778@item Configuration-driven theme (style and layout)
1779@item Scalable Vector Graphics (SVG) support
1780@item PDF document outline (i.e., bookmarks)
1781@item Table of contents page(s)
1782@item Document metadata (title, authors, subject, keywords, etc.)
1783@item Internal cross reference links
1784@item Syntax highlighting with Rouge, Pygments, or CodeRay
1785@item Page numbering
1786@item Customizable running content (header and footer)
1787@item
1788“Keep together” blocks (i.e., page breaks avoided in certain block content)
1789@item Orphaned section titles avoided
1790@item Autofit verbatim blocks (as permitted by base_font_size_min setting)
1791@item Table border settings honored
1792@item Font-based icons
1793@item Custom TrueType (TTF) fonts
1794@item Double-sided printing mode (margins alternate on recto and verso pages)
1795@end itemize")
1796 (home-page "https://asciidoctor.org/docs/asciidoctor-pdf")
1797 (license license:expat))))
1798
d5840f77
CB
1799(define-public ruby-ast
1800 (package
1801 (name "ruby-ast")
308104f8 1802 (version "2.4.1")
d5840f77
CB
1803 (source
1804 (origin
308104f8
MC
1805 (method git-fetch) ;no test included in gem from v2.4.1
1806 (uri (git-reference
1807 (url "https://github.com/whitequark/ast")
1808 (commit (string-append "v" version))))
1809 (file-name (git-file-name name version))
d5840f77
CB
1810 (sha256
1811 (base32
308104f8 1812 "0k8vya256chimy473g818gim06m5rjgh6mz5sc5g8xz3csh3rysi"))))
d5840f77
CB
1813 (build-system ruby-build-system)
1814 (arguments
1815 '(#:phases
1816 (modify-phases %standard-phases
1817 (add-after 'unpack 'remove-coveralls-requirement
1818 (lambda _
1819 (substitute* "test/helper.rb"
1820 (("require 'coveralls'") "")
1821 (("Coveralls::SimpleCov::Formatter") ""))
1822 #t))
1823 (add-after 'extract-gemspec 'remove-unnecessary-requirements
1824 (lambda _
1825 (substitute* "ast.gemspec"
1826 ((".*coveralls.*") "\n")
1827 (("%q<rest-client>.*") "%q<rest-client>.freeze, [\">= 0\"])\n")
1828 (("%q<mime-types>.*") "%q<mime-types>.freeze, [\">= 0\"])\n")
1829 (("%q<rake>.*") "%q<rake>.freeze, [\">= 0\"])\n"))
1830 #t)))))
1831 (native-inputs
1832 `(("bundler" ,bundler)
1833 ("ruby-simplecov" ,ruby-simplecov)
1834 ("ruby-json-pure" ,ruby-json-pure)
1835 ("ruby-mime-times" ,ruby-mime-types)
1836 ("ruby-yard" ,ruby-yard)
1837 ("ruby-kramdown" ,ruby-kramdown)
1838 ("ruby-rest-client" ,ruby-rest-client)
1839 ("ruby-bacon" ,ruby-bacon)
1840 ("ruby-bacon-colored-output" ,ruby-bacon-colored-output)
1841 ("ruby-racc" ,ruby-racc)))
1842 (synopsis "Library for working with Abstract Syntax Trees")
1843 (description
1844 "@code{ast} is a Ruby library for working with Abstract Syntax Trees.
1845It does this through immutable data structures.")
1846 (home-page "https://whitequark.github.io/ast/")
1847 (license license:expat)))
1848
b88502c9
BW
1849(define-public ruby-sporkmonger-rack-mount
1850 ;; Testing the addressable gem requires a newer commit than that released, so
1851 ;; use an up to date version.
1852 (let ((revision "1")
1853 (commit "076aa2c47d9a4c081f1e9bcb56a826a9e72bd5c3"))
1854 (package
1855 (name "ruby-sporkmonger-rack-mount")
1856 (version (git-version "0.8.3" revision commit))
1857 (source (origin
1858 (method git-fetch)
1859 (uri (git-reference
b0e7b699 1860 (url "https://github.com/sporkmonger/rack-mount")
b88502c9
BW
1861 (commit commit)))
1862 (file-name (git-file-name name version))
1863 (sha256
1864 (base32
1865 "1scx273g3xd93424x9lxc4zyvcp2niknbw5mkz6wkivpf7xsyxdq"))))
1866 (build-system ruby-build-system)
1867 (arguments
1868 ;; Tests currently fail so disable them.
1869 ;; https://github.com/sporkmonger/rack-mount/pull/1
1870 `(#:tests? #f))
1871 (propagated-inputs `(("ruby-rack" ,ruby-rack)))
1872 (synopsis "Stackable dynamic tree based Rack router")
1873 (description
1874 "@code{Rack::Mount} supports Rack's @code{X-Cascade} convention to
1875continue trying routes if the response returns pass. This allows multiple
1876routes to be nested or stacked on top of each other.")
1877 (home-page "https://github.com/sporkmonger/rack-mount")
1878 (license license:expat))))
1879
2f9e0b68
RW
1880(define-public ruby-ci-reporter
1881 (package
1882 (name "ruby-ci-reporter")
1883 (version "2.0.0")
1884 (source (origin
1885 (method url-fetch)
1886 (uri (rubygems-uri "ci_reporter" version))
1887 (sha256
1888 (base32
1889 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
1890 (build-system ruby-build-system)
1891 (arguments
1892 `(#:test-target "rspec"))
1893 (propagated-inputs
1894 `(("ruby-builder" ,ruby-builder)))
1895 (native-inputs
1896 `(("bundler" ,bundler)
1897 ("ruby-rspec" ,ruby-rspec)))
1898 (synopsis "Generate XML reports of runs test")
1899 (description
1900 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
1901you to generate XML reports of your test runs. The resulting files can be
1902read by a continuous integration system that understands Ant's JUnit report
1903format.")
1904 (home-page "https://github.com/nicksieger/ci_reporter")
1905 (license license:expat)))
1906
2ed201c1
CB
1907(define-public ruby-contracts
1908 (package
1909 (name "ruby-contracts")
1910 (version "0.16.0")
1911 (source
1912 (origin
1913 (method url-fetch)
1914 (uri (rubygems-uri "contracts" version))
1915 (sha256
1916 (base32
1917 "119f5p1n6r5svbx8h09za6a4vrsnj5i1pzr9cqdn9hj3wrxvyl3a"))))
1918 (build-system ruby-build-system)
1919 (arguments
1920 '(#:test-target "spec"
1921 #:phases
1922 (modify-phases %standard-phases
1923 ;; Don't run or require rubocop, the code linting tool, as this is a
1924 ;; bit unnecessary.
1925 (add-after 'unpack 'dont-run-rubocop
1926 (lambda _
1927 (substitute* "Rakefile"
1928 ((".*rubocop.*") "")
1929 ((".*RuboCop.*") ""))
1930 #t)))))
1931 (native-inputs
1932 `(("ruby-rspec" ,ruby-rspec)))
1933 (synopsis "Method contracts for Ruby")
1934 (description
1935 "This library provides contracts for Ruby. A contract describes the
1936correct inputs and output for a method, and will raise an error if a incorrect
1937value is found.")
1938 (home-page "https://github.com/egonSchiele/contracts.ruby")
1939 (license license:bsd-2)))
1940
6f8bf0eb
CB
1941(define-public ruby-crack
1942 (package
1943 (name "ruby-crack")
1944 (version "0.4.3")
1945 (source
1946 (origin
1947 (method url-fetch)
1948 (uri (rubygems-uri "crack" version))
1949 (sha256
1950 (base32
1951 "0abb0fvgw00akyik1zxnq7yv391va148151qxdghnzngv66bl62k"))))
1952 (build-system ruby-build-system)
1953 (arguments
1954 `(#:phases
1955 (modify-phases %standard-phases
1956 (replace 'check
1957 (lambda* (#:key tests? #:allow-other-keys)
1958 (when tests?
1959 (for-each (lambda (file)
1960 (display file)(display "\n")
1961 (invoke "ruby" "-Ilib" "-Itest" "-rrubygems" file))
1962 (find-files "test" ".*rb$")))
1963 #t)))))
1964 (propagated-inputs
1965 `(("ruby-safe-yaml" ,ruby-safe-yaml)))
1966 (synopsis "Simple JSON and XML parsing for Ruby")
1967 (description
1968 "@code{crack} provides really simple JSON and XML parsing, extracted from
1969code in Merb and Rails.")
1970 (home-page "https://github.com/jnunemaker/crack")
1971 (license license:expat)))
1972
bef3506e
CB
1973(define-public ruby-cliver
1974 (package
1975 (name "ruby-cliver")
1976 (version "0.3.2")
1977 (source
1978 (origin
1979 (method url-fetch)
1980 (uri (rubygems-uri "cliver" version))
1981 (sha256
1982 (base32
1983 "096f4rj7virwvqxhkavy0v55rax10r4jqf8cymbvn4n631948xc7"))))
1984 (build-system ruby-build-system)
1985 (arguments
1986 '(#:phases
1987 (modify-phases %standard-phases
1988 ;; Avoid a incompatibility between rspec@2 and rake. Using rspec@3
1989 ;; would be nice, but the tests look to be incompatible:
1990 ;;
1991 ;; NoMethodError: undefined method `last_comment'
1992 (replace 'check
1993 (lambda* (#:key tests? #:allow-other-keys)
1994 (when tests?
1995 (invoke "rspec"))
1996 #t)))))
1997 (native-inputs
1998 `(("bundler" ,bundler)
1999 ("ruby-rspec" ,ruby-rspec-2)))
2000 (synopsis "Assertions for command-line dependencies in Ruby")
2001 (description
2002 "@code{cliver} provides a way to detect missing command-line
2003dependencies, including versions.")
2004 (home-page "https://github.com/yaauie/cliver")
2005 (license license:expat)))
2006
fe5dd5f4
CB
2007(define-public ruby-czmq-ffi-gen
2008 (package
2009 (name "ruby-czmq-ffi-gen")
2010 (version "0.13.0")
2011 (source
2012 (origin
2013 (method url-fetch)
2014 (uri (rubygems-uri "czmq-ffi-gen" version))
2015 (sha256
2016 (base32
2017 "1yf719dmf4mwks1hqdsy6i5kzfvlsha69sfnhb2fr2cgk2snbys3"))))
2018 (build-system ruby-build-system)
2019 (arguments
2020 '(#:tests? #f ;; Tests are not included in the release on rubygems.org
2021 #:phases
2022 (modify-phases %standard-phases
2023 (add-after 'unpack 'patch-lib_dirs
2024 (lambda* (#:key inputs #:allow-other-keys)
2025 (substitute* "lib/czmq-ffi-gen/czmq/ffi.rb"
2026 (("lib\\_dirs = \\[.*\\]")
2027 (string-append "lib_dirs = ['"
2028 (assoc-ref inputs "czmq") "/lib"
2029 "']")))
2030 (substitute* "lib/czmq-ffi-gen/libzmq.rb"
2031 (("lib\\_dirs = \\[.*\\]")
2032 (string-append "lib_dirs = ['"
2033 (assoc-ref inputs "zeromq") "/lib"
2034 "']"))))))))
2035 (inputs
2036 `(("zeromq" ,zeromq)
2037 ("czmq" ,czmq)))
2038 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
2039 (synopsis "Low-level Ruby bindings for CZMQ (generated using zproject)")
2040 (description
2041 "These Ruby bindings are not intended to be directly used, but rather
2042used by higher level bindings like those provided by CZTop.")
2043 (home-page
2044 "https://github.com/paddor/czmq-ffi-gen")
2045 (license license:isc)))
2046
d0afff26
CB
2047(define-public ruby-cztop
2048 (package
2049 (name "ruby-cztop")
2050 (version "0.12.2")
2051 (source
2052 (origin
2053 (method url-fetch)
2054 (uri (rubygems-uri "cztop" version))
2055 (sha256
2056 (base32
2057 "0yqbpaiw5d7f271d73lyrsh8xpx6n4zi6xqwfgi00dacxrq3s3fa"))))
2058 (build-system ruby-build-system)
2059 (arguments
2060 '(#:test-target "spec"
2061 #:phases
2062 (modify-phases %standard-phases
2063 (add-after 'unpack 'patch-lib_paths
2064 (lambda* (#:key inputs #:allow-other-keys)
2065 (substitute* "lib/cztop/poller/zmq.rb"
2066 (("lib\\_paths = \\[.*\\]")
2067 (string-append "lib_paths = ['"
2068 (assoc-ref inputs "zeromq") "/lib"
2069 "']"))))))))
2070 (native-inputs
2071 `(("bundler" ,bundler)
2072 ("ruby-rspec" ,ruby-rspec)))
2073 (inputs
2074 `(("zeromq" ,zeromq)))
2075 (propagated-inputs
2076 `(("ruby-czmq-ffi-gen" ,ruby-czmq-ffi-gen)))
2077 (synopsis "CZMQ Ruby bindings")
2078 (description
2079 "CZMQ Ruby bindings, based on the generated low-level FFI bindings of
2080CZMQ. The focus of of CZTop is on being easy to use and providing first class
2081support for security mechanisms.")
2082 (home-page "https://github.com/paddor/cztop")
2083 (license license:isc)))
2084
b004fb6a
RW
2085(define-public ruby-saikuro-treemap
2086 (package
2087 (name "ruby-saikuro-treemap")
2088 (version "0.2.0")
2089 (source (origin
2090 (method url-fetch)
2091 (uri (rubygems-uri "saikuro_treemap" version))
2092 (sha256
2093 (base32
2094 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
2095 (build-system ruby-build-system)
2096 ;; Some of the tests fail because the generated JSON has keys in a
2097 ;; different order. This is a problem with the test suite rather than any
2098 ;; of the involved libraries.
2099 (arguments `(#:tests? #f))
2100 (propagated-inputs
2101 `(("ruby-json-pure" ,ruby-json-pure)
2102 ("ruby-atoulme-saikuro" ,ruby-atoulme-saikuro)))
2103 (synopsis "Generate complexity treemap based on saikuro analysis")
2104 (description
2105 "This gem generates a treemap showing the complexity of Ruby code on
2106which it is run. It uses Saikuro under the covers to analyze Ruby code
2107complexity.")
7bf837fd 2108 (home-page "https://github.com/ThoughtWorksStudios/saikuro_treemap")
b004fb6a
RW
2109 (license license:expat)))
2110
92b37500
CB
2111(define-public ruby-oauth2
2112 (package
2113 (name "ruby-oauth2")
5dd10be5 2114 (version "1.4.2")
92b37500
CB
2115 (source
2116 (origin
2117 (method url-fetch)
2118 (uri (rubygems-uri "oauth2" version))
2119 (sha256
5dd10be5 2120 (base32 "15i9z4j5pcjkr30lkcd79xzbr4kpmy0bqgwa436fqyqk646fv036"))))
92b37500
CB
2121 (build-system ruby-build-system)
2122 (arguments
5dd10be5 2123 '(#:tests? #f)) ; no included tests
92b37500
CB
2124 (propagated-inputs
2125 `(("ruby-faraday" ,ruby-faraday)
2126 ("ruby-jwt" ,ruby-jwt)
2127 ("ruby-multi-json" ,ruby-multi-json)
2128 ("ruby-multi-xml" ,ruby-multi-xml)
2129 ("ruby-rack" ,ruby-rack)))
2130 (synopsis "Ruby wrapper for the OAuth 2.0")
2131 (description
2132 "This package provides a Ruby wrapper for the OAuth 2.0 protocol built
2133with a similar style to the original OAuth spec.")
2134 (home-page "https://github.com/oauth-xx/oauth2")
2135 (license license:expat)))
2136
29dc4823
CB
2137(define-public ruby-omniauth
2138 (package
2139 (name "ruby-omniauth")
a7b7817d 2140 (version "1.9.1")
29dc4823
CB
2141 (source
2142 (origin
2143 (method url-fetch)
2144 (uri (rubygems-uri "omniauth" version))
2145 (sha256
a7b7817d 2146 (base32 "002vi9gwamkmhf0dsj2im1d47xw2n1jfhnzl18shxf3ampkqfmyz"))))
29dc4823
CB
2147 (build-system ruby-build-system)
2148 (arguments
2149 '(#:tests? #f)) ; No included tests
2150 (propagated-inputs
2151 `(("ruby-hashie" ,ruby-hashie)
2152 ("ruby-rack" ,ruby-rack)))
2153 (synopsis "Generalized Rack framework for multiple-provider authentication")
2154 (description
2155 "This package provides a generalized Rack framework for multiple-provider
2156authentication.")
2157 (home-page "https://github.com/omniauth/omniauth")
2158 (license license:expat)))
2159
d6084cdb
CB
2160(define-public ruby-omniauth-oauth2
2161 (package
2162 (name "ruby-omniauth-oauth2")
2163 (version "1.6.0")
2164 (source
2165 (origin
2166 (method url-fetch)
2167 (uri (rubygems-uri "omniauth-oauth2" version))
2168 (sha256
2169 (base32
2170 "11mi36l9d97r77q99jnafdc1yaa0a9wahhpp7dj7ank8q52g7g79"))))
2171 (build-system ruby-build-system)
2172 (arguments
2173 '(#:phases
2174 (modify-phases %standard-phases
2175 (add-after 'unpack 'remove-unnecessary-dependencies
2176 (lambda _
2177 ;; The coveralls gem submits coverage information to an online
2178 ;; service, and is unnecessary when running the tests
2179 (substitute* "Gemfile"
2180 ((".*coveralls\"") ""))
2181 (substitute* "spec/helper.rb"
2182 (("require \"coveralls\"") "")
2183 (("Coveralls::SimpleCov::Formatter") ""))
2184 #t)))))
2185 (propagated-inputs
2186 `(("ruby-oauth2" ,ruby-oauth2)
2187 ("ruby-omniauth" ,ruby-omniauth)))
2188 (native-inputs
2189 `(("bundler" ,bundler)
2190 ("ruby-rspec" ,ruby-rspec)
2191 ("ruby-simplecov" ,ruby-simplecov)
2192 ("ruby-rack-test" ,ruby-rack-test)
2193 ("ruby-webmock" ,ruby-webmock-2)))
2194 (synopsis "Abstract OAuth2 strategy for OmniAuth")
2195 (description
2196 "This library provides a generic OAuth2 strategy for OmniAuth. It
2197doesn't provide a way to gather user information, so should be used as a
2198building block for authentication strategies.")
2199 (home-page "https://github.com/omniauth/omniauth-oauth2")
2200 (license license:expat)))
2201
433e3154
CB
2202(define-public ruby-open4
2203 (package
2204 (name "ruby-open4")
2205 (version "1.3.4")
2206 (source
2207 (origin
2208 (method url-fetch)
2209 (uri (rubygems-uri "open4" version))
2210 (sha256
2211 (base32
2212 "1cgls3f9dlrpil846q0w7h66vsc33jqn84nql4gcqkk221rh7px1"))))
2213 (build-system ruby-build-system)
2214 (arguments
2215 '(#:phases
2216 (modify-phases %standard-phases
2217 (add-after 'unpack 'patch
2218 (lambda _
2219 (substitute* "rakefile"
2220 ;; Update the Rakefile so it works
2221 (("-rubygems") "-rrubygems")
2222 (("Config") "RbConfig"))
2223 #t))
2224 (add-before 'check 'set-LIB
2225 (lambda _
2226 ;; This is used in the rakefile when running the tests
2227 (setenv "LIB" "open4")
2228 #t)))))
2229 (synopsis "Open child processes from Ruby and manage them easily")
2230 (description
2231 "@code{Open4} is a Ruby library to run child processes and manage their
2232input and output.")
2233 (home-page "https://github.com/ahoward/open4")
2234 (license license:ruby)))
2235
cef87ed6
CB
2236(define-public ruby-options
2237 (package
2238 (name "ruby-options")
2239 (version "2.3.2")
2240 (source
2241 (origin
2242 (method url-fetch)
2243 (uri (rubygems-uri "options" version))
2244 (sha256
2245 (base32
2246 "1s650nwnabx66w584m1cyw82icyym6hv5kzfsbp38cinkr5klh9j"))))
2247 (build-system ruby-build-system)
2248 (arguments
2249 '(#:tests? #f ;; TODO: NameError: uninitialized constant Config
2250 #:phases
2251 (modify-phases %standard-phases
2252 (add-before 'check 'set-LIB
2253 (lambda _
2254 ;; This is used in the Rakefile, and setting it avoids an issue
2255 ;; with running the tests.
fe27238c
CB
2256 (setenv "LIB" "options")
2257 #t)))))
cef87ed6
CB
2258 (synopsis "Ruby library to parse options from *args cleanly")
2259 (description
2260 "The @code{options} library helps with parsing keyword options in Ruby
2261functions.")
2262 (home-page "https://github.com/ahoward/options")
2263 (license license:ruby)))
2264
d15dbe83
CB
2265(define-public ruby-erubi
2266 (package
2267 (name "ruby-erubi")
2268 (version "1.8.0")
2269 (source
2270 (origin
2271 (method url-fetch)
2272 (uri (rubygems-uri "erubi" version))
2273 (sha256
2274 (base32
2275 "1kagnf6ziahj0d781s6ryy6fwqwa3ad4xbzzj84p9m4nv4c2jir1"))))
2276 (build-system ruby-build-system)
2277 (synopsis "ERB template engine for Ruby")
2278 (description
2279 "Erubi is a ERB template engine for Ruby. It is a simplified fork of
2280Erubis")
2281 (home-page "https://github.com/jeremyevans/erubi")
2282 (license license:expat)))
2283
d64ebebd
BW
2284(define-public ruby-erubis
2285 (package
2286 (name "ruby-erubis")
2287 (version "2.7.0")
2288 (source
2289 (origin
2290 (method url-fetch)
2291 (uri (rubygems-uri "erubis" version))
2292 (sha256
2293 (base32
2294 "1fj827xqjs91yqsydf0zmfyw9p4l2jz5yikg3mppz6d7fi8kyrb3"))))
2295 (build-system ruby-build-system)
2296 (arguments
2297 '(#:tests? #f)) ; tests do not run properly with Ruby 2.0
2298 (synopsis "Implementation of embedded Ruby (eRuby)")
2299 (description
2300 "Erubis is a fast implementation of embedded Ruby (eRuby) with several
2301features such as multi-language support, auto escaping, auto trimming spaces
2302around @code{<% %>}, a changeable embedded pattern, and Ruby on Rails
2303support.")
2304 (home-page "http://www.kuwata-lab.com/erubis/")
2305 (license license:expat)))
2306
3ca43524
CB
2307(define-public ruby-execjs
2308 (package
2309 (name "ruby-execjs")
2310 (version "2.7.0")
2311 (source
2312 (origin
2313 ;; fetch from github as the gem does not contain testing code
2314 (method git-fetch)
2315 (uri (git-reference
b0e7b699 2316 (url "https://github.com/rails/execjs")
3ca43524
CB
2317 (commit (string-append "v" version))))
2318 (file-name (git-file-name name version))
2319 (sha256
2320 (base32
2321 "0c0vd2mmqq3ar4plbwi2wsbr31vn4h45i19r5km66skydnnbp1y6"))))
2322 (build-system ruby-build-system)
2323 (native-inputs
2324 `(("bundler" ,bundler)
2325 ;; The test suite tests all the available backends. Currenly, this just
2326 ;; means the node backend.
2327 ;;
2328 ;; PASSED: test:node
2329 ;; SKIPPED: test:duktape, ;; test:javascriptcore, test:jscript,
2330 ;; test:miniracer, test:rubyracer, ;; test:rubyrhino, test:v8
2331 ("node" ,node)))
2332 (synopsis "Run JavaScript code from Ruby")
2333 (description
2334 "ExecJS lets you run JavaScript code from Ruby. It automatically picks a
2335runtime to evaluate your JavaScript program, then returns the result to you as
2336a Ruby object.")
2337 (home-page "https://github.com/rails/execjs")
2338 (license license:expat)))
2339
6623a151
MB
2340(define-public ruby-fakefs
2341 (package
2342 (name "ruby-fakefs")
2343 (version "1.2.2")
2344 (home-page "https://github.com/fakefs/fakefs")
2345 (source (origin
2346 ;; The Rubygems release does not contain tests.
2347 (method git-fetch)
2348 (uri (git-reference
2349 (url home-page)
2350 (commit (string-append "v" version))))
2351 (file-name (git-file-name name version))
2352 (sha256
2353 (base32
2354 "008dq9knyip2bfbl0mrk8b8r7bv0k3bf128wcfqsgy1rqal4mgwk"))))
2355 (build-system ruby-build-system)
2356 (arguments
2357 '(#:phases (modify-phases %standard-phases
2358 (replace 'replace-git-ls-files
2359 (lambda _
2360 (substitute* "fakefs.gemspec"
2361 (("`git ls-files lib README.md LICENSE`")
2362 "`find lib README.md LICENSE -type f | sort`"))
2363 #t))
2364 (add-before 'check 'remove-version-constraints
2365 (lambda _
2366 ;; Drop hard version requirements for test dependencies.
2367 (substitute* "fakefs.gemspec"
2368 (("(.*add_development_dependency .*), .*" _ dep)
2369 (string-append dep "\n")))
a011f67b 2370 #t)))))
6623a151
MB
2371 (native-inputs
2372 `(("ruby-bump" ,ruby-bump)
2373 ("ruby-maxitest" ,ruby-maxitest)
2374 ("ruby-rubocop" ,ruby-rubocop)
2375 ("ruby-rspec" ,ruby-rspec)))
2376 (synopsis "Fake file system for Ruby")
2377 (description
2378 "This package provides a fake file system for use in test suites. It
2379avoids the need for manually creating temporary directories, or dealing
2380with platform intricacies in @code{File} and @code{FileUtils}.")
2381 (license license:expat)))
2382
cc53e630
RW
2383(define-public ruby-orderedhash
2384 (package
2385 (name "ruby-orderedhash")
2386 (version "0.0.6")
2387 (source (origin
2388 (method url-fetch)
2389 (uri (rubygems-uri "orderedhash" version))
2390 (sha256
2391 (base32
2392 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
2393 (build-system ruby-build-system)
2394 (arguments
2395 '(#:tests? #f)) ; no test suite
2396 (synopsis "Ruby library providing an order-preserving hash")
2397 (description "Orderedhash is a Ruby library providing a hash
2398implementation that preserves the order of items and features some array-like
2399extensions.")
2400 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
2401 (license license:public-domain)))
2402
28c5d42d
PP
2403(define-public ruby-libxml
2404 (package
2405 (name "ruby-libxml")
acbc5062 2406 (version "3.0.0")
28c5d42d
PP
2407 (source
2408 (origin
2409 (method url-fetch)
2410 (uri (rubygems-uri "libxml-ruby" version))
2411 (sha256
2412 (base32
acbc5062 2413 "0xy8wmjwjcnv36zi042678ncjzpxvy351ccbv7mzkns2n3kxfp54"))))
28c5d42d
PP
2414 (build-system ruby-build-system)
2415 (inputs
2416 `(("zlib" ,zlib)
2417 ("libxml2" ,libxml2)))
2418 (arguments
2419 '(#:tests? #f ; test suite hangs for unknown reason
2420 #:gem-flags
2421 (list "--"
2422 (string-append "--with-xml2-include="
2423 (assoc-ref %build-inputs "libxml2")
2424 "/include/libxml2" ))))
2425 (synopsis "Ruby bindings for GNOME Libxml2")
2426 (description "The Libxml-Ruby project provides Ruby language bindings for
2427the GNOME Libxml2 XML toolkit.")
2f3800e5 2428 (home-page "https://xml4r.github.com/libxml-ruby")
28c5d42d
PP
2429 (license license:expat)))
2430
b3222518
CB
2431(define-public ruby-lino
2432 (package
2433 (name "ruby-lino")
2434 (version "1.1.0")
2435 (source
2436 (origin
2437 (method url-fetch)
2438 (uri (rubygems-uri "lino" version))
2439 (sha256
2440 (base32
2441 "11d29g0fk372b9fcpyr0k6hxm2b4j4igpysmi542hgbbgqgp9cd3"))))
2442 (build-system ruby-build-system)
2443 (arguments
2444 '(#:tests? #f)) ; No included tests
2445 (propagated-inputs
2446 `(("ruby-hamster" ,ruby-hamster)
2447 ("ruby-open4" ,ruby-open4)))
2448 (synopsis "Build and execute commands in Ruby")
2449 (description
2450 "@code{Lino} provides an interface to run external commands. It provides
2451an interface to add options as well as managing the standard input, output and
2452error streams.")
2453 (home-page "https://github.com/tobyclemson/lino")
2454 (license license:expat)))
2455
8b9bde07
RW
2456(define-public ruby-xml-simple
2457 (package
2458 (name "ruby-xml-simple")
2459 (version "1.1.5")
2460 (source (origin
2461 (method url-fetch)
2462 (uri (rubygems-uri "xml-simple" version))
2463 (sha256
2464 (base32
2465 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
2466 (build-system ruby-build-system)
2467 (arguments
2468 '(#:tests? #f)) ; no test suite
2469 (synopsis "Simple Ruby library for XML processing")
2470 (description "This library provides a simple API for XML processing in
2471Ruby.")
2472 (home-page "https://github.com/maik/xml-simple")
2473 (license license:ruby)))
2474
2cb3ab48
RW
2475(define-public ruby-thor
2476 (package
2477 (name "ruby-thor")
bb719d6a 2478 (version "1.0.1")
2cb3ab48 2479 (source (origin
bb719d6a
MB
2480 ;; Pull from git because the gem has no tests.
2481 (method git-fetch)
2482 (uri (git-reference
2483 (url "https://github.com/erikhuda/thor")
2484 (commit (string-append "v" version))))
2485 (file-name (git-file-name name version))
2cb3ab48
RW
2486 (sha256
2487 (base32
bb719d6a 2488 "1anrx5vynk57hn5c8ig5pgkmcsbj9q5mvckd5rviw1jid7n89k57"))))
2cb3ab48
RW
2489 (build-system ruby-build-system)
2490 (arguments
bb719d6a
MB
2491 '(#:phases (modify-phases %standard-phases
2492 (add-after 'unpack 'fix-readline-tests
2493 (lambda _
2494 ;; Ensure Readline is initialized before running the
2495 ;; test to avoid a type clash with the mock ::Readline.
2496 ;; See <https://github.com/erikhuda/thor/pull/717>.
2497 (substitute* "spec/line_editor/readline_spec.rb"
2498 (("unless defined\\? ::Readline" all)
2499 (string-append "Thor::LineEditor::Readline.available?\n"
2500 all)))
2501 #t))
2502 (add-after 'unpack 'remove-coveralls-dependency
2503 (lambda _
2504 ;; Do not hook the test suite into the online
2505 ;; coveralls service.
2506 (substitute* "Gemfile"
2507 ((".*coveralls.*") ""))
2508 (substitute* "spec/helper.rb"
2509 (("require \"coveralls\"") "")
2510 (("Coveralls::SimpleCov::Formatter") "")
2511 ;; Also drop the WebMock dependency which is only
2512 ;; present to allow a coveralls.io connection, and
2513 ;; would otherwise introduce a circular dependency.
2514 (("require \"webmock/rspec\"") "")
2515 (("WebMock\\.disable_net_connect.*") ""))
2516 #t))
2517 (add-after 'unpack 'disable-network-tests
2518 (lambda _
2519 ;; These tests attempt to look up example.com.
2520 (substitute* "spec/actions/file_manipulation_spec.rb"
2521 (("it \"accepts (https?) remote sources" _ proto)
2522 (string-append "xit \"accepts " proto " remote sources")))
2523 #t))
2524 (add-after 'unpack 'disable-quality-tests
2525 (lambda _
2526 ;; These tests attempt to check the git repository for
2527 ;; tabs vs spaces, double vs single quotes, etc, and
2528 ;; depend on the git checkout.
2529 (delete-file "spec/quality_spec.rb")
2530 #t))
2531 (add-before 'check 'make-files-writable
2532 (lambda _
2533 ;; The tests needs rw access to the test suite.
2534 (for-each make-file-writable (find-files "spec"))
2535 #t))
2536 (replace 'check
2537 (lambda _
2538 (invoke "rspec" "spec"))))))
2cb3ab48 2539 (native-inputs
bb719d6a
MB
2540 `(("ruby-rspec" ,ruby-rspec)
2541 ("ruby-simplecov" ,ruby-simplecov)))
2cb3ab48
RW
2542 (synopsis "Ruby toolkit for building command-line interfaces")
2543 (description "Thor is a toolkit for building powerful command-line
2544interfaces.")
2545 (home-page "http://whatisthor.com/")
2546 (license license:expat)))
2547
ec79018e
RW
2548(define-public ruby-lumberjack
2549 (package
2550 (name "ruby-lumberjack")
41700efa 2551 (version "1.0.13")
ec79018e
RW
2552 (source (origin
2553 (method url-fetch)
2554 (uri (rubygems-uri "lumberjack" version))
2555 (sha256
2556 (base32
41700efa 2557 "06im7gcg42x77yhz2w5da2ly9xz0n0c36y5ks7xs53v0l9g0vf5n"))))
ec79018e
RW
2558 (build-system ruby-build-system)
2559 (native-inputs
8be62d3f
BW
2560 `(("ruby-rspec" ,ruby-rspec)
2561 ("ruby-timecop" ,ruby-timecop)))
ec79018e
RW
2562 (synopsis "Logging utility library for Ruby")
2563 (description "Lumberjack is a simple logging utility that can be a drop in
2564replacement for Logger or ActiveSupport::BufferedLogger. It provides support
2565for automatically rolling log files even with multiple processes writing the
2566same log file.")
7bf837fd 2567 (home-page "https://github.com/bdurand/lumberjack")
ec79018e
RW
2568 (license license:expat)))
2569
2a9ce5cb
CB
2570(define-public ruby-rbnacl
2571 (package
2572 (name "ruby-rbnacl")
2573 (version "6.0.1")
2574 (source
2575 (origin
2576 (method url-fetch)
2577 (uri (rubygems-uri "rbnacl" version))
2578 (sha256
2579 (base32
2580 "0ajxy5kj2jw09wdsla3jmha8w07vj5l14288xr9djpl327g3lzhn"))))
2581 (build-system ruby-build-system)
2582 (arguments
2583 `(#:phases
2584 (modify-phases %standard-phases
2585 (add-after 'unpack 'remove-unnecessary-dependencies
2586 (lambda _
2587 ;; Coveralls relates to a network service, and Rubocop to code
2588 ;; linting and both are unnecessary to run the tests
2589 (substitute* "Gemfile"
2590 ((".*rubocop.*") "\n")
2591 ((".*guard-rspec.*") "\n")
2592 ((".*coveralls.*") "\n"))
2593 (substitute* "spec/spec_helper.rb"
2594 (("require \"coveralls\"") "")
2595 (("Coveralls.wear!") ""))
2596 #t))
2597 (add-after 'unpack 'use-libsodium-from-store
2598 (lambda* (#:key inputs #:allow-other-keys)
2599 (substitute* '("lib/rbnacl/init.rb"
2600 "lib/rbnacl/sodium.rb")
2601 (("ffi_lib \\[.+\\]")
2602 (string-append "ffi_lib [\""
2603 (assoc-ref inputs "libsodium") "/lib/libsodium.so"
2604 "\"]")))
2605 #t))
2606 ;; Run Rspec directly to avoid the Rubocop dependency in the Rakefile
2607 (replace 'check
2608 (lambda* (#:key tests? #:allow-other-keys)
2609 (when tests?
2610 (invoke "rspec"))
2611 #t)))))
2612 (propagated-inputs
2613 `(("ruby-ffi" ,ruby-ffi)))
2614 (inputs
2615 `(("libsodium" ,libsodium)))
2616 (native-inputs
2617 `(("bundler" ,bundler)
2618 ("ruby-rspec" ,ruby-rspec)))
2619 (synopsis "Ruby FFI binding to libsodium")
2620 (description
2621 "This package provides Ruby FFI bindings to the Networking and
2622Cryptography (NaCl) library, also known as libsodium. This provides a
2623high-level toolkit for building cryptographic systems and protocols.")
2624 (home-page "https://github.com/crypto-rb/rbnacl")
2625 (license license:expat)))
2626
70b4cf38
RW
2627(define-public ruby-nenv
2628 (package
2629 (name "ruby-nenv")
12313cd0 2630 (version "0.3.0")
70b4cf38
RW
2631 (source (origin
2632 (method url-fetch)
2633 (uri (rubygems-uri "nenv" version))
2634 (sha256
2635 (base32
12313cd0 2636 "0r97jzknll9bhd8yyg2bngnnkj8rjhal667n7d32h8h7ny7nvpnr"))))
70b4cf38
RW
2637 (build-system ruby-build-system)
2638 (arguments
2639 `(#:tests? #f)) ; no tests included
2640 (native-inputs
2641 `(("ruby-rspec" ,ruby-rspec)
2642 ("bundler" ,bundler)))
2643 (synopsis "Ruby interface for modifying the environment")
2644 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
2645and inspect the environment.")
2646 (home-page "https://github.com/e2/nenv")
2647 (license license:expat)))
2648
af59d4b4
MB
2649(define-public ruby-ptools
2650 (package
2651 (name "ruby-ptools")
2652 (version "1.3.5")
2653 (source (origin
2654 (method url-fetch)
2655 (uri (rubygems-uri "ptools" version))
2656 (sha256
2657 (base32
2658 "1jb1h1nsk9zwykpniw8filbsk26kjsdlpk5wz6w0zyamcd41h87j"))))
2659 (build-system ruby-build-system)
2660 (arguments
2661 '(#:phases (modify-phases %standard-phases
2662 (add-after 'unpack 'patch-/bin/ls
2663 (lambda _
2664 (substitute* "test/test_binary.rb"
2665 (("/bin/ls")
2666 (which "ls")))
2667 #t))
2668 (add-before 'install 'create-gem
2669 (lambda _
2670 ;; Do not attempt to sign the gem.
2671 (substitute* "Rakefile"
2672 (("spec\\.signing_key = .*")
2673 ""))
2674 (invoke "rake" "gem:create"))))))
2675 (synopsis "Extra methods for Ruby's @code{File} class")
2676 (description
2677 "The @dfn{ptools} (power tools) library extends Ruby's core @code{File}
2678class with many additional methods modelled after common POSIX tools, such as
2679@code{File.which} for finding executables, @code{File.tail} to print the last
2680lines of a file, @code{File.wc} to count words, and so on.")
2681 (home-page "https://github.com/djberg96/ptools")
2682 (license license:artistic2.0)))
2683
8d9e9f28
RW
2684(define-public ruby-permutation
2685 (package
2686 (name "ruby-permutation")
2687 (version "0.1.8")
2688 (source (origin
2689 (method url-fetch)
2690 (uri (rubygems-uri "permutation" version))
2691 (sha256
2692 (base32
2693 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
2694 (build-system ruby-build-system)
2695 (arguments
2696 `(#:phases
2697 (modify-phases %standard-phases
2698 (add-after 'unpack 'fix-rakefile
2699 (lambda _
2700 (substitute* "Rakefile"
2701 (("require 'rake/gempackagetask'")
2702 "require 'rubygems/package_task'")
2703 (("include Config") ""))
2704 #t))
2705 (replace 'check
2706 (lambda _
9923d5a4 2707 (invoke "ruby" "-Ilib" "test/test.rb"))))))
8d9e9f28
RW
2708 (synopsis "Library to perform operations with sequence permutations")
2709 (description "This package provides a Ruby library to perform different
2710operations with permutations of sequences, such as strings and arrays.")
2f3800e5 2711 (home-page "https://flori.github.io/permutation")
8d9e9f28
RW
2712 (license license:gpl2))) ; GPL 2 only
2713
c5d14d42
RW
2714(define-public ruby-shellany
2715 (package
2716 (name "ruby-shellany")
2717 (version "0.0.1")
2718 (source (origin
2719 (method url-fetch)
2720 (uri (rubygems-uri "shellany" version))
2721 (sha256
2722 (base32
2723 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
2724 (build-system ruby-build-system)
2725 (arguments
2726 `(#:test-target "default"
2727 #:phases
2728 (modify-phases %standard-phases
2729 (add-after 'unpack 'fix-version-test
2730 (lambda _
2731 (substitute* "spec/shellany_spec.rb"
2732 (("^RSpec") "require \"shellany\"\nRSpec"))
2733 #t)))))
2734 (native-inputs
2735 `(("ruby-rspec" ,ruby-rspec)
2736 ("ruby-nenv" ,ruby-nenv)
2737 ("bundler" ,bundler)))
2738 (synopsis "Capture command output")
2739 (description "Shellany is a Ruby library providing functions to capture
2740the output produced by running shell commands.")
2741 (home-page "https://rubygems.org/gems/shellany")
2742 (license license:expat)))
2743
d152162f
RW
2744(define-public ruby-notiffany
2745 (package
2746 (name "ruby-notiffany")
8c1e4a4f 2747 (version "0.1.3")
d152162f
RW
2748 (source (origin
2749 (method url-fetch)
2750 (uri (rubygems-uri "notiffany" version))
2751 (sha256
2752 (base32
8c1e4a4f 2753 "0f47h3bmg1apr4x51szqfv3rh2vq58z3grh4w02cp3bzbdh6jxnk"))))
d152162f
RW
2754 (build-system ruby-build-system)
2755 ;; Tests are not included in the gem.
2756 (arguments `(#:tests? #f))
2757 (propagated-inputs
2758 `(("ruby-shellany" ,ruby-shellany)
2759 ("ruby-nenv" ,ruby-nenv)))
2760 (native-inputs
2761 `(("bundler" ,bundler)))
01eb17de
VC
2762 (synopsis "Wrapper library for notification libraries")
2763 (description "Notiffany is a Ruby wrapper library for notification
d152162f
RW
2764libraries such as Libnotify.")
2765 (home-page "https://github.com/guard/notiffany")
2766 (license license:expat)))
2767
96bf7521
MB
2768(define-public ruby-forking-test-runner
2769 (package
2770 (name "ruby-forking-test-runner")
2771 (version "1.6.0")
2772 (home-page "https://github.com/grosser/forking_test_runner")
2773 (source (origin
2774 (method git-fetch)
2775 (uri (git-reference (url home-page)
2776 (commit (string-append "v" version))))
2777 (file-name (git-file-name name version))
2778 (sha256
2779 (base32
2780 "1mrglzkj2nrgisccf2f30zbfmcs0awv1g3lw994b2az90fl39x8m"))))
2781 (build-system ruby-build-system)
2782 (arguments
2783 '(#:test-target "spec"
2784 ;; FIXME: ActiveRecord depends on sqlite3 1.3.6, but Guix has
2785 ;; 1.4.1, which in turn breaks the tests that use ActiveRecord.
2786 #:tests? #f
2787 #:phases (modify-phases %standard-phases
2788 (replace 'replace-git-ls-files
2789 (lambda _
2790 (substitute* "forking_test_runner.gemspec"
2791 (("`git ls-files lib/ bin/ MIT-LICENSE`")
2792 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
2793 #t))
2794 (add-before 'check 'remove-version-constraints
2795 (lambda _
2796 ;; Ignore hard coded version constraints for the tests.
2797 (delete-file "Gemfile.lock")
2798 #t))
2799 (add-before 'check 'set-HOME
2800 (lambda _
2801 ;; Many tests invoke Bundler, and fails when Bundler
2802 ;; warns that /homeless-shelter does not exist.
2803 (setenv "HOME" "/tmp")
2804 #t)))))
2805 (native-inputs
2806 `(("ruby-activerecord" ,ruby-activerecord)
2807 ("ruby-bump" ,ruby-bump)
2808 ("ruby-rspec" ,ruby-rspec)
2809 ("ruby-sqlite3" ,ruby-sqlite3)
2810 ("ruby-wwtd" ,ruby-wwtd)))
2811 (propagated-inputs
2812 `(("ruby-parallel-tests" ,ruby-parallel-tests)))
2813 (synopsis "Run every test in a fork")
2814 (description
2815 "This package is a wrapper around @code{parallel_tests} that runs every
2816test in a fork to avoid pollution and get clean output per test.")
2817 (license license:expat)))
2818
8528365b
RW
2819(define-public ruby-formatador
2820 (package
2821 (name "ruby-formatador")
2822 (version "0.2.5")
2823 (source (origin
2824 (method url-fetch)
2825 (uri (rubygems-uri "formatador" version))
2826 (sha256
2827 (base32
2828 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
2829 (build-system ruby-build-system)
2830 ;; Circular dependency: Tests require ruby-shindo, which requires
2831 ;; ruby-formatador at runtime.
2832 (arguments `(#:tests? #f))
2833 (synopsis "Ruby library to format text on stdout")
2834 (description "Formatador is a Ruby library to format text printed to the
2835standard output stream.")
7bf837fd 2836 (home-page "https://github.com/geemus/formatador")
8528365b
RW
2837 (license license:expat)))
2838
5437c741
CB
2839(define-public ruby-fuubar
2840 (package
2841 (name "ruby-fuubar")
2842 (version "2.3.2")
2843 (source
2844 (origin
2845 ;; Fetch from the git repository, as the gem package doesn't include
2846 ;; the tests.
2847 (method git-fetch)
2848 (uri (git-reference
b0e7b699 2849 (url "https://github.com/thekompanee/fuubar")
5437c741
CB
2850 (commit (string-append "releases/v" version))))
2851 (file-name (git-file-name name version))
2852 (sha256
2853 (base32
2854 "0jm1x2xp13csbnadixaikj7mlkp5yk4byx51npm56zi13izp7259"))))
2855 (build-system ruby-build-system)
2856 (arguments
2857 '(;; TODO: Some tests fail, unsure why.
2858 ;; 21 examples, 7 failures
2859 #:tests? #f
2860 #:phases
2861 (modify-phases %standard-phases
2862 (add-before 'build 'delete-certificate
2863 (lambda _
2864 ;; Remove 's.cert_chain' as we do not build with a private key
2865 (substitute* "fuubar.gemspec"
2866 ((".*cert_chain.*") "")
2867 ((".*signing_key.*") ""))
2868 #t))
2869 (replace 'check
2870 (lambda* (#:key tests? #:allow-other-keys)
2871 (when tests?
2872 (invoke "rspec"))
2873 #t)))))
2874 (native-inputs
2875 `(("bundler" ,bundler)))
2876 (propagated-inputs
2877 `(("ruby-rspec-core" ,ruby-rspec-core)
2878 ("ruby-progressbar" ,ruby-progressbar)))
2879 (synopsis "Fuubar is an RSpec formatter that uses a progress bar")
2880 (description
2881 "Fuubar is an RSpec formatter that uses a progress bar instead of a
2882string of letters and dots as feedback. It also stops on the first test
2883failure.")
2884 (home-page "https://github.com/thekompanee/fuubar")
2885 (license license:expat)))
2886
8ea991e3
CB
2887(define-public ruby-haml
2888 (package
2889 (name "ruby-haml")
2890 (version "5.0.4")
2891 (source
2892 (origin
2893 (method url-fetch)
2894 (uri (rubygems-uri "haml" version))
2895 (sha256
2896 (base32
2897 "1q0a9fvqh8kn6wm97fcks6qzbjd400bv8bx748w8v87m7p4klhac"))))
2898 (build-system ruby-build-system)
2899 (arguments
2900 '(#:tests? #f)) ; No included tests
2901 (propagated-inputs
2902 `(("ruby-tilt" ,ruby-tilt)
2903 ("ruby-temple" ,ruby-temple)))
2904 (synopsis "Haml is a Ruby library to generate HTML documents")
2905 (description
2906 "@acronym{Haml, HTML Abstraction Markup Language} is a layer on top of
2907HTML or XML that is designed to express the structure of documents using
2908indentation rather than closing tags. It was originally envisioned as a
2909plugin for Ruby on Rails, but it can function as a stand-alone templating
2910engine.")
2911 (home-page "http://haml.info/")
2912 (license license:expat)))
2913
353b7eb8
CB
2914(define-public ruby-hamster
2915 (package
2916 (name "ruby-hamster")
2917 (version "3.0.0")
2918 (source
2919 (origin
2920 (method url-fetch)
2921 (uri (rubygems-uri "hamster" version))
2922 (sha256
2923 (base32
2924 "1n1lsh96vnyc1pnzyd30f9prcsclmvmkdb3nm5aahnyizyiy6lar"))))
2925 (build-system ruby-build-system)
2926 (arguments
2927 '(#:phases
2928 (modify-phases %standard-phases
2929 (add-after 'unpack 'remove-unnecessary-dependencies
2930 (lambda _
2931 ;; pry is a debugging tool, and is unnecessary when running the
2932 ;; tests
2933 (substitute* "spec/lib/hamster/vector/insert_spec.rb"
2934 (("require 'pry'") ""))
2935 (substitute* "spec/spec_helper.rb"
2936 (("require \"pry\"") "")
2937 ;; CodeClimate is an online service, and is unnecessary for
2938 ;; running the tests
2939 (("require \"codeclimate-test-reporter\"") "")
2940 (("CodeClimate.*\n") ""))
2941 #t))
2942 ;; No Rakefile is included, so run rspec directly.
2943 (replace 'check
2944 (lambda* (#:key tests? #:allow-other-keys)
2945 (when tests?
2946 (invoke "rspec"))
2947 #t)))))
2948 (propagated-inputs
2949 `(("ruby-concurrent" ,ruby-concurrent)))
2950 (native-inputs
2951 `(("ruby-rspec" ,ruby-rspec)))
2952 (synopsis "Efficient, immutable, thread-safe collection classes for Ruby")
2953 (description
2954 "Hamster provides 6 persistent data structures: @code{Hash}, @code{Vector},
2955@code{Set}, @code{SortedSet}, @code{List}, and @code{Deque} (which works as an
2956immutable queue or stack).")
2957 (home-page "https://github.com/hamstergem/hamster")
2958 (license license:expat)))
2959
21781436
CB
2960(define-public ruby-hashdiff
2961 (package
2962 (name "ruby-hashdiff")
2963 (version "0.3.8")
2964 (source
2965 (origin
2966 (method url-fetch)
2967 (uri (rubygems-uri "hashdiff" version))
2968 (sha256
2969 (base32
2970 "19ykg5pax8798nh1yv71adkx0zzs7gn2rxjj86v7nsw0jba5lask"))))
2971 (build-system ruby-build-system)
2972 (arguments
2973 '(#:phases
2974 (modify-phases %standard-phases
2975 ;; Run tests directly via rspec to avoid Rake issue:
2976 ;; NoMethodError: undefined method `last_comment'
2977 (replace 'check
2978 (lambda* (#:key tests? #:allow-other-keys)
2979 (when tests?
2980 (invoke "rspec"))
2981 #t)))))
2982 (native-inputs
2983 `(("bundler" ,bundler)
2984 ("ruby-rspec" ,ruby-rspec-2)))
2985 (synopsis "HashDiff computes the smallest difference between two hashes")
2986 (description
2987 "HashDiff is a Ruby library to compute the smallest difference between
2988two hashes.")
2989 (home-page "https://github.com/liufengyun/hashdiff")
2990 (license license:expat)))
2991
3cc8e029
MB
2992(define-public ruby-hydra
2993 ;; No releases yet.
2994 (let ((commit "5abfa378743756ae4d9306cc134bcc482f5c9525")
2995 (revision "0"))
2996 (package
2997 (name "ruby-hydra")
2998 (version (git-version "0.0" revision commit))
2999 (home-page "https://github.com/hyphenation/hydra")
3000 (source (origin
3001 (method git-fetch)
3002 (uri (git-reference (url home-page) (commit commit)))
3003 (file-name (git-file-name name version))
3004 (sha256
3005 (base32
3006 "1cik398l2765y3d9sdhjzki3303hkry58ac6jlkiy7iy62nm529f"))))
3007 (build-system ruby-build-system)
3008 (arguments
3009 '(#:phases (modify-phases %standard-phases
3010 (add-after 'unpack 'make-files-writable
3011 (lambda _
3012 (for-each make-file-writable (find-files "."))
3013 #t))
3014 (replace 'check
3015 (lambda _
3016 (invoke "rspec"))))))
3017 (native-inputs
3018 `(("ruby-rspec" ,ruby-rspec)))
3019 (propagated-inputs
3020 `(("ruby-byebug" ,ruby-byebug)))
3021 (synopsis "Ruby hyphenation patterns")
3022 (description
3023 "ruby-hydra is a Ruby library for working with hyphenation patterns.")
3024 (license license:expat))))
3025
7ac4610f
RW
3026(define-public ruby-shindo
3027 (package
3028 (name "ruby-shindo")
3029 (version "0.3.8")
3030 (source (origin
3031 (method url-fetch)
3032 (uri (rubygems-uri "shindo" version))
3033 (sha256
3034 (base32
3035 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
3036 (build-system ruby-build-system)
3037 (arguments
3038 `(#:test-target "shindo_tests"
3039 #:phases
3040 (modify-phases %standard-phases
3041 (add-after 'unpack 'fix-tests
0b060e34
CB
3042 (lambda _
3043 (substitute* "tests/tests_helper.rb"
3044 (("-rubygems") ""))
3045 (substitute* "Rakefile"
3046 (("system \"shindo") "system \"./bin/shindo")
3047 ;; This test doesn't work, so we disable it.
3048 (("fail \"The build_error test should fail") "#")
3049 ((" -rubygems") ""))
3050 #t)))))
7ac4610f
RW
3051 (propagated-inputs
3052 `(("ruby-formatador" ,ruby-formatador)))
3053 (synopsis "Simple depth first Ruby testing")
3054 (description "Shindo is a simple depth first testing library for Ruby.")
3055 (home-page "https://github.com/geemus/shindo")
3056 (license license:expat)))
3057
f13636f2
RW
3058(define-public ruby-rubygems-tasks
3059 (package
3060 (name "ruby-rubygems-tasks")
f0f5f2d3 3061 (version "0.2.5")
f13636f2
RW
3062 (source (origin
3063 (method url-fetch)
3064 (uri (rubygems-uri "rubygems-tasks" version))
3065 (sha256
3066 (base32
f0f5f2d3 3067 "1x3sz3n2dlknd3v7w1mrq6f0ag6pwzhjvg7z29p75w3p42ma1gbx"))))
f13636f2
RW
3068 (build-system ruby-build-system)
3069 ;; Tests need Internet access.
3070 (arguments `(#:tests? #f))
3071 (native-inputs
3072 `(("ruby-rspec" ,ruby-rspec)
3073 ("ruby-yard" ,ruby-yard)))
3074 (synopsis "Rake tasks for managing and releasing Ruby Gems")
3075 (description "Rubygems-task provides Rake tasks for managing and releasing
3076Ruby Gems.")
3077 (home-page "https://github.com/postmodern/rubygems-tasks")
3078 (license license:expat)))
3079
cb6bc5df
CB
3080(define-public ruby-rubyzip
3081 (package
3082 (name "ruby-rubyzip")
3083 (version "1.2.1")
3084 (source
3085 (origin
3086 (method url-fetch)
3087 (uri (rubygems-uri "rubyzip" version))
3088 (sha256
3089 (base32
3090 "06js4gznzgh8ac2ldvmjcmg9v1vg9llm357yckkpylaj6z456zqz"))))
3091 (build-system ruby-build-system)
3092 (arguments
3093 '(#:phases
3094 (modify-phases %standard-phases
3095 (add-before 'check 'patch-tests
3096 (lambda* (#:key inputs #:allow-other-keys)
3097 (substitute* "test/gentestfiles.rb"
3098 (("/usr/bin/zip")
3099 (string-append
3100 (assoc-ref inputs "zip") "/bin/zip")))
3101 (substitute* "test/input_stream_test.rb"
3102 (("/usr/bin/env ruby") (which "ruby")))
3103 #t)))))
3104 (native-inputs
3105 `(("bundler" ,bundler)
3106 ("ruby-simplecov" ,ruby-simplecov)
3107 ("zip" ,zip)
3108 ("unzip" ,unzip)))
3109 (synopsis "Ruby module is for reading and writing zip files")
3110 (description
3111 "The rubyzip module provides ways to read from and create zip files.")
702a1012 3112 (home-page "https://github.com/rubyzip/rubyzip")
cb6bc5df
CB
3113 (license license:bsd-2)))
3114
58b59742
RW
3115(define-public ruby-simplecov-html
3116 (package
3117 (name "ruby-simplecov-html")
53fd476f 3118 (version "0.10.2")
58b59742
RW
3119 (source (origin
3120 (method url-fetch)
3121 (uri (rubygems-uri "simplecov-html" version))
3122 (sha256
3123 (base32
53fd476f 3124 "1lihraa4rgxk8wbfl77fy9sf0ypk31iivly8vl3w04srd7i0clzn"))))
58b59742 3125 (build-system ruby-build-system)
8b749cf3 3126 (arguments `(#:tests? #f)) ; there are no tests
58b59742
RW
3127 (native-inputs
3128 `(("bundler" ,bundler)))
3129 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
3130 (description "This package provides the default HTML formatter for
3131the SimpleCov code coverage tool for Ruby version 1.9 and above.")
3132 (home-page "https://github.com/colszowka/simplecov-html")
3133 (license license:expat)))
3134
a84fa2ad
RW
3135(define-public ruby-simplecov
3136 (package
3137 (name "ruby-simplecov")
d432682b 3138 (version "0.17.1")
a84fa2ad
RW
3139 (source (origin
3140 (method url-fetch)
3141 (uri (rubygems-uri "simplecov" version))
3142 (sha256
3143 (base32
d432682b 3144 "1135k46nik05sdab30yxb8264lqiz01c8v000g16cl9pjc4mxrdw"))))
a84fa2ad
RW
3145 (build-system ruby-build-system)
3146 ;; Simplecov depends on rubocop for code style checking at build time.
3147 ;; Rubocop needs simplecov at build time.
3148 (arguments `(#:tests? #f))
3149 (propagated-inputs
3150 `(("ruby-json" ,ruby-json)
3151 ("ruby-docile" ,ruby-docile)
3152 ("ruby-simplecov-html" ,ruby-simplecov-html)))
3153 (native-inputs
3154 `(("bundler" ,bundler)))
3155 (synopsis "Code coverage framework for Ruby")
3156 (description "SimpleCov is a code coverage framework for Ruby with a
3157powerful configuration library and automatic merging of coverage across test
3158suites.")
7bf837fd 3159 (home-page "https://github.com/colszowka/simplecov")
a84fa2ad
RW
3160 (license license:expat)))
3161
98b87b82
DT
3162(define-public ruby-useragent
3163 (package
3164 (name "ruby-useragent")
959d908d 3165 (version "0.16.10")
98b87b82
DT
3166 (source (origin
3167 (method url-fetch)
e83c6d00 3168 (uri (rubygems-uri "useragent" version))
98b87b82
DT
3169 (sha256
3170 (base32
959d908d 3171 "1fv5kvq494swy0p17h9qya9r50w15xsi9zmvhzb8gh55kq6ki50p"))))
98b87b82
DT
3172 (build-system ruby-build-system)
3173 (arguments
e83c6d00 3174 '(#:tests? #f)) ; no test suite
98b87b82
DT
3175 (synopsis "HTTP user agent parser for Ruby")
3176 (description "UserAgent is a Ruby library that parses and compares HTTP
3177User Agents.")
3178 (home-page "https://github.com/gshutler/useragent")
3179 (license license:expat)))
96086cc5 3180
f7e9b2f3
CB
3181(define-public ruby-backports
3182 (package
3183 (name "ruby-backports")
3184 (version "3.11.4")
3185 (source
3186 (origin
3187 (method url-fetch)
3188 (uri (rubygems-uri "backports" version))
3189 (sha256
3190 (base32
3191 "1hshjxww2h7s0dk57njrygq4zpp0nlqrjfya7zwm27iq3rhc3y8g"))))
3192 (build-system ruby-build-system)
3193 (arguments
3194 '(;; TODO: This should be default, but there is one test failure
3195 #:test-target "all_spec"))
3196 (native-inputs
3197 `(("ruby-mspec" ,ruby-mspec)
3198 ("ruby-activesupport" ,ruby-activesupport)))
3199 (synopsis "Backports of the features in newer Ruby versions")
3200 (description
3201 "Backports enables more compatibility across Ruby versions by providing
3202backports of some features.")
3203 (home-page "https://github.com/marcandre/backports")
3204 (license license:expat)))
3205
96086cc5
DT
3206(define-public ruby-bacon
3207 (package
3208 (name "ruby-bacon")
e83c6d00 3209 (version "1.2.0")
96086cc5
DT
3210 (source (origin
3211 (method url-fetch)
e83c6d00 3212 (uri (rubygems-uri "bacon" version))
96086cc5
DT
3213 (sha256
3214 (base32
e83c6d00 3215 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
96086cc5 3216 (build-system ruby-build-system)
96086cc5
DT
3217 (synopsis "Small RSpec clone")
3218 (description "Bacon is a small RSpec clone providing all essential
3219features.")
3220 (home-page "https://github.com/chneukirchen/bacon")
3221 (license license:expat)))
de59d316 3222
a8d2bf3c
CB
3223(define-public ruby-bacon-bits
3224 (package
3225 (name "ruby-bacon-bits")
3226 (version "0.1.0")
3227 (source
3228 (origin
3229 (method url-fetch)
3230 (uri (rubygems-uri "bacon-bits" version))
3231 (sha256
3232 (base32
3233 "1ghpj8ja94lhi8rgi872hqk4fd2amz2k7g9znd64z5dj7v6l0dmx"))))
3234 (build-system ruby-build-system)
3235 (arguments
3236 ;; No tests
3237 '(#:tests? #f))
3238 (propagated-inputs `(("ruby-bacon" ,ruby-bacon)))
3239 (synopsis "Extensions to Bacon, for disabling tests, before and after
3240blocks and more")
3241 (description
3242 "This extends the bacon testing framework with useful extensions to
3243disable tests, have before and after blocks that run once and more.")
3244 (home-page "https://github.com/cldwalker/bacon-bits")
3245 (license license:expat)))
3246
65f65889
CB
3247(define-public ruby-bacon-colored-output
3248 (package
3249 (name "ruby-bacon-colored-output")
3250 (version "1.1.1")
3251 (source
3252 (origin
3253 (method url-fetch)
3254 (uri (rubygems-uri "bacon-colored_output" version))
3255 (sha256
3256 (base32
3257 "1znyh3vkfdlmf19p3k4zip88ibym41dn5g4p4n5hmks2iznb7qpx"))))
3258 (build-system ruby-build-system)
3259 (arguments
3260 '(;; No included tests
3261 #:tests? #f))
3262 (propagated-inputs
3263 `(("ruby-bacon" ,ruby-bacon)))
3264 (synopsis "Colored output for Bacon test framework")
3265 (description
3266 "This package adds color through ANSI escape codes to Bacon test
3267output.")
3268 (home-page "https://github.com/whitequark/bacon-colored_output")
3269 (license license:expat)))
3270
e259bdf0
DT
3271(define-public ruby-connection-pool
3272 (package
3273 (name "ruby-connection-pool")
58021db4 3274 (version "2.2.2")
e259bdf0
DT
3275 (source (origin
3276 (method url-fetch)
e83c6d00 3277 (uri (rubygems-uri "connection_pool" version))
e259bdf0
DT
3278 (sha256
3279 (base32
58021db4 3280 "0lflx29mlznf1hn0nihkgllzbj8xp5qasn8j7h838465pi399k68"))))
e259bdf0
DT
3281 (build-system ruby-build-system)
3282 (native-inputs
3283 `(("bundler" ,bundler)))
3284 (synopsis "Generic connection pool for Ruby")
3285 (description "Connection_pool provides a generic connection pooling
3286interface for Ruby programs.")
3287 (home-page "https://github.com/mperham/connection_pool")
3288 (license license:expat)))
4c0aeb44 3289
4a98314d
MB
3290(define-public ruby-fast-gettext
3291 (package
3292 (name "ruby-fast-gettext")
c3beb7ce 3293 (version "2.0.3")
4a98314d
MB
3294 (home-page "https://github.com/grosser/fast_gettext")
3295 (source (origin
3296 (method git-fetch)
3297 (uri (git-reference (url home-page)
3298 (commit (string-append "v" version))))
3299 (file-name (git-file-name name version))
3300 (sha256
3301 (base32
c3beb7ce 3302 "1dg14apq5sfjshhcq0idphhs7aq9ikzswhqmn689p1h76mxqr1v6"))))
4a98314d
MB
3303 (build-system ruby-build-system)
3304 (arguments
3305 '(#:test-target "spec"
3306 #:phases (modify-phases %standard-phases
3307 (add-before 'check 'remove-version-constraints
3308 (lambda _
3309 (delete-file "Gemfile.lock")
3310 #t))
3311 (add-before 'check 'remove-activerecord-test
3312 (lambda _
3313 ;; FIXME: This test fails because ActiveRecord depends on
3314 ;; a different version of ruby-sqlite than the currently
3315 ;; available one.
3316 (delete-file
3317 "spec/fast_gettext/translation_repository/db_spec.rb")
3318 #t))
3319 (add-before 'check 'disable-i18n-test
3320 (lambda _
3321 ;; XXX: This test checks i18n intricasies with Rails 3 and
3322 ;; automatically disables itself for Rails 4.0, but does
3323 ;; not know about newer versions as it has not been updated
3324 ;; since 2014. Disable for later versions of Rails too.
3325 (substitute* "spec/fast_gettext/vendor/string_spec.rb"
3326 (((string-append "ActiveRecord::VERSION::MAJOR == 4 and "
3327 "ActiveRecord::VERSION::MINOR == 0"))
3328 "ActiveRecord::VERSION::MAJOR >= 4"))
3329 #t)))))
3330 (native-inputs
3331 `(;; For tests.
3332 ("ruby-activerecord" ,ruby-activerecord)
3333 ("ruby-activesupport" ,ruby-activesupport)
3334 ("ruby-bump" ,ruby-bump)
3335 ("ruby-forking-test-runner" ,ruby-forking-test-runner)
3336 ("ruby-i18n" ,ruby-i18n)
3337 ("ruby-rubocop" ,ruby-rubocop)
3338 ("ruby-rspec" ,ruby-rspec)
3339 ("ruby-single-cov" ,ruby-single-cov)
3340 ("ruby-sqlite3" ,ruby-sqlite3)
3341 ("ruby-wwtd" ,ruby-wwtd)))
3342 (synopsis "Fast implementation of @code{GetText}")
3343 (description
3344 "This package provides an alternative implementation of the Ruby
3345@code{GetText} library that is approximately 12x faster yet thread safe.")
3346 ;; Some parts are covered by the Ruby license, see file headers.
3347 (license (list license:expat license:ruby))))
3348
4c0aeb44
DT
3349(define-public ruby-net-http-persistent
3350 (package
3351 (name "ruby-net-http-persistent")
185ea446 3352 (version "3.0.0")
4c0aeb44
DT
3353 (source (origin
3354 (method url-fetch)
e83c6d00 3355 (uri (rubygems-uri "net-http-persistent" version))
4c0aeb44
DT
3356 (sha256
3357 (base32
185ea446 3358 "156rv95bgxfz6qw5y1r7c7bswr77918hygl8dyl14qzbqc5vyp18"))))
4c0aeb44 3359 (build-system ruby-build-system)
4c0aeb44
DT
3360 (native-inputs
3361 `(("ruby-connection-pool" ,ruby-connection-pool)
3362 ("ruby-hoe" ,ruby-hoe)))
3363 (synopsis "Persistent HTTP connection manager")
3364 (description "Net::HTTP::Persistent manages persistent HTTP connections
3365using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
3366 (home-page "https://github.com/drbrain/net-http-persistent")
3367 (license license:expat)))
afbbdf77 3368
f88bacaf
RW
3369(define-public ruby-power-assert
3370 (package
3371 (name "ruby-power-assert")
6754323b 3372 (version "1.1.5")
f88bacaf
RW
3373 (source (origin
3374 (method url-fetch)
3375 (uri (rubygems-uri "power_assert" version))
3376 (sha256
3377 (base32
6754323b 3378 "1dii0wkfa0jm8sk9b20zl1z4980dmrjh0zqnii058485pp3ws10s"))))
f88bacaf 3379 (build-system ruby-build-system)
6754323b
CB
3380 (arguments
3381 '(#:tests? #f)) ; No included tests
f88bacaf
RW
3382 (native-inputs
3383 `(("bundler" ,bundler)))
3384 (synopsis "Assert library with descriptive assertion messages")
3385 (description "Power-assert is an assertion library providing descriptive
3386assertion messages for tests.")
3387 (home-page "https://github.com/k-tsj/power_assert")
3388 (license (list license:bsd-2 license:ruby))))
3389
e42e3bfa
CB
3390(define-public ruby-powerpack
3391 (package
3392 (name "ruby-powerpack")
3393 (version "0.1.2")
3394 (source
3395 (origin
3396 (method url-fetch)
3397 (uri (rubygems-uri "powerpack" version))
3398 (sha256
3399 (base32
3400 "1r51d67wd467rpdfl6x43y84vwm8f5ql9l9m85ak1s2sp3nc5hyv"))))
3401 (build-system ruby-build-system)
3402 (arguments
3403 '(#:test-target "spec"))
3404 (native-inputs
3405 `(("bundler" ,bundler)
3406 ("ruby-rspec" ,ruby-rspec)
3407 ("ruby-yard" ,ruby-yard)))
3408 (synopsis "Useful extensions to core Ruby classes")
3409 (description
3410 "This package provides a few useful extensions to core Ruby classes,
3411including @code{Array}, @code{Enumerable}, @code{Hash}, @code{Numeric}, and
3412@code{String}.")
3413 (home-page "https://github.com/bbatsov/powerpack")
3414 (license license:expat)))
3415
347eb21e
RW
3416(define-public ruby-locale
3417 (package
3418 (name "ruby-locale")
3419 (version "2.1.2")
3420 (source (origin
3421 (method url-fetch)
3422 (uri (rubygems-uri "locale" version))
3423 (sha256
3424 (base32
3425 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
3426 (build-system ruby-build-system)
3427 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3428 ;; which needs ruby-gettext, which needs ruby-locale. To break the
3429 ;; dependency cycle we disable tests.
3430 (arguments `(#:tests? #f))
3431 (native-inputs
3432 `(("bundler" ,bundler)
3433 ("ruby-yard" ,ruby-yard)))
3434 (synopsis "Ruby library providing basic localization APIs")
3435 (description
3436 "Ruby-Locale is the pure ruby library which provides basic APIs for
3437localization.")
3438 (home-page "https://github.com/ruby-gettext/locale")
3439 (license (list license:lgpl3+ license:ruby))))
3440
09e2b0af
CB
3441(define-public ruby-temple
3442 (package
3443 (name "ruby-temple")
b1c79cab 3444 (version "0.8.2")
09e2b0af
CB
3445 (source
3446 (origin
3447 (method url-fetch)
3448 (uri (rubygems-uri "temple" version))
3449 (sha256
3450 (base32
b1c79cab 3451 "060zzj7c2kicdfk6cpnn40n9yjnhfrr13d0rsbdhdij68chp2861"))))
09e2b0af
CB
3452 (build-system ruby-build-system)
3453 (native-inputs
3454 `(("ruby-tilt" ,ruby-tilt)
3455 ("ruby-bacon" ,ruby-bacon)
3456 ("ruby-erubis" ,ruby-erubis)))
3457 (synopsis "Template compilation framework in Ruby")
3458 (description
3459 "Temple is an abstraction and framework for compiling templates to pure
3460Ruby.")
3461 (home-page "https://github.com/judofyr/temple")
3462 (license license:expat)))
3463
e2333ea3
RW
3464(define-public ruby-text
3465 (package
3466 (name "ruby-text")
3467 (version "1.3.1")
3468 (source (origin
3469 (method url-fetch)
3470 (uri (rubygems-uri "text" version))
3471 (sha256
3472 (base32
3473 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
3474 (build-system ruby-build-system)
3475 (synopsis "Collection of text algorithms for Ruby")
3476 (description
3477 "This package provides a collection of text algorithms: Levenshtein,
3478Soundex, Metaphone, Double Metaphone, Porter Stemming.")
7bf837fd 3479 (home-page "https://github.com/threedaymonk/text")
e2333ea3
RW
3480 (license license:expat)))
3481
c1f52261
RW
3482(define-public ruby-gettext
3483 (package
3484 (name "ruby-gettext")
3485 (version "3.1.7")
3486 (source (origin
3487 (method url-fetch)
3488 (uri (rubygems-uri "gettext" version))
3489 (sha256
3490 (base32
3491 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
3492 (build-system ruby-build-system)
3493 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3494 ;; which needs ruby-gettext. To break the dependency cycle we disable
3495 ;; tests.
3496 (arguments `(#:tests? #f))
3497 (propagated-inputs
3498 `(("ruby-locale" ,ruby-locale)
3499 ("ruby-text" ,ruby-text)))
3500 (native-inputs
3501 `(("bundler" ,bundler)
3502 ("ruby-yard" ,ruby-yard)))
3503 (synopsis "GNU gettext-like program for Ruby")
3504 (description
3505 "Gettext is a GNU gettext-like program for Ruby. The catalog
3506file (po-file) used is the same as that used by GNU gettext, allowing you to
3507use GNU gettext tools for maintenance.")
2f3800e5 3508 (home-page "https://ruby-gettext.github.com/")
c1f52261
RW
3509 (license (list license:lgpl3+ license:ruby))))
3510
cc5aeb8c
RW
3511(define-public ruby-packnga
3512 (package
3513 (name "ruby-packnga")
1d60c436 3514 (version "1.0.4")
cc5aeb8c
RW
3515 (source (origin
3516 (method url-fetch)
3517 (uri (rubygems-uri "packnga" version))
3518 (sha256
3519 (base32
1d60c436 3520 "1vv2j0i43s4xid2km5hgrrxqlqpwgq8nlm8kaxfg2531c1vwfsd4"))))
cc5aeb8c
RW
3521 (build-system ruby-build-system)
3522 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
3523 ;; To break the dependency cycle we disable tests.
3524 (arguments `(#:tests? #f))
3525 (propagated-inputs
3526 `(("ruby-gettext" ,ruby-gettext)
3527 ("ruby-yard" ,ruby-yard)))
3528 (native-inputs
3529 `(("bundler" ,bundler)))
3530 (synopsis "Utility library to package internationalized libraries")
3531 (description
3532 "Packnga is a library to translate to many languages using YARD.")
3533 (home-page "http://ranguba.org/packnga/")
3534 (license license:lgpl2.0+)))
3535
93dc8684
CB
3536(define-public ruby-test-construct
3537 (package
3538 (name "ruby-test-construct")
3539 (version "2.0.1")
3540 (source
3541 (origin
3542 (method url-fetch)
3543 (uri (rubygems-uri "test_construct" version))
3544 (sha256
3545 (base32
3546 "1a2ym3l068d0pxzzr95kvqx87zpdsarxslz9ygd4qfm9frrz0kgj"))))
3547 (build-system ruby-build-system)
3548 (native-inputs
3549 `(("bundler" ,bundler)
3550 ("ruby-mocha" ,ruby-mocha)
3551 ("ruby-rspec" ,ruby-rspec)))
3552 (synopsis "Creates temporary files and directories for testing")
3553 (description
3554 "TestConstruct is a @acronym{DSL, Domain Specific Language} for creating
3555temporary files and directories during tests.")
3556 (home-page "https://github.com/bhb/test_construct")
3557 (license license:expat)))
3558
3383f5bd
RW
3559(define-public ruby-test-unit
3560 (package
3561 (name "ruby-test-unit")
d74d96e4 3562 (version "3.2.5")
3383f5bd
RW
3563 (source (origin
3564 (method url-fetch)
3565 (uri (rubygems-uri "test-unit" version))
3566 (sha256
3567 (base32
d74d96e4 3568 "05bx36fw01iqz0xqhvjfrwjgnj1zx3b2vn6w1fzp19rchd7zqc52"))))
3383f5bd
RW
3569 (build-system ruby-build-system)
3570 (propagated-inputs
3571 `(("ruby-power-assert" ,ruby-power-assert)))
3572 (native-inputs
3573 `(("bundler" ,bundler)
3574 ("ruby-packnga" ,ruby-packnga)
3575 ("ruby-yard" ,ruby-yard)))
3576 (synopsis "Unit testing framework for Ruby")
3577 (description "@code{Test::Unit} is unit testing framework for Ruby, based
3578on xUnit principles. These were originally designed by Kent Beck, creator of
3579extreme programming software development methodology, for Smalltalk's SUnit.
3580It allows writing tests, checking results and automated testing in Ruby.")
2f3800e5 3581 (home-page "https://test-unit.github.io/")
3383f5bd
RW
3582 (license (list license:psfl license:ruby))))
3583
76b732fb
CB
3584(define-public ruby-markaby
3585 (package
3586 (name "ruby-markaby")
3587 (version "0.9.0")
3588 (source
3589 (origin
3590 (method url-fetch)
3591 (uri (rubygems-uri "markaby" version))
3592 (sha256
3593 (base32
3594 "1j4jc31ycydbkh5h3q6zwidzpavg3g5mbb5lqyaczd3jrq78rd7i"))))
3595 (build-system ruby-build-system)
3596 (arguments
3597 '(#:phases
3598 (modify-phases %standard-phases
3599 ;; Run rspec manually without using the Rakefile, as the versions of
3600 ;; Rake and RSpec 2 are incompatible:
3601 ;;
3602 ;; NoMethodError: undefined method `last_comment'
3603 (replace 'check
3604 (lambda* (#:key tests? #:allow-other-keys)
3605 (when tests?
3606 (invoke "rspec"))
3607 #t)))))
3608 (propagated-inputs
3609 `(("ruby-builder" ,ruby-builder)))
3610 (native-inputs
3611 `(("bundler" ,bundler)
3612 ("ruby-rspec" ,ruby-rspec-2)))
3613 (synopsis "Write HTML pages in pure Ruby")
3614 (description
3615 "Markaby allows writing HTML packages in pure Ruby. This is similar to
e54af322 3616the functionality provided by @acronym{ERB, Embedded Ruby}, but without the
76b732fb 3617mixture of HTML and additional ERB syntax.")
41181b76 3618 (home-page "https://markaby.github.io/")
76b732fb
CB
3619 (license license:expat)))
3620
b9511aa9
CB
3621(define-public ruby-maruku
3622 (package
3623 (name "ruby-maruku")
3624 (version "0.7.3")
3625 (source
3626 (origin
3627 (method url-fetch)
3628 (uri (rubygems-uri "maruku" version))
3629 (sha256
3630 (base32
3631 "1r7bxpgnx2hp3g12bjrmdrpv663dfqxsdp0af69kjhxmaxpia56x"))))
3632 (build-system ruby-build-system)
3633 (arguments
3634 '(;; TODO: 3 tests seem to fail due to HTML encoding issues
3635 #:tests? #f
3636 #:phases
3637 (modify-phases %standard-phases
3638 (replace 'check
3639 (lambda* (#:key tests? #:allow-other-keys)
3640 (when tests?
3641 (invoke "rspec"))
3642 #t)))))
3643 (native-inputs
3644 `(("ruby-rspec" ,ruby-rspec)
3645 ("ruby-simplecov" ,ruby-simplecov)
3646 ("ruby-nokogiri-diff" ,ruby-nokogiri-diff)))
3647 (synopsis "Markdown interpreter in Ruby")
3648 (description
3649 "Maruku is a Markdown interpreter in Ruby. It can export Markdown to
3650HTML, and PDF through LaTeX.")
3651 (home-page "https://github.com/bhollis/maruku")
3652 (license license:expat)))
3653
25d6d49b
RW
3654(define-public ruby-metaclass
3655 (package
3656 (name "ruby-metaclass")
3657 (version "0.0.4")
3658 (source (origin
3659 (method url-fetch)
3660 (uri (rubygems-uri "metaclass" version))
3661 (sha256
3662 (base32
3663 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
3664 (build-system ruby-build-system)
3665 (arguments
3666 `(#:phases
3667 (modify-phases %standard-phases
3668 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 3669 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3670 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
3671 (substitute* "Rakefile"
3672 (("t\\.libs << \"test\"" line)
3673 (string-append line "; t.libs << \""
3cb3fa67 3674 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
3675 "/gems/test-unit-"
3676 ,(package-version ruby-test-unit)
3677 "/lib\""))))
3678 #t)))))
25d6d49b
RW
3679 (native-inputs
3680 `(("bundler" ,bundler)
3681 ("ruby-test-unit" ,ruby-test-unit)))
3682 (synopsis "Ruby library adding metaclass method to all objects")
3683 (description
3684 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
3685objects.")
7bf837fd 3686 (home-page "https://github.com/floehopper/metaclass")
25d6d49b
RW
3687 (license license:expat)))
3688
fae1c866
MB
3689(define-public ruby-mkmf-lite
3690 (package
3691 (name "ruby-mkmf-lite")
3692 (version "0.3.2")
3693 (source (origin
3694 (method url-fetch)
3695 (uri (rubygems-uri "mkmf-lite" version))
3696 (sha256
3697 (base32
3698 "0br9k6zijj1zc25n8p7f2j1mwl58nfgdknf3q13h9k156jvrir06"))))
3699 (build-system ruby-build-system)
3700 (propagated-inputs
3701 `(("ruby-ptools" ,ruby-ptools)))
3702 (synopsis "Lightweight alternative to @code{mkmf}")
3703 (description
3704 "@code{mkmf-lite} is a light version of Ruby's @code{mkmf.rb} designed
3705for use as a library. It does not create packages, builds, or log files of
3706any kind. Instead, it provides mixin methods that you can use in FFI or tests
3707to check for the presence of header files, constants, and so on.")
3708 (home-page "https://github.com/djberg96/mkmf-lite")
3709 (license license:asl2.0)))
3710
1d1d20b0
CB
3711(define-public ruby-mspec
3712 (package
3713 (name "ruby-mspec")
3714 (version "1.9.1")
3715 (source
3716 (origin
3717 (method url-fetch)
3718 (uri (rubygems-uri "mspec" version))
3719 (sha256
3720 (base32
3721 "0wmyh2n40m4srwdx9z6h6g6p46k02pzyhcsja3hqcw5h5b0hfmhd"))))
3722 (build-system ruby-build-system)
3723 (arguments
3724 '(;; TODO: 3 test failures
3725 ;; ./spec/mocks/mock_spec.rb:82
3726 ;; ./spec/utils/name_map_spec.rb:151
3727 ;; ./spec/utils/name_map_spec.rb:155
3728 #:tests? #f
3729 #:phases
3730 (modify-phases %standard-phases
3731 (add-after 'extract-gemspec 'change-dependency-constraints
3732 (lambda _
3733 (substitute* "mspec.gemspec"
3734 (("rake.*") "rake>)\n")
3735 (("rspec.*") "rspec>)\n"))
3736 #t))
3737 (replace 'check
3738 (lambda* (#:key tests? #:allow-other-keys)
3739 (when tests?
3740 (invoke "rspec" "spec"))
3741 #t)))))
3742 (native-inputs
3743 `(("bundler" ,bundler)
3744 ("ruby-rake" ,ruby-rake)
3745 ("ruby-rspec" ,ruby-rspec)))
3746 (synopsis "MSpec is a specialized framework for RubySpec")
3747 (description
3748 "MSpec is a specialized framework that is syntax-compatible with RSpec 2
3749for basic features. MSpec contains additional features that assist in writing
3750specs for Ruby implementations in ruby/spec.")
3751 (home-page "http://rubyspec.org")
3752 (license license:expat)))
3753
b8aecc31
CB
3754(define-public ruby-mysql2
3755 (package
3756 (name "ruby-mysql2")
3757 (version "0.5.2")
3758 (source
3759 (origin
3760 (method git-fetch)
3761 (uri (git-reference
b0e7b699 3762 (url "https://github.com/brianmario/mysql2")
b8aecc31
CB
3763 (commit version)))
3764 (file-name (git-file-name name version))
3765 (sha256
3766 (base32
3767 "11lvfgc2rmvkm52jp0nbi6pvhk06klznghr7llldfw8basl9n5wv"))))
3768 (build-system ruby-build-system)
3769 (arguments
3770 '(;; TODO: Tests require a running MySQL/MariaDB service
3771 #:tests? #f
3772 #:phases
3773 (modify-phases %standard-phases
3774 (replace 'replace-git-ls-files
3775 (lambda _
3776 (substitute* "mysql2.gemspec"
3777 (("git ls-files .*`") "find . -type f |sort`"))
3778 #t))
3779 (add-before 'install 'set-MAKEFLAGS
3780 (lambda* (#:key outputs #:allow-other-keys)
3781 (setenv "MAKEFLAGS"
3782 (string-append
3783 "V=1 "
3784 "prefix=" (assoc-ref outputs "out")))
3785 #t))
3786 ;; Move the 'check phase to after 'install, as then you can test
3787 ;; using the installed mysql2 gem in the store.
3788 (delete 'check)
3789 (add-after 'install 'check
3790 (lambda* (#:key outputs tests? #:allow-other-keys)
3791 (setenv "GEM_PATH"
3792 (string-append
3793 (getenv "GEM_PATH")
3794 ":"
3795 (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))
3796 (when tests?
3797 (invoke "rspec"))
3798 #t)))))
3799 (inputs
2b8491fb
JL
3800 `(("mariadb" ,mariadb "lib")
3801 ("mariadb-dev" ,mariadb "dev")
b8aecc31
CB
3802 ("zlib" ,zlib)))
3803 (native-inputs
3804 `(("ruby-rspec" ,ruby-rspec)
3805 ("ruby-rake-compiler" ,ruby-rake-compiler)))
3806 (synopsis "MySQL library for Ruby, binding to libmysql")
3807 (description
3808 "This package provides a simple, fast MySQL library for Ruby, binding to
3809libmysql.")
3810 (home-page "https://github.com/brianmario/mysql2")
3811 (license license:expat)))
3812
21f7b7bd
RW
3813(define-public ruby-blankslate
3814 (package
3815 (name "ruby-blankslate")
3816 (version "3.1.3")
3817 (source (origin
3818 (method url-fetch)
3819 (uri (rubygems-uri "blankslate" version))
3820 (sha256
3821 (base32
3822 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
3823 (build-system ruby-build-system)
3824 (arguments
3825 `(#:phases
3826 (modify-phases %standard-phases
3827 (replace 'check
9923d5a4 3828 (lambda _ (invoke "rspec" "spec/"))))))
21f7b7bd
RW
3829 (native-inputs
3830 `(("bundler" ,bundler)
3831 ("ruby-rspec" ,ruby-rspec)))
3832 (synopsis "Abstract base class with no predefined methods")
3833 (description
3834 "BlankSlate provides an abstract base class with no predefined
3835methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
3836as a base class when writing classes that depend upon
3837@code{method_missing} (e.g. dynamic proxies).")
7bf837fd 3838 (home-page "https://github.com/masover/blankslate")
21f7b7bd
RW
3839 (license license:expat)))
3840
afdb437c
CB
3841(define-public ruby-bond
3842 (package
3843 (name "ruby-bond")
3844 (version "0.5.1")
3845 (source
3846 (origin
3847 (method url-fetch)
3848 (uri (rubygems-uri "bond" version))
3849 (sha256
3850 (base32
3851 "1r19ifc4skyl2gxnifrxa5jvbbay9fb2in79ppgv02b6n4bhsw90"))))
3852 (build-system ruby-build-system)
3853 (native-inputs
3854 `(("ruby-bacon" ,ruby-bacon)
3855 ("ruby-bacon-bits" ,ruby-bacon-bits)
3856 ("ruby-mocha-on-bacon" ,ruby-mocha-on-bacon)))
3857 (synopsis "Bond can provide custom autocompletion for arguments, methods
3858and more")
3859 (description
3860 "Bond can autocomplete argument(s) to methods, uniquely completing per
3861module, per method and per argument. Bond provides a configuration system and
3862a DSL for creating custom completions and completion rules. Bond can also
3863load completions that ship with gems. Bond is able to offer more than irb's
3864completion since it uses the full line of input when completing as opposed to
3865irb's last-word approach.")
3866 (home-page "http://tagaholic.me/bond/")
3867 (license license:expat)))
3868
f3d7bb93
CB
3869(define-public ruby-idn-ruby
3870 (package
3871 (name "ruby-idn-ruby")
3872 (version "0.1.0")
3873 (source
3874 (origin
3875 (method url-fetch)
3876 (uri (rubygems-uri "idn-ruby" version))
3877 (sha256
3878 (base32
3879 "07vblcyk3g72sbq12xz7xj28snpxnh3sbcnxy8bglqbfqqhvmawr"))))
3880 (build-system ruby-build-system)
3881 (arguments
3882 '(#:phases
3883 (modify-phases %standard-phases
3884 (delete 'check)
3885 (add-after 'install 'check
3886 (lambda* (#:key tests? outputs #:allow-other-keys)
3887 (when tests?
3888 (let* ((gem-file (cadr (find-files "." "\\.gem")))
3889 (name-and-version (basename gem-file ".gem")))
3890 (apply invoke
3891 "ruby" "--verbose"
3892 (string-append "-I"
3893 (assoc-ref outputs "out")
3894 "/lib/ruby/vendor_ruby/gems/"
3895 name-and-version
3896 "/lib")
3897 (find-files "./test" ".*\\.rb"))))
3898 #t)))))
3899 (inputs
3900 `(("libidn" ,libidn)))
3901 (synopsis "Ruby Bindings for the GNU LibIDN library")
3902 (description
3903 "Ruby Bindings for the GNU LibIDN library, an implementation of the
3904Stringprep, Punycode and IDNA specifications. These are used to encode and
3905decode internationalized domain + names according to the IDNA2003
3906specifications.
3907
3908Included are the most important parts of the Stringprep, Punycode and IDNA
3909APIs like performing Stringprep processings, encoding to and decoding from
3910Punycode strings and converting entire domain names to and from the ACE
3911encoded form.")
3912 (home-page "https://github.com/deepfryed/idn-ruby")
3913 (license license:asl2.0)))
3914
4016ba3f
RW
3915(define-public ruby-instantiator
3916 (package
3917 (name "ruby-instantiator")
688c9076 3918 (version "0.0.7")
4016ba3f
RW
3919 (source (origin
3920 (method url-fetch)
3921 (uri (rubygems-uri "instantiator" version))
3922 (sha256
3923 (base32
688c9076 3924 "0w07w3gkyqr7m0vz5h13vm8b411660qywjm2xxxgdjv4wb3fazbr"))))
4016ba3f
RW
3925 (build-system ruby-build-system)
3926 (arguments
3927 `(#:phases
3928 (modify-phases %standard-phases
3929 (add-after 'unpack 'add-test-unit-to-search-path
761e7042 3930 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3931 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
3932 (substitute* "Rakefile"
3933 (("t\\.libs << \"test\"" line)
3934 (string-append line "; t.libs << \""
3cb3fa67 3935 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
3936 "/gems/test-unit-"
3937 ,(package-version ruby-test-unit)
3938 "/lib\""))))
3939 #t)))))
4016ba3f
RW
3940 (propagated-inputs
3941 `(("ruby-blankslate" ,ruby-blankslate)))
3942 (native-inputs
3943 `(("bundler" ,bundler)
3944 ("ruby-test-unit" ,ruby-test-unit)))
3945 (synopsis "Instantiate an arbitrary Ruby class")
3946 (description
3947 "Instantiator lets you instantiate an arbitrary Ruby class without
3948knowing anything about the constructor.")
3949 (home-page "https://github.com/floehopper/instantiator")
3950 (license license:expat)))
3951
97aee8d3
RW
3952(define-public ruby-introspection
3953 (package
3954 (name "ruby-introspection")
98ff58a5 3955 (version "0.0.4")
97aee8d3
RW
3956 (source (origin
3957 (method url-fetch)
3958 (uri (rubygems-uri "introspection" version))
3959 (sha256
3960 (base32
98ff58a5 3961 "1y2nbijkc0zlfmn9ss6588ilarq2kbn2i7w7pwwsli66dj84zgca"))))
97aee8d3
RW
3962 (build-system ruby-build-system)
3963 (arguments
3964 `(#:phases
3965 (modify-phases %standard-phases
3966 (add-after 'unpack 'add-test-unit-to-search-path
3967 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 3968 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
761e7042
BW
3969 (substitute* "Rakefile"
3970 (("t\\.libs << \"test\"" line)
3971 (string-append line "; t.libs << \""
3cb3fa67 3972 test-unit "/lib/ruby/vendor_ruby"
761e7042
BW
3973 "/gems/test-unit-"
3974 ,(package-version ruby-test-unit)
3975 "/lib\""))))
97aee8d3
RW
3976 #t)))))
3977 (propagated-inputs
3978 `(("ruby-instantiator" ,ruby-instantiator)
3979 ("ruby-metaclass" ,ruby-metaclass)))
3980 (native-inputs
3981 `(("bundler" ,bundler)
3982 ("ruby-blankslate" ,ruby-blankslate)
3983 ("ruby-test-unit" ,ruby-test-unit)))
3984 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
3985 (description
3986 "Introspection provides tools to inspect the hierarchy of method
3987definitions on a Ruby object.")
3988 (home-page "https://github.com/floehopper/introspection")
3989 (license license:expat)))
3990
d93062fd
RW
3991(define-public ruby-redcarpet
3992 (package
3993 (name "ruby-redcarpet")
ba4084bb 3994 (version "3.5.0")
d93062fd
RW
3995 (source (origin
3996 (method url-fetch)
3997 (uri (rubygems-uri "redcarpet" version))
3998 (sha256
3999 (base32
ba4084bb 4000 "0skcyx1h8b5ms0rp2zm3ql6g322b8c1adnkwkqyv7z3kypb4bm7k"))))
d93062fd
RW
4001 (build-system ruby-build-system)
4002 (arguments
4003 `(#:phases
4004 (modify-phases %standard-phases
4005 ;; The gem archive does not include the conformance tests.
4006 (add-after 'unpack 'disable-conformance-tests
4007 (lambda _
4008 (substitute* "Rakefile"
4009 (("task :test => %w\\[test:unit test:conformance\\]")
4010 "task :test => %w[test:unit]"))
4011 #t)))))
4012 (native-inputs
4013 `(("bundler" ,bundler)
4014 ("ruby-test-unit" ,ruby-test-unit)
4015 ("ruby-rake-compiler" ,ruby-rake-compiler)))
4016 (synopsis "Extensible Markdown to (X)HTML converter")
4017 (description
4018 "Redcarpet is an extensible Ruby library for Markdown processing and
4019conversion to (X)HTML.")
7bf837fd 4020 (home-page "https://github.com/vmg/redcarpet")
d93062fd
RW
4021 (license license:expat)))
4022
09924294
CB
4023(define-public ruby-rerun
4024 (package
4025 (name "ruby-rerun")
4026 (version "0.13.0")
4027 (source
4028 (origin
4029 (method url-fetch)
4030 (uri (rubygems-uri "rerun" version))
4031 (sha256
4032 (base32
4033 "1cskvxk8z8vmfail8na7hj91hs0qnvds9nydj04zi3dbddgnbmvz"))))
4034 (build-system ruby-build-system)
4035 (arguments
4036 '(#:tests? #f)) ; No included tests
4037 (propagated-inputs
4038 `(("ruby-listen" ,ruby-listen)))
4039 (synopsis "Run a process, and restart when some monitored files change")
4040 (description
52beae7b 4041 "Rerun is a tool to launch programs, then monitor the file system, and
09924294
CB
4042restart the program when any of the monitored files change. It's written in
4043Ruby, but can be used for all programs.")
4044 (home-page "https://github.com/alexch/rerun/")
4045 (license license:expat)))
4046
8d85543b
MB
4047(define-public ruby-maxitest
4048 (package
4049 (name "ruby-maxitest")
4050 (version "3.6.0")
4051 (home-page "https://github.com/grosser/maxitest")
4052 (source (origin
4053 ;; Pull from git because the gem does not contain tests.
4054 (method git-fetch)
4055 (uri (git-reference
4056 (url home-page)
4057 (commit (string-append "v" version))))
4058 (file-name (git-file-name name version))
4059 (sha256
4060 (base32
4061 "07b3j0bv3dx5j42jlvpvl07aaxplyi6wq688y3jl8y528ww2hjz8"))))
4062 (build-system ruby-build-system)
4063 (arguments
4064 '(#:test-target "default"
4065 #:phases (modify-phases %standard-phases
4066 (replace 'replace-git-ls-files
4067 (lambda _
4068 (substitute* "maxitest.gemspec"
4069 (("`git ls-files lib/ bin/ MIT-LICENSE Readme.md`")
4070 "`find lib/ bin/ MIT-LICENSE Readme.md -type f | sort`"))
4071 #t))
4072 (add-before 'check 'remove-version-constraints
4073 (lambda _
4074 ;; Don't use specific versions of dependencies, instead
4075 ;; take whatever is available in Guix.
4076 (delete-file "Gemfile.lock")
4077 #t))
4078 (add-before 'check 'add-mtest-on-PATH
4079 (lambda _
4080 ;; Tests use 'mtest' which is not automatically added on
4081 ;; PATH.
4082 (setenv "PATH" (string-append (getcwd) "/bin:"
4083 (getenv "PATH")))
4084 #t)))))
4085 (native-inputs
4086 `(("ps" ,procps)
4087 ("ruby-bump" ,ruby-bump)
4088 ("ruby-byebug" ,ruby-byebug)
4089 ("ruby-rspec" ,ruby-rspec)
4090 ("ruby-wwtd" ,ruby-wwtd)))
4091 (propagated-inputs
4092 `(("ruby-minitest" ,ruby-minitest)))
4093 (synopsis "Minitest with extra features")
4094 (description
4095 "Maxitest is a wrapper around Minitest with extra functionality such
4096as timeouts, an @command{mtest} executable that can run tests by line
4097number, support for interrupted tests, better backtraces, and more.")
4098 (license license:expat)))
4099
4f2a52ae
RW
4100(define-public ruby-mocha
4101 (package
4102 (name "ruby-mocha")
2fc3cc24 4103 (version "1.11.2")
4f2a52ae
RW
4104 (source (origin
4105 (method url-fetch)
4106 (uri (rubygems-uri "mocha" version))
4107 (sha256
4108 (base32
2fc3cc24 4109 "0hxmkm8qxd04vwj8mqnpyrf2dwy7g1k9zipdfhl4y71cw7ijm9n4"))))
4f2a52ae
RW
4110 (build-system ruby-build-system)
4111 (arguments
4112 `(#:phases
4113 (modify-phases %standard-phases
2fc3cc24
MB
4114 (add-before 'check 'remove-rubocop-dependency
4115 (lambda _
4116 ;; Disable dependency on Rubocop, which is just a linter,
4117 ;; and would introduce a circular dependency.
4118 (substitute* "mocha.gemspec"
4119 ((".*rubocop.*")
4120 "true\n"))
4121 #t)))))
4f2a52ae 4122 (native-inputs
2fc3cc24 4123 `(("ruby-introspection" ,ruby-introspection)))
4f2a52ae
RW
4124 (synopsis "Mocking and stubbing library for Ruby")
4125 (description
4126 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
4127allows mocking and stubbing of methods on real (non-mock) classes.")
4128 (home-page "http://gofreerange.com/mocha/docs")
e3febab5
MB
4129 ;; Mocha can be used with either license at the users choice.
4130 (license (list license:expat license:ruby))))
4f2a52ae 4131
cf646acf
CB
4132(define-public ruby-mocha-on-bacon
4133 (package
4134 (name "ruby-mocha-on-bacon")
4135 (version "0.2.3")
4136 (source
4137 (origin
4138 (method url-fetch)
4139 (uri (rubygems-uri "mocha-on-bacon" version))
4140 (sha256
4141 (base32
4142 "1h49b33rq889hn8x3wp9byczl91va16jh1w4d2wyy4yj23icdrcp"))))
4143 (build-system ruby-build-system)
4144 (arguments
4145 ;; rubygems.org release missing tests
4146 '(#:tests? #f))
4147 (propagated-inputs `(("ruby-mocha" ,ruby-mocha)))
4148 (synopsis "Mocha adapter for Bacon")
4149 (description
4150 "This package provides a Mocha adapter for Bacon, allowing you to use the
4151Mocha stubbing and mocking library with Bacon, a small RSpec clone.")
4152 (home-page
4153 "https://github.com/alloy/mocha-on-bacon")
4154 (license license:expat)))
4155
2c84ba7e
RW
4156(define-public ruby-net-ssh
4157 (package
4158 (name "ruby-net-ssh")
5803f872 4159 (version "4.2.0")
2c84ba7e
RW
4160 (source (origin
4161 (method url-fetch)
4162 (uri (rubygems-uri "net-ssh" version))
4163 (sha256
4164 (base32
5803f872 4165 "07c4v97zl1daabmri9zlbzs6yvkl56z1q14bw74d53jdj0c17nhx"))))
2c84ba7e
RW
4166 (build-system ruby-build-system)
4167 (native-inputs
a7938625
MB
4168 `(("bundler" ,bundler)
4169 ("ruby-mocha" ,ruby-mocha)
2c84ba7e
RW
4170 ("ruby-test-unit" ,ruby-test-unit)))
4171 (synopsis "Ruby implementation of the SSH2 client protocol")
4172 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
4173client protocol. It allows you to write programs that invoke and interact
4174with processes on remote servers, via SSH2.")
4175 (home-page "https://github.com/net-ssh/net-ssh")
4176 (license license:expat)))
4177
d38755cb
DM
4178(define-public ruby-net-scp
4179 (package
4180 (name "ruby-net-scp")
4181 ;; The 1.2.1 release would be incompatible with ruby-net-ssh >= 4.
4182 (version "1.2.2.rc2")
4183 (source
4184 (origin
e405f996
TGR
4185 (method git-fetch)
4186 (uri (git-reference
b0e7b699 4187 (url "https://github.com/net-ssh/net-scp")
e405f996
TGR
4188 (commit (string-append "v" version))))
4189 (file-name (git-file-name name version))
d38755cb 4190 (sha256
e405f996 4191 (base32 "1nyn17sy71fn7zs3y6wbgcn35318c10flqgc0582409095x4h0sx"))))
d38755cb
DM
4192 (build-system ruby-build-system)
4193 (native-inputs
4194 `(("bundler" ,bundler)
4195 ("ruby-test-unit" ,ruby-test-unit)
4196 ("ruby-mocha" ,ruby-mocha)))
4197 (propagated-inputs
4198 `(("ruby-net-ssh" ,ruby-net-ssh)))
4199 (synopsis "Pure-Ruby SCP client library")
4200 (description "@code{Net::SCP} is a pure-Ruby implementation of the SCP
4201client protocol.")
4202 (home-page "https://github.com/net-ssh/net-scp")
4203 (license license:expat)))
4204
2206e948
DT
4205(define-public ruby-minitest
4206 (package
4207 (name "ruby-minitest")
88a105c1 4208 (version "5.11.3")
2206e948 4209 (source (origin
e83c6d00
DT
4210 (method url-fetch)
4211 (uri (rubygems-uri "minitest" version))
2206e948
DT
4212 (sha256
4213 (base32
88a105c1 4214 "0icglrhghgwdlnzzp4jf76b0mbc71s80njn5afyfjn4wqji8mqbq"))))
2206e948 4215 (build-system ruby-build-system)
2206e948
DT
4216 (native-inputs
4217 `(("ruby-hoe" ,ruby-hoe)))
4218 (synopsis "Small test suite library for Ruby")
4219 (description "Minitest provides a complete suite of Ruby testing
4220facilities supporting TDD, BDD, mocking, and benchmarking.")
4221 (home-page "https://github.com/seattlerb/minitest")
4222 (license license:expat)))
4223
1db6e09f
RW
4224;; This is the last release of Minitest 4, which is used by some packages.
4225(define-public ruby-minitest-4
4226 (package (inherit ruby-minitest)
4227 (version "4.7.5")
4228 (source (origin
4229 (method url-fetch)
4230 (uri (rubygems-uri "minitest" version))
4231 (sha256
4232 (base32
4233 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
4234 (arguments
4235 `(#:phases
4236 (modify-phases %standard-phases
4237 (add-after 'unpack 'remove-unsupported-method
4238 (lambda _
4239 (substitute* "Rakefile"
4240 (("self\\.rubyforge_name = .*") ""))
9a7017eb
BW
4241 #t))
4242 (add-after 'build 'exclude-failing-tests
4243 (lambda _
4244 ;; Some tests are failing on Ruby 2.4 due to the deprecation of
4245 ;; Fixnum.
4246 (delete-file "test/minitest/test_minitest_spec.rb")
4247 #t)))))))
1db6e09f 4248
450a3f7f
CB
4249(define-public ruby-minitest-around
4250 (package
4251 (name "ruby-minitest-around")
4252 (version "0.5.0")
4253 (source
4254 (origin
4255 (method url-fetch)
4256 (uri (rubygems-uri "minitest-around" version))
4257 (sha256
4258 (base32
4259 "15ywnqx0719jl9c25yqfshmwcir57i5f4hr1ra9v9vay9ylcwndr"))))
4260 (build-system ruby-build-system)
4261 (arguments
4262 '(#:phases
4263 (modify-phases %standard-phases
4264 (add-after 'extract-gemspec 'remove-unnecessary-dependency-versions
4265 (lambda _
4266 (substitute* "minitest-around.gemspec"
4267 (("%q<cucumber>.*") "%q<cucumber>, [\">= 0\"])\n"))
4268 #t)))))
4269 (propagated-inputs
4270 `(("ruby-minitest" ,ruby-minitest)))
4271 (native-inputs
4272 `(("bundler" ,bundler)
4273 ("ruby-cucumber" ,ruby-cucumber)
4274 ("ruby-bump" ,ruby-bump)
4275 ("ruby-test-construct" ,ruby-test-construct)))
4276 (synopsis "Run code around tests in Minitest")
4277 (description
4278 "This library provides a way to run code around tests in Minitest,
4279written using either the unit test or spec style.")
4280 (home-page "https://github.com/splattael/minitest-around")
4281 (license license:expat)))
4282
35130835
DT
4283(define-public ruby-minitest-sprint
4284 (package
4285 (name "ruby-minitest-sprint")
4286 (version "1.1.0")
4287 (source (origin
e83c6d00
DT
4288 (method url-fetch)
4289 (uri (rubygems-uri "minitest-sprint" version))
35130835
DT
4290 (sha256
4291 (base32
e83c6d00 4292 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
35130835 4293 (build-system ruby-build-system)
35130835
DT
4294 (native-inputs
4295 `(("ruby-hoe" ,ruby-hoe)
4296 ("ruby-minitest" ,ruby-minitest)))
4297 (synopsis "Fast test suite runner for minitest")
4298 (description "Minitest-sprint is a test runner for minitest that makes it
4299easier to re-run individual failing tests.")
4300 (home-page "https://github.com/seattlerb/minitest-sprint")
4301 (license license:expat)))
4302
0808e361
DT
4303(define-public ruby-minitest-bacon
4304 (package
4305 (name "ruby-minitest-bacon")
6f9652b0 4306 (version "1.0.3")
0808e361 4307 (source (origin
e83c6d00
DT
4308 (method url-fetch)
4309 (uri (rubygems-uri "minitest-bacon" version))
0808e361
DT
4310 (sha256
4311 (base32
6f9652b0 4312 "0zhdwcl6bgha61qiyfvr7zs7ywaxc33wmj9xhxl8jdmpdvifvfaj"))))
0808e361 4313 (build-system ruby-build-system)
0808e361
DT
4314 (native-inputs
4315 `(("ruby-hoe" ,ruby-hoe)))
4316 (inputs
4317 `(("ruby-minitest" ,ruby-minitest)))
4318 (synopsis "Bacon compatibility library for minitest")
4319 (description "Minitest-bacon extends minitest with bacon-like
4320functionality, making it easier to migrate test suites from bacon to minitest.")
4321 (home-page "https://github.com/seattlerb/minitest-bacon")
4322 (license license:expat)))
4323
39dc0eb5
BW
4324(define-public ruby-minitest-focus
4325 (package
4326 (name "ruby-minitest-focus")
4327 (version "1.1.2")
4328 (source
4329 (origin
4330 (method url-fetch)
4331 (uri (rubygems-uri "minitest-focus" version))
4332 (sha256
4333 (base32
4334 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
4335 (build-system ruby-build-system)
4336 (propagated-inputs
4337 `(("ruby-minitest" ,ruby-minitest)))
4338 (native-inputs
4339 `(("ruby-hoe" ,ruby-hoe)))
4340 (synopsis "Allows a few specific tests to be focused on")
4341 (description
4342 "@code{minitest-focus} gives the ability focus on a few tests with ease
4343without having to use command-line arguments. It introduces a @code{focus}
4344class method for use in testing classes, specifying that the next defined test
4345is to be run.")
4346 (home-page "https://github.com/seattlerb/minitest-focus")
4347 (license license:expat)))
4348
99fc5cd5
BW
4349(define-public ruby-minitest-pretty-diff
4350 ;; Use git reference because gem is out of date and does not contain testing
4351 ;; script. There are no releases on GitHub.
4352 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
4353 (package
4354 (name "ruby-minitest-pretty-diff")
4355 (version (string-append "0.1-1." (string-take commit 8)))
4356 (source (origin
4357 (method git-fetch)
4358 (uri (git-reference
b0e7b699 4359 (url "https://github.com/adammck/minitest-pretty_diff")
99fc5cd5
BW
4360 (commit commit)))
4361 (file-name (string-append name "-" version "-checkout"))
4362 (sha256
4363 (base32
4364 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
4365 (build-system ruby-build-system)
4366 (arguments
4367 `(#:phases
4368 (modify-phases %standard-phases
4369 (replace 'check
4370 (lambda _
9923d5a4 4371 (invoke "script/test"))))))
99fc5cd5
BW
4372 (native-inputs
4373 `(("bundler" ,bundler)
4374 ("ruby-turn" ,ruby-turn)))
4375 (synopsis "Pretty-print hashes and arrays in MiniTest")
4376 (description
4377 "@code{minitest-pretty_diff} monkey-patches
4378@code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
4379diffing them. This makes it easier to spot differences between nested
4380structures when tests fail.")
4381 (home-page "https://github.com/adammck/minitest-pretty_diff")
4382 (license license:expat))))
4383
685d0d2f
BW
4384(define-public ruby-minitest-moar
4385 (package
4386 (name "ruby-minitest-moar")
4387 (version "0.0.4")
4388 (source
4389 (origin
4390 (method url-fetch)
4391 (uri (rubygems-uri "minitest-moar" version))
4392 (sha256
4393 (base32
4394 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
4395 (build-system ruby-build-system)
4396 (arguments
4397 `(#:phases
4398 (modify-phases %standard-phases
4399 (add-before 'check 'clean-dependencies
4400 (lambda _
4401 ;; Remove all gems defined in the Gemfile because these are not
4402 ;; truly needed.
4403 (substitute* "Gemfile"
4404 (("gem .*") ""))
4405 ;; Remove byebug as not needed to run tests.
4406 (substitute* "test/test_helper.rb"
4407 (("require 'byebug'") ""))
4408 #t)))))
4409 (native-inputs
4410 `(("bundler" ,bundler)
4411 ("ruby-minitest" ,ruby-minitest)))
4412 (synopsis "Extra features and changes to MiniTest")
4413 (description "@code{MiniTest Moar} add some additional features and
4414changes some default behaviours in MiniTest. For instance, Moar replaces the
4415MiniTest @code{Object#stub} with a global @code{stub} method.")
4416 (home-page "https://github.com/dockyard/minitest-moar")
4417 (license license:expat)))
4418
e07ef1d6
BW
4419(define-public ruby-minitest-bonus-assertions
4420 (package
4421 (name "ruby-minitest-bonus-assertions")
c9e261b7 4422 (version "3.0")
e07ef1d6
BW
4423 (source
4424 (origin
4425 (method url-fetch)
4426 (uri (rubygems-uri "minitest-bonus-assertions" version))
4427 (sha256
4428 (base32
c9e261b7 4429 "1hbq9jk904xkz868yha1bqcm6azm7kmjsll2k4pn2nrcib508h2a"))))
e07ef1d6
BW
4430 (build-system ruby-build-system)
4431 (arguments
4432 `(#:phases
4433 (modify-phases %standard-phases
4434 (add-before 'check 'clean-dependencies
4435 (lambda _
4436 ;; Remove unneeded require statement that would entail another
4437 ;; dependency.
4438 (substitute* "test/minitest_config.rb"
4439 (("require 'minitest/bisect'") ""))
4440 #t)))))
4441 (native-inputs
4442 `(("ruby-hoe" ,ruby-hoe)
4443 ("ruby-minitest-pretty-diff" ,ruby-minitest-pretty-diff)
4444 ("ruby-minitest-focus" ,ruby-minitest-focus)
4445 ("ruby-minitest-moar" ,ruby-minitest-moar)))
4446 (synopsis "Bonus assertions for @code{Minitest}")
4447 (description
4448 "Minitest bonus assertions provides extra MiniTest assertions. For
4449instance, it provides @code{assert_true}, @code{assert_false} and
4450@code{assert_set_equal}.")
4451 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
4452 (license license:expat)))
4453
e2c9a9cc
CB
4454(define-public ruby-minitest-reporters
4455 (package
4456 (name "ruby-minitest-reporters")
4457 (version "1.3.6")
4458 (source
4459 (origin
4460 (method url-fetch)
4461 (uri (rubygems-uri "minitest-reporters" version))
4462 (sha256
4463 (base32
4464 "1a3das80rwgys5rj48i5ly144nvszyqyi748bk9bss74jblcf5ay"))))
4465 (build-system ruby-build-system)
4466 (arguments
4467 '(#:phases
4468 (modify-phases %standard-phases
4469 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
4470 ;; including it as an input can lead to circular dependencies.
4471 (add-after 'unpack 'remove-rubocop-from-Rakefile
4472 (lambda _
4473 (substitute* "Rakefile"
4474 (("require 'rubocop/rake\\_task'") "")
4475 (("RuboCop::RakeTask\\.new\\(:rubocop\\)") "[].each"))
4476 #t))
4477 (add-after 'extract-gemspec 'remove-rubocop-from-gemspec
4478 (lambda _
4479 (substitute* "minitest-reporters.gemspec"
4480 ((".*%q<rubocop>.*") "\n"))
4481 #t)))))
4482 (propagated-inputs
4483 `(("ruby-ansi" ,ruby-ansi)
4484 ("ruby-builder" ,ruby-builder)
4485 ("ruby-minitest" ,ruby-minitest)
4486 ("ruby-progressbar" ,ruby-progressbar)))
4487 (native-inputs
4488 `(("bundler" ,bundler)
4489 ("ruby-maruku" ,ruby-maruku)))
4490 (synopsis "Enhanced reporting for Minitest tests")
4491 (description
4492 "@code{minitest/reporters} provides a custom Minitest runner to improve
4493how the test state is reported. A number of different reporters are
4494available, including a spec reporter, progress bar reporter, a HTML
4495reporter.")
4496 (home-page "https://github.com/kern/minitest-reporters")
4497 (license license:expat)))
4498
e582fa93
BW
4499(define-public ruby-minitest-rg
4500 (package
4501 (name "ruby-minitest-rg")
4502 (version "5.2.0")
4503 (source
4504 (origin
4505 (method url-fetch)
4506 (uri (rubygems-uri "minitest-rg" version))
4507 (sha256
4508 (base32
4509 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
4510 (build-system ruby-build-system)
4511 (arguments
4512 ;; Some tests fail even outside Guix, so disable tests.
4513 ;; https://github.com/blowmage/minitest-rg/issues/12
4514 ;; https://github.com/blowmage/minitest-rg/pull/13
4515 `(#:tests? #f))
4516 (propagated-inputs
4517 `(("ruby-minitest" ,ruby-minitest)))
4518 (synopsis "Coloured output for Minitest")
4519 (description
4520 "@code{minitest-rg} changes the colour of the output from Minitest.")
8e486e80 4521 (home-page "https://blowmage.com/minitest-rg/")
e582fa93
BW
4522 (license license:expat)))
4523
2a96dbe6
BW
4524(define-public ruby-minitest-hooks
4525 (package
4526 (name "ruby-minitest-hooks")
eaaf8b12 4527 (version "1.4.2")
2a96dbe6
BW
4528 (source
4529 (origin
4530 (method url-fetch)
4531 (uri (rubygems-uri "minitest-hooks" version))
4532 (sha256
4533 (base32
eaaf8b12 4534 "0lnpvzijbjrvxjc43d155jnbk2mkfshrz22an711wh004scavlzc"))))
2a96dbe6
BW
4535 (build-system ruby-build-system)
4536 (arguments
4537 '(#:test-target "spec"))
4538 (native-inputs
4539 `(("ruby-sequel" ,ruby-sequel)
4540 ("ruby-sqlite3" ,ruby-sqlite3)))
4541 (synopsis "Hooks for the minitest framework")
4542 (description
4543 "Minitest-hooks adds @code{around}, @code{before_all}, @code{after_all},
4544@code{around_all} hooks for Minitest. This allows, for instance, running each
4545suite of specs inside a database transaction, running each spec inside its own
4546savepoint inside that transaction. This can significantly speed up testing
4547for specs that share expensive database setup code.")
7bf837fd 4548 (home-page "https://github.com/jeremyevans/minitest-hooks")
2a96dbe6
BW
4549 (license license:expat)))
4550
afbbdf77
DT
4551(define-public ruby-daemons
4552 (package
4553 (name "ruby-daemons")
f03153db 4554 (version "1.2.5")
afbbdf77
DT
4555 (source (origin
4556 (method url-fetch)
e83c6d00 4557 (uri (rubygems-uri "daemons" version))
afbbdf77
DT
4558 (sha256
4559 (base32
f03153db 4560 "15smbsg0gxb7nf0nrlnplc68y0cdy13dm6fviavpmw7c630sring"))))
afbbdf77
DT
4561 (build-system ruby-build-system)
4562 (arguments
4563 `(#:tests? #f)) ; no test suite
4564 (synopsis "Daemonize Ruby programs")
4565 (description "Daemons provides a way to wrap existing Ruby scripts to be
4566run as a daemon and to be controlled by simple start/stop/restart commands.")
4567 (home-page "https://github.com/thuehlinger/daemons")
4568 (license license:expat)))
b03eb6ac
CB
4569
4570(define-public ruby-data_uri
4571 (package
4572 (name "ruby-data_uri")
4573 (version "0.1.0")
4574 (source
4575 (origin
4576 (method url-fetch)
4577 (uri (rubygems-uri "data_uri" version))
4578 (sha256
4579 (base32
4580 "0fzkxgdxrlbfl4537y3n9mjxbm28kir639gcw3x47ffchwsgdcky"))))
4581 (build-system ruby-build-system)
4582 (synopsis "URI class for parsing data URIs")
4583 (description
4584 "Data @acronym{URI, universal resource idenfitier}s allow resources to be
4585embedded inside a URI. The URI::Data class provides support for parsing these
4586URIs using the normal URI.parse method.")
4587 (home-page "https://github.com/dball/data_uri")
4588 (license license:expat)))
66e20863 4589
72c785f9
MB
4590(define-public ruby-deep-merge
4591 (package
4592 (name "ruby-deep-merge")
4593 (version "1.2.1")
4594 (home-page "https://github.com/danielsdeleo/deep_merge")
4595 ;; The Rubygem source does not contain the gemspec required for tests.
4596 (source (origin
4597 (method git-fetch)
4598 (uri (git-reference (url home-page) (commit version)))
4599 (file-name (git-file-name name version))
4600 (sha256
4601 (base32
4602 "0c9rk23ilhc0n4489y6lda2wzphpzh6ish6fahlbpjhxn82wb931"))))
4603 (build-system ruby-build-system)
4604 (native-inputs
4605 `(("ruby-minitest" ,ruby-minitest)))
4606 (synopsis "Recursively merge hashes")
4607 (description
4608 "Deep Merge is a set of utility functions for @code{Hash}. It permits
4609you to merge elements inside a hash together recursively.")
4610 (license license:expat)))
4611
66e20863
DT
4612(define-public ruby-git
4613 (package
4614 (name "ruby-git")
ceaff59e 4615 (version "1.3.0")
66e20863
DT
4616 (source (origin
4617 (method url-fetch)
e83c6d00 4618 (uri (rubygems-uri "git" version))
66e20863
DT
4619 (sha256
4620 (base32
ceaff59e 4621 "1waikaggw7a1d24nw0sh8fd419gbf7awh000qhsf411valycj6q3"))))
66e20863
DT
4622 (build-system ruby-build-system)
4623 (arguments
e83c6d00
DT
4624 `(#:tests? #f ; no tests
4625 #:phases (modify-phases %standard-phases
4626 (add-after 'install 'patch-git-binary
4627 (lambda* (#:key inputs outputs #:allow-other-keys)
66e20863
DT
4628 ;; Make the default git binary an absolute path to the
4629 ;; store.
e83c6d00
DT
4630 (let ((git (string-append (assoc-ref inputs "git")
4631 "/bin/git"))
3cb3fa67
CB
4632 (config (string-append
4633 (assoc-ref outputs "out")
4634 "/lib/ruby/vendor_ruby/gems/git-"
4635 ,version "/lib/git/config.rb")))
e83c6d00 4636 (substitute* (list config)
66e20863
DT
4637 (("'git'")
4638 (string-append "'" git "'")))
e83c6d00 4639 #t))))))
66e20863
DT
4640 (inputs
4641 `(("git" ,git)))
4642 (synopsis "Ruby wrappers for Git")
4643 (description "Ruby/Git is a Ruby library that can be used to create, read
4644and manipulate Git repositories by wrapping system calls to the git binary.")
4645 (home-page "https://github.com/schacon/ruby-git")
4646 (license license:expat)))
71d3e2c2 4647
95598153
MB
4648(define-public ruby-hocon
4649 (package
4650 (name "ruby-hocon")
fd13ec5f 4651 (version "1.3.1")
95598153
MB
4652 (home-page "https://github.com/puppetlabs/ruby-hocon")
4653 (source (origin
4654 (method git-fetch)
4655 (uri (git-reference (url home-page) (commit version)))
4656 (file-name (git-file-name name version))
4657 (sha256
4658 (base32
fd13ec5f 4659 "172hh2zr0n9nnszv0qvlgwszgkrq84yahrg053m68asy79zpmbqr"))))
95598153
MB
4660 (build-system ruby-build-system)
4661 (arguments
4662 '(#:phases (modify-phases %standard-phases
4663 (replace 'check
4664 (lambda* (#:key tests? #:allow-other-keys)
4665 (if tests?
4666 (invoke "rspec")
4667 (format #t "test suite not run~%"))
4668 #t)))))
4669 (native-inputs
4670 `(("bundler" ,bundler)
4671 ("ruby-rspec" ,ruby-rspec)))
4672 (synopsis "HOCON config library")
4673 (description
4674 "This package provides Ruby support for the @acronym{HOCON,
4675Human-Optimized Config Object Notation} configuration file format. It
4676supports parsing and modifying HOCON and JSON files, and rendering parsed
4677objects back to a @code{String}.")
4678 (license license:asl2.0)))
4679
71d3e2c2
DT
4680(define-public ruby-slop
4681 (package
4682 (name "ruby-slop")
d14e5eaa 4683 (version "4.5.0")
71d3e2c2
DT
4684 (source (origin
4685 (method url-fetch)
e83c6d00 4686 (uri (rubygems-uri "slop" version))
71d3e2c2
DT
4687 (sha256
4688 (base32
d14e5eaa 4689 "0bfm8535g0rkn9cbjndkckf0f7a3wj0rg4rqhrpsgxnbfdf2lm0p"))))
71d3e2c2
DT
4690 (build-system ruby-build-system)
4691 (native-inputs
4692 `(("ruby-minitest" ,ruby-minitest)))
4693 (synopsis "Ruby command line option parser")
4694 (description "Slop provides a Ruby domain specific language for gathering
4695options and parsing command line flags.")
4696 (home-page "https://github.com/leejarvis/slop")
4697 (license license:expat)))
e778a549 4698
5337f8b9
DT
4699(define-public ruby-slop-3
4700 (package (inherit ruby-slop)
4701 (version "3.6.0")
4702 (source (origin
4703 (method url-fetch)
4704 (uri (rubygems-uri "slop" version))
4705 (sha256
4706 (base32
4707 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
4708
ca914b5b
CB
4709(define-public ruby-multi-xml
4710 (package
4711 (name "ruby-multi-xml")
4712 (version "0.6.0")
4713 (source
4714 (origin
4715 (method url-fetch)
4716 (uri (rubygems-uri "multi_xml" version))
4717 (sha256
4718 (base32
4719 "0lmd4f401mvravi1i1yq7b2qjjli0yq7dfc4p1nj5nwajp7r6hyj"))))
4720 (build-system ruby-build-system)
4721 (arguments
4722 '(#:tests? #f)) ; No included tests
4723 (synopsis "Swappable XML backends for Ruby")
4724 (description
4725 "@code{MultiXml} provides swappable XML backends utilizing either LibXML,
4726Nokogiri, Ox, or REXML.")
4727 (home-page "https://github.com/sferik/multi_xml")
4728 (license license:expat)))
4729
e778a549
DT
4730(define-public ruby-multipart-post
4731 (package
4732 (name "ruby-multipart-post")
4733 (version "2.0.0")
4734 (source (origin
4735 (method url-fetch)
e83c6d00 4736 (uri (rubygems-uri "multipart-post" version))
e778a549
DT
4737 (sha256
4738 (base32
e83c6d00 4739 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
e778a549
DT
4740 (build-system ruby-build-system)
4741 (native-inputs
4742 `(("bundler" ,bundler)))
4743 (synopsis "Multipart POST library for Ruby")
4744 (description "Multipart-Post Adds multipart POST capability to Ruby's
4745net/http library.")
4746 (home-page "https://github.com/nicksieger/multipart-post")
4747 (license license:expat)))
f8da3af0 4748
9a97e7ce
CB
4749(define-public ruby-multi-json
4750 (package
4751 (name "ruby-multi-json")
1b6f5475 4752 (version "1.13.1")
9a97e7ce
CB
4753 (source
4754 (origin
b872b47b 4755 (method git-fetch)
1b6f5475
BW
4756 ;; Tests are not distributed at rubygems.org so download from GitHub
4757 ;; instead.
b872b47b
EF
4758 (uri (git-reference
4759 (url "https://github.com/intridea/multi_json")
4760 (commit (string-append "v" version))))
4761 (file-name (git-file-name name version))
9a97e7ce
CB
4762 (sha256
4763 (base32
b872b47b 4764 "18wpb6p01rrkl4v33byh70vxj2a5jxkfxzv3pz8z6pssy4ymwkm4"))))
9a97e7ce
CB
4765 (build-system ruby-build-system)
4766 (arguments
1b6f5475
BW
4767 `(#:phases
4768 (modify-phases %standard-phases
4769 (add-after 'unpack 'remove-signing-key-reference
4770 (lambda _
4771 (substitute* "multi_json.gemspec"
4772 ((".*spec.signing_key.*") ""))
4773 #t)))))
4774 (native-inputs
4775 `(("bundler" ,bundler)
4776 ("ruby-rspec" ,ruby-rspec)
4777 ("ruby-yard" ,ruby-yard)
4778 ("ruby-json-pure" ,ruby-json-pure)
4779 ("ruby-oj" ,ruby-oj)
4780 ("ruby-yajl-ruby" ,ruby-yajl-ruby)))
9a97e7ce
CB
4781 (synopsis "Common interface to multiple JSON libraries for Ruby")
4782 (description
4783 "This package provides a common interface to multiple JSON libraries,
4784including Oj, Yajl, the JSON gem (with C-extensions), the pure-Ruby JSON gem,
4785NSJSONSerialization, gson.rb, JrJackson, and OkJson.")
1b6f5475 4786 (home-page "https://github.com/intridea/multi_json")
9a97e7ce
CB
4787 (license license:expat)))
4788
5edef88b
BW
4789(define-public ruby-multi-test
4790 (package
4791 (name "ruby-multi-test")
4792 (version "0.1.2")
4793 (source
4794 (origin
4795 (method url-fetch)
4796 (uri (rubygems-uri "multi_test" version))
4797 (sha256
4798 (base32
4799 "1sx356q81plr67hg16jfwz9hcqvnk03bd9n75pmdw8pfxjfy1yxd"))))
4800 (build-system ruby-build-system)
4801 (arguments
4802 '(;; Tests require different sets of specific gem versions to be available,
4803 ;; and there is no gemfile that specifies the newest versions of
4804 ;; dependencies to be tested.
4805 #:tests? #f))
4806 (synopsis
4807 "Interface to testing libraries loaded into a running Ruby process")
4808 (description
4809 "@code{multi_test} provides a uniform interface onto whatever testing
4810libraries that have been loaded into a running Ruby process to help control
4811rogue test/unit/autorun requires.")
4812 (home-page "https://github.com/cucumber/multi_test")
9a97e7ce
CB
4813 (license license:expat)))
4814
f8da3af0
DT
4815(define-public ruby-arel
4816 (package
4817 (name "ruby-arel")
aecd533d 4818 (version "9.0.0")
f8da3af0
DT
4819 (source (origin
4820 (method url-fetch)
4821 (uri (rubygems-uri "arel" version))
4822 (sha256
4823 (base32
aecd533d 4824 "1jk7wlmkr61f6g36w9s2sn46nmdg6wn2jfssrhbhirv5x9n95nk0"))))
f8da3af0
DT
4825 (build-system ruby-build-system)
4826 (arguments '(#:tests? #f)) ; no tests
4827 (home-page "https://github.com/rails/arel")
4828 (synopsis "SQL AST manager for Ruby")
6f23e2fb
TGR
4829 (description "Arel is an SQL @dfn{Abstract Syntax Tree} (AST) manager for
4830Ruby. It simplifies the generation of complex SQL queries and adapts to
4831various relational database implementations.")
f8da3af0 4832 (license license:expat)))
616eaead 4833
554bf4f6
CB
4834(define-public ruby-marcel
4835 (package
4836 (name "ruby-marcel")
4837 (version "0.3.3")
4838 (source
4839 (origin
4840 (method url-fetch)
4841 (uri (rubygems-uri "marcel" version))
4842 (sha256
4843 (base32
4844 "1nxbjmcyg8vlw6zwagf17l9y2mwkagmmkg95xybpn4bmf3rfnksx"))))
4845 (build-system ruby-build-system)
4846 (arguments
4847 '(;; No included tests
4848 #:tests? #f))
4849 (propagated-inputs
4850 `(("ruby-mimemagic" ,ruby-mimemagic)))
4851 (synopsis "MIME type detection using magic numbers, filenames and extensions")
4852 (description
4853 "@code{marcel} provides @acronym{MIME, Multipurpose Internet Mail
4854Extensions} type detection using magic numbers, filenames, and extensions")
4855 (home-page "https://github.com/basecamp/marcel")
4856 (license license:expat)))
4857
616eaead 4858(define-public ruby-minitar
bfaf8efd
BW
4859 ;; We package from the GitHub source to fix the security issue reported at
4860 ;; https://github.com/halostatue/minitar/issues/16.
4861 (let ((commit "e25205ecbb6277ae8a3df1e6a306d7ed4458b6e4"))
4862 (package
4863 (name "ruby-minitar")
4864 (version (string-append "0.5.4-1." (string-take commit 8)))
4865 (source
4866 (origin
4867 (method git-fetch)
4868 (uri (git-reference
b0e7b699 4869 (url "https://github.com/halostatue/minitar")
bfaf8efd
BW
4870 (commit commit)))
4871 (file-name (string-append name "-" version "-checkout"))
4872 (sha256
4873 (base32
4874 "1iywfx07jgjqcmixzkxk9zdwfmij1fyg1z2jlwzj15cj7s99qlfv"))))
4875 (build-system ruby-build-system)
4876 (arguments
4877 '(#:tests? #f)) ; missing a gemspec
4878 (synopsis "Ruby library and utility for handling tar archives")
4879 (description
4880 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
616eaead 4881that provides the ability to deal with POSIX tar archive files.")
bfaf8efd
BW
4882 (home-page "http://www.github.com/atoulme/minitar")
4883 (license (list license:gpl2+ license:ruby)))))
bea1c0e2
DT
4884
4885(define-public ruby-mini-portile
4886 (package
4887 (name "ruby-mini-portile")
4888 (version "0.6.2")
4889 (source
4890 (origin
4891 (method url-fetch)
4892 (uri (rubygems-uri "mini_portile" version))
4893 (sha256
4894 (base32
4895 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
4896 (build-system ruby-build-system)
4897 (arguments
4898 '(#:tests? #f)) ; tests require network access
4899 (synopsis "Ports system for Ruby developers")
4900 (description "Mini-portile is a port/recipe system for Ruby developers.
4901It provides a standard way to compile against specific versions of libraries
4902to reproduce user environments.")
7bf837fd 4903 (home-page "https://github.com/flavorjones/mini_portile")
bea1c0e2 4904 (license license:expat)))
e920bfca 4905
d000fc92
BW
4906(define-public ruby-mini-portile-2
4907 (package (inherit ruby-mini-portile)
a88ac044 4908 (version "2.4.0")
d000fc92
BW
4909 (source (origin
4910 (method url-fetch)
4911 (uri (rubygems-uri "mini_portile2" version))
4912 (sha256
4913 (base32
a88ac044 4914 "15zplpfw3knqifj9bpf604rb3wc1vhq6363pd6lvhayng8wql5vy"))))))
d000fc92 4915
e920bfca
DT
4916(define-public ruby-nokogiri
4917 (package
4918 (name "ruby-nokogiri")
62cc7344 4919 (version "1.10.9")
e920bfca
DT
4920 (source (origin
4921 (method url-fetch)
4922 (uri (rubygems-uri "nokogiri" version))
4923 (sha256
4924 (base32
62cc7344 4925 "12j76d0bp608932xkzmfi638c7aqah57l437q8494znzbj610qnm"))))
e920bfca
DT
4926 (build-system ruby-build-system)
4927 (arguments
4928 ;; Tests fail because Nokogiri can only test with an installed extension,
4929 ;; and also because many test framework dependencies are missing.
7b01f250 4930 `(#:tests? #f
e920bfca
DT
4931 #:gem-flags (list "--" "--use-system-libraries"
4932 (string-append "--with-xml2-include="
4933 (assoc-ref %build-inputs "libxml2")
5e7f1b0b
BW
4934 "/include/libxml2" ))
4935 #:phases
4936 (modify-phases %standard-phases
7b01f250
BW
4937 (add-before 'build 'patch-extconf
4938 ;; 'pkg-config' is not included in the GEM_PATH during
4939 ;; installation, so we add it directly to the load path.
4940 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 4941 (let* ((pkg-config (assoc-ref inputs "ruby-pkg-config")))
7b01f250
BW
4942 (substitute* "ext/nokogiri/extconf.rb"
4943 (("gem 'pkg-config'.*")
4944 (string-append "$:.unshift '"
3cb3fa67 4945 pkg-config "/lib/ruby/vendor_ruby"
7b01f250
BW
4946 "/gems/pkg-config-"
4947 ,(package-version ruby-pkg-config)
4948 "/lib'\n"))))
5e7f1b0b 4949 #t)))))
e920bfca 4950 (native-inputs
7b01f250 4951 `(("ruby-hoe" ,ruby-hoe)))
e920bfca
DT
4952 (inputs
4953 `(("zlib" ,zlib)
4954 ("libxml2" ,libxml2)
4955 ("libxslt" ,libxslt)))
4956 (propagated-inputs
7b01f250
BW
4957 `(("ruby-mini-portile" ,ruby-mini-portile-2)
4958 ("ruby-pkg-config" ,ruby-pkg-config)))
e920bfca
DT
4959 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
4960 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
4961both CSS3 selector and XPath 1.0 support.")
4962 (home-page "http://www.nokogiri.org/")
4963 (license license:expat)))
30b0b725
DT
4964
4965(define-public ruby-method-source
4966 (package
4967 (name "ruby-method-source")
ec08f469 4968 (version "1.0.0")
30b0b725
DT
4969 (source
4970 (origin
4971 (method url-fetch)
4972 (uri (rubygems-uri "method_source" version))
4973 (sha256
4974 (base32
ec08f469 4975 "1pnyh44qycnf9mzi1j6fywd5fkskv3x7nmsqrrws0rjn5dd4ayfp"))))
30b0b725 4976 (build-system ruby-build-system)
c8355037
BW
4977 (arguments
4978 `(#:test-target "spec"))
30b0b725 4979 (native-inputs
c8355037 4980 `(("ruby-rspec" ,ruby-rspec)
30b0b725
DT
4981 ("git" ,git)))
4982 (synopsis "Retrieve the source code for Ruby methods")
4983 (description "Method_source retrieves the source code for Ruby methods.
4984Additionally, it can extract source code from Proc and Lambda objects or just
4985extract comments.")
4986 (home-page "https://github.com/banister/method_source")
4987 (license license:expat)))
2e3fdea4
DT
4988
4989(define-public ruby-coderay
4990 (package
4991 (name "ruby-coderay")
5cf0997a 4992 (version "1.1.2")
2e3fdea4
DT
4993 (source
4994 (origin
4995 (method url-fetch)
4996 (uri (rubygems-uri "coderay" version))
4997 (sha256
4998 (base32
5cf0997a 4999 "15vav4bhcc2x3jmi3izb11l4d9f3xv8hp2fszb7iqmpsccv1pz4y"))))
2e3fdea4
DT
5000 (build-system ruby-build-system)
5001 (arguments
5002 '(#:tests? #f)) ; missing test files
5003 (synopsis "Ruby syntax highlighting library")
5004 (description "Coderay is a Ruby library that provides syntax highlighting
5005for select languages.")
5006 (home-page "http://coderay.rubychan.de")
5007 (license license:expat)))
96e76083 5008
f9083965
MC
5009(define-public ruby-cuke-modeler
5010 (package
5011 (name "ruby-cuke-modeler")
5012 (version "3.1.0")
5013 (source
5014 (origin
5015 (method url-fetch)
5016 (uri (rubygems-uri "cuke_modeler" version))
5017 (sha256
5018 (base32
5019 "19smj3g3wvz0203l549sadpcxgh0ir350a6k78gq0bmlv9cchmjb"))))
5020 (build-system ruby-build-system)
5021 (arguments `(#:tests? #f)) ;no test suite in gem
5022 (propagated-inputs
5023 `(("ruby-gherkin" ,ruby-gherkin)))
5024 (synopsis "Gherkin test suite analysis tool")
5025 (description "CukeModeler facilitates modeling a test suite that is
5026written in Gherkin (e.g. Cucumber, SpecFlow, Lettuce, etc.). It does this by
5027providing an abstraction layer on top of the Abstract Syntax Tree (AST) that
5028the @code{cucumber-gherkin} generates when parsing features, as well as
5029providing models for feature files and directories in order to be able to have
5030a fully traversable model tree of a test suite's structure. These models can
5031then be analyzed or manipulated more easily than the underlying AST layer.")
5032 (home-page "https://github.com/enkessler/cuke_modeler")
5033 (license license:expat)))
5034
2156cc9c
MB
5035(define-public ruby-parallel-tests
5036 (package
5037 (name "ruby-parallel-tests")
8a01e2fa 5038 (version "3.0.0")
2156cc9c
MB
5039 (home-page "https://github.com/grosser/parallel_tests")
5040 (source (origin
5041 (method git-fetch)
5042 (uri (git-reference
5043 (url home-page)
5044 (commit (string-append "v" version))))
5045 (file-name (string-append name version))
5046 (sha256
5047 (base32
8a01e2fa 5048 "08a6ndqn2dqacmc7yg48k0dh2rfrynvhkd5hiay16dl9m1r9q8pz"))))
2156cc9c
MB
5049 (build-system ruby-build-system)
5050 (arguments
5051 '(#:test-target "default"
5052 #:phases (modify-phases %standard-phases
5053 (add-after 'patch-source-shebangs 'patch-shell-invokations
5054 (lambda _
5055 (substitute* '("lib/parallel_tests/tasks.rb"
5056 "spec/parallel_tests/tasks_spec.rb")
5057 (("/bin/sh") (which "sh"))
5058 (("/bin/bash") (which "bash")))
5059 #t))
5060 (add-before 'check 'remove-version-constraints
5061 (lambda _
5062 ;; Remove hard coded version constraints, instead just
5063 ;; use whatever versions are available in Guix.
5064 (delete-file "Gemfile.lock")
5065 (substitute* "Gemfile"
5066 (("'minitest',.*")
5067 "'minitest'\n")
5068 (("'cucumber',.*")
5069 "'cucumber'\n"))
5070 #t))
5071 (add-before 'check 'disable-rails-test
5072 (lambda _
5073 ;; XXX: This test attempts to download and run the test
5074 ;; suites of multiple Rails versions(!) directly.
5075 (delete-file "spec/rails_spec.rb")
5076 #t))
5077 (add-before 'check 'set-HOME
5078 (lambda _
5079 ;; Some tests check the output of Bundler, and fail when
5080 ;; Bundler warns that /homeless-shelter does not exist.
5081 (setenv "HOME" "/tmp")
5082 #t)))))
5083 (native-inputs
5084 `(("ruby-bump" ,ruby-bump)
5085 ("ruby-cucumber" ,ruby-cucumber)
8a01e2fa 5086 ("ruby-cuke-modeler" ,ruby-cuke-modeler)
2156cc9c
MB
5087 ("ruby-minitest" ,ruby-minitest)
5088 ("ruby-rake" ,ruby-rake)
5089 ("ruby-rspec" ,ruby-rspec)
5090 ("ruby-spinach" ,ruby-spinach)))
5091 (propagated-inputs
5092 `(("ruby-parallel" ,ruby-parallel)))
5093 (synopsis "Run tests in parallel")
5094 (description
5095 "This package can speed up @code{Test::Unit}, @code{RSpec},
5096@code{Cucumber}, and @code{Spinach} tests by running them concurrently
5097across multiple CPU cores.")
5098 (license license:expat)))
5099
54993457
CB
5100(define-public ruby-parser
5101 (package
5102 (name "ruby-parser")
9fc61da9 5103 (version "2.7.1.4")
54993457
CB
5104 (source
5105 (origin
5106 (method url-fetch)
5107 (uri (rubygems-uri "parser" version))
5108 (sha256
5109 (base32
9fc61da9 5110 "1030znhvhkfn39svwbj6qn4xb6hgl94gnvg57k4d3r76f9bryqmn"))))
54993457
CB
5111 (build-system ruby-build-system)
5112 (native-inputs
5113 `(("bundler" ,bundler)
5114 ("ruby-cliver" ,ruby-cliver)
5115 ("ruby-simplecov" ,ruby-simplecov)
5116 ("ruby-racc" ,ruby-racc)))
5117 (inputs
5118 `(("ragel" ,ragel)))
5119 (propagated-inputs
5120 `(("ruby-ast" ,ruby-ast)))
5121 (synopsis "Ruby parser written in pure Ruby")
5122 (description
5123 "This package provides a Ruby parser written in pure Ruby.")
5124 (home-page "https://github.com/whitequark/parser")
5125 (license license:expat)))
5126
a8cdfd53
MC
5127(define-public ruby-sexp-processor
5128 (package
5129 (name "ruby-sexp-processor")
5130 (version "4.15.0")
5131 (source
5132 (origin
5133 (method url-fetch)
5134 (uri (rubygems-uri "sexp_processor" version))
5135 (sha256
5136 (base32
5137 "0d1vks77xnd0m3s94a58f9bkdwlaml5qdkmprx279m2s0pc2gv55"))))
5138 (build-system ruby-build-system)
5139 (native-inputs
5140 ;; TODO: Add ruby-minitest-proveit once available.
5141 `(("hoe" ,ruby-hoe)))
5142 (synopsis "ParseTree fork which includes generic S-exp processing tools")
5143 (description "The sexp_processor package is derived from ParseTree, but
5144contrary to ParseTree, it includes all the generic S-exp processing tools.
5145Amongst the included tools are @code{Sexp}, @code{SexpProcessor} and
5146@code{Environment}")
5147 (home-page "https://github.com/seattlerb/sexp_processor")
5148 (license license:expat)))
5149
24be6751
MC
5150(define-public ruby-ruby-parser
5151 (package
5152 (name "ruby-ruby-parser")
5153 (version "3.14.2")
5154 (source
5155 (origin
5156 (method url-fetch)
5157 (uri (rubygems-uri "ruby_parser" version))
5158 (sha256
5159 (base32
5160 "09qcdyjjw3p7g6cjm5m9swkms1xnv35ndiy7yw24cas16qrhha6c"))))
5161 (build-system ruby-build-system)
5162 (native-inputs
5163 `(("hoe" ,ruby-hoe)
5164 ("racc" ,ruby-racc)
5165 ("unifdef" ,unifdef)))
5166 (propagated-inputs
5167 `(("ruby-sexp-processor" ,ruby-sexp-processor)))
5168 (home-page "https://github.com/seattlerb/ruby_parser/")
5169 (synopsis "Ruby parser written in pure Ruby")
5170 (description "The ruby_parser (RP) package provides a Ruby parser written
5171in pure Ruby. It outputs S-expressions which can be manipulated and converted
5172back to Ruby via the @code{ruby2ruby} library.")
5173 (license license:expat)))
5174
16f423cb
CB
5175(define-public ruby-prawn-manual-builder
5176 (package
5177 (name "ruby-prawn-manual-builder")
1d4f0019 5178 (version "0.3.1")
16f423cb
CB
5179 (source
5180 (origin
5181 (method url-fetch)
5182 (uri (rubygems-uri "prawn-manual_builder" version))
5183 (sha256
1d4f0019 5184 (base32 "1vlg5w7wq43g2hgpgra2nrcxj1kb4ayqliz4gmja2rhs037j2vzs"))))
16f423cb
CB
5185 (build-system ruby-build-system)
5186 (arguments
1d4f0019 5187 '(#:tests? #f ; no included tests
16f423cb
CB
5188 #:phases
5189 (modify-phases %standard-phases
5190 (add-after 'extract-gemspec 'patch-gemspec
5191 (lambda _
5192 (substitute* ".gemspec"
5193 ;; Loosen the requirement for pdf-inspector
5194 (("~> 1\\.0\\.7") ">= 0")))))))
5195 (propagated-inputs
5196 `(("ruby-coderay" ,ruby-coderay)))
5197 (synopsis "Tool for writing manuals for Prawn and Prawn accessories")
5198 (description
5199 "This package provides a tool for writing manuals for Prawn and Prawn
5200accessories")
5201 (home-page "https://github.com/prawnpdf/prawn-manual_builder")
cc10ca33 5202 (license %prawn-project-licenses)))
16f423cb 5203
268643b9
CB
5204(define-public ruby-progress_bar
5205 (package
5206 (name "ruby-progress_bar")
5207 (version "1.1.0")
5208 (source
5209 (origin
5210 (method url-fetch)
5211 (uri (rubygems-uri "progress_bar" version))
5212 (sha256
5213 (base32
5214 "1qc40mr6p1z9a3vlpnsg1zfgk1qswviql2a31y63wpv3vr6b5f48"))))
5215 (build-system ruby-build-system)
5216 (arguments
5217 '(#:test-target "spec"))
5218 (propagated-inputs
5219 `(("ruby-highline" ,ruby-highline)
5220 ("ruby-options" ,ruby-options)))
5221 (native-inputs
5222 `(("bundler" ,bundler)
5223 ("ruby-rspec" ,ruby-rspec)
5224 ("ruby-timecop" ,ruby-timecop)))
5225 (synopsis
5226 "Ruby library for displaying progress bars")
5227 (description
5228 "ProgressBar is a simple library for displaying progress bars. The
5229maximum value is configurable, and additional information can be displayed
5230like the percentage completion, estimated time remaining, elapsed time and
5231rate.")
5232 (home-page "https://github.com/paul/progress_bar")
5233 (license license:wtfpl2)))
5234
95f85d44
CB
5235(define-public ruby-dep
5236 (package
5237 (name "ruby-dep")
5238 (version "1.5.0")
5239 (source
5240 (origin
5241 (method url-fetch)
5242 (uri (rubygems-uri "ruby_dep" version))
5243 (sha256
5244 (base32
5245 "1c1bkl97i9mkcvkn1jks346ksnvnnp84cs22gwl0vd7radybrgy5"))))
5246 (build-system ruby-build-system)
5247 (arguments
5248 '(#:tests? #f)) ; No included tests
5249 (synopsis "Creates a version constraint of supported Rubies")
5250 (description
5251 "This package helps create a version constraint of supported Rubies,
5252suitable for a gemspec file.")
5253 (home-page "https://github.com/e2/ruby_dep")
5254 (license license:expat)))
5255
158a9253
CB
5256(define-public ruby-progressbar
5257 (package
5258 (name "ruby-progressbar")
2d2a2363 5259 (version "1.10.1")
158a9253
CB
5260 (source
5261 (origin
5262 (method url-fetch)
5263 (uri (rubygems-uri "ruby-progressbar" version))
5264 (sha256
2d2a2363 5265 (base32 "1k77i0d4wsn23ggdd2msrcwfy0i376cglfqypkk2q77r2l3408zf"))))
158a9253
CB
5266 (build-system ruby-build-system)
5267 (arguments
5268 '(;; TODO: There looks to be a circular dependency with ruby-fuubar.
5269 #:tests? #f))
5270 (synopsis "Text progress bar library for Ruby")
5271 (description
5272 "Ruby/ProgressBar is an flexible text progress bar library for Ruby.
5273The output can be customized with a formatting system.")
5274 (home-page "https://github.com/jfelchner/ruby-progressbar")
5275 (license license:expat)))
5276
96e76083
DT
5277(define-public ruby-pry
5278 (package
5279 (name "ruby-pry")
a0d93c17 5280 (version "0.13.1")
96e76083
DT
5281 (source
5282 (origin
5283 (method url-fetch)
5284 (uri (rubygems-uri "pry" version))
5285 (sha256
5286 (base32
a0d93c17 5287 "0iyw4q4an2wmk8v5rn2ghfy2jaz9vmw2nk8415nnpx2s866934qk"))))
96e76083
DT
5288 (build-system ruby-build-system)
5289 (arguments
5290 '(#:tests? #f)) ; no tests
5291 (propagated-inputs
5292 `(("ruby-coderay" ,ruby-coderay)
1960d4fd 5293 ("ruby-method-source" ,ruby-method-source)))
96e76083
DT
5294 (synopsis "Ruby REPL")
5295 (description "Pry is an IRB alternative and runtime developer console for
5296Ruby. It features syntax highlighting, a plugin architecture, runtime
5297invocation, and source and documentation browsing.")
a0d93c17 5298 (home-page "https://cobaltbluemedia.com/pryrepl/")
96e76083 5299 (license license:expat)))
1415792a 5300
def7908a
MB
5301(define-public ruby-single-cov
5302 (package
5303 (name "ruby-single-cov")
5304 (version "1.3.2")
5305 (home-page "https://github.com/grosser/single_cov")
5306 (source (origin
5307 (method git-fetch)
5308 (uri (git-reference (url home-page)
5309 (commit (string-append "v" version))))
5310 (file-name (git-file-name name version))
5311 (sha256
5312 (base32
5313 "05qdzpcai1p23a120gb9bxkfl4y73k9hicx34ch2lsk31lgi9bl7"))))
5314 (build-system ruby-build-system)
5315 (arguments
5316 '(#:test-target "default"
5317 #:phases (modify-phases %standard-phases
5318 (replace 'replace-git-ls-files
5319 (lambda _
5320 (substitute* "single_cov.gemspec"
5321 (("`git ls-files lib/ bin/ MIT-LICENSE`")
5322 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
5323 #t))
5324 (add-before 'check 'remove-version-constraints
5325 (lambda _
5326 (delete-file "Gemfile.lock")
5327 #t))
5328 (add-before 'check 'make-files-writable
5329 (lambda _
5330 ;; Tests need to create local directories and open files
5331 ;; with write permissions.
5332 (for-each make-file-writable
5333 (find-files "specs" #:directories? #t))
5334 #t))
5335 (add-before 'check 'disable-failing-test
5336 (lambda _
5337 ;; XXX: This test copies assets from minitest, but can
5338 ;; not cope with the files being read-only. Just skip
5339 ;; it for now.
5340 (substitute* "specs/single_cov_spec.rb"
5341 (("it \"complains when coverage is bad\"")
5342 "xit \"complains when coverage is bad\""))
5343 #t)))))
5344 (native-inputs
5345 `(("ruby-bump" ,ruby-bump)
5346 ("ruby-minitest" ,ruby-minitest)
5347 ("ruby-rspec" ,ruby-rspec)
5348 ("ruby-simplecov" ,ruby-simplecov)))
5349 (synopsis "Code coverage reporting tool")
5350 (description
5351 "This package provides actionable code coverage reports for Ruby
5352projects. It has very little overhead and can be easily integrated with
5353development tools to catch coverage problems early.")
5354 (license license:expat)))
5355
051deeb7
RW
5356(define-public ruby-guard
5357 (package
5358 (name "ruby-guard")
5359 (version "2.13.0")
5360 (source (origin
3c6128f6 5361 (method git-fetch)
051deeb7
RW
5362 ;; The gem does not include a Rakefile, nor does it contain a
5363 ;; gemspec file, nor does it come with the tests. This is why
5364 ;; we fetch the tarball from Github.
3c6128f6
EF
5365 (uri (git-reference
5366 (url "https://github.com/guard/guard")
5367 (commit (string-append "v" version))))
5368 (file-name (git-file-name name version))
051deeb7
RW
5369 (sha256
5370 (base32
3c6128f6 5371 "16pxcszr0g2jnl3090didxh1d8z5m2mly14m3w4rspb8fmclsnjs"))))
051deeb7
RW
5372 (build-system ruby-build-system)
5373 (arguments
5374 `(#:tests? #f ; tests require cucumber
5375 #:phases
5376 (modify-phases %standard-phases
5377 (add-after 'unpack 'remove-git-ls-files
5378 (lambda* (#:key outputs #:allow-other-keys)
5379 (substitute* "guard.gemspec"
5380 (("git ls-files -z") "find . -type f -print0"))
5381 #t))
5382 (replace 'build
5383 (lambda _
9923d5a4 5384 (invoke "gem" "build" "guard.gemspec"))))))
051deeb7
RW
5385 (propagated-inputs
5386 `(("ruby-formatador" ,ruby-formatador)
5387 ("ruby-listen" ,ruby-listen)
5388 ("ruby-lumberjack" ,ruby-lumberjack)
5389 ("ruby-nenv" ,ruby-nenv)
5390 ("ruby-notiffany" ,ruby-notiffany)
5391 ("ruby-pry" ,ruby-pry)
5392 ("ruby-shellany" ,ruby-shellany)
5393 ("ruby-thor" ,ruby-thor)))
5394 (native-inputs
5395 `(("bundler" ,bundler)
5396 ("ruby-rspec" ,ruby-rspec)))
5397 (synopsis "Tool to handle events on file system modifications")
5398 (description
5399 "Guard is a command line tool to easily handle events on file system
5400modifications. Guard automates various tasks by running custom rules whenever
5401file or directories are modified.")
3c6128f6 5402 (home-page "https://guardgem.org/")
051deeb7
RW
5403 (license license:expat)))
5404
c09bc60d
MB
5405(define-public ruby-spinach
5406 (package
5407 (name "ruby-spinach")
5408 (version "0.11.0")
702a1012 5409 (home-page "https://github.com/codegram/spinach")
c09bc60d
MB
5410 (source (origin
5411 (method url-fetch)
5412 (uri (rubygems-uri "spinach" version))
5413 (sha256
5414 (base32
5415 "1mv053mqz9c8ngqa6wp1ymk2fax6j0yqzax6918akrdr7c3fx3c6"))))
5416 (build-system ruby-build-system)
5417 (arguments
5418 ;; FIXME: Disable tests altogether because they depend on 'capybara'
5419 ;; which in turn depends on many other unpackaged gems. Enable once
5420 ;; capybara is available.
5421 '(#:tests? #f))
5422 (propagated-inputs
5423 `(("ruby-colorize" ,ruby-colorize)
5424 ("ruby-gherkin-ruby" ,ruby-gherkin-ruby)
5425 ("ruby-json" ,ruby-json)))
5426 (synopsis "Gherkin-based BDD framework")
5427 (description
5428 "Spinach is a high-level @acronym{BDD, Behavior-driven development}
5429framework that leverages the expressive @code{Gherkin} language to help you
5430define executable specifications of your code.")
5431 (license license:expat)))
5432
bcbb3cc9
CB
5433(define-public ruby-tilt
5434 (package
5435 (name "ruby-tilt")
c3f15f54 5436 (version "2.0.10")
bcbb3cc9
CB
5437 (source
5438 (origin
c3f15f54
MC
5439 (method git-fetch) ;the distributed gem lacks tests
5440 (uri (git-reference
b0e7b699 5441 (url "https://github.com/rtomayko/tilt")
c3f15f54
MC
5442 (commit (string-append "v" version))))
5443 (file-name (git-file-name name version))
bcbb3cc9
CB
5444 (sha256
5445 (base32
c3f15f54 5446 "0adb7fg7925n2rd9a8kkqz3mgylw2skp9hkh9qc1rnph72mqsm6r"))))
bcbb3cc9
CB
5447 (build-system ruby-build-system)
5448 (arguments
5449 '(#:phases
5450 (modify-phases %standard-phases
5451 (add-after 'unpack 'remove-some-dependencies
5452 (lambda _
5453 (substitute* "Gemfile"
5454 ;; TODO ronn is used for generating the manual
5455 (("gem 'ronn'.*") "\n")
5456 ;; ruby-haml has a runtime dependency on ruby-tilt, so don't
5457 ;; pass it in as a native-input
5458 (("gem 'haml'.*") "\n")
5459 ;; TODO Not all of these gems are packaged for Guix yet:
5460 ;; less, coffee-script, livescript, babel-transpiler,
5461 ;; typescript-node
5462 (("if can_execjs") "if false")
5463 ;; Disable the secondary group to reduce the number of
5464 ;; dependencies. None of the normal approaches work, so patch
5465 ;; the Gemfile instead.
5466 (("group :secondary") "[].each"))
5467 #t)))))
cfa4a318
MC
5468 (propagated-inputs
5469 `(("ruby-pandoc-ruby" ,ruby-pandoc-ruby)
5470 ("ruby-sassc" ,ruby-sassc)))
bcbb3cc9
CB
5471 (native-inputs
5472 `(("bundler" ,bundler)
5473 ("ruby-yard" ,ruby-yard)
5474 ("ruby-builder" ,ruby-builder)
5475 ("ruby-erubis" ,ruby-erubis)
cfa4a318 5476 ("ruby-markaby" ,ruby-markaby)))
bcbb3cc9
CB
5477 (synopsis "Generic interface to multiple Ruby template engines")
5478 (description
5479 "Tilt is a thin interface over a number of different Ruby template
5480engines in an attempt to make their usage as generic as possible.")
5481 (home-page "https://github.com/rtomayko/tilt/")
5482 (license license:expat)))
5483
1415792a
DT
5484(define-public ruby-thread-safe
5485 (package
5486 (name "ruby-thread-safe")
313dd5dd 5487 (version "0.3.6")
1415792a
DT
5488 (source
5489 (origin
5490 (method url-fetch)
5491 (uri (rubygems-uri "thread_safe" version))
5492 (sha256
5493 (base32
313dd5dd 5494 "0nmhcgq6cgz44srylra07bmaw99f5271l0dpsvl5f75m44l0gmwy"))))
1415792a
DT
5495 (build-system ruby-build-system)
5496 (arguments
5497 '(#:tests? #f)) ; needs simplecov, among others
5498 (synopsis "Thread-safe utilities for Ruby")
5499 (description "The thread_safe library provides thread-safe collections and
5500utilities for Ruby.")
5501 (home-page "https://github.com/ruby-concurrency/thread_safe")
5502 (license license:asl2.0)))
08a1b701
DT
5503
5504(define-public ruby-tzinfo
5505 (package
5506 (name "ruby-tzinfo")
4237af85 5507 (version "1.2.4")
08a1b701
DT
5508 (source
5509 (origin
5510 (method url-fetch)
5511 (uri (rubygems-uri "tzinfo" version))
5512 (sha256
5513 (base32
4237af85 5514 "09dpbrih054mn42flbbcdpzk2727mzfvjrgqb12zdafhx7p9rrzp"))))
08a1b701 5515 (build-system ruby-build-system)
740fea08
CB
5516 (arguments
5517 '(#:phases
5518 (modify-phases %standard-phases
5519 (add-after 'unpack 'skip-safe-tests
5520 (lambda _
5521 (substitute* "test/test_utils.rb"
5522 (("def safe_test\\(options = \\{\\}\\)")
5523 "def safe_test(options = {})
5524 skip('The Guix build environment has an unsafe load path')"))
5525 #t)))))
08a1b701
DT
5526 (propagated-inputs
5527 `(("ruby-thread-safe" ,ruby-thread-safe)))
5528 (synopsis "Time zone library for Ruby")
5529 (description "TZInfo is a Ruby library that provides daylight savings
5530aware transformations between times in different time zones.")
2f3800e5 5531 (home-page "https://tzinfo.github.io")
1e12924a
BW
5532 (license license:expat)))
5533
5534(define-public ruby-tzinfo-data
5535 (package
5536 (name "ruby-tzinfo-data")
92513191 5537 (version "1.2017.3")
1e12924a
BW
5538 (source
5539 (origin
bb1e7ed0 5540 (method git-fetch)
1e12924a
BW
5541 ;; Download from GitHub because the rubygems version does not contain
5542 ;; Rakefile or tests.
bb1e7ed0
EF
5543 (uri (git-reference
5544 (url "https://github.com/tzinfo/tzinfo-data")
5545 (commit (string-append "v" version))))
5546 (file-name (git-file-name name version))
1e12924a
BW
5547 (sha256
5548 (base32
bb1e7ed0 5549 "0v3phl5l3jrm6waxcszqmj2dkjhqawxfsxb6mss7vkp1hlckqcdp"))
1e12924a
BW
5550 ;; Remove the known test failure.
5551 ;; https://github.com/tzinfo/tzinfo-data/issues/10
5552 ;; https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1587128
5553 (patches (search-patches
5554 "ruby-tzinfo-data-ignore-broken-test.patch"))))
5555 (build-system ruby-build-system)
5556 (propagated-inputs
5557 `(("ruby-tzinfo" ,ruby-tzinfo)))
5558 (synopsis "Data from the IANA Time Zone database")
5559 (description
5560 "This library provides @code{TZInfo::Data}, which contains data from the
5561IANA Time Zone database packaged as Ruby modules for use with @code{TZInfo}.")
2f3800e5 5562 (home-page "https://tzinfo.github.io")
08a1b701 5563 (license license:expat)))
c99e2247 5564
48e6851f
RW
5565(define-public ruby-rb-inotify
5566 (package
5567 (name "ruby-rb-inotify")
32bbfea8 5568 (version "0.9.10")
48e6851f
RW
5569 (source
5570 (origin
5571 (method url-fetch)
5572 (uri (rubygems-uri "rb-inotify" version))
5573 (sha256
5574 (base32
32bbfea8 5575 "0yfsgw5n7pkpyky6a9wkf1g9jafxb0ja7gz0qw0y14fd2jnzfh71"))))
48e6851f
RW
5576 (build-system ruby-build-system)
5577 (arguments
5578 '(#:tests? #f ; there are no tests
5579 #:phases
5580 (modify-phases %standard-phases
5581 ;; Building the gemspec with rake is not working here since it is
5582 ;; generated with Jeweler. It is also unnecessary because the
5583 ;; existing gemspec does not use any development tools to generate a
5584 ;; list of files.
5585 (replace 'build
5586 (lambda _
9923d5a4 5587 (invoke "gem" "build" "rb-inotify.gemspec"))))))
48e6851f
RW
5588 (propagated-inputs
5589 `(("ruby-ffi" ,ruby-ffi)))
5590 (native-inputs
5591 `(("ruby-yard" ,ruby-yard)))
5592 (synopsis "Ruby wrapper for Linux's inotify")
5593 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
5594kernel subsystem for monitoring changes to files and directories.")
5595 (home-page "https://github.com/nex3/rb-inotify")
5596 (license license:expat)))
5597
a75bdfce
RW
5598(define-public ruby-pry-editline
5599 (package
5600 (name "ruby-pry-editline")
5601 (version "1.1.2")
5602 (source (origin
5603 (method url-fetch)
5604 (uri (rubygems-uri "pry-editline" version))
5605 (sha256
5606 (base32
5607 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
5608 (build-system ruby-build-system)
5609 (arguments `(#:tests? #f)) ; no tests included
5610 (native-inputs
5611 `(("bundler" ,bundler)))
5612 (synopsis "Open the current REPL line in an editor")
5613 (description
5614 "This gem provides a plugin for the Ruby REPL to enable opening the
5615current line in an external editor.")
5616 (home-page "https://github.com/tpope/pry-editline")
5617 (license license:expat)))
5618
d3b20a02
RW
5619(define-public ruby-sdoc
5620 (package
5621 (name "ruby-sdoc")
6700dc33 5622 (version "1.1.0")
d3b20a02
RW
5623 (source (origin
5624 (method url-fetch)
5625 (uri (rubygems-uri "sdoc" version))
5626 (sha256
5627 (base32
6700dc33 5628 "1am73dldx1fqlw2xny5vyk00pgkisg6bvs0pa8jjd7c19drjczrd"))))
d3b20a02
RW
5629 (build-system ruby-build-system)
5630 (arguments
5631 `(#:phases
5632 (modify-phases %standard-phases
fc29d5e6 5633 (add-before 'check 'set-rubylib-and-patch-gemfile
d3b20a02 5634 (lambda _
fdf3a68d 5635 (setenv "RUBYLIB" "lib")
fc29d5e6
BW
5636 (substitute* "sdoc.gemspec"
5637 (("s.add_runtime_dependency.*") "\n")
5638 (("s.add_dependency.*") "\n"))
5639 (substitute* "Gemfile"
5640 (("gem \"rake\".*")
5641 "gem 'rake'\ngem 'rdoc'\ngem 'json'\n"))
d3b20a02
RW
5642 #t)))))
5643 (propagated-inputs
5644 `(("ruby-json" ,ruby-json)))
5645 (native-inputs
5646 `(("bundler" ,bundler)
fdf3a68d
BW
5647 ("ruby-minitest" ,ruby-minitest)
5648 ("ruby-hoe" ,ruby-hoe)))
d3b20a02
RW
5649 (synopsis "Generate searchable RDoc documentation")
5650 (description
5651 "SDoc is an RDoc documentation generator to build searchable HTML
5652documentation for Ruby code.")
7bf837fd 5653 (home-page "https://github.com/voloko/sdoc")
d3b20a02
RW
5654 (license license:expat)))
5655
70b002aa
RW
5656(define-public ruby-tins
5657 (package
5658 (name "ruby-tins")
fbefd6ff 5659 (version "1.15.0")
70b002aa
RW
5660 (source (origin
5661 (method url-fetch)
5662 (uri (rubygems-uri "tins" version))
5663 (sha256
5664 (base32
fbefd6ff 5665 "09whix5a7ics6787zrkwjmp16kqyh6560p9f317syks785805f7s"))))
70b002aa
RW
5666 (build-system ruby-build-system)
5667 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
5668 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
5669 ;; the gemspec.
5670 (arguments
5671 `(#:tests? #f ; there are no tests
5672 #:phases
5673 (modify-phases %standard-phases
5674 (replace 'build
5675 (lambda _
5676 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
5677 ;; causes an error.
5678 (substitute* "tins.gemspec"
5679 (("\"lib/spruz\", ") ""))
9923d5a4 5680 (invoke "gem" "build" "tins.gemspec"))))))
70b002aa
RW
5681 (synopsis "Assorted tools for Ruby")
5682 (description "Tins is a Ruby library providing assorted tools.")
5683 (home-page "https://github.com/flori/tins")
5684 (license license:expat)))
5685
bc8277e4
RW
5686(define-public ruby-gem-hadar
5687 (package
5688 (name "ruby-gem-hadar")
3fd577e3 5689 (version "1.9.1")
bc8277e4
RW
5690 (source (origin
5691 (method url-fetch)
5692 (uri (rubygems-uri "gem_hadar" version))
5693 (sha256
5694 (base32
3fd577e3 5695 "1zxvd9l95rbks7x3cxn396w0sn7nha5542bf97v8akkn4vm7nby9"))))
bc8277e4
RW
5696 (build-system ruby-build-system)
5697 ;; This gem needs itself at development time. We disable rebuilding of the
5698 ;; gemspec to avoid this loop.
5699 (arguments
5700 `(#:tests? #f ; there are no tests
5701 #:phases
5702 (modify-phases %standard-phases
5703 (replace 'build
5704 (lambda _
9923d5a4 5705 (invoke "gem" "build" "gem_hadar.gemspec"))))))
bc8277e4
RW
5706 (propagated-inputs
5707 `(("git" ,git)
5708 ("ruby-tins" ,ruby-tins)
3fd577e3 5709 ("ruby-yard" ,ruby-yard)))
bc8277e4
RW
5710 (synopsis "Library for the development of Ruby gems")
5711 (description
5712 "This library contains some useful functionality to support the
5713development of Ruby gems.")
5714 (home-page "https://github.com/flori/gem_hadar")
5715 (license license:expat)))
5716
d8cafe29
RW
5717(define-public ruby-minitest-tu-shim
5718 (package
5719 (name "ruby-minitest-tu-shim")
5720 (version "1.3.3")
5721 (source (origin
5722 (method url-fetch)
5723 (uri (rubygems-uri "minitest_tu_shim" version))
5724 (sha256
5725 (base32
5726 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
5727 (build-system ruby-build-system)
5728 (arguments
5729 `(#:phases
5730 (modify-phases %standard-phases
5731 (add-after 'unpack 'fix-test-include-path
5732 (lambda* (#:key inputs #:allow-other-keys)
3cb3fa67 5733 (let* ((minitest (assoc-ref inputs "ruby-minitest-4")))
761e7042
BW
5734 (substitute* "Rakefile"
5735 (("Hoe\\.add_include_dirs .*")
5736 (string-append "Hoe.add_include_dirs \""
3cb3fa67 5737 minitest "/lib/ruby/vendor_ruby"
761e7042
BW
5738 "/gems/minitest-"
5739 ,(package-version ruby-minitest-4)
5740 "/lib" "\""))))
5741 #t))
d8cafe29
RW
5742 (add-before 'check 'fix-test-assumptions
5743 (lambda _
5744 ;; The test output includes the file name, so a couple of tests
5745 ;; fail. Changing the regular expressions slightly fixes this
5746 ;; problem.
5747 (substitute* "test/test_mini_test.rb"
5748 (("output.sub!\\(.*, 'FILE:LINE'\\)")
5749 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
5750 (("gsub\\(/.*, 'FILE:LINE'\\)")
5751 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
5752 #t)))))
5753 (propagated-inputs
5754 `(("ruby-minitest-4" ,ruby-minitest-4)))
5755 (native-inputs
5756 `(("ruby-hoe" ,ruby-hoe)))
5757 (synopsis "Adapter library between minitest and test/unit")
5758 (description
5759 "This library bridges the gap between the small and fast minitest and
5760Ruby's large and slower test/unit.")
5761 (home-page "https://rubygems.org/gems/minitest_tu_shim")
5762 (license license:expat)))
5763
fd83a212
RW
5764(define-public ruby-term-ansicolor
5765 (package
5766 (name "ruby-term-ansicolor")
f3a6311a 5767 (version "1.6.0")
fd83a212
RW
5768 (source (origin
5769 (method url-fetch)
5770 (uri (rubygems-uri "term-ansicolor" version))
5771 (sha256
5772 (base32
f3a6311a 5773 "1b1wq9ljh7v3qyxkk8vik2fqx2qzwh5lval5f92llmldkw7r7k7b"))))
fd83a212
RW
5774 (build-system ruby-build-system)
5775 ;; Rebuilding the gemspec seems to require git, even though this is not a
5776 ;; git repository, so we just build the gem from the existing gemspec.
5777 (arguments
5778 `(#:phases
5779 (modify-phases %standard-phases
39ecb977
CB
5780 (add-after 'unpack 'fix-test
5781 (lambda -
5782 (substitute* "tests/hsl_triple_test.rb"
5783 (("0\\\\\\.0%")
5784 "0\\.?0?%"))))
fd83a212
RW
5785 (replace 'build
5786 (lambda _
9923d5a4 5787 (invoke "gem" "build" "term-ansicolor.gemspec"))))))
fd83a212
RW
5788 (propagated-inputs
5789 `(("ruby-tins" ,ruby-tins)))
5790 (native-inputs
5791 `(("ruby-gem-hadar" ,ruby-gem-hadar)
5792 ("ruby-minitest-tu-shim" ,ruby-minitest-tu-shim)))
5793 (synopsis "Ruby library to control the attributes of terminal output")
5794 (description
5795 "This Ruby library uses ANSI escape sequences to control the attributes
5796of terminal output.")
2f3800e5 5797 (home-page "https://flori.github.io/term-ansicolor/")
fd83a212
RW
5798 ;; There is no mention of the "or later" clause.
5799 (license license:gpl2)))
5800
a714c30f
CB
5801(define-public ruby-terraform
5802 (package
5803 (name "ruby-terraform")
5804 (version "0.22.0")
5805 (source
5806 (origin
5807 (method url-fetch)
5808 (uri (rubygems-uri "ruby-terraform" version))
5809 (sha256
5810 (base32
5811 "13zjkp71cd19j2ds2h9rqwcfr1zdg5nsh63p89l6qcsc9z39z324"))))
5812 (build-system ruby-build-system)
5813 (arguments
5814 '(#:tests? #f)) ; No included tests
5815 (propagated-inputs
5816 `(("ruby-lino" ,ruby-lino)))
5817 (synopsis "Ruby wrapper around the Terraform command line interface")
5818 (description
5819 "This package provides a Ruby wrapper around the Terraform command line
5820interface so that Terraform can be more easily invoked from Ruby code.")
5821 (home-page "https://github.com/infrablocks/ruby_terraform")
5822 (license license:expat)))
5823
6e376ca4
RW
5824(define-public ruby-pstree
5825 (package
5826 (name "ruby-pstree")
5827 (version "0.1.0")
5828 (source (origin
5829 (method url-fetch)
5830 (uri (rubygems-uri "pstree" version))
5831 (sha256
5832 (base32
5833 "1mig1sv5qx1cdyhjaipy8jlh9j8pnja04vprrzihyfr54x0215p1"))))
5834 (build-system ruby-build-system)
5835 (native-inputs
5836 `(("ruby-gem-hadar" ,ruby-gem-hadar)
5837 ("bundler" ,bundler)))
5838 (synopsis "Create a process tree data structure")
5839 (description
5840 "This library uses the output of the @code{ps} command to create a
5841process tree data structure for the current host.")
2f3800e5 5842 (home-page "https://github.com/flori/pstree")
6e376ca4
RW
5843 ;; There is no mention of the "or later" clause.
5844 (license license:gpl2)))
5845
53239b5f
RW
5846(define-public ruby-utils
5847 (package
5848 (name "ruby-utils")
cd698b6e 5849 (version "0.9.0")
53239b5f
RW
5850 (source (origin
5851 (method url-fetch)
5852 (uri (rubygems-uri "utils" version))
5853 (sha256
5854 (base32
cd698b6e 5855 "196zhgcygrnx09bb9mh22qas03rl9avzx8qs0wnxznpin4pffwcl"))))
53239b5f
RW
5856 (build-system ruby-build-system)
5857 (propagated-inputs
5858 `(("ruby-tins" ,ruby-tins)
5859 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
5860 ("ruby-pstree" ,ruby-pstree)
5861 ("ruby-pry-editline" ,ruby-pry-editline)))
5862 (native-inputs
5863 `(("ruby-gem-hadar" ,ruby-gem-hadar)
5864 ("bundler" ,bundler)))
5865 (synopsis "Command line tools for working with Ruby")
5866 (description
5867 "This package provides assorted command line tools that may be useful
5868when working with Ruby code.")
5869 (home-page "https://github.com/flori/utils")
5870 ;; There is no mention of the "or later" clause.
5871 (license license:gpl2)))
5872
433f10b5
CB
5873(define-public ruby-jaro-winkler
5874 (package
5875 (name "ruby-jaro-winkler")
37b23e44 5876 (version "1.5.4")
433f10b5
CB
5877 (source
5878 (origin
5879 (method url-fetch)
5880 (uri (rubygems-uri "jaro_winkler" version))
5881 (sha256
37b23e44 5882 (base32 "1y8l6k34svmdyqxya3iahpwbpvmn3fswhwsvrz0nk1wyb8yfihsh"))))
433f10b5
CB
5883 (build-system ruby-build-system)
5884 (arguments
37b23e44 5885 '(#:tests? #f)) ; no included tests
433f10b5
CB
5886 (synopsis "Ruby implementation of Jaro-Winkler distance algorithm")
5887 (description
5888 "@code{jaro_winkler} is an implementation of Jaro-Winkler distance
5889algorithm. It is written as a C extension and will fallback to a pure Ruby
5890implementation on platforms where this is unsupported.")
5891 (home-page "https://github.com/tonytonyjan/jaro_winkler")
5892 (license license:expat)))
5893
c99e2247
DT
5894(define-public ruby-json
5895 (package
5896 (name "ruby-json")
a281acce 5897 (version "2.1.0")
c99e2247
DT
5898 (source
5899 (origin
5900 (method url-fetch)
5901 (uri (rubygems-uri "json" version))
5902 (sha256
5903 (base32
a281acce 5904 "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp"))))
c99e2247
DT
5905 (build-system ruby-build-system)
5906 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
5907 (synopsis "JSON library for Ruby")
5908 (description "This Ruby library provides a JSON implementation written as
5909a native C extension.")
5910 (home-page "http://json-jruby.rubyforge.org/")
5911 (license (list license:ruby license:gpl2)))) ; GPL2 only
5ff89a1b 5912
763624f5
RW
5913(define-public ruby-json-pure
5914 (package
5915 (name "ruby-json-pure")
1c65d99f 5916 (version "2.2.0")
763624f5
RW
5917 (source (origin
5918 (method url-fetch)
5919 (uri (rubygems-uri "json_pure" version))
5920 (sha256
5921 (base32
1c65d99f 5922 "0m0j1mfwv0mvw72kzqisb26xjl236ivqypw1741dkis7s63b8439"))))
763624f5
RW
5923 (build-system ruby-build-system)
5924 (arguments
ac01cb07 5925 `(#:phases
763624f5 5926 (modify-phases %standard-phases
ac01cb07 5927 (add-after 'unpack 'fix-rakefile
763624f5 5928 (lambda _
ac01cb07
BW
5929 (substitute* "Rakefile"
5930 ;; Since this is not a git repository, do not call 'git'.
5931 (("`git ls-files`") "`find . -type f |sort`")
5932 ;; Loosen dependency constraint.
5933 (("'test-unit', '~> 2.0'") "'test-unit', '>= 2.0'"))
5934 #t))
5935 (add-after 'replace-git-ls-files 'regenerate-gemspec
5936 (lambda _
5937 ;; Regenerate gemspec so loosened dependency constraints are
5938 ;; propagated.
17cfb7ae
CB
5939 (invoke "rake" "gemspec")))
5940 (add-after 'regenerate-gemspec 'fix-json-java.gemspec
5941 (lambda _
5942 ;; This gemspec doesn't look to be generated by the above
5943 ;; command, so patch it separately.
5944 (substitute* "json-java.gemspec"
5945 (("%q<test-unit>\\.freeze, \\[\"~> 2\\.0\"\\]")
5946 "%q<test-unit>.freeze, [\">= 2.0\"]"))
5947 #t)))))
763624f5 5948 (native-inputs
ac01cb07 5949 `(("bundler" ,bundler)
0c9f73cd
TGR
5950 ("ragel" ,ragel)
5951 ("ruby-simplecov" ,ruby-simplecov)
5952 ("ruby-test-unit" ,ruby-test-unit)))
763624f5
RW
5953 (synopsis "JSON implementation in pure Ruby")
5954 (description
5955 "This package provides a JSON implementation written in pure Ruby.")
1c65d99f 5956 (home-page "https://flori.github.com/json/")
763624f5
RW
5957 (license license:ruby)))
5958
2a8581ac
CB
5959(define-public ruby-jwt
5960 (package
5961 (name "ruby-jwt")
5962 (version "2.1.0")
5963 (source
5964 (origin
5965 (method url-fetch)
5966 (uri (rubygems-uri "jwt" version))
5967 (sha256
5968 (base32
5969 "1w0kaqrbl71cq9sbnixc20x5lqah3hs2i93xmhlfdg2y3by7yzky"))))
5970 (build-system ruby-build-system)
5971 (arguments
5972 '(#:test-target "test"
5973 #:phases
5974 (modify-phases %standard-phases
5975 (add-after 'unpack 'remove-unnecessary-dependencies
5976 (lambda _
5977 (substitute* "spec/spec_helper.rb"
5978 (("require 'simplecov.*") "\n")
5979 ;; Use [].each to disable running the SimpleCov configuration
5980 ;; block
5981 (("SimpleCov\\.configure") "[].each")
5982 (("require 'codeclimate-test-reporter'") "")
5983 (("require 'codacy-coverage'") "")
5984 (("Codacy::Reporter\\.start") ""))
5985 #t)))))
5986 (native-inputs
5987 `(("bundler" ,bundler)
5988 ("ruby-rspec" ,ruby-rspec)
5989 ("ruby-rbnacl" ,ruby-rbnacl)))
5990 (synopsis "Ruby implementation of the JSON Web Token standard")
5991 (description
5992 "This package provides a pure Ruby implementation of the RFC 7519 OAuth
5993@acronym{JWT, JSON Web Token} standard.")
5994 (home-page "https://github.com/jwt/ruby-jwt")
5995 (license license:expat)))
5996
16b324cd
RW
5997;; Even though this package only provides bindings for a Mac OSX API it is
5998;; required by "ruby-listen" at runtime.
5999(define-public ruby-rb-fsevent
6000 (package
6001 (name "ruby-rb-fsevent")
b0ef15ed 6002 (version "0.10.3")
16b324cd
RW
6003 (source (origin
6004 (method url-fetch)
6005 (uri (rubygems-uri "rb-fsevent" version))
6006 (sha256
6007 (base32
b0ef15ed 6008 "1lm1k7wpz69jx7jrc92w3ggczkjyjbfziq5mg62vjnxmzs383xx8"))))
16b324cd
RW
6009 (build-system ruby-build-system)
6010 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
6011 ;; "listen", which needs "rb-fsevent" at runtime.
6012 (arguments `(#:tests? #f))
6013 (synopsis "FSEvents API with signals catching")
6014 (description
6015 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
6016 (home-page "https://rubygems.org/gems/rb-fsevent")
6017 (license license:expat)))
6018
b86be2ad
RW
6019(define-public ruby-listen
6020 (package
6021 (name "ruby-listen")
12341d34 6022 (version "3.2.0")
b86be2ad
RW
6023 (source
6024 (origin
35602819
CB
6025 ;; The gem does not include a Rakefile, so fetch from the Git
6026 ;; repository.
6027 (method git-fetch)
6028 (uri (git-reference
b0e7b699 6029 (url "https://github.com/guard/listen")
35602819
CB
6030 (commit (string-append "v" version))))
6031 (file-name (git-file-name name version))
b86be2ad
RW
6032 (sha256
6033 (base32
12341d34 6034 "1hkp1g6hk5clsmbd001gkc12ma6s459x820piajyasv61m87if24"))))
b86be2ad 6035 (build-system ruby-build-system)
35602819
CB
6036 (arguments
6037 `(#:test-target "spec"
6038 #:phases
6039 (modify-phases %standard-phases
6040 (add-after 'unpack 'fix-files-in-gemspec
6041 (lambda _
6042 (substitute* "listen.gemspec"
6043 (("`git ls-files -z`") "`find . -type f -printf '%P\\\\0' |sort -z`"))
6044 #t))
6045 (add-before 'check 'remove-unnecessary-dependencies'
6046 (lambda _
6047 (substitute* "Rakefile"
6048 ;; Rubocop is for code linting, and is unnecessary for running
6049 ;; the tests.
6050 ((".*rubocop.*") ""))
6051 #t)))))
6052 (native-inputs
6053 `(("bundler" ,bundler)
6054 ("ruby-rspec" ,ruby-rspec)))
6055 (inputs
6056 `(;; ruby-thor is used for the command line interface, and is referenced
6057 ;; in the wrapper, and therefore just needs to be an input.
6058 ("ruby-thor" ,ruby-thor)))
b86be2ad 6059 (propagated-inputs
35602819
CB
6060 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
6061 ("ruby-rb-inotify" ,ruby-rb-inotify)
6062 ("ruby-dep" ,ruby-dep)))
b86be2ad
RW
6063 (synopsis "Listen to file modifications")
6064 (description "The Listen gem listens to file modifications and notifies
6065you about the changes.")
6066 (home-page "https://github.com/guard/listen")
6067 (license license:expat)))
6068
8d3c5ff6
CB
6069(define-public ruby-loofah
6070 (package
6071 (name "ruby-loofah")
6072 (version "2.2.3")
6073 (source
6074 (origin
6075 (method url-fetch)
6076 (uri (rubygems-uri "loofah" version))
6077 (sha256
6078 (base32
6079 "1ccsid33xjajd0im2xv941aywi58z7ihwkvaf1w2bv89vn5bhsjg"))))
6080 (build-system ruby-build-system)
6081 (arguments
6082 '(#:phases
6083 (modify-phases %standard-phases
6084 (add-after 'unpack 'remove-unnecessary-dependencies
6085 (lambda _
6086 ;; concourse is a development tool which is unused, so remove it
6087 ;; so it's not required.
6088 (substitute* "Gemfile"
6089 ((".*\"concourse\".*") "\n"))
6090 (substitute* "Rakefile"
6091 (("require 'concourse'") "")
6092 (("Concourse\\.new.*") "\n"))
6093 #t)))))
6094 (native-inputs
6095 `(("ruby-hoe" ,ruby-hoe)
6096 ("ruby-rr" ,ruby-rr)))
6097 (propagated-inputs
6098 `(("ruby-nokogiri" ,ruby-nokogiri)
6099 ("ruby-crass" ,ruby-crass)))
6100 (synopsis "Ruby library for manipulating and transforming HTML/XML")
6101 (description
6102 "Loofah is a general library for manipulating and transforming HTML/XML
6103documents and fragments. It's built on top of Nokogiri and libxml2.")
6104 (home-page "https://github.com/flavorjones/loofah")
6105 (license license:expat)))
6106
5ff89a1b
DT
6107(define-public ruby-activesupport
6108 (package
6109 (name "ruby-activesupport")
bcf1fe5b 6110 (version "5.2.2.1")
5ff89a1b
DT
6111 (source
6112 (origin
6113 (method url-fetch)
6114 (uri (rubygems-uri "activesupport" version))
6115 (sha256
6116 (base32
bcf1fe5b 6117 "161bp4p01v1a1lvszrhd1a02zf9x1p1l1yhw79a3rix1kvzkkdqb"))))
5ff89a1b
DT
6118 (build-system ruby-build-system)
6119 (arguments
2af45e50
BW
6120 `(#:phases
6121 (modify-phases %standard-phases
6122 (replace 'check
6123 (lambda _
9923d5a4
TGR
6124 ;; There are no tests, instead attempt to load the library.
6125 (invoke "ruby" "-Ilib" "-r" "active_support"))))))
5ff89a1b 6126 (propagated-inputs
2af45e50
BW
6127 `(("ruby-concurrent" ,ruby-concurrent)
6128 ("ruby-i18n" ,ruby-i18n)
5ff89a1b 6129 ("ruby-minitest" ,ruby-minitest)
606ee9a1
BW
6130 ("ruby-tzinfo" ,ruby-tzinfo)
6131 ("ruby-tzinfo-data" ,ruby-tzinfo-data)))
5ff89a1b
DT
6132 (synopsis "Ruby on Rails utility library")
6133 (description "ActiveSupport is a toolkit of support libraries and Ruby
6134core extensions extracted from the Rails framework. It includes support for
6135multibyte strings, internationalization, time zones, and testing.")
6136 (home-page "http://www.rubyonrails.org")
6137 (license license:expat)))
f847ad7b 6138
3996f0aa
RW
6139(define-public ruby-crass
6140 (package
6141 (name "ruby-crass")
a84a185a
MB
6142 (version "1.0.6")
6143 (home-page "https://github.com/rgrove/crass")
3996f0aa 6144 (source (origin
a84a185a
MB
6145 ;; The gem does not contain tests, so pull from git.
6146 (method git-fetch)
6147 (uri (git-reference
6148 (url home-page)
6149 (commit (string-append "v" version))))
6150 (file-name (git-file-name name version))
3996f0aa
RW
6151 (sha256
6152 (base32
a84a185a 6153 "1gbsb81psgb6xhnwpx4s409jc0mk0gijh039sy5xyi8jpaaadp40"))))
3996f0aa 6154 (build-system ruby-build-system)
3996f0aa
RW
6155 (synopsis "Pure Ruby CSS parser")
6156 (description
6157 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
3996f0aa
RW
6158 (license license:expat)))
6159
c2c4e5b2 6160(define-public ruby-nokogumbo
2e366b0a
MB
6161 (package
6162 (name "ruby-nokogumbo")
6163 (version "2.0.2")
6164 (source (origin
6165 ;; We use the git reference, because there's no Rakefile in the
6166 ;; published gem and the tarball on Github is outdated.
6167 (method git-fetch)
6168 (uri (git-reference
b0e7b699 6169 (url "https://github.com/rubys/nokogumbo")
2e366b0a
MB
6170 (commit (string-append "v" version))))
6171 (file-name (string-append name "-" version "-checkout"))
6172 (sha256
6173 (base32
6174 "1qg0iyw450lw6d0j1ghzg79a6l60nm1m4qmrzwzybi585861jxcx"))))
6175 (build-system ruby-build-system)
6176 (native-inputs
6177 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
6178 (inputs
6179 `(("gumbo-parser" ,gumbo-parser)))
6180 (propagated-inputs
6181 `(("ruby-nokogiri" ,ruby-nokogiri)))
6182 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
6183 (description
6184 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
c2c4e5b2 6185access the result as a Nokogiri parsed document.")
2e366b0a
MB
6186 (home-page "https://github.com/rubys/nokogumbo/")
6187 (license license:asl2.0)))
c2c4e5b2 6188
d56ff88b
RW
6189(define-public ruby-sanitize
6190 (package
6191 (name "ruby-sanitize")
f362b53c
MB
6192 (version "5.1.0")
6193 (home-page "https://github.com/rgrove/sanitize")
d56ff88b 6194 (source (origin
f362b53c 6195 (method git-fetch)
d56ff88b 6196 ;; The gem does not include the Rakefile, so we download the
f362b53c
MB
6197 ;; source from Github.
6198 (uri (git-reference
6199 (url home-page)
6200 (commit (string-append "v" version))))
6201 (file-name (git-file-name name version))
6202 (patches (search-patches "ruby-sanitize-system-libxml.patch"))
d56ff88b
RW
6203 (sha256
6204 (base32
f362b53c 6205 "0lj0q9yhjp0q0in5majkshnki07mw8m2vxgndx4m5na6232aszl0"))))
d56ff88b
RW
6206 (build-system ruby-build-system)
6207 (propagated-inputs
6208 `(("ruby-crass" ,ruby-crass)
6209 ("ruby-nokogiri" ,ruby-nokogiri)
6210 ("ruby-nokogumbo" ,ruby-nokogumbo)))
6211 (native-inputs
f362b53c 6212 `(("ruby-minitest" ,ruby-minitest)))
d56ff88b
RW
6213 (synopsis "Whitelist-based HTML and CSS sanitizer")
6214 (description
6215 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
6216acceptable elements, attributes, and CSS properties, Sanitize will remove all
6217unacceptable HTML and/or CSS from a string.")
d56ff88b
RW
6218 (license license:expat)))
6219
ed4b6b18
BW
6220(define-public ruby-oj
6221 (package
6222 (name "ruby-oj")
93dfdec5 6223 (version "3.10.1")
ed4b6b18
BW
6224 (source
6225 (origin
b09ef660 6226 (method git-fetch)
ed4b6b18
BW
6227 ;; Version on rubygems.org does not contain Rakefile, so download from
6228 ;; GitHub instead.
b09ef660
EF
6229 (uri (git-reference
6230 (url "https://github.com/ohler55/oj")
6231 (commit (string-append "v" version))))
6232 (file-name (git-file-name name version))
ed4b6b18
BW
6233 (sha256
6234 (base32
93dfdec5 6235 "0i5xjx4sh816zx2c1a4d1q67k7vllg5jnnc4jy6zhbmwi1dvp5vw"))))
ed4b6b18
BW
6236 (build-system ruby-build-system)
6237 (arguments
6238 '(#:test-target "test_all"
6239 #:phases
6240 (modify-phases %standard-phases
6241 (add-before 'check 'disable-bundler
6242 (lambda _
6243 (substitute* "Rakefile"
6244 (("Bundler\\.with_clean_env") "1.times")
6245 (("bundle exec ") "")))))))
6246 (native-inputs
6247 `(("bundler" ,bundler)
6248 ("ruby-rspec" ,ruby-rspec)
6249 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6250 (synopsis "JSON parser for Ruby optimized for speed")
6251 (description
6252 "Oj is a JSON parser and generator for Ruby, where the encoding and
6253decoding of JSON is implemented as a C extension to Ruby.")
b09ef660 6254 (home-page "http://www.ohler.com/oj/")
ed4b6b18
BW
6255 (license (list license:expat ; Ruby code
6256 license:bsd-3)))) ; extension code
6257
f847ad7b
DT
6258(define-public ruby-ox
6259 (package
6260 (name "ruby-ox")
263c0dbf 6261 (version "2.6.0")
f847ad7b
DT
6262 (source
6263 (origin
6264 (method url-fetch)
6265 (uri (rubygems-uri "ox" version))
6266 (sha256
6267 (base32
263c0dbf 6268 "0fmk62b1h2i79dfzjj8wmf8qid1rv5nhwfc17l489ywnga91xl83"))))
f847ad7b
DT
6269 (build-system ruby-build-system)
6270 (arguments
6271 '(#:tests? #f)) ; no tests
6272 (synopsis "Optimized XML library for Ruby")
6273 (description
6274 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
6275written as a native C extension. It was designed to be an alternative to
6276Nokogiri and other Ruby XML parsers for generic XML parsing and as an
6277alternative to Marshal for Object serialization. ")
6278 (home-page "http://www.ohler.com/ox")
6279 (license license:expat)))
4a9e0585 6280
0c4e7625
RW
6281(define-public ruby-redcloth
6282 (package
6283 (name "ruby-redcloth")
2a91494e 6284 (version "4.3.2")
0c4e7625
RW
6285 (source (origin
6286 (method url-fetch)
6287 (uri (rubygems-uri "RedCloth" version))
6288 (sha256
6289 (base32
2a91494e 6290 "0m9dv7ya9q93r8x1pg2gi15rxlbck8m178j1fz7r5v6wr1avrrqy"))))
0c4e7625
RW
6291 (build-system ruby-build-system)
6292 (arguments
6293 `(#:tests? #f ; no tests
6294 #:phases
6295 (modify-phases %standard-phases
6296 ;; Redcloth has complicated rake tasks to build various versions for
6297 ;; multiple targets using RVM. We don't want this so we just use the
6298 ;; existing gemspec.
6299 (replace 'build
6300 (lambda _
9923d5a4 6301 (invoke "gem" "build" "redcloth.gemspec"))))))
0c4e7625
RW
6302 (native-inputs
6303 `(("bundler" ,bundler)
6304 ("ruby-diff-lcs" ,ruby-diff-lcs)
6305 ("ruby-rspec-2" ,ruby-rspec-2)))
6306 (synopsis "Textile markup language parser for Ruby")
6307 (description
6308 "RedCloth is a Ruby parser for the Textile markup language.")
6309 (home-page "http://redcloth.org")
6310 (license license:expat)))
6311
4a9e0585
DT
6312(define-public ruby-pg
6313 (package
6314 (name "ruby-pg")
ffc4869e 6315 (version "1.1.4")
4a9e0585
DT
6316 (source
6317 (origin
6318 (method url-fetch)
6319 (uri (rubygems-uri "pg" version))
6320 (sha256
6321 (base32
ffc4869e 6322 "0fmnyxcyrvgdbgq7m09whgn9i8rwfybk0w8aii1nc4g5kqw0k2jy"))))
4a9e0585
DT
6323 (build-system ruby-build-system)
6324 (arguments
6325 '(#:test-target "spec"))
6326 (native-inputs
6327 `(("ruby-rake-compiler" ,ruby-rake-compiler)
6328 ("ruby-hoe" ,ruby-hoe)
6329 ("ruby-rspec" ,ruby-rspec)))
6330 (inputs
ffc4869e 6331 `(("postgresql" ,postgresql)))
4a9e0585
DT
6332 (synopsis "Ruby interface to PostgreSQL")
6333 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
4db80f8b 6334with PostgreSQL 9.0 and later.")
4a9e0585
DT
6335 (home-page "https://bitbucket.org/ged/ruby-pg")
6336 (license license:ruby)))
468e5657
DT
6337
6338(define-public ruby-byebug
6339 (package
6340 (name "ruby-byebug")
d5489a61 6341 (version "9.0.6")
468e5657
DT
6342 (source
6343 (origin
6344 (method url-fetch)
6345 (uri (rubygems-uri "byebug" version))
6346 (sha256
6347 (base32
d5489a61 6348 "1kbfcn65rgdhi72n8x9l393b89rvi5z542459k7d1ggchpb0idb0"))))
468e5657
DT
6349 (build-system ruby-build-system)
6350 (arguments
6351 '(#:tests? #f)) ; no tests
6352 (synopsis "Debugger for Ruby 2")
6353 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
6354TracePoint C API for execution control and the Debug Inspector C API for call
6355stack navigation. The core component provides support that front-ends can
6356build on. It provides breakpoint handling and bindings for stack frames among
6357other things and it comes with a command line interface.")
7bf837fd 6358 (home-page "https://github.com/deivid-rodriguez/byebug")
468e5657 6359 (license license:bsd-2)))
64b6ccc3 6360
7aa00628
MC
6361;;; TODO: Make it the default byebug in core-updates.
6362(define-public ruby-byebug-11
6363 (package
6364 (inherit ruby-byebug)
6365 (name "ruby-byebug")
6366 (version "11.1.3")
6367 (source
6368 (origin
6369 (method git-fetch)
6370 (uri (git-reference
b0e7b699 6371 (url "https://github.com/deivid-rodriguez/byebug")
7aa00628
MC
6372 (commit (string-append "v" version))))
6373 (file-name (git-file-name name version))
6374 (sha256
6375 (base32
6376 "0vyy3k2s7dcndngj6m8kxhs1vxc2c93dw8b3yyand3srsg9ffpij"))
6377 (modules '((guix build utils)))
6378 (snippet
6379 '(begin
6380 ;; Remove wrappers that try to setup a bundle environment.
6381 (with-directory-excursion "bin"
6382 (for-each delete-file '("bundle" "rake" "rubocop"))
6383 ;; ruby-minitest doesn't come with a launcher, so fix the one
6384 ;; provided.
6385 (substitute* "minitest"
6386 (("load File\\.expand_path\\(\"bundle\".*") "")
6387 (("require \"bundler/setup\".*") "")))
6388 #t))))
6389 (arguments
6390 `(#:tests? #t
6391 #:phases
6392 (modify-phases %standard-phases
6393 (add-after 'unpack 'skip-tmp-path-sensitive-test
6394 (lambda _
6395 (substitute* "test/commands/where_test.rb"
6396 (("unless /cygwin\\|mswin\\|mingw\\|darwin/.*")
6397 "unless true\n"))
6398 #t))
6399 (add-before 'build 'compile
6400 (lambda _
6401 (invoke "rake" "compile")))
6402 (add-before 'check 'set-home
6403 (lambda _
6404 (setenv "HOME" (getcwd))
6405 #t)))))
6406 (native-inputs
6407 `(("bundler" ,bundler)
6408 ("ruby-chandler" ,ruby-chandler)
6409 ("ruby-minitest" ,ruby-minitest)
6410 ("ruby-pry" ,ruby-pry)
6411 ("ruby-rake-compiler" ,ruby-rake-compiler)
6412 ("ruby-rubocop" ,ruby-rubocop)
6413 ("ruby-yard" ,ruby-yard)))))
6414
5799bc2b
RW
6415(define-public ruby-netrc
6416 (package
6417 (name "ruby-netrc")
6418 (version "0.11.0")
6419 (source (origin
6420 (method url-fetch)
6421 (uri (rubygems-uri "netrc" version))
6422 (sha256
6423 (base32
6424 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
6425 (build-system ruby-build-system)
6426 (arguments
6427 `(#:phases
6428 (modify-phases %standard-phases
6429 (replace 'check
6430 ;; There is no Rakefile and minitest can only run one file at once,
6431 ;; so we have to iterate over all test files.
6432 (lambda _
9923d5a4
TGR
6433 (map (lambda (file)
6434 (invoke "ruby" "-Itest" file))
6435 (find-files "./test" "test_.*\\.rb")))))))
5799bc2b
RW
6436 (native-inputs
6437 `(("ruby-minitest" ,ruby-minitest)))
6438 (synopsis "Library to read and update netrc files")
6439 (description
6440 "This library can read and update netrc files, preserving formatting
6441including comments and whitespace.")
6442 (home-page "https://github.com/geemus/netrc")
6443 (license license:expat)))
6444
3a6989ce
RW
6445(define-public ruby-unf-ext
6446 (package
6447 (name "ruby-unf-ext")
14db8f19 6448 (version "0.0.7.6")
3a6989ce
RW
6449 (source (origin
6450 (method url-fetch)
6451 (uri (rubygems-uri "unf_ext" version))
6452 (sha256
6453 (base32
14db8f19 6454 "1ll6w64ibh81qwvjx19h8nj7mngxgffg7aigjx11klvf5k2g4nxf"))))
3a6989ce 6455 (build-system ruby-build-system)
b809cc9a
RW
6456 (arguments
6457 `(#:phases
6458 (modify-phases %standard-phases
6459 (add-after 'build 'build-ext
14db8f19
MB
6460 (lambda _ (invoke "rake" "compile:unf_ext")))
6461 (add-before 'check 'lose-rake-compiler-dock-dependency
6462 (lambda _
6463 ;; rake-compiler-dock is listed in the gemspec, but only
6464 ;; required when cross-compiling.
6465 (substitute* "unf_ext.gemspec"
6466 ((".*rake-compiler-dock.*") ""))
6467 #t)))))
3a6989ce
RW
6468 (native-inputs
6469 `(("bundler" ,bundler)
6470 ("ruby-rake-compiler" ,ruby-rake-compiler)
6471 ("ruby-test-unit" ,ruby-test-unit)))
6472 (synopsis "Unicode normalization form support library")
6473 (description
6474 "This package provides unicode normalization form support for Ruby.")
6475 (home-page "https://github.com/knu/ruby-unf_ext")
6476 (license license:expat)))
6477
2632a067 6478(define-public ruby-tdiff
5071f17b
BW
6479 ;; Use a newer than released snapshot so that rspec-2 is not required.
6480 (let ((commit "b662a6048f08abc45c1a834e5f34dd1c662935e2"))
6481 (package
6482 (name "ruby-tdiff")
6483 (version (string-append "0.3.3-1." (string-take commit 8)))
6484 (source (origin
6485 (method git-fetch)
6486 (uri (git-reference
b0e7b699 6487 (url "https://github.com/postmodern/tdiff")
5071f17b
BW
6488 (commit commit)))
6489 (file-name (string-append name "-" version "-checkout"))
6490 (sha256
6491 (base32
6492 "0n3gq8rx49f7ln6zqlshqfg2mgqyy30rsdjlnki5mv307ykc7ad4"))))
6493 (build-system ruby-build-system)
6494 (native-inputs
6495 `(("ruby-rspec" ,ruby-rspec)
6496 ("ruby-yard" ,ruby-yard)
6497 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
6498 (synopsis "Calculate the differences between two tree-like structures")
6499 (description
6500 "This library provides functions to calculate the differences between two
2632a067 6501tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
5071f17b
BW
6502 (home-page "https://github.com/postmodern/tdiff")
6503 (license license:expat))))
2632a067 6504
f60f5002 6505(define-public ruby-nokogiri-diff
5b0c223a
BW
6506 ;; Use a newer than released snapshot so that rspec-2 is not required.
6507 (let ((commit "a38491e4d8709b7406f2cae11a50226d927d06f5"))
6508 (package
6509 (name "ruby-nokogiri-diff")
6510 (version (string-append "0.2.0-1." (string-take commit 8)))
6511 (source (origin
6512 (method git-fetch)
6513 (uri (git-reference
b0e7b699 6514 (url "https://github.com/postmodern/nokogiri-diff")
5b0c223a
BW
6515 (commit commit)))
6516 (file-name (string-append name "-" version "-checkout"))
6517 (sha256
6518 (base32
6519 "1ah2sfjh9n1p0ln2wkqzfl448ml7j4zfy6dhp1qgzq2m41php6rf"))))
6520 (build-system ruby-build-system)
6521 (propagated-inputs
6522 `(("ruby-tdiff" ,ruby-tdiff)
6523 ("ruby-nokogiri" ,ruby-nokogiri)))
6524 (native-inputs
6525 `(("ruby-rspec" ,ruby-rspec)
6526 ("ruby-yard" ,ruby-yard)
6527 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
6528 (synopsis "Calculate the differences between two XML/HTML documents")
6529 (description
6530 "@code{Nokogiri::Diff} adds the ability to calculate the
f60f5002 6531differences (added or removed nodes) between two XML/HTML documents.")
5b0c223a
BW
6532 (home-page "https://github.com/postmodern/nokogiri-diff")
6533 (license license:expat))))
f60f5002 6534
6dc21310
CB
6535(define-public ruby-racc
6536 (package
6537 (name "ruby-racc")
6538 (version "1.4.14")
6539 (source
6540 (origin
6541 (method url-fetch)
6542 (uri (rubygems-uri "racc" version))
6543 (sha256
6544 (base32
6545 "00yhs2ag7yy5v83mqvkbnhk9bvsh6mx3808k53n61ddzx446v1zl"))))
6546 (build-system ruby-build-system)
6547 (native-inputs
6548 `(("ruby-hoe" ,ruby-hoe)
6549 ("ruby-rake-compiler" ,ruby-rake-compiler)))
6550 (synopsis "LALR(1) parser generator for Ruby")
6551 (description
6552 "Racc is a LALR(1) parser generator. It is written in Ruby itself, and
6553generates Ruby program.")
6554 (home-page "http://i.loveruby.net/en/projects/racc/")
6555 (license (list
6556 ;; Generally licensed under the LGPL2.1, and some files also
6557 ;; available under the same license as Ruby.
6558 license:lgpl2.1
6559 license:ruby))))
6560
64b6ccc3
DT
6561(define-public ruby-rack
6562 (package
6563 (name "ruby-rack")
288d2480 6564 (version "2.0.6")
64b6ccc3
DT
6565 (source
6566 (origin
83870c32 6567 (method git-fetch)
1db791d5 6568 ;; Download from GitHub so that the patch can be applied.
83870c32
EF
6569 (uri (git-reference
6570 (url "https://github.com/rack/rack")
6571 (commit version)))
6572 (file-name (git-file-name name version))
64b6ccc3
DT
6573 (sha256
6574 (base32
83870c32 6575 "1n7z4g1x6yxip096cdc04wq7yk7ywpinq28g2xjb46r4nlv5h0j6"))
1db791d5
BW
6576 ;; Ignore test which fails inside the build environment but works
6577 ;; outside.
6578 (patches (search-patches "ruby-rack-ignore-failing-test.patch"))))
64b6ccc3
DT
6579 (build-system ruby-build-system)
6580 (arguments
6581 '(#:phases
6582 (modify-phases %standard-phases
6583 (add-before 'check 'fix-tests
6584 (lambda _
6585 ;; A few of the tests use the length of a file on disk for
6586 ;; Content-Length and Content-Range headers. However, this file
6587 ;; has a shebang in it which an earlier phase patches, growing
6588 ;; the file size from 193 to 239 bytes when the store prefix is
6589 ;; "/gnu/store".
6590 (let ((size-diff (- (string-length (which "ruby"))
6591 (string-length "/usr/bin/env ruby"))))
6592 (substitute* '("test/spec_file.rb")
6593 (("193")
6594 (number->string (+ 193 size-diff)))
6595 (("bytes(.)22-33" all delimiter)
6596 (string-append "bytes"
6597 delimiter
6598 (number->string (+ 22 size-diff))
6599 "-"
6600 (number->string (+ 33 size-diff))))))
83870c32
EF
6601 #t))
6602 (add-before 'reset-gzip-timestamps 'make-files-writable
6603 (lambda* (#:key outputs #:allow-other-keys)
6604 ;; Make sure .gz files are writable so that the
6605 ;; 'reset-gzip-timestamps' phase can do its work.
6606 (let ((out (assoc-ref outputs "out")))
6607 (for-each make-file-writable
6608 (find-files out "\\.gz$"))
6609 #t))))))
64b6ccc3 6610 (native-inputs
1db791d5
BW
6611 `(("ruby-minitest" ,ruby-minitest)
6612 ("ruby-minitest-sprint" ,ruby-minitest-sprint)
6613 ("which" ,which)))
6614 (propagated-inputs
6615 `(("ruby-concurrent" ,ruby-concurrent)))
64b6ccc3
DT
6616 (synopsis "Unified web application interface for Ruby")
6617 (description "Rack provides a minimal, modular and adaptable interface for
6618developing web applications in Ruby. By wrapping HTTP requests and responses,
6619it unifies the API for web servers, web frameworks, and software in between
6620into a single method call.")
2f3800e5 6621 (home-page "https://rack.github.io/")
64b6ccc3 6622 (license license:expat)))
62e4cc5a 6623
20a0f804
BW
6624(define-public ruby-rack-test
6625 (package
6626 (name "ruby-rack-test")
6627 (version "0.8.3")
6628 (source
6629 (origin
6630 (method url-fetch)
6631 (uri (rubygems-uri "rack-test" version))
6632 (sha256
6633 (base32
6634 "14ij39zywvr1i9f6jsixfg4zxi2q1m1n1nydvf47f0b6sfc9mv1g"))))
6635 (build-system ruby-build-system)
6636 (arguments
6637 ;; Disable tests because of circular dependencies: requires sinatra,
6638 ;; which requires rack-protection, which requires rack-test. Instead
6639 ;; simply require the library.
6640 `(#:phases
6641 (modify-phases %standard-phases
6642 (replace 'check
6643 (lambda _
6644 (invoke "ruby" "-Ilib" "-r" "rack/test"))))))
6645 (propagated-inputs
6646 `(("ruby-rack" ,ruby-rack)))
6647 (synopsis "Testing API for Rack applications")
6648 (description
6649 "Rack::Test is a small, simple testing API for Rack applications. It can
6650be used on its own or as a reusable starting point for Web frameworks and
6651testing libraries to build on.")
6652 (home-page "https://github.com/rack-test/rack-test")
6653 (license license:expat)))
6654
a0a7e690
BW
6655(define-public ruby-rack-protection
6656 (package
6657 (name "ruby-rack-protection")
3355e49c 6658 (version "2.0.5")
a0a7e690
BW
6659 (source
6660 (origin
6661 (method url-fetch)
6662 (uri (rubygems-uri "rack-protection" version))
6663 (sha256
6664 (base32
3355e49c 6665 "15167q25rmxipqwi6hjqj3i1byi9iwl3xq9b7mdar7qiz39pmjsk"))))
a0a7e690
BW
6666 (build-system ruby-build-system)
6667 (arguments
fafeeaa2 6668 '(;; Tests missing from the gem.
a0a7e690
BW
6669 #:tests? #f))
6670 (propagated-inputs
6671 `(("ruby-rack" ,ruby-rack)))
6672 (native-inputs
6673 `(("bundler" ,bundler)
6674 ("ruby-rspec" ,ruby-rspec-2)
6675 ("ruby-rack-test" ,ruby-rack-test)))
6676 (synopsis "Rack middleware that protects against typical web attacks")
6677 (description "Rack middleware that can be used to protect against typical
6678web attacks. It can protect all Rack apps, including Rails. For instance, it
6679protects against cross site request forgery, cross site scripting,
6680clickjacking, directory traversal, session hijacking and IP spoofing.")
6681 (home-page "https://github.com/sinatra/sinatra/tree/master/rack-protection")
6682 (license license:expat)))
6683
6edabcb2
CB
6684(define-public ruby-rainbow
6685 (package
6686 (name "ruby-rainbow")
6687 (version "3.0.0")
6688 (source
6689 (origin
6690 (method url-fetch)
6691 (uri (rubygems-uri "rainbow" version))
6692 (sha256
6693 (base32
6694 "0bb2fpjspydr6x0s8pn1pqkzmxszvkfapv0p4627mywl7ky4zkhk"))))
6695 (build-system ruby-build-system)
6696 (arguments
6697 '(#:phases
6698 (modify-phases %standard-phases
6699 ;; Run rspec directly, to avoid requiring Rubocop which is used from
6700 ;; the Rakefile.
6701 (replace 'check
6702 (lambda* (#:key tests? #:allow-other-keys)
6703 (when tests?
6704 (invoke "rspec"))
6705 #t)))))
6706 (native-inputs
6707 `(("bundler" ,bundler)
6708 ("ruby-rspec" ,ruby-rspec)))
6709 (synopsis "Colorize printed text on ANSI terminals")
6710 (description
6711 "@code{rainbow} provides a string presenter object to colorize strings by
6712wrapping them in ANSI escape codes.")
6713 (home-page "https://github.com/sickill/rainbow")
79193b20
CB
6714 (license license:expat)))
6715
6188d643
CB
6716(define-public ruby-rr
6717 (package
6718 (name "ruby-rr")
6719 (version "1.2.1")
6720 (source
6721 (origin
6722 (method url-fetch)
6723 (uri (rubygems-uri "rr" version))
6724 (sha256
6725 (base32
6726 "1n9g78ba4c2zzmz8cdb97c38h1xm0clircag00vbcxwqs4dq0ymp"))))
6727 (build-system ruby-build-system)
6728 (arguments
6729 '(#:tests? #f)) ; test files not included
6730 (native-inputs
6731 `(("bundler" ,bundler)
6732 ("ruby-rspec" ,ruby-rspec)))
6733 (synopsis "Ruby test double framework")
6734 (description
6735 "RR is a test double framework that features a rich selection of double
6736techniques and a terse syntax.")
6737 (home-page "https://rr.github.io/rr/")
6738 (license license:expat)))
6739
79193b20
CB
6740(define-public ruby-rest-client
6741 (package
6742 (name "ruby-rest-client")
6743 (version "2.0.2")
6744 (source
6745 (origin
6746 (method url-fetch)
6747 (uri (rubygems-uri "rest-client" version))
6748 (sha256
6749 (base32
6750 "1hzcs2r7b5bjkf2x2z3n8z6082maz0j8vqjiciwgg3hzb63f958j"))))
6751 (build-system ruby-build-system)
6752 (arguments
6753 '(#:phases
6754 (modify-phases %standard-phases
6755 (add-before 'check 'remove-unnecessary-development-dependencies
6756 (lambda _
6757 (substitute* "rest-client.gemspec"
6758 ;; Remove rubocop as it's unused. Rubocop also indirectly
6759 ;; depends on this package through ruby-parser and ruby-ast so
6760 ;; this avoids a dependency loop.
6761 ((".*rubocop.*") "\n")
6762 ;; Remove pry as it's unused, it's a debugging tool
6763 ((".*pry.*") "\n")
6764 ;; Remove an unnecessarily strict rdoc dependency
6765 ((".*rdoc.*") "\n"))
6766 #t))
6767 (add-before 'check 'delete-network-dependent-tests
6768 (lambda _
6769 (delete-file "spec/integration/request_spec.rb")
6770 (delete-file "spec/integration/httpbin_spec.rb")
6771 #t)))))
6772 (propagated-inputs
6773 `(("ruby-http-cookie" ,ruby-http-cookie)
6774 ("ruby-mime-types" ,ruby-mime-types)
6775 ("ruby-netrc" ,ruby-netrc)))
6776 (native-inputs
6777 `(("bundler" ,bundler)
eea094cc
TGR
6778 ("ruby-webmock" ,ruby-webmock-2)
6779 ("ruby-rspec" ,ruby-rspec)))
79193b20
CB
6780 (synopsis "Simple HTTP and REST client for Ruby")
6781 (description
6782 "@code{rest-client} provides a simple HTTP and REST client for Ruby,
6783inspired by the Sinatra microframework style of specifying actions:
6784@code{get}, @code{put}, @code{post}, @code{delete}.")
6785 (home-page "https://github.com/rest-client/rest-client")
6edabcb2
CB
6786 (license license:expat)))
6787
5c4c28f8
MC
6788(define-public ruby-rubocop-ast
6789 (package
6790 (name "ruby-rubocop-ast")
6791 (version "0.1.0")
6792 (source
6793 (origin
6794 (method git-fetch) ;no test suite in distributed gem
6795 (uri (git-reference
6796 (url "https://github.com/rubocop-hq/rubocop-ast.git")
6797 (commit (string-append "v" version))))
6798 (file-name (git-file-name name version))
6799 (sha256
6800 (base32
6801 "0nz25z5b76xkgb9sh370hni3l946j07fr05cdwkdj9x7ibgsb6nj"))))
6802 (build-system ruby-build-system)
6803 (arguments
6804 `(#:test-target "spec"
6805 #:phases (modify-phases %standard-phases
6806 (add-after 'unpack 'disable-bundler
6807 (lambda _
6808 (substitute* "Rakefile"
6809 (("Bundler\\.setup.*") "nil\n"))
6810 #t))
6811 (replace 'replace-git-ls-files
6812 (lambda _
6813 (substitute* "rubocop-ast.gemspec"
6814 (("`git ls-files(.*)`" _ files)
6815 (format #f "`find ~a -type f| sort`" files)))
6816 #t)))))
6817 (native-inputs
6818 `(("ruby-bump" ,ruby-bump)
6819 ("ruby-rspec" ,ruby-rspec)))
6820 (propagated-inputs
6821 `(("ruby-parser" ,ruby-parser)))
6822 (synopsis "RuboCop's AST extensions and NodePattern functionality")
6823 (description "Rubocop::AST extends @code{ruby-parser} with classes used
6824by RuboCop to deal with Ruby's Abstract Syntax Tree (AST), in particular:
6825@itemize
6826@item @code{RuboCop::AST::Node}
6827@item @code{RuboCop::AST::NodePattern}
6828@end itemize")
6829 (home-page "https://rubocop.org/")
6830 (license license:expat)))
6831
e098bdae
MC
6832(define-public ruby-rexml
6833 (package
6834 (name "ruby-rexml")
6835 (version "3.2.4")
6836 (source
6837 (origin
6838 (method git-fetch) ;no tests in distributed gem
6839 (uri (git-reference
6840 (url "https://github.com/ruby/rexml.git")
6841 (commit (string-append "v" version))))
6842 (file-name (git-file-name name version))
6843 (sha256
6844 (base32
6845 "0rhjjbkaq2f2cs8hyr2i4yjqpcyl8m0wmr2cypa401m3fvz4221i"))))
6846 (build-system ruby-build-system)
6847 (synopsis "XML toolkit for Ruby")
6848 (description "Inspired by Electric XML library for Java, REXML aims to be
6849easy-to-use API, small and fast. It supports both tree and stream document
6850parsing.")
6851 (home-page "https://github.com/ruby/rexml")
6852 (license license:bsd-2)))
6853
93ec41c6
MC
6854(define-public ruby-character-set
6855 (package
6856 (name "ruby-character-set")
6857 (version "1.4.0")
6858 (source
6859 (origin
6860 (method url-fetch)
6861 (uri (rubygems-uri "character_set" version))
6862 (sha256
6863 (base32
6864 "0affq9n77vwy897ri2zhmfinfagf37hcwwimrccy1bcxan9mj3h3"))))
6865 (build-system ruby-build-system)
6866 (arguments '(#:tests? #f)) ;avoid a cycle with ruby-regexp-parser
6867 (synopsis "Ruby library to manipulate Unicode")
6868 (description "CharacterSet is a C-extended Ruby library to work with sets
6869of Unicode code points. It can read and write these sets in various formats
6870and implements the @code{stdlib} @code{Set} interface for them. It also
6871offers an alternate paradigm of @code{String} processing which grants much
6872better performance than @code{Regexp} and @code{String} methods from the
6873@code{stdlib} where applicable. Many parts can be used independently, e.g.:
6874@itemize
6875@item @code{CharacterSet::Character}
6876@item @code{CharacterSet::Parser}
6877@item @code{CharacterSet::Writer}
6878@item @code{RangeCompressor}
6879@end itemize")
6880 (home-page "https://github.com/jaynetics/character_set")
6881 (license license:expat)))
6882
ac75f1df
MC
6883(define-public ruby-range-compressor
6884 (package
6885 (name "ruby-range-compressor")
6886 (version "1.0.0")
6887 (source
6888 (origin
6889 (method git-fetch)
6890 (uri (git-reference
6891 (url "https://github.com/janosch-x/range_compressor.git")
6892 (commit (string-append "v" version))))
6893 (file-name (git-file-name name version))
6894 (sha256
6895 (base32
6896 "0y8slri2msyyg2szgwgriqd6qw9hkxycssdrcl5lk2dbcq5zvn54"))))
6897 (build-system ruby-build-system)
6898 (arguments
6899 `(#:test-target "spec"
6900 #:phases (modify-phases %standard-phases
6901 (add-after 'extract-gemspec 'strip-version-requirements
6902 (lambda _
6903 (substitute* "range_compressor.gemspec"
6904 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
6905 (string-append stripped "\n")))
6906 #t)))))
6907 (native-inputs
6908 `(("ruby-rspec" ,ruby-rspec)))
6909 (synopsis "Simple arrays of objects to arrays of ranges compressor")
6910 (description "RangeCompresses is a tiny library that allows compressing
6911arrays of objects into arrays of ranges. For example, it can turn the
6912following: @code{[1, 2, 3, 4, 6, 8, 9, 10]} into @code{[1..4, 6..6, 8..10]}.")
6913 (home-page "https://github.com/janosch-x/range_compressor")
6914 (license license:expat)))
6915
8aba0333
MC
6916(define-public ruby-regexp-property-values
6917 (package
6918 (name "ruby-regexp-property-values")
6919 (version "1.0.0")
6920 (source
6921 (origin
6922 (method git-fetch)
6923 (uri (git-reference ;no test suite in distributed gem
6924 (url "https://github.com/jaynetics/regexp_property_values.git")
6925 (commit (string-append "v" version))))
6926 (file-name (git-file-name name version))
6927 (sha256
6928 (base32
6929 "0l3fjmscg1wxn7kc6bl022cc6k5d91pwb7daq1b5w36kvsx52w1j"))))
6930 (build-system ruby-build-system)
6931 (arguments
6932 '(#:test-target "default"))
6933 (native-inputs
6934 `(("ruby-character-set" ,ruby-character-set)
6935 ("ruby-rake-compiler" ,ruby-rake-compiler)
6936 ("ruby-range-compressor" ,ruby-range-compressor)
6937 ("ruby-rspec" ,ruby-rspec)))
6938 (synopsis "Inspect Ruby's regex engine property values")
6939 (description "This small library lets you see which property values are
6940supported by the regular expression engine of the Ruby version you are running
6941and can directly read out their code point ranges. In other words, it
6942determines all supported values for @code{\\p{value}} expressions and what
6943they match.")
6944 (home-page "https://github.com/jaynetics/regexp_property_values")
6945 (license license:expat)))
6946
b6f2a8d1
MC
6947(define-public ruby-regexp-parser
6948 (package
6949 (name "ruby-regexp-parser")
6950 (version "1.7.1")
6951 (source
6952 (origin
6953 (method git-fetch) ;bin/test missing from gem
6954 (uri (git-reference
6955 (url "https://github.com/ammar/regexp_parser.git")
6956 (commit (string-append "v" version))))
6957 (file-name (git-file-name name version))
6958 (sha256
6959 (base32
6960 "0dk9d4vpw31cc06s29fqyr1kq0kipym1mydifkcrnppvpl3pd53r"))))
6961 (build-system ruby-build-system)
6962 (arguments
6963 '(#:test-target "default"
6964 #:phases (modify-phases %standard-phases
6965 (add-before 'build 'compile-scanner.rb
6966 (lambda _
6967 (invoke "rake" "build")
6968 ;; XXX: This is needed otherwise the install
6969 ;; phase fails to delete the installed cached
6970 ;; gem file.
6971 (delete-file-recursively "pkg")
6972 #t)))))
6973 (native-inputs
6974 `(("ragel" ,ragel)
6975 ("ruby-regexp-property-values" ,ruby-regexp-property-values)
6976 ("ruby-rspec" ,ruby-rspec)))
6977 (synopsis "A regular expression parser library for Ruby ")
6978 (description "A Ruby gem for tokenizing, parsing, and transforming regular
6979expressions. It comprises the following components:
6980@itemize
6981@item A scanner/tokenizer based on Ragel,
6982@item A lexer that produces a stream of token objects,
6983@item A parser that produces a tree of Expression objects.
6984@end itemize")
6985 (home-page "https://github.com/ammar/regexp_parser")
6986 (license license:expat)))
6987
12ed6da4
MC
6988(define-public ruby-test-queue
6989 (package
6990 (name "ruby-test-queue")
6991 (version "0.4.2")
6992 (source
6993 (origin
6994 (method url-fetch)
6995 (uri (rubygems-uri "test-queue" version))
6996 (sha256
6997 (base32
6998 "0hvm3n1qrqxqilhqk4rjivw3gcrd08zz1i6am9qzg1ppjxv6f36f"))))
6999 (build-system ruby-build-system)
7000 (arguments
7001 '(#:phases
7002 (modify-phases %standard-phases
7003 (replace 'check
7004 (lambda* (#:key tests? #:allow-other-keys)
7005 (when tests?
7006 (invoke "rspec"))
7007 #t)))))
7008 (native-inputs
7009 `(("ruby-rspec" ,ruby-rspec)))
7010 (synopsis "Minitest/RSpec parallel test runner for CI environments")
7011 (description "The test-queue module is a parallel test runner,
7012built using a centralized queue to ensure optimal distribution of
7013tests between workers. It is specifically optimized for Continuous
7014Integration (CI) environments: build statistics from each run are
7015stored locally and used to sort the queue at the beginning of the next
7016run.")
7017 (home-page "https://github.com/tmm1/test-queue")
7018 (license license:expat)))
7019
5d8fe6de
CB
7020(define-public ruby-rubocop
7021 (package
7022 (name "ruby-rubocop")
c164c402 7023 (version "0.88.0")
5d8fe6de
CB
7024 (source
7025 (origin
c164c402
MC
7026 (method git-fetch) ;no tests in distributed gem
7027 (uri (git-reference
7028 (url "https://github.com/rubocop-hq/rubocop.git")
7029 (commit (string-append "v" version))))
7030 (file-name (git-file-name name version))
5d8fe6de
CB
7031 (sha256
7032 (base32
c164c402
MC
7033 "1d06893jp8pd85fvgp5d16vqcf31bafi430v4f4y746ihyvhzz5r"))
7034 (patches (search-patches "ruby-rubocop-break-dependency-cycle.patch"))))
5d8fe6de
CB
7035 (build-system ruby-build-system)
7036 (arguments
c164c402
MC
7037 '(#:test-target "default"
7038 #:phases
7039 (modify-phases %standard-phases
7040 (add-after 'unpack 'remove-problematic-tests
7041 ;; These tests depend on Rubocop extensions, which cannot be
7042 ;; included as they cause a dependency cycle with Rubocop itself.
7043 (lambda _
7044 (delete-file "spec/rubocop/config_loader_spec.rb")
7045 (substitute* "Gemfile"
7046 ((".*'rubocop-performance'.*") "")
7047 ((".*'rubocop-rspec'.*") ""))
7048 ;; Prevent "Unnecessary disabling of RSpec/* (unknown cop)"
7049 ;; errors.
7050 (substitute* (find-files "spec/rubocop/cop/" "_spec\\.rb$")
7051 (("# (rubocop:(enable|disable) RSpec.*)" _ what)
7052 (string-append "# Disabled: " what)))
7053 #t))
7054 (add-after 'unpack 'disable-bundler
7055 (lambda _
7056 (substitute* "Rakefile"
7057 (("Bundler\\.setup.*") "nil\n"))
7058 #t))
7059 (replace 'replace-git-ls-files
7060 (lambda _
7061 (substitute* "rubocop.gemspec"
7062 (("`git ls-files(.*)`" _ files)
7063 (format #f "`find ~a -type f| sort`" files)))
7064 #t))
7065 (add-before 'check 'set-home
7066 (lambda _
7067 (setenv "HOME" (getcwd))
7068 #t))
7069 (add-before 'check 'make-adoc-files-writable
7070 (lambda _
7071 (let ((adoc-files (find-files "docs/modules/ROOT/pages"
7072 "\\.adoc$")))
7073 (for-each make-file-writable adoc-files))
7074 #t)))))
7075 (native-inputs
7076 `(("ruby-bump" ,ruby-bump)
7077 ("ruby-pry" ,ruby-pry)
7078 ("ruby-rspec" ,ruby-rspec)
7079 ("ruby-test-queue" ,ruby-test-queue)
7080 ("ruby-webmock" ,ruby-webmock-2)
7081 ("ruby-yard" ,ruby-yard)))
5d8fe6de 7082 (propagated-inputs
c164c402
MC
7083 `(("ruby-parallel" ,ruby-parallel)
7084 ("ruby-parser" ,ruby-parser)
5d8fe6de 7085 ("ruby-rainbow" ,ruby-rainbow)
c164c402
MC
7086 ("ruby-regexp-parser" ,ruby-regexp-parser)
7087 ("ruby-rexml" ,ruby-rexml)
7088 ("ruby-rubocop-ast" ,ruby-rubocop-ast)
5d8fe6de 7089 ("ruby-progressbar" ,ruby-progressbar)
5d8fe6de
CB
7090 ("ruby-unicode-display-width" ,ruby-unicode-display-width)))
7091 (synopsis "Ruby code style checking tool")
7092 (description
7093 "@code{rubocop} is a Ruby code style checking tool. It aims to enforce
7094the community-driven Ruby Style Guide.")
7095 (home-page "https://github.com/rubocop-hq/rubocop")
7096 (license license:expat)))
7097
6ef85256
BW
7098(define-public ruby-contest
7099 (package
7100 (name "ruby-contest")
7101 (version "0.1.3")
7102 (source
7103 (origin
7104 (method url-fetch)
7105 (uri (rubygems-uri "contest" version))
7106 (sha256
7107 (base32
7108 "1p9f2292b7b0fbrcjswvj9v01z7ig5ig52328wyqcabgb553qsdf"))))
7109 (build-system ruby-build-system)
7110 (synopsis "Write declarative tests using nested contexts")
7111 (description
7112 "Contest allows writing declarative @code{Test::Unit} tests using nested
7113contexts without performance penalties.")
7114 (home-page "https://github.com/citrusbyte/contest")
7115 (license license:expat)))
7116
c4550f75
BW
7117(define-public ruby-creole
7118 (package
7119 (name "ruby-creole")
7120 (version "0.5.0")
7121 (source
7122 (origin
7123 (method url-fetch)
7124 (uri (rubygems-uri "creole" version))
7125 (sha256
7126 (base32
7127 "00rcscz16idp6dx0dk5yi5i0fz593i3r6anbn5bg2q07v3i025wm"))))
7128 (build-system ruby-build-system)
7129 (native-inputs
7130 `(("ruby-bacon" ,ruby-bacon)))
7131 (synopsis "Creole markup language converter")
7132 (description
7133 "Creole is a lightweight markup language and this library for converting
7134creole to @code{HTML}.")
7135 (home-page "https://github.com/minad/creole")
7136 (license license:ruby)))
7137
6aaa815e
PP
7138(define-public ruby-docile
7139 (package
7140 (name "ruby-docile")
7141 (version "1.1.5")
7142 (source
7143 (origin
7144 (method url-fetch)
7145 (uri (rubygems-uri "docile" version))
7146 (sha256
7147 (base32
7148 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
7149 (build-system ruby-build-system)
7150 (arguments
7151 '(#:tests? #f)) ; needs github-markup, among others
7152 (synopsis "Ruby EDSL helper library")
7153 (description "Docile is a Ruby library that provides an interface for
7154creating embedded domain specific languages (EDSLs) that manipulate existing
7155Ruby classes.")
7156 (home-page "https://ms-ati.github.io/docile/")
7157 (license license:expat)))
7158
fab8fed3
MC
7159(define-public ruby-middleware
7160 (package
7161 (name "ruby-middleware")
7162 (version "0.1.0")
7163 (source
7164 (origin
7165 (method url-fetch)
7166 (uri (rubygems-uri "middleware" version))
7167 (sha256
7168 (base32
7169 "0703nkf2v371wqr41c04x5qid7ww45cxqv3hnlg07if3b3xrm9xl"))))
7170 (build-system ruby-build-system)
7171 (arguments '(#:tests? #f)) ;no test suite
7172 (synopsis "Implementation of a middleware abstraction for Ruby")
7173 (description "Middleware is a generalized implementation of a middleware
7174abstraction for Ruby.")
7175 (home-page "https://github.com/mitchellh/middleware")
7176 (license license:expat)))
7177
1d537c71
MC
7178(define-public ruby-benchmark-ips
7179 (package
7180 (name "ruby-benchmark-ips")
7181 (version "2.8.2")
7182 (source
7183 (origin
7184 (method url-fetch)
7185 (uri (rubygems-uri "benchmark-ips" version))
7186 (sha256
7187 (base32
7188 "1n9397j7kh4vvikfann1467qgksc679imlr50hax3lk1q3af8kdw"))))
7189 (build-system ruby-build-system)
7190 (native-inputs
7191 `(("ruby-hoe" ,ruby-hoe)))
7192 (synopsis "Iterations per second enhancement for the Ruby Benchmark module")
7193 (description "Benchmark-ips enhances the Ruby Benchmark module with the
7194iterations per second count. For short snippets of code, it can automatically
7195figure out how many times to run the code to get interesting data.")
7196 (home-page "https://github.com/evanphx/benchmark-ips")
7197 (license license:expat)))
7198
fc5d1c5a
MC
7199(define-public ruby-ffi-rzmq-core
7200 (package
7201 (name "ruby-ffi-rzmq-core")
7202 (version "1.0.7")
7203 (source
7204 (origin
7205 (method url-fetch)
7206 (uri (rubygems-uri "ffi-rzmq-core" version))
7207 (sha256
7208 (base32
7209 "0amkbvljpjfnv0jpdmz71p1i3mqbhyrnhamjn566w0c01xd64hb5"))))
7210 (build-system ruby-build-system)
7211 (arguments
7212 `(#:phases
7213 (modify-phases %standard-phases
7214 (add-after 'unpack 'patch-libzmq-search-path
7215 (lambda* (#:key inputs #:allow-other-keys)
7216 (let ((zeromq (assoc-ref inputs "zeromq")))
7217 (substitute* "lib/ffi-rzmq-core/libzmq.rb"
7218 (("/usr/local/lib")
7219 (string-append zeromq "/lib")))
7220 #t)))
7221 (replace 'check
7222 (lambda _
7223 (invoke "rspec"))))))
7224 (native-inputs
7225 `(("ruby-rspec" ,ruby-rspec)))
7226 (inputs
7227 `(("zeromq" ,zeromq)))
7228 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
7229 (synopsis "Low-level Ruby FFI wrapper for the ZeroMQ networking library")
7230 (description "This library only provides the FFI wrapper for the ZeroMQ
7231networking library. It can be used to implement a Ruby API for the ZeroMQ
7232library.")
7233 (home-page "https://github.com/chuckremes/ffi-rzmq-core")
7234 (license license:expat)))
7235
7a503516
MC
7236(define-public ruby-ffi-rzmq
7237 (package
7238 (name "ruby-ffi-rzmq")
7239 (version "2.0.7")
7240 (source
7241 (origin
7242 (method url-fetch)
7243 (uri (rubygems-uri "ffi-rzmq" version))
7244 (sha256
7245 (base32
7246 "14a5kxfnf8l3ngyk8hgmk30z07aj1324ll8i48z67ps6pz2kpsrg"))))
7247 (build-system ruby-build-system)
7248 (arguments '(#:tests? #t
7249 #:phases (modify-phases %standard-phases
7250 (replace 'check
7251 (lambda _
7252 (invoke "rspec"))))))
7253 (native-inputs
7254 `(("ruby-rspec" ,ruby-rspec)))
7255 (propagated-inputs
7256 `(("ruby-ffi-rzmq-core" ,ruby-ffi-rzmq-core)))
7257 (synopsis "High-level Ruby wrapper for the ZeroMQ networking library")
7258 (description "This library provides a high-level API that wraps the ZeroMQ
7259networking library using the Ruby foreign function interface (FFI). It is a
7260pure Ruby wrapper, hence is compatible with any Ruby runtime that has support
7261for FFI.")
7262 (home-page "https://github.com/chuckremes/ffi-rzmq")
7263 (license license:expat)))
7264
03a0f98a
MC
7265(define-public ruby-sawyer
7266 (package
7267 (name "ruby-sawyer")
7268 (version "0.8.2")
7269 (source
7270 (origin
7271 (method url-fetch)
7272 (uri (rubygems-uri "sawyer" version))
7273 (sha256
7274 (base32
7275 "0yrdchs3psh583rjapkv33mljdivggqn99wkydkjdckcjn43j3cz"))))
7276 (build-system ruby-build-system)
7277 (propagated-inputs
7278 `(("ruby-addressable" ,ruby-addressable)
7279 ("ruby-faraday" ,ruby-faraday)))
7280 (synopsis "Experimental hypermedia agent for Ruby")
7281 (description "Sawyer is an experimental hypermedia agent for Ruby built on
7282top of Faraday.")
7283 (home-page "https://github.com/lostisland/sawyer")
7284 (license license:expat)))
7285
aa3c76b1
MC
7286(define-public ruby-octokit
7287 (package
7288 (name "ruby-octokit")
7289 (version "4.18.0")
7290 (source
7291 (origin
7292 (method url-fetch)
7293 (uri (rubygems-uri "octokit" version))
7294 (sha256
7295 (base32
7296 "0zvfr9njmj5svi39fcsi2b0g7pcxb0vamw9dlyas8bg814jlzhi6"))))
7297 (build-system ruby-build-system)
7298 (arguments '(#:tests? #f)) ;no test suite in the gem release
7299 (propagated-inputs
7300 `(("ruby-faraday" ,ruby-faraday)
7301 ("ruby-sawyer" ,ruby-sawyer)))
7302 (synopsis "Ruby toolkit for the GitHub API")
7303 (description "Octokit wraps the GitHub API in a flat API client that
7304follows Ruby conventions and requires little knowledge of REST.")
7305 (home-page "https://github.com/octokit/octokit.rb")
7306 (license license:expat)))
7307
1157d2f8
MC
7308(define-public ruby-chandler
7309 (package
7310 (name "ruby-chandler")
7311 (version "0.9.0")
7312 (source
7313 (origin
7314 (method url-fetch)
7315 (uri (rubygems-uri "chandler" version))
7316 (sha256
7317 (base32
7318 "1n8a4mr2jkcz5vaaps45g2rxa2pzy1wb7cylgw85xmmyyp14lnrr"))))
7319 (build-system ruby-build-system)
7320 (native-inputs
7321 `(("ruby-rubocop" ,ruby-rubocop)))
7322 (propagated-inputs
7323 `(("ruby-netrc" ,ruby-netrc)
7324 ("ruby-octokit" ,ruby-octokit)))
7325 (synopsis "Sync CHANGELOG entries to GitHub's release notes")
7326 (description "Chandler syncs a project's CHANGELOG file entries to
7327GitHub's release notes to remove the need of manually entering release
7328notes.")
7329 (home-page "https://github.com/mattbrictson/chandler")
7330 (license license:expat)))
7331
acb28876
MC
7332(define-public ruby-pry-byebug
7333 (package
7334 (name "ruby-pry-byebug")
7335 (version "3.9.0")
7336 (source
7337 (origin
7338 (method git-fetch)
7339 (uri (git-reference
b0e7b699 7340 (url "https://github.com/deivid-rodriguez/pry-byebug")
acb28876
MC
7341 (commit (string-append "v" version))))
7342 (file-name (git-file-name name version))
7343 (sha256
7344 (base32
7345 "1kchrwccai92068p50zyd6mh524ywqnm0jw5g3lks7iwmf0xkmgc"))))
7346 (build-system ruby-build-system)
7347 (arguments
7348 `(#:phases (modify-phases %standard-phases
7349 (add-before 'check 'set-home
7350 (lambda _
7351 (setenv "HOME" (getcwd))
7352 #t)))))
7353 (native-inputs
7354 `(("ruby-chandler" ,ruby-chandler)
7355 ("ruby-rubocop" ,ruby-rubocop)
7356 ("ruby-simplecov" ,ruby-simplecov)))
7357 (propagated-inputs
7358 `(("ruby-byebug" ,ruby-byebug-11)
7359 ("ruby-pry" ,ruby-pry)))
7360 (synopsis "Step-by-step debugging and stack navigation in Pry")
7361 (description "This package adds step-by-step debugging and stack
7362navigation capabilities to @code{pry}, using @code{byebug}.")
7363 (home-page "https://github.com/deivid-rodriguez/pry-byebug")
7364 (license license:expat)))
7365
4d31fe6b
MC
7366(define-public ruby-binding-of-caller
7367 (package
7368 (name "ruby-binding-of-caller")
7369 (version "0.8.0")
7370 (source
7371 (origin
7372 (method url-fetch)
7373 (uri (rubygems-uri "binding_of_caller" version))
7374 (sha256
7375 (base32
7376 "05syqlks7463zsy1jdfbbdravdhj9hpj5pv2m74blqpv8bq4vv5g"))))
7377 (build-system ruby-build-system)
7378 ;; Attempting to run the test suite fails with a rake deprecation error
7379 ;; (see: https://github.com/banister/binding_of_caller/issues/76).
7380 (arguments '(#:tests? #f))
7381 (propagated-inputs
7382 `(("ruby-debug-inspector" ,ruby-debug-inspector)))
7383 (synopsis "Retrieve the binding of a method's caller")
7384 (description "The @code{binding_of_caller} module provides the
7385@code{Binding#of_caller} method. It allows accessing bindings from upper
7386frames in the call stack and can evaluate code in that context.")
7387 (home-page "https://github.com/banister/binding_of_caller")
7388 (license license:expat)))
7389
f4699abc
MC
7390(define-public ruby-pry-stack-explorer
7391 (package
7392 (name "ruby-pry-stack-explorer")
7393 (version "0.5.1")
7394 (source
7395 (origin
7396 (method url-fetch)
7397 (uri (rubygems-uri "pry-stack_explorer" version))
7398 (sha256
7399 (base32
7400 "157rd2n9pfvcmmicm0xkq8z4p6famaj13syrpra6b4032qpb1wn0"))))
7401 (build-system ruby-build-system)
7402 (arguments '(#:tests? #f)) ;no test suite in gem release
7403 (propagated-inputs
7404 `(("ruby-binding-of-caller" ,ruby-binding-of-caller)
7405 ("ruby-pry" ,ruby-pry)))
7406 (synopsis "Call-stack navigation plugin for the Pry REPL")
7407 (description "@code{pry-stack_explorer} is a plugin for the Pry REPL that
7408add support to navigate the call-stack.")
7409 (home-page "https://github.com/pry/pry-stack_explorer")
7410 (license license:expat)))
7411
1f014c97
MC
7412(define-public ruby-varint
7413 (package
7414 (name "ruby-varint")
7415 (version "0.1.1")
7416 (source
7417 (origin
7418 (method url-fetch)
7419 (uri (rubygems-uri "varint" version))
7420 (sha256
7421 (base32
7422 "1y0l2qc64cwsyv76ygg9bbjnk86riz2kq73kmn87gdrlmpiyrdac"))))
7423 (build-system ruby-build-system)
7424 (arguments '(#:tests? #f)) ;no test suite
7425 (synopsis "Variable length integers (varint) C extension for Ruby")
7426 (description "This package provides a small C extension to speed up
7427variable length integers (varint) in Ruby Protocol Buffers.")
7428 (home-page "https://github.com/liquidm/varint")
7429 (license license:bsd-3)))
7430
1b214174
MC
7431(define-public ruby-ruby-prof
7432 (package
7433 (name "ruby-ruby-prof")
7434 (version "1.4.1")
7435 (source
7436 (origin
7437 (method url-fetch)
7438 (uri (rubygems-uri "ruby-prof" version))
7439 (sha256
7440 (base32
7441 "12cd91m08ih0imfpy4k87618hd4mhyz291a6bx2hcskza4nf6d27"))))
7442 (build-system ruby-build-system)
7443 (arguments
7444 `(#:phases
7445 (modify-phases %standard-phases
7446 (add-after 'unpack 'patch-rakefile
7447 ;; This fixes the following error: "NameError: uninitialized
7448 ;; constant Bundler::GemHelper" (see:
7449 ;; https://github.com/ruby-prof/ruby-prof/issues/274).
7450 (lambda _
7451 (substitute* "Rakefile"
7452 ((".*require \"bundler/setup\".*" all)
7453 (string-append all " require 'bundler/gem_tasks'\n")))
7454 #t))
661ad8d7
MC
7455 ;; The LineNumbersTest test fails non-deterministically (see:
7456 ;; https://github.com/ruby-prof/ruby-prof/issues/276).
7457 (add-after 'extract-gemspec 'delete-flaky-test
7458 (lambda _
7459 (delete-file "test/line_number_test.rb")
7460 (substitute* "ruby-prof.gemspec"
7461 (("\"test/line_number_test\\.rb\"\\.freeze, ") ""))
7462 #t))
1b214174
MC
7463 (add-before 'check 'compile
7464 (lambda _
7465 (invoke "rake" "compile"))))))
7466 (native-inputs
7467 `(("bundler" ,bundler)
7468 ("ruby-minitest" ,ruby-minitest)
7469 ("ruby-rake-compiler" ,ruby-rake-compiler)
7470 ("ruby-rdoc" ,ruby-rdoc)))
7471 (synopsis "Fast code profiler for Ruby")
7472 (description "RubyProf is a fast code profiler for Ruby. Its features
7473include:
7474@table @asis
7475@item Speed
7476Being a C extension, it is many times faster than the standard Ruby profiler.
7477@item Measurement Modes
7478It can measure program wall time, process time, object allocations and memory
7479usage.
7480@item Reports
7481A variety of text and cross-referenced HTML reports can be generated.
7482@item Threads
7483Profiling multiple threads simultaneously is supported.
7484@end table")
7485 (home-page "https://github.com/ruby-prof/ruby-prof")
7486 (license license:bsd-2)))
7487
dff5392f
MC
7488(define-public ruby-cucumber-messages
7489 (package
7490 (name "ruby-cucumber-messages")
7491 (version "12.2.0")
7492 (source (origin
7493 (method git-fetch)
7494 (uri (git-reference
b0e7b699 7495 (url "https://github.com/cucumber/messages-ruby")
dff5392f
MC
7496 (commit "12cd07eac87bce7843fd1bb0bf64bc4da09f097c")))
7497 (file-name (git-file-name name version))
7498 (sha256
7499 (base32
7500 "16wwqfpsq7crvxc3q08lphgyh12cl2d83p1c79p312q4jmy9cn5a"))))
7501 (build-system ruby-build-system)
7502 (arguments
7503 `(#:phases (modify-phases %standard-phases
7504 (add-after 'unpack 'patch-protobuf.rb
7505 (lambda _
7506 (substitute* "rake/protobuf.rb"
7507 (("load 'protobuf/tasks/compile.rake'")
7508 "require 'protobuf/tasks'"))
7509 #t))
7510 (add-before 'build 'compile
7511 (lambda _
7512 (substitute* "Makefile"
7513 (("bundle exec ") "")
7514 (("include default.mk.*" all)
7515 (string-append "#" all)))
7516 (invoke "make")))
7517 (replace 'check
7518 (lambda _
7519 (invoke "rspec"))))))
7520 (propagated-inputs
7521 `(("ruby-protobuf" ,ruby-protobuf-cucumber)))
7522 (native-inputs
7523 `(("ruby-rspec" ,ruby-rspec)))
7524 (home-page "https://github.com/cucumber/messages-ruby")
7525 (synopsis "Cucumber Messages for Ruby (Protocol Buffers)")
7526 (description "Cucumber Messages for Ruby is a library which allows
7527serialization and deserialization of the protocol buffer messages used in
7528Cucumber.")
7529 (license license:expat)))
7530
44514637 7531(define-public ruby-gherkin
62e4cc5a 7532 (package
44514637 7533 (name "ruby-gherkin")
cfef316f
MC
7534 (version "14.0.1")
7535 (source (origin
7536 (method git-fetch)
7537 (uri (git-reference
7538 (url "https://github.com/cucumber/gherkin-ruby")
7539 (commit (string-append "v" version))))
7540 (file-name (git-file-name name version))
7541 (sha256
7542 (base32
7543 "1dwa8632nc6kijv8p257jl64rsjmc0fimlaqvxlkdi2h9n1nympb"))))
62e4cc5a
PP
7544 (build-system ruby-build-system)
7545 (native-inputs
cfef316f
MC
7546 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
7547 ("ruby-rspec" ,ruby-rspec)))
62e4cc5a 7548 (arguments
cfef316f 7549 `(#:test-target "spec"))
62e4cc5a 7550 (synopsis "Gherkin parser for Ruby")
44514637 7551 (description "Gherkin is a parser and compiler for the Gherkin language.
aada5f6f
CB
7552It is intended be used by all Cucumber implementations to parse
7553@file{.feature} files.")
cfef316f 7554 (home-page "https://github.com/cucumber/gherkin-ruby")
62e4cc5a 7555 (license license:expat)))
cd89fecb 7556
8f85018d
MB
7557(define-public ruby-gherkin-ruby
7558 (package
7559 (name "ruby-gherkin-ruby")
7560 (version "0.3.2")
702a1012 7561 (home-page "https://github.com/codegram/gherkin-ruby")
8f85018d
MB
7562 (source (origin
7563 (method url-fetch)
7564 (uri (rubygems-uri "gherkin-ruby" version))
7565 (sha256
7566 (base32
7567 "18ay7yiibf4sl9n94k7mbi4k5zj2igl4j71qcmkswv69znyx0sn1"))))
7568 (build-system ruby-build-system)
7569 (synopsis "Pure Ruby Gherkin parser")
7570 (description
7571 "Gherkin-ruby is a Gherkin parser written in pure Ruby and less than
7572200 lines of code.")
7573 ;; XXX: No license information anywhere but Readme.md.
7574 (license license:expat)))
7575
15b16c2c
CB
7576(define-public ruby-aruba
7577 (package
7578 (name "ruby-aruba")
cf7201c4 7579 (version "0.14.14")
15b16c2c
CB
7580 (source
7581 (origin
7582 (method url-fetch)
7583 (uri (rubygems-uri "aruba" version))
7584 (sha256
7585 (base32
cf7201c4 7586 "0l2mfpdxc03gdrbwc2hv4vdhjhqhfcdp6d02j05j64ncpi9srlqn"))))
15b16c2c
CB
7587 (build-system ruby-build-system)
7588 (arguments
7589 '(#:test-target "spec"
7590 #:phases
7591 (modify-phases %standard-phases
7592 (add-after 'unpack 'patch
7593 (lambda _
7594 (substitute* "spec/aruba/api_spec.rb"
7595 ;; This resolves some errors in the specs
7596 ;;
7597 ;; undefined method `parse' for Time:Class
7598 (("require 'spec_helper'")
7599 "require 'spec_helper'\nrequire 'time'"))
7600 ;; Avoid shebang issues in this spec file
7601 (substitute* "spec/aruba/matchers/command_spec.rb"
7602 (("/usr/bin/env bash")
7603 (which "bash")))
7604 #t))
7605 (add-before 'check 'remove-unnecessary-dependencies
7606 (lambda _
7607 (substitute* "Gemfile"
7608 ((".*byebug.*") "\n")
7609 ((".*pry.*") "\n")
7610 ((".*yaml.*") "\n")
7611 ((".*bcat.*") "\n")
7612 ((".*kramdown.*") "\n")
7613 ((".*rubocop.*") "\n")
7614 ((".*cucumber-pro.*") "\n")
7615 ((".*cucumber.*") "\n")
7616 ((".*license_finder.*") "\n")
7617 ((".*rake.*") "gem 'rake'\n")
15b16c2c 7618 ((".*relish.*") "\n"))
15b16c2c
CB
7619 (substitute* "aruba.gemspec"
7620 (("spec\\.add\\_runtime\\_dependency 'cucumber'.*")
7621 "spec.add_runtime_dependency 'cucumber'"))
7622 #t))
7623 (add-before 'check 'set-home
7624 (lambda _ (setenv "HOME" "/tmp") #t)))))
7625 (native-inputs
7626 `(("bundler" ,bundler)
7627 ("ruby-rspec" ,ruby-rspec)
cf7201c4
CB
7628 ("ruby-fuubar" ,ruby-fuubar)
7629 ("ruby-simplecov" ,ruby-simplecov)))
15b16c2c
CB
7630 (propagated-inputs
7631 `(("ruby-childprocess" ,ruby-childprocess)
7632 ("ruby-contracts" ,ruby-contracts)
7633 ("ruby-cucumber" ,ruby-cucumber)
7634 ("ruby-ffi" ,ruby-ffi)
7635 ("ruby-rspec-expectations" ,ruby-rspec-expectations)
7636 ("ruby-thor" ,ruby-thor)
7637 ("ruby-yard" ,ruby-yard)))
7638 (synopsis "Test command-line applications with Cucumber, RSpec or Minitest")
7639 (description
7640 "Aruba is an extension for Cucumber, RSpec and Minitest for testing
7641command-line applications. It supports applications written in any
7642language.")
7643 (home-page "https://github.com/cucumber/aruba")
7644 (license license:expat)))
7645
7646;; A version of ruby-aruba without tests run so that circular dependencies can
7647;; be avoided.
7648(define ruby-aruba-without-tests
7649 (package
7650 (inherit ruby-aruba)
7651 (arguments '(#:tests? #f))
7652 (propagated-inputs
7653 `(("ruby-cucumber" ,ruby-cucumber-without-tests)
7654 ,@(alist-delete "ruby-cucumber"
7655 (package-propagated-inputs ruby-aruba))))
7656 (native-inputs '())))
7657
fd6577b4
MC
7658(define-public ruby-sys-uname
7659 (package
7660 (name "ruby-sys-uname")
7661 (version "1.2.1")
7662 (source
7663 (origin
7664 (method url-fetch)
7665 (uri (rubygems-uri "sys-uname" version))
7666 (sha256
7667 (base32
7668 "00p3wwvkdbg6pl38bchaagncv3i4fq4y0ks470imwykjanpy2ic0"))))
7669 (build-system ruby-build-system)
7670 (arguments
7671 `(#:test-target "spec"))
7672 (propagated-inputs `(("ruby-ffi" ,ruby-ffi)))
7673 (native-inputs `(("ruby-rspec" ,ruby-rspec)))
7674 (synopsis "Ruby interface for gathering system information")
7675 (description "The sys-uname library provides an interface for gathering
7676information about your current platform. It allows retrieving information
7677such as the OS name, OS version, system name, etc.")
7678 (home-page "https://github.com/djberg96/sys-uname")
7679 (license license:asl2.0)))
7680
ac3ec612
MC
7681(define-public ruby-cucumber-create-meta
7682 (package
7683 (name "ruby-cucumber-create-meta")
7684 (version "1.0.0")
7685 (source
7686 (origin
7687 (method url-fetch)
7688 (uri (rubygems-uri "cucumber-create-meta" version))
7689 (sha256
7690 (base32
7691 "0i0i3arymjrnjk72mg79w1a11607x4d0lrqafm9sz2gq9l52zasw"))))
7692 (build-system ruby-build-system)
7693 (arguments
7694 `(#:phases (modify-phases %standard-phases
7695 (add-after 'extract-gemspec 'relax-version-requirements
7696 (lambda _
7697 (substitute* ".gemspec"
7698 ((" 12\\.2")
7699 " 12.1"))
7700 #t))
7701 (replace 'check
7702 (lambda _
7703 (invoke "rspec"))))))
7704 (native-inputs
7705 `(("ruby-rspec" ,ruby-rspec)))
7706 (propagated-inputs
7707 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
7708 ("ruby-sys-uname" ,ruby-sys-uname)))
7709 (synopsis "Function to create @code{Meta} messages for Cucumber Ruby")
7710 (description "The @code{createMeta} utility function allows generating
7711system-specific @code{Meta} messages for Cucumber Ruby.")
7712 (home-page "https://github.com/cucumber/cucumber/tree/master/create-meta/ruby")
7713 (license license:expat)))
7714
f3574624
MC
7715(define-public ruby-cucumber-html-formatter
7716 (package
7717 (name "ruby-cucumber-html-formatter")
7718 (version "7.0.0")
7719 (source
7720 (origin
7721 (method url-fetch)
7722 (uri (rubygems-uri "cucumber-html-formatter" version))
7723 (sha256
7724 (base32
7725 "0lshj4sw9jw7687wrhknyb9kffblai3l843zgrznyqij3ga0bc62"))))
7726 (build-system ruby-build-system)
7727 (arguments
7728 `(#:phases (modify-phases %standard-phases
7729 (replace 'check
7730 (lambda _
7731 (invoke "rspec"))))))
7732 (native-inputs
7733 `(("ruby-rspec" ,ruby-rspec)))
7734 (propagated-inputs
7735 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)))
7736 (synopsis "HTML formatter for Cucumber")
7737 (description "Cucumber HTML Formatter produces a HTML report for Cucumber
7738runs. It is built on top of cucumber-react and works with any Cucumber
7739implementation with a protocol buffer formatter that outputs Cucumber
7740messages.")
7741 (home-page "https://github.com/cucumber/cucumber/tree/\
7742master/html-formatter/ruby")
7743 (license license:expat)))
7744
15b16c2c
CB
7745(define-public ruby-cucumber
7746 (package
7747 (name "ruby-cucumber")
92ebbaad 7748 (version "4.1.0")
15b16c2c
CB
7749 (source
7750 (origin
7751 (method git-fetch)
7752 (uri (git-reference
b0e7b699 7753 (url "https://github.com/cucumber/cucumber-ruby")
15b16c2c
CB
7754 (commit (string-append "v" version))))
7755 (file-name (git-file-name name version))
7756 (sha256
7757 (base32
92ebbaad 7758 "0g9rqfslbzkkrq2kvl14fgknrhfbji3bjjpjxff5nc9wzd3hd549"))))
15b16c2c
CB
7759 (build-system ruby-build-system)
7760 (arguments
fa8e4dbf 7761 '(#:test-target "default"
15b16c2c
CB
7762 #:phases
7763 (modify-phases %standard-phases
fa8e4dbf
MC
7764 (add-after 'unpack 'disable-rubocop
7765 ;; Rubocop lint check fails with our more recent version.
7766 (lambda _
7767 (substitute* "Rakefile"
7768 (("spec cucumber rubocop")
7769 "spec cucumber"))
7770 #t))
92ebbaad 7771 (add-after 'extract-gemspec 'strip-version-requirements
15b16c2c 7772 (lambda _
fa8e4dbf 7773 (delete-file "Gemfile") ;do not use Bundler
92ebbaad
MC
7774 (substitute* "cucumber.gemspec"
7775 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
7776 (string-append stripped "\n")))
fa8e4dbf
MC
7777 #t))
7778 (add-before 'check 'set-home
7779 (lambda _
7780 (setenv "HOME" (getcwd))
15b16c2c
CB
7781 #t)))))
7782 (propagated-inputs
7783 `(("ruby-builder" ,ruby-builder)
7784 ("ruby-cucumber-core" ,ruby-cucumber-core)
92ebbaad
MC
7785 ("ruby-cucumber-create-meta" ,ruby-cucumber-create-meta)
7786 ("ruby-cucumber-html-formatter" ,ruby-cucumber-html-formatter)
7787 ("ruby-cucumber-messages" ,ruby-cucumber-messages)
15b16c2c 7788 ("ruby-cucumber-wire" ,ruby-cucumber-wire)
15b16c2c
CB
7789 ("ruby-diff-lcs" ,ruby-diff-lcs)
7790 ("ruby-gherkin" ,ruby-gherkin)
7791 ("ruby-multi-json" ,ruby-multi-json)
7792 ("ruby-multi-test" ,ruby-multi-test)))
7793 (native-inputs
92ebbaad 7794 `(;; Use a untested version of aruba, to avoid a circular dependency, as
15b16c2c
CB
7795 ;; ruby-aruba depends on ruby-cucumber.
7796 ("ruby-aruba", ruby-aruba-without-tests)
7797 ("ruby-rspec" ,ruby-rspec)
7798 ("ruby-pry" ,ruby-pry)
92ebbaad
MC
7799 ("ruby-nokogiri" ,ruby-nokogiri)
7800 ("ruby-rubocop" ,ruby-rubocop)))
15b16c2c 7801 (synopsis "Describe automated tests in plain language")
92ebbaad
MC
7802 (description "Cucumber is a tool for running automated tests written in
7803plain language. It's designed to support a Behaviour Driven Development (BDD)
15b16c2c
CB
7804software development workflow.")
7805 (home-page "https://cucumber.io/")
7806 (license license:expat)))
7807
7808(define ruby-cucumber-without-tests
7809 (package (inherit ruby-cucumber)
7810 (arguments
7811 '(#:tests? #f))
7812 (native-inputs
7813 '())))
7814
f048ef52
MC
7815(define-public ruby-coveralls
7816 (package
7817 (name "ruby-coveralls")
7818 (version "0.8.23")
7819 (source
7820 (origin
7821 (method url-fetch)
7822 (uri (rubygems-uri "coveralls" version))
7823 (sha256
7824 (base32
7825 "1mv4fn5lfxhy7bc2f1lpnc5yp9mvv97az77j4r7jgrxcqwn8fqxc"))))
7826 (build-system ruby-build-system)
7827 ;; The test suite depends on ruby-vcr, which cannot be included in Guix
fe9993b1
MC
7828 ;; because of its nonfree, Hippocratic-derived license.
7829 (arguments
7830 `(#:tests? #f
7831 #:phases (modify-phases %standard-phases
7832 (add-after 'extract-gemspec 'strip-version-requirements
7833 ;; Keeping strict version requirements can cause problems
7834 ;; to users of the library, such as: Gem::ConflictError:
7835 ;; Unable to activate coveralls-0.8.23, because
7836 ;; simplecov-0.17.1 conflicts with simplecov (~> 0.16.1).
7837 (lambda _
7838 (substitute* "coveralls-ruby.gemspec"
7839 (("(.*add_.*dependency\\([^,]+), .*" _ stripped)
7840 (string-append stripped ")\n")))
7841 #t)))))
f048ef52
MC
7842 (propagated-inputs
7843 `(("ruby-json" ,ruby-json)
7844 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
7845 ("ruby-thor" ,ruby-thor)
7846 ("ruby-tins" ,ruby-tins)))
7847 (synopsis "Ruby implementation of the Coveralls API")
7848 (description "This package provides a Ruby implementation of the Coveralls
7849API.")
7850 (home-page "https://coveralls.io")
7851 (license license:expat)))
f2a1b7fa
MC
7852
7853(define-public ruby-unindent
7854 (package
7855 (name "ruby-unindent")
7856 (version "1.0")
7857 (source
7858 (origin
7859 (method url-fetch)
7860 (uri (rubygems-uri "unindent" version))
7861 (sha256
7862 (base32
7863 "1wqh3rzv8589yzibigminxx3qpmj2nqj28f90xy1sczk1pijmcrd"))))
7864 (build-system ruby-build-system)
7865 (synopsis "Ruby method to unindent strings")
7866 (description "This module provides a @code{String#unindent} Ruby method to
7867unindent strings, which can be useful to unindent multiline strings embedded
7868in already-indented code.")
7869 (home-page "https://github.com/mynyml/unindent")
7870 (license license:expat)))
f048ef52 7871
cd89fecb
PP
7872(define-public ruby-cucumber-core
7873 (package
7874 (name "ruby-cucumber-core")
95a5d992 7875 (version "7.1.0")
cd89fecb
PP
7876 (source
7877 (origin
95a5d992
MC
7878 (method git-fetch)
7879 (uri (git-reference
b0e7b699 7880 (url "https://github.com/cucumber/cucumber-ruby-core")
95a5d992
MC
7881 (commit (string-append "v" version))))
7882 (file-name (git-file-name name version))
cd89fecb
PP
7883 (sha256
7884 (base32
95a5d992 7885 "1p5wb6wbggbw37ariyag4kxpiczznvgm3c8cnz1744dmbj79q1rn"))))
cd89fecb 7886 (build-system ruby-build-system)
95a5d992
MC
7887 (arguments
7888 `(#:test-target "spec"
7889 #:phases
7890 (modify-phases %standard-phases
7891 (add-after 'extract-gemspec 'relax-version-requirements
7892 (lambda _
7893 (substitute* "cucumber-core.gemspec"
7894 (("'cucumber-tag-expressions',.*")
7895 "'cucumber-tag-expressions', '>=2.0.0'\n"))
7896 #t)))))
7897 (native-inputs
7898 `(("ruby-rspec" ,ruby-rspec)
7899 ("ruby-coveralls" ,ruby-coveralls)
7900 ("ruby-rubocop" ,ruby-rubocop)
7901 ("ruby-simplecov" ,ruby-simplecov)
7902 ("ruby-unindent" ,ruby-unindent)))
cd89fecb 7903 (propagated-inputs
95a5d992 7904 `(("ruby-cucumber-messages" ,ruby-cucumber-messages)
5cd047e8
CB
7905 ("ruby-gherkin" ,ruby-gherkin)
7906 ("ruby-cucumber-tag-expressions" ,ruby-cucumber-tag-expressions)))
cd89fecb
PP
7907 (synopsis "Core library for the Cucumber BDD app")
7908 (description "Cucumber is a tool for running automated tests
7909written in plain language. Because they're written in plain language,
7910they can be read by anyone on your team. Because they can be read by
7911anyone, you can use them to help improve communication, collaboration
7912and trust on your team.")
7913 (home-page "https://cucumber.io/")
7914 (license license:expat)))
212d563d 7915
fb1a8954
CB
7916(define-public ruby-cucumber-expressions
7917 (package
7918 (name "ruby-cucumber-expressions")
4ada4a42 7919 (version "10.2.0")
fb1a8954
CB
7920 (source
7921 (origin
4ada4a42
MC
7922 (method git-fetch)
7923 (uri (git-reference
b0e7b699 7924 (url "https://github.com/cucumber/cucumber-expressions-ruby")
4ada4a42
MC
7925 (commit (string-append "v" version))))
7926 (file-name (git-file-name name version))
fb1a8954
CB
7927 (sha256
7928 (base32
4ada4a42 7929 "1aivhcpjrmbvp9bg0y7g6zxh2swfvylvg0sapq5jc4i1y74k8npd"))))
fb1a8954
CB
7930 (build-system ruby-build-system)
7931 (arguments
7932 '(#:test-target "spec"))
7933 (native-inputs
4ada4a42 7934 `(("ruby-rspec" ,ruby-rspec)
fb1a8954
CB
7935 ("ruby-simplecov" ,ruby-simplecov)))
7936 (synopsis "Simpler alternative to Regular Expressions")
7937 (description "Cucumber Expressions offer similar functionality to Regular
7938Expressions, with a syntax that is easier to read and write. Cucumber
7939Expressions are extensible with parameter types.")
7940 (home-page "https://github.com/cucumber/cucumber-expressions-ruby")
7941 (license license:expat)))
7942
ce872770
CB
7943(define-public ruby-cucumber-wire
7944 (package
7945 (name "ruby-cucumber-wire")
6516827e 7946 (version "3.1.0")
ce872770
CB
7947 (source
7948 (origin
7949 (method url-fetch)
7950 (uri (rubygems-uri "cucumber-wire" version))
7951 (sha256
7952 (base32
6516827e 7953 "0z1n13lqv70zb2lcrvs2263lm0gsb3gz8gbv890kxzwp8cvd433k"))))
ce872770
CB
7954 (build-system ruby-build-system)
7955 (arguments
6516827e 7956 '(#:tests? #f ;tests use cucumber, causing a cycle
ce872770
CB
7957 #:phases
7958 (modify-phases %standard-phases
6516827e 7959 (add-after 'extract-gemspec 'relax-version-requirements
ce872770 7960 (lambda _
6516827e
MC
7961 (substitute* ".gemspec"
7962 ((" 10\\.1") " 10.2"))
ce872770 7963 #t)))))
6516827e
MC
7964 (propagated-inputs
7965 `(("ruby-cucumber-core" ,ruby-cucumber-core)
7966 ("ruby-cucumber-expressions" ,ruby-cucumber-expressions)
7967 ("ruby-cucumber-messages" ,ruby-cucumber-messages)))
ce872770 7968 (synopsis "Cucumber wire protocol plugin")
6516827e
MC
7969 (description "Cucumber's wire protocol allows step definitions to be
7970implemented and invoked on any platform.")
ce872770
CB
7971 (home-page "https://github.com/cucumber/cucumber-ruby-wire")
7972 (license license:expat)))
7973
0ce8f344
CB
7974(define-public ruby-cucumber-tag-expressions
7975 (package
7976 (name "ruby-cucumber-tag-expressions")
0d2c45ce 7977 (version "3.0.0")
0ce8f344
CB
7978 (source
7979 (origin
0d2c45ce
MC
7980 (method git-fetch)
7981 (uri (git-reference
b0e7b699 7982 (url "https://github.com/cucumber/tag-expressions-ruby")
0d2c45ce
MC
7983 (commit (string-append "v" version))))
7984 (file-name (git-file-name name version))
0ce8f344
CB
7985 (sha256
7986 (base32
0d2c45ce 7987 "15dw4w0npd4m6aw7zhqkjxxzngp42kswrkwfygxkxcxnhy5zl1vx"))))
0ce8f344
CB
7988 (build-system ruby-build-system)
7989 (arguments
0d2c45ce 7990 `(#:test-target "spec"))
0ce8f344
CB
7991 (native-inputs
7992 `(("ruby-rspec" ,ruby-rspec)))
7993 (synopsis "Cucumber tag expressions for Ruby")
0d2c45ce
MC
7994 (description "Cucumber tag expression parser for Ruby. A tag expression
7995is an infix boolean expression used by Cucumber.")
0ce8f344
CB
7996 (home-page "https://github.com/cucumber/tag-expressions-ruby")
7997 (license license:expat)))
7998
73a5aff7
CB
7999(define-public ruby-bindex
8000 (package
8001 (name "ruby-bindex")
8002 (version "0.5.0")
8003 (source
8004 (origin
8005 (method url-fetch)
8006 (uri (rubygems-uri "bindex" version))
8007 (sha256
8008 (base32
8009 "1wvhf4v8sk5x8li03pcc0v0wglmyv7ikvvg05bnms83dfy7s4k8i"))))
8010 (build-system ruby-build-system)
8011 (arguments
8012 '(#:test-target "default"))
8013 (native-inputs
8014 `(("bundler" ,bundler)
8015 ("ruby-rake-compiler" ,ruby-rake-compiler)))
8016 (synopsis "Provides access for bindings relating to Ruby exceptions")
8017 (description
8018 "@code{bindex} provides a way to access the bindings that relate to
8019exceptions in Ruby, providing more information about the context in which the
8020exception occurred.")
8021 (home-page "https://github.com/gsamokovarov/bindex")
8022 (license license:expat)))
8023
212d563d
PP
8024(define-public ruby-bio-logger
8025 (package
8026 (name "ruby-bio-logger")
8027 (version "1.0.1")
8028 (source
8029 (origin
8030 (method url-fetch)
8031 (uri (rubygems-uri "bio-logger" version))
8032 (sha256
8033 (base32
8034 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
8035 (build-system ruby-build-system)
8036 (arguments
8037 `(#:tests? #f)) ; rake errors, missing shoulda
8038 (propagated-inputs
8039 `(("ruby-log4r" ,ruby-log4r)))
8040 (synopsis "Log4r wrapper for Ruby")
8041 (description "Bio-logger is a wrapper around Log4r adding extra logging
8042features such as filtering and fine grained logging.")
8043 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
8044 (license license:expat)))
07f61cb2 8045
2db0f9c8
BW
8046(define-public ruby-yajl-ruby
8047 (package
8048 (name "ruby-yajl-ruby")
8049 (version "1.4.1")
8050 (source
8051 (origin
8052 (method url-fetch)
8053 (uri (rubygems-uri "yajl-ruby" version))
8054 (sha256
8055 (base32
8056 "16v0w5749qjp13xhjgr2gcsvjv6mf35br7iqwycix1n2h7kfcckf"))))
8057 (build-system ruby-build-system)
8058 (arguments
8059 '(#:test-target "spec"
8060 #:phases
8061 (modify-phases %standard-phases
8062 (add-before 'check 'patch-test-to-update-load-path
8063 (lambda _
8064 (substitute* "spec/parsing/large_number_spec.rb"
8065 (("require \"yajl\"")
8066 "$LOAD_PATH << 'lib'; require 'yajl'"))
8067 #t)))))
8068 (native-inputs
8069 `(("ruby-rake-compiler" ,ruby-rake-compiler)
8070 ("ruby-rspec" ,ruby-rspec)))
8071 (synopsis "Streaming JSON parsing and encoding library for Ruby")
8072 (description
8073 "Ruby C bindings to the Yajl JSON stream-based parser library. The API
8074is compatible with the JSON gem, so yajl-ruby can act as a drop in
8075replacement.
8076
8077A modified copy of yajl is used, and included in the package.")
8078 (home-page "https://github.com/brianmario/yajl-ruby")
8079 (license (list license:expat ; Ruby code, yajl_ext.c and yajl_ext.h
8080 license:bsd-3)))) ; Included, modified copy of yajl
8081
07f61cb2 8082(define-public ruby-yard
6499893e
BW
8083 (package
8084 (name "ruby-yard")
7eb8ff0b 8085 (version "0.9.25")
6499893e
BW
8086 (source
8087 (origin
f3fd70c0 8088 (method git-fetch)
6499893e 8089 ;; Tests do not pass if we build from the distributed gem.
f3fd70c0 8090 (uri (git-reference
65a61239
MC
8091 (url "https://github.com/lsegal/yard")
8092 (commit (string-append "v" version))))
f3fd70c0 8093 (file-name (git-file-name name version))
6499893e
BW
8094 (sha256
8095 (base32
7eb8ff0b 8096 "1x7y4s557hrnq439lih7nqg1y7ximardw75jx9i92x3yzpviqqwa"))))
6499893e
BW
8097 (build-system ruby-build-system)
8098 (arguments
65a61239
MC
8099 ;; Note: Tests are willfully disabled to alleviate dependency cycle
8100 ;; problems.
8101 `(#:tests? #f))
6499893e 8102 (synopsis "Documentation generation tool for Ruby")
65a61239
MC
8103 (description "YARD is a documentation generation tool for the Ruby
8104programming language. It enables the user to generate consistent, usable
8105documentation that can be exported to a number of formats very easily, and
8106also supports extending for custom Ruby constructs such as custom class level
8107definitions.")
2f3800e5 8108 (home-page "https://yardoc.org")
6499893e 8109 (license license:expat)))
2cbcd23a 8110
df32ab11
MC
8111(define-public ruby-yard-with-tests
8112 (package
8113 (inherit ruby-yard)
8114 (name "ruby-yard-with-tests")
8115 (arguments
8116 (substitute-keyword-arguments (package-arguments ruby-yard)
8117 ((#:tests? _ #t) #t)
8118 ((#:test-target _ "default") "default")
8119 ((#:phases phases '%standard-phases)
8120 `(modify-phases ,phases
8121 (add-before 'check 'prepare-for-tests
8122 (lambda* (#:key tests? #:allow-other-keys)
8123 (when tests?
8124 (substitute* "Rakefile"
8125 ((".*[Ss]amus.*") ""))
8126 ;; Delete the Gemfile to avoid errors relating to it.
8127 (delete-file "Gemfile")
8128 ;; $HOME needs to be set to somewhere writeable for tests to
8129 ;; run.
8130 (setenv "HOME" "/tmp"))
8131 #t))))))
8132 (native-inputs
8133 `(("ruby-rspec" ,ruby-rspec)
8134 ("ruby-rack" ,ruby-rack)
8135 ("ruby-redcloth" ,ruby-redcloth)
8136 ("ruby-asciidoc" ,ruby-asciidoctor)))))
8137
908df675
MC
8138(define-public ruby-spectroscope
8139 (package
8140 (name "ruby-spectroscope")
8141 (version "0.1.0")
8142 (source
8143 (origin
8144 (method url-fetch)
8145 (uri (rubygems-uri "spectroscope" version))
8146 (sha256
8147 (base32
8148 "0iiid9sm110qhx0i1zkds710cvsnmhd308wbqa7slkzbq2akrb3y"))))
8149 (build-system ruby-build-system)
8150 (arguments
8151 `(#:phases
8152 (modify-phases %standard-phases
8153 (replace 'check
8154 (lambda _
8155 (with-output-to-file ".test"
8156 (lambda _
8157 (display
8158 "\
8159require 'ae/should'
8160require 'rspec'
8161
8162include RSpec
8163
8164Test.run :default do |run|
8165 run.files << 'spec/*_spec.rb'
8166end")))
8167 (invoke "ruby" "-Ilib" "-rrubytest" ".test"))))))
8168 (native-inputs
8169 `(("ruby-ae" ,ruby-ae)
8170 ("ruby-rspec" ,ruby-rspec)))
8171 (propagated-inputs
8172 `(("ruby-rubytest" ,ruby-rubytest)))
8173 (synopsis "Behavior-Driven Development (BDD) framework built on RubyTest")
8174 (description "Spectroscope is a Behavior-Driven Development (BDD)
8175framework built on RubyTest, designed to emulate RSpec in most respects. It
8176is assertion framework independent so any number of assertion systems can be
8177used, such as Assay or AE.")
8178 (home-page "http://rubyworks.github.com/spectroscope/")
8179 (license license:bsd-2)))
8180
24ffd91b
MC
8181(define-public ruby-tomparse
8182 (package
8183 (name "ruby-tomparse")
8184 (version "0.4.2")
8185 (source
8186 (origin
8187 (method url-fetch)
8188 (uri (rubygems-uri "tomparse" version))
8189 (sha256
8190 (base32
8191 "06xakk41f1kgj6j1ahkwn4r6cvidixvm4phhlrvmwb7c3pr8ygc8"))))
8192 (build-system ruby-build-system)
8193 ;; TODO: Tests require citron and rulebow, not yet packaged.
8194 (arguments '(#:tests? #f))
8195 (synopsis "TomDoc parser for Ruby")
8196 (description "TomParse is a TomDoc parser for Ruby. It takes a code
8197comment as input and parses it into a convenient object-oriented structure in
8198accordance with the TomDoc standard. See
8199@url{https://github.com/mojombo/tomdoc, TomDoc} for more information about the
8200TomDoc format.")
8201 (home-page "http://rubyworks.github.com/tomparse/")
8202 (license license:bsd-2)))
8203
257dee50
MC
8204(define-public ruby-yard-tomdoc
8205 (package
8206 (name "ruby-yard-tomdoc")
8207 (version "0.7.1")
8208 (source
8209 (origin
8210 (method url-fetch)
8211 (uri (rubygems-uri "yard-tomdoc" version))
8212 (sha256
8213 (base32
8214 "1725gs8b8klpwhrvnf2wwp7dw3zxs9vz2la983l2d8c4r4fn1j2z"))))
8215 (build-system ruby-build-system)
8216 (arguments
8217 `(#:phases (modify-phases %standard-phases
8218 (replace 'check
8219 (lambda _
8220 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
8221 (native-inputs
8222 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
8223 ("ruby-spectroscope" ,ruby-spectroscope)
8224 ("ruby-ae" ,ruby-ae)))
8225 (propagated-inputs
8226 `(("ruby-tomparse" ,ruby-tomparse)
8227 ("ruby-yard" ,ruby-yard)))
8228 (synopsis "TomDoc syntax for YARD")
8229 (description "This module adds support for the TomDoc documentation format
8230to YARD, a documentation generation tool for Ruby.")
8231 (home-page "http://rubyworks.github.com/yard-tomdoc/")
8232 (license license:expat)))
8233
ad686ef3
RW
8234(define-public ruby-clap
8235 (package
8236 (name "ruby-clap")
8237 (version "1.0.0")
8238 (source (origin
8239 (method url-fetch)
8240 (uri (rubygems-uri "clap" version))
8241 (sha256
8242 (base32
8243 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
8244 (build-system ruby-build-system)
8245 ;; Clap needs cutest for running tests, but cutest needs clap.
8246 (arguments `(#:tests? #f))
8247 (synopsis "Command line argument parsing for simple applications")
8248 (description
8249 "Clap provides command line argument parsing features. It covers the
8250simple case of executing code based on the flags or parameters passed.")
8251 (home-page "https://github.com/djanowski/cutest")
0c80451e
RW
8252 (license license:expat)))
8253
8254(define-public ruby-cutest
8255 (package
8256 (name "ruby-cutest")
8257 (version "1.2.2")
8258 (source (origin
8259 (method url-fetch)
8260 (uri (rubygems-uri "cutest" version))
8261 (sha256
8262 (base32
8263 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
8264 (build-system ruby-build-system)
8265 (propagated-inputs
8266 `(("ruby-clap" ,ruby-clap)))
8267 (synopsis "Run tests in separate processes")
8268 (description
8269 "Cutest runs tests in separate processes to avoid shared state.")
8270 (home-page "https://github.com/djanowski/cutest")
ad686ef3
RW
8271 (license license:expat)))
8272
ac09beba
RW
8273(define-public ruby-pygmentize
8274 (package
8275 (name "ruby-pygmentize")
8276 (version "0.0.3")
8277 (source (origin
8278 (method url-fetch)
8279 (uri (rubygems-uri "pygmentize" version))
8280 (sha256
8281 (base32
8282 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
8283 (build-system ruby-build-system)
8284 (arguments
8285 `(#:phases
8286 (modify-phases %standard-phases
8287 (add-after 'unpack 'fix-pygmentize-path
8288 (lambda _
8289 (substitute* "lib/pygmentize.rb"
8290 (("\"/usr/bin/env python.*")
8291 (string-append "\"" (which "pygmentize") "\"\n")))
8292 #t))
8293 (add-after 'build 'do-not-use-vendor-directory
8294 (lambda _
8295 ;; Remove bundled pygments sources
8296 ;; FIXME: ruby-build-system does not support snippets.
8297 (delete-file-recursively "vendor")
8298 (substitute* "pygmentize.gemspec"
8299 (("\"vendor/\\*\\*/\\*\",") ""))
8300 #t)))))
8301 (inputs
8302 `(("pygments" ,python-pygments)))
8303 (native-inputs
8304 `(("ruby-cutest" ,ruby-cutest)
8305 ("ruby-nokogiri" ,ruby-nokogiri)))
8306 (synopsis "Thin Ruby wrapper around pygmentize")
8307 (description
8308 "Pygmentize provides a simple way to call pygmentize from within a Ruby
8309application.")
8310 (home-page "https://github.com/djanowski/pygmentize")
8311 (license license:expat)))
8312
2cbcd23a
DT
8313(define-public ruby-eventmachine
8314 (package
8315 (name "ruby-eventmachine")
c207fa5e 8316 (version "1.2.7")
2cbcd23a
DT
8317 (source
8318 (origin
8319 (method url-fetch)
8320 (uri (rubygems-uri "eventmachine" version))
8321 (sha256
8322 (base32
c207fa5e 8323 "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"))))
2cbcd23a
DT
8324 (build-system ruby-build-system)
8325 (arguments
c5d269fb 8326 '(#:tests? #f)) ; test suite tries to connect to google.com
2cbcd23a
DT
8327 (native-inputs
8328 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
8329 (synopsis "Single-threaded network event framework for Ruby")
8330 (description
8331 "EventMachine implements a single-threaded engine for arbitrary network
8332communications. EventMachine wraps all interactions with sockets, allowing
8333programs to concentrate on the implementation of network protocols. It can be
8334used to create both network servers and clients.")
24a26227
TGR
8335 ;; The ‘official’ rubyeventmachine.com domain is now registrar-squatted.
8336 (home-page "https://github.com/eventmachine/eventmachine")
2cbcd23a 8337 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
7d3a1a2d 8338
e218b0c8
BW
8339(define-public ruby-ruby-engine
8340 (package
8341 (name "ruby-ruby-engine")
77d098bf 8342 (version "2.0.0")
e218b0c8
BW
8343 (source
8344 (origin
8345 (method url-fetch)
8346 (uri (rubygems-uri "ruby_engine" version))
8347 (sha256
8348 (base32
77d098bf 8349 "0wqdcv8gxybp1y7kjhh18g3r9dczacs62d4ahcvyhz32bih8c9fm"))))
e218b0c8
BW
8350 (build-system ruby-build-system)
8351 (arguments
8352 `(#:phases
8353 (modify-phases %standard-phases
77d098bf 8354 (add-after 'extract-gemspec 'clean-up
e218b0c8
BW
8355 (lambda _
8356 (delete-file "Gemfile.lock")
8357 (substitute* "ruby_engine.gemspec"
8358 ;; Remove unnecessary imports that would entail further
8359 ;; dependencies.
8360 ((".*<rdoc.*") "")
8361 ((".*<rubygems-tasks.*") "")
8362 ;; Remove extraneous .gem file
77d098bf
MC
8363 (("\"pkg/ruby_engine-[0-9.]+\\.gem\".freeze, ") "")
8364 (("\"Gemfile.lock\".freeze, ") "")
e218b0c8 8365 ;; Soften rake dependency
77d098bf 8366 (("%q<rake>.freeze, \\[\"~> 10.0\"\\]")
e218b0c8
BW
8367 "%q<rake>.freeze, [\">= 10.0\"]")
8368 ;; Soften the rspec dependency
77d098bf 8369 (("%q<rspec>.freeze, \\[\"~> 2.4\"\\]")
e218b0c8
BW
8370 "%q<rspec>.freeze, [\">= 2.4\"]"))
8371 (substitute* "Rakefile"
8372 (("require 'rubygems/tasks'") "")
8373 (("Gem::Tasks.new") ""))
8374 ;; Remove extraneous .gem file that otherwise gets installed.
77d098bf 8375 (delete-file-recursively "pkg")
e218b0c8
BW
8376 #t)))))
8377 (native-inputs
8378 `(("bundler" ,bundler)
8379 ("ruby-rake" ,ruby-rake)
8380 ("ruby-rspec" ,ruby-rspec)))
8381 (synopsis "Simplifies checking for Ruby implementation")
8382 (description
8383 "@code{ruby_engine} provides an RubyEngine class that can be used to
8384check which implementation of Ruby is in use. It can provide the interpreter
8385name and provides query methods such as @{RubyEngine.mri?}.")
8386 (home-page "https://github.com/janlelis/ruby_engine")
8387 (license license:expat)))
8388
8092e333
BW
8389(define-public ruby-turn
8390 (package
8391 (name "ruby-turn")
8392 (version "0.9.7")
8393 (source
8394 (origin
8395 (method url-fetch)
8396 (uri (rubygems-uri "turn" version))
8397 (sha256
8398 (base32
8399 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
8400 (build-system ruby-build-system)
8401 (arguments
8402 `(#:phases
8403 (modify-phases %standard-phases
8404 ;; Tests fail because turn changes its environment so can no longer
8405 ;; find test/unit. Instead simply test if the executable runs
8406 ;; without issue.
8407 (replace 'check
8408 (lambda _
9923d5a4 8409 (invoke "ruby" "-Ilib" "bin/turn" "-h"))))))
8092e333
BW
8410 (propagated-inputs
8411 `(("ruby-ansi" ,ruby-ansi)
8412 ("ruby-minitest" ,ruby-minitest-4)))
8413 (synopsis "Alternate set of alternative runners for MiniTest")
8414 (description
8415 "TURN provides a set of alternative runners for MiniTest which are both
8416colorful and informative. TURN displays each test on a separate line with
8417failures being displayed immediately instead of at the end of the tests. Note
8418that TURN is no longer being maintained.")
f433b662 8419 (home-page "https://rubygems.org/gems/turn")
8092e333
BW
8420 (license license:expat)))
8421
8279b1d3
CB
8422(define-public ruby-mimemagic
8423 (package
8424 (name "ruby-mimemagic")
60bc8952 8425 (version "0.3.3")
8279b1d3
CB
8426 (source
8427 (origin
8428 (method url-fetch)
8429 (uri (rubygems-uri "mimemagic" version))
8430 (sha256
60bc8952 8431 (base32 "04cp5sfbh1qx82yqxn0q75c7hlcx8y1dr5g3kyzwm4mx6wi2gifw"))))
8279b1d3
CB
8432 (build-system ruby-build-system)
8433 (arguments
8434 '(#:phases
8435 (modify-phases %standard-phases
8436 ;; This phase breaks the tests, as it patches some of the test data.
8437 (delete 'patch-source-shebangs))))
8438 (native-inputs
8439 `(("ruby-bacon" ,ruby-bacon)))
8440 (synopsis "Ruby library for MIME detection by extension or content")
8441 (description
8442 "@acronym{MIME, Multipurpose Internet Mail Extensions} detection by
8443extension or content, using the freedesktop.org.xml shared-mime-info
8444database.")
8445 (home-page "https://github.com/minad/mimemagic")
8446 (license license:expat)))
8447
32d1c06f
BW
8448(define-public ruby-mime-types-data
8449 (package
8450 (name "ruby-mime-types-data")
f49511db 8451 (version "3.2016.0521")
32d1c06f
BW
8452 (source
8453 (origin
8454 (method url-fetch)
8455 (uri (rubygems-uri "mime-types-data" version))
8456 (sha256
8457 (base32
f49511db 8458 "04my3746hwa4yvbx1ranhfaqkgf6vavi1kyijjnw8w3dy37vqhkm"))))
32d1c06f
BW
8459 (build-system ruby-build-system)
8460 (native-inputs
8461 `(("ruby-hoe" ,ruby-hoe)))
8462 (synopsis "Registry for information about MIME media type definitions")
8463 (description
8464 "@code{mime-types-data} provides a registry for information about
8465Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
8466be used with the Ruby mime-types library or other software to determine
8467defined filename extensions for MIME types, or to use filename extensions to
8468look up the likely MIME type definitions.")
8469 (home-page "https://github.com/mime-types/mime-types-data/")
8470 (license license:expat)))
8471
d39b606c
BW
8472(define-public ruby-mime-types
8473 (package
8474 (name "ruby-mime-types")
803bcc81 8475 (version "3.1")
d39b606c
BW
8476 (source
8477 (origin
8478 (method url-fetch)
8479 (uri (rubygems-uri "mime-types" version))
8480 (sha256
8481 (base32
803bcc81 8482 "0087z9kbnlqhci7fxh9f6il63hj1k02icq2rs0c6cppmqchr753m"))))
d39b606c
BW
8483 (build-system ruby-build-system)
8484 (propagated-inputs
8485 `(("ruby-mime-types-data" ,ruby-mime-types-data)))
8486 (native-inputs
8487 `(("ruby-hoe" ,ruby-hoe)
8488 ("ruby-fivemat" ,ruby-fivemat)
8489 ("ruby-minitest-focus" ,ruby-minitest-focus)
8490 ("ruby-minitest-rg" ,ruby-minitest-rg)
803bcc81
BW
8491 ("ruby-minitest-bonus-assertions" ,ruby-minitest-bonus-assertions)
8492 ("ruby-minitest-hooks" ,ruby-minitest-hooks)))
d39b606c
BW
8493 (synopsis "Library and registry for MIME content type definitions")
8494 (description "The mime-types library provides a library and registry for
8495information about Multipurpose Internet Mail Extensions (MIME) content type
8496definitions. It can be used to determine defined filename extensions for MIME
8497types, or to use filename extensions to look up the likely MIME type
8498definitions.")
8499 (home-page "https://github.com/mime-types/ruby-mime-types")
8500 (license license:expat)))
8501
eb5e0bd9
BW
8502(define-public ruby-fivemat
8503 (package
8504 (name "ruby-fivemat")
c664ebcc 8505 (version "1.3.7")
eb5e0bd9
BW
8506 (source
8507 (origin
8508 (method url-fetch)
8509 (uri (rubygems-uri "fivemat" version))
8510 (sha256
8511 (base32
c664ebcc 8512 "0pzlycasvwmg4bbx7plllpqnhd9zlmmff8l2w3yii86nrm2nvf9n"))))
eb5e0bd9
BW
8513 (build-system ruby-build-system)
8514 (arguments
8515 `(#:tests? #f)) ; no tests
8516 (synopsis "Each test file given its own line of dots")
8517 (description
8518 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
8519its own line of dots during testing. It aims to provide test output that is
8520neither too verbose nor too minimal.")
8521 (home-page "https://github.com/tpope/fivemat")
8522 (license license:expat)))
8523
4fea500b
BW
8524(define-public ruby-sqlite3
8525 (package
8526 (name "ruby-sqlite3")
e7cdba61 8527 (version "1.4.2")
4fea500b
BW
8528 (source
8529 (origin
8530 (method url-fetch)
8531 (uri (rubygems-uri "sqlite3" version))
8532 (sha256
8533 (base32
e7cdba61 8534 "0lja01cp9xd5m6vmx99zwn4r7s97r1w5cb76gqd8xhbm1wxyzf78"))))
4fea500b
BW
8535 (build-system ruby-build-system)
8536 (arguments
8537 `(#:phases
8538 (modify-phases %standard-phases
8539 (add-before 'check 'add-gemtest-file
8540 ;; This file exists in the repository but is not distributed.
9923d5a4 8541 (lambda _ (invoke "touch" ".gemtest"))))))
4fea500b
BW
8542 (inputs
8543 `(("sqlite" ,sqlite)))
8544 (native-inputs
8545 `(("ruby-hoe" ,ruby-hoe)
8546 ("ruby-rake-compiler" ,ruby-rake-compiler)
8547 ("ruby-mini-portile" ,ruby-mini-portile)))
8548 (synopsis "Interface with SQLite3 databases")
8549 (description
8550 "This module allows Ruby programs to interface with the SQLite3 database
8551engine.")
8552 (home-page
8553 "https://github.com/sparklemotion/sqlite3-ruby")
8554 (license license:bsd-3)))
8555
4dfa39cc
BW
8556(define-public ruby-shoulda-context
8557 (package
8558 (name "ruby-shoulda-context")
e7d1d472 8559 (version "1.2.2")
4dfa39cc
BW
8560 (source
8561 (origin
8562 (method url-fetch)
8563 (uri (rubygems-uri "shoulda-context" version))
8564 (sha256
8565 (base32
e7d1d472 8566 "1l0ncsxycb4s8n47dml97kdnixw4mizljbkwqc3rh05r70csq9bc"))))
4dfa39cc
BW
8567 (build-system ruby-build-system)
8568 (arguments
8569 `(#:phases
8570 (modify-phases %standard-phases
8571 (replace 'check
8572 (lambda _
8573 ;; Do not run tests to avoid circular dependence with rails.
8574 ;; Instead just import the library to test.
9923d5a4 8575 (invoke "ruby" "-Ilib" "-r" "shoulda-context"))))))
4dfa39cc
BW
8576 (synopsis "Test::Unit context framework extracted from Shoulda")
8577 (description
8578 "@code{shoulda-context} is the context framework extracted from Shoulda.
8579Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
8580context, setup, and should blocks combine to produce natural test method
8581names.")
8582 (home-page "https://github.com/thoughtbot/shoulda-context")
8583 (license license:expat)))
8584
e4fea008
BW
8585(define-public ruby-shoulda-matchers
8586 (package
8587 (name "ruby-shoulda-matchers")
d1c1f368 8588 (version "3.1.2")
e4fea008
BW
8589 (source
8590 (origin
8591 (method url-fetch)
8592 (uri (rubygems-uri "shoulda-matchers" version))
8593 (sha256
8594 (base32
d1c1f368 8595 "1zvv94pqk5b5my3w1shdz7h34xf2ldhg5k4qfdpbwi2iy0j9zw2a"))))
e4fea008
BW
8596 (build-system ruby-build-system)
8597 (arguments
8598 `(#:phases
8599 (modify-phases %standard-phases
e4fea008
BW
8600 (replace 'check
8601 (lambda _
8602 ;; Do not run tests to avoid circular dependence with rails. Instead
8603 ;; just import the library to test.
9923d5a4 8604 (invoke "ruby" "-Ilib" "-r" "shoulda-matchers"))))))
e4fea008
BW
8605 (propagated-inputs
8606 `(("ruby-activesupport" ,ruby-activesupport)))
8607 (synopsis "Collection of testing matchers extracted from Shoulda")
8608 (description
8609 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
8610test common Rails functionality. These tests would otherwise be much longer,
8611more complex, and error-prone.")
8612 (home-page "https://github.com/thoughtbot/shoulda-matchers")
8613 (license license:expat)))
8614
3885c58b
BW
8615(define-public ruby-shoulda-matchers-2
8616 (package
8617 (inherit ruby-shoulda-matchers)
8618 (version "2.8.0")
8619 (source (origin
8620 (method url-fetch)
8621 (uri (rubygems-uri "shoulda-matchers" version))
8622 (sha256
8623 (base32
8624 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
8625
6f390716
BW
8626(define-public ruby-shoulda
8627 (package
8628 (name "ruby-shoulda")
8629 (version "3.5.0")
8630 (source
8631 (origin
8632 (method url-fetch)
8633 (uri (rubygems-uri "shoulda" version))
8634 (sha256
8635 (base32
8636 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
8637 (build-system ruby-build-system)
8638 (arguments
8639 `(#:phases
8640 (modify-phases %standard-phases
8641 (replace 'check
8642 ;; Don't run tests to avoid circular dependence with rails. Instead
8643 ;; just import the library to test.
9923d5a4 8644 (lambda _ (invoke "ruby" "-Ilib" "-r" "shoulda"))))))
6f390716
BW
8645 (propagated-inputs
8646 `(("ruby-shoulda-context" ,ruby-shoulda-context)
8647 ("ruby-shoulda-matchers" ,ruby-shoulda-matchers-2)))
8648 (synopsis "Context framework and matchers for testing")
8649 (description
8650 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
8651@code{shoulda-matchers} providing tools for writing tests.")
8652 (home-page "https://github.com/thoughtbot/shoulda")
8653 (license license:expat)))
8654
3b44bcdf
BW
8655(define-public ruby-unf
8656 (package
8657 (name "ruby-unf")
8658 (version "0.1.4")
8659 (source
8660 (origin
8661 (method url-fetch)
8662 (uri (rubygems-uri "unf" version))
8663 (sha256
8664 (base32
8665 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
8666 (build-system ruby-build-system)
8667 (arguments
8668 `(#:phases
8669 (modify-phases %standard-phases
8670 (add-before 'check 'add-dependency-to-bundler
8671 (lambda _
8672 ;; test-unit is required but not provided by the bundler
8673 ;; environment. This is fixed in the upstream repository but fix
8674 ;; has not been released.
8675 (substitute* "Gemfile"
8676 (("^gemspec") "gem 'test-unit'\ngemspec"))
8677 #t)))))
8678 (propagated-inputs
8679 `(("ruby-unf-ext" ,ruby-unf-ext)))
8680 (native-inputs
8681 `(("ruby-shoulda" ,ruby-shoulda)
8682 ("bundler" ,bundler)
8683 ("ruby-test-unit" ,ruby-test-unit)))
8684 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
8685 (description
8686 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
8687support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
8688@code{java.text.Normalizer} on JRuby.")
8689 (home-page "https://github.com/knu/ruby-unf")
8690 (license license:bsd-2)))
8691
e32c99d2
CB
8692(define-public ruby-warden
8693 (package
8694 (name "ruby-warden")
8695 (version "1.2.8")
8696 (source
8697 (origin
8698 (method url-fetch)
8699 (uri (rubygems-uri "warden" version))
8700 (sha256
8701 (base32
8702 "1fr9n9i9r82xb6i61fdw4xgc7zjv7fsdrr4k0njchy87iw9fl454"))))
8703 (build-system ruby-build-system)
8704 (arguments
8705 '(#:tests? #f)) ; No included tests
8706 (propagated-inputs
8707 `(("ruby-rack" ,ruby-rack)))
8708 (synopsis "Rack middleware providing authentication")
8709 (description
8710 "Warden is a Rack-based middleware that provides a mechanism for
8711authentication in Ruby web applications.")
8712 (home-page "https://github.com/wardencommunity/warden")
8713 (license license:expat)))
8714
e42eecdb
CB
8715(define-public ruby-warden-oauth2
8716 (package
8717 (name "ruby-warden-oauth2")
8718 (version "0.0.1")
8719 (source
8720 (origin
8721 (method url-fetch)
8722 (uri (rubygems-uri "warden-oauth2" version))
8723 (sha256
8724 (base32
8725 "1z9154lvzrnnfjbjkmirh4n811nygp6pm2fa6ikr7y1ysa4zv3cz"))))
8726 (build-system ruby-build-system)
8727 (arguments
8728 '(#:test-target "spec"
8729 #:phases
8730 (modify-phases %standard-phases
8731 (add-after 'unpack 'remove-unnecessary-dependencies
8732 (lambda _
8733 (substitute* "Gemfile"
8734 ;; All of these gems relate to development, and are unnecessary
8735 ;; when running the tests
8736 (("gem 'guard-bundler'") "")
8737 (("gem 'guard'") "")
8738 (("gem 'guard-rspec'") "")
8739 (("gem 'rb-fsevent'") "")
8740 (("gem 'pry'") "")
8741 (("gem 'growl'") ""))
8742 #t))
8743 ;; The test suite doesn't work with rspec@2, and this is incompatible
8744 ;; with the current version of Rake, so invoke Rspec directly
8745 (replace 'check
8746 (lambda* (#:key tests? #:allow-other-keys)
8747 (when tests?
8748 (invoke "bundle" "exec" "rspec"))
8749 #t)))))
8750 (propagated-inputs
8751 `(("ruby-warden" ,ruby-warden)))
8752 (native-inputs
8753 `(("bundler" ,bundler)
8754 ("ruby-rspec" ,ruby-rspec-2)
8755 ("ruby-rack-test" ,ruby-rack-test)))
8756 (synopsis "OAuth 2.0 strategies for Warden")
8757 (description
8758 "This library extends Warden to support OAuth 2.0 authorized API
8759requests.")
8760 (home-page "https://github.com/opperator/warden-oauth2")
8761 (license license:expat)))
8762
8c7ae384
CB
8763(define-public ruby-webmock-2
8764 (package
8765 (name "ruby-webmock")
8766 (version "2.3.2")
8767 (source
8768 (origin
8769 (method url-fetch)
8770 (uri (rubygems-uri "webmock" version))
8771 (sha256
8772 (base32
8773 "04hkcqsmbfnp8g237pisnc834vpgildklicbjbyikqg0bg1rwcy5"))))
8774 (build-system ruby-build-system)
8775 (native-inputs
8776 `(("bundler" ,bundler)
8777 ("ruby-rspec" ,ruby-rspec)))
8778 (propagated-inputs
8779 `(("ruby-addressable" ,ruby-addressable)
8780 ("ruby-crack" ,ruby-crack)
8781 ("ruby-hashdiff" ,ruby-hashdiff)))
8782 (synopsis "Allows stubbing and setting expectations on HTTP requests")
8783 (description
8784 "WebMock allows stubbing HTTP requests and setting expectations on HTTP
8785requests. This is useful when testing software.")
8786 (home-page "https://github.com/bblimke/webmock")
8787 (license license:expat)))
8788
d8c189ed
CB
8789(define-public ruby-unicode-display-width
8790 (package
8791 (name "ruby-unicode-display-width")
216ccced 8792 (version "1.6.0")
d8c189ed
CB
8793 (source
8794 (origin
8795 (method url-fetch)
8796 (uri (rubygems-uri "unicode-display_width" version))
8797 (sha256
8798 (base32
216ccced 8799 "08kfiniak1pvg3gn5k6snpigzvhvhyg7slmm0s2qx5zkj62c1z2w"))))
d8c189ed
CB
8800 (build-system ruby-build-system)
8801 (arguments
8802 '(;; Test data not included.
8803 #:tests? #f))
8804 (synopsis "Determine the monospace display width of Ruby strings")
8805 (description
8806 "@code{Unicode::DisplayWidth} is a Ruby library which can determine the
8807display width of strings in Ruby.")
8808 (home-page "https://github.com/janlelis/unicode-display_width")
8809 (license license:expat)))
8810
6120589f
CB
8811;; There is another gem called 'ruby-version' so we use an underscore in this
8812;; name
8813(define-public ruby_version
8814 (package
8815 (name "ruby_version")
1097fdbe 8816 (version "1.0.2")
6120589f
CB
8817 (source
8818 (origin
8819 (method url-fetch)
8820 (uri (rubygems-uri "ruby_version" version))
8821 (sha256
8822 (base32
1097fdbe 8823 "0lvc7bd5ps3w2vq2wb02i0pi3vfcx2rnckx2ix4rjym1qf52kb2j"))))
6120589f
CB
8824 (build-system ruby-build-system)
8825 (arguments
1097fdbe 8826 `(#:phases
6120589f
CB
8827 (modify-phases %standard-phases
8828 (add-before 'check 'fix-dependencies
8829 (lambda _
8830 ;; Remove the Gemfile.lock, as we want to use Guix packages at
8831 ;; whatever versions.
8832 (delete-file "Gemfile.lock")
1097fdbe
MC
8833 ;; Remove the included gem files as they unnecessary.
8834 (delete-file-recursively "pkg/")
8835 ;; Accept any version of rake, rdoc and rspec
6120589f 8836 (substitute* "ruby_version.gemspec"
6120589f 8837 (("%q<rake.*") "%q<rake>)\n")
1097fdbe 8838 (("%q<rdoc.*") "%q<rdoc>)\n")
6120589f 8839 (("%q<rspec.*") "%q<rspec>)\n"))
1097fdbe 8840 ;; Do not use bundler.
6120589f 8841 (substitute* "Rakefile"
1097fdbe 8842 (("Bundler\\.setup.*") "nil\n"))
6120589f
CB
8843 #t)))))
8844 (native-inputs
1097fdbe
MC
8845 `(("ruby-rdoc" ,ruby-rdoc)
8846 ("ruby-rspec" ,ruby-rspec)
8847 ("ruby-rubygems-tasks", ruby-rubygems-tasks)))
6120589f 8848 (synopsis "Ruby library to help check the Ruby version")
1097fdbe 8849 (description "@code{ruby_version} provides a @code{RubyVersion} module to simplify
6120589f
CB
8850checking for the right Ruby version in software.")
8851 (home-page "https://github.com/janlelis/ruby_version")
8852 (license license:expat)))
8853
a229acff
CB
8854(define-public ruby-websocket-driver
8855 (package
8856 (name "ruby-websocket-driver")
9d1cf6d4 8857 (version "0.7.1")
a229acff
CB
8858 (source
8859 (origin
8860 (method url-fetch)
8861 (uri (rubygems-uri "websocket-driver" version))
8862 (sha256
9d1cf6d4 8863 (base32 "1bxamwqldmy98hxs5pqby3andws14hl36ch78g0s81gaz9b91nj2"))))
a229acff
CB
8864 (build-system ruby-build-system)
8865 (arguments
9d1cf6d4 8866 '(#:tests? #f)) ; no included tests
a229acff
CB
8867 (propagated-inputs
8868 `(("ruby-websocket-extensions" ,ruby-websocket-extensions)))
8869 (synopsis "WebSocket protocol handler with pluggable I/O")
8870 (description
8871 "@code{websocket-driver} provides a complete implementation of the
8872WebSocket protocols that can be hooked up to any TCP library")
8873 (home-page "https://github.com/faye/websocket-driver-ruby")
8874 (license license:expat)))
8875
52b015a9
CB
8876(define-public ruby-websocket-extensions
8877 (package
8878 (name "ruby-websocket-extensions")
8879 (version "0.1.3")
8880 (source
8881 (origin
8882 (method url-fetch)
8883 (uri (rubygems-uri "websocket-extensions" version))
8884 (sha256
8885 (base32
8886 "034sdr7fd34yag5l6y156rkbhiqgmy395m231dwhlpcswhs6d270"))))
8887 (build-system ruby-build-system)
8888 (arguments
8889 '(;; No included tests
8890 #:tests? #f))
8891 (synopsis "Generic extension manager for WebSocket connections")
8892 (description
8893 "@code{websocket-extensions} provides a container for registering
8894extension plugins.")
8895 (home-page "https://github.com/faye/websocket-extensions-ruby")
8896 (license license:expat)))
8897
5799aadd
BW
8898(define-public ruby-domain-name
8899 (package
8900 (name "ruby-domain-name")
222999c9 8901 (version "0.5.20180417")
5799aadd
BW
8902 (source
8903 (origin
8904 (method url-fetch)
8905 (uri (rubygems-uri "domain_name" version))
8906 (sha256
8907 (base32
222999c9 8908 "0abdlwb64ns7ssmiqhdwgl27ly40x2l27l8hs8hn0z4kb3zd2x3v"))))
5799aadd
BW
8909 (build-system ruby-build-system)
8910 (arguments
8911 `(#:phases
8912 (modify-phases %standard-phases
8913 (add-before 'check 'fix-versions
8914 (lambda _
8915 ;; Fix NameError that appears to already be fixed upstream.
8916 (substitute* "Rakefile"
8917 (("DomainName::VERSION")
8918 "Bundler::GemHelper.gemspec.version"))
8919 ;; Loosen unnecessarily strict test-unit version specification.
8920 (substitute* "domain_name.gemspec"
71596c3c 8921 (("<test-unit>.freeze, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
5799aadd
BW
8922 #t)))))
8923 (propagated-inputs
8924 `(("ruby-unf" ,ruby-unf)))
8925 (native-inputs
8926 `(("ruby-shoulda" ,ruby-shoulda)
8927 ("bundler" ,bundler)
8928 ("ruby-test-unit" ,ruby-test-unit)))
8929 (synopsis "Domain name manipulation library")
8930 (description
8931 "@code{domain_name} is a Domain name manipulation library. It parses a
8932domain name ready for extracting the registered domain and TLD (Top Level
8933Domain). It can also be used for cookie domain validation based on the Public
8934Suffix List.")
8935 (home-page "https://github.com/knu/ruby-domain_name")
8936 (license license:bsd-2)))
8937
d114ceeb
BW
8938(define-public ruby-http-cookie
8939 (package
8940 (name "ruby-http-cookie")
2a2eb07d 8941 (version "1.0.3")
d114ceeb
BW
8942 (source
8943 (origin
8944 (method url-fetch)
8945 (uri (rubygems-uri "http-cookie" version))
8946 (sha256
8947 (base32
2a2eb07d 8948 "004cgs4xg5n6byjs7qld0xhsjq3n6ydfh897myr2mibvh6fjc49g"))))
d114ceeb
BW
8949 (build-system ruby-build-system)
8950 (arguments
8951 `(#:phases
8952 (modify-phases %standard-phases
8953 (add-before 'check 'add-dependency-to-bundler
8954 (lambda _
8955 ;; Fix NameError
8956 (substitute* "Rakefile"
8957 (("HTTP::Cookie::VERSION")
8958 "Bundler::GemHelper.gemspec.version"))
8959 #t)))))
8960 (propagated-inputs
8961 `(("ruby-domain-name" ,ruby-domain-name)))
8962 (native-inputs
8963 `(("rubysimplecov" ,ruby-simplecov)
8964 ("bundler" ,bundler)
8965 ("ruby-sqlite3" ,ruby-sqlite3)
8966 ("ruby-test-unit" ,ruby-test-unit)))
8967 (synopsis "Handle HTTP Cookies based on RFC 6265")
8968 (description
8969 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
8970RFC 6265. It has been designed with security, standards compliance and
8971compatibility in mind, to behave just the same as today's major web browsers.
8972It has built-in support for the legacy @code{cookies.txt} and
8973@code{cookies.sqlite} formats of Mozilla Firefox.")
8974 (home-page "https://github.com/sparklemotion/http-cookie")
8975 (license license:expat)))
8976
1c8e6fd3
CB
8977(define-public ruby-httpclient
8978 (package
8979 (name "ruby-httpclient")
8980 (version "2.8.3")
8981 (source
8982 (origin
8983 (method url-fetch)
8984 (uri (rubygems-uri "httpclient" version))
8985 (sha256
8986 (base32
8987 "19mxmvghp7ki3klsxwrlwr431li7hm1lczhhj8z4qihl2acy8l99"))))
8988 (build-system ruby-build-system)
8989 (arguments
8990 '(;; TODO: Some tests currently fail
8991 ;; ------
8992 ;; 211 tests, 729 assertions, 13 failures, 4 errors, 0 pendings,
8993 ;; 2 omissions, 0 notifications
8994 ;; 91.866% passed
8995 ;; ------
8996 ;; 6.49 tests/s, 22.41 assertions/s
8997 #:tests? #f
8998 #:phases
8999 (modify-phases %standard-phases
9000 (replace 'check
9001 (lambda* (#:key tests? #:allow-other-keys)
9002 (if tests?
9923d5a4
TGR
9003 (invoke "ruby"
9004 "-Ilib"
9005 "test/runner.rb")
0076f5a9 9006 #t))))))
1c8e6fd3
CB
9007 (native-inputs
9008 `(("ruby-rack" ,ruby-rack)))
9009 (synopsis
9010 "Make HTTP requests with support for HTTPS, Cookies, authentication and more")
9011 (description
9012 "The @code{httpclient} ruby library provides functionality related to
9013HTTP. Compared to the @code{net/http} library, @{httpclient} also provides
9014Cookie, multithreading and authentication (digest, NTLM) support.
9015
9016Also provided is a @command{httpclient} command, which can perform HTTP
9017requests either using arguments or with an interactive prompt.")
9018 (home-page "https://github.com/nahi/httpclient")
9019 (license license:ruby)))
9020
7d3a1a2d
BW
9021(define-public ruby-ansi
9022 (package
9023 (name "ruby-ansi")
9024 (version "1.5.0")
9025 (source
9026 (origin
3d30c332 9027 (method git-fetch)
7d3a1a2d 9028 ;; Fetch from GitHub as the gem does not contain testing code.
3d30c332
EF
9029 (uri (git-reference
9030 (url "https://github.com/rubyworks/ansi")
9031 (commit version)))
9032 (file-name (git-file-name name version))
7d3a1a2d
BW
9033 (sha256
9034 (base32
3d30c332 9035 "1wsz7xxwl3vkh277jb7fd7akqnqqgbvalxzpjwniiqk8ghfprbi5"))))
7d3a1a2d
BW
9036 (build-system ruby-build-system)
9037 (arguments
9038 `(#:phases
9039 (modify-phases %standard-phases
9040 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
9041 ;; cycle ansi, qed, ansi. Instead simply test that the library can
9042 ;; be require'd.
9043 (replace 'check
9044 (lambda _
9923d5a4 9045 (invoke "ruby" "-Ilib" "-r" "ansi")))
0899352f
MB
9046 (add-before 'validate-runpath 'replace-broken-symlink
9047 (lambda* (#:key outputs #:allow-other-keys)
9048 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
9049 (file (string-append
9050 out "/lib/ruby/vendor_ruby/gems/ansi-"
9051 ,version "/lib/ansi.yml")))
0899352f
MB
9052 ;; XXX: This symlink is broken since ruby 2.4.
9053 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9054 (delete-file file)
9055 (symlink "../.index" file)
9056 #t))))))
7d3a1a2d
BW
9057 (synopsis "ANSI escape code related libraries")
9058 (description
9059 "This package is a collection of ANSI escape code related libraries
9060enabling ANSI colorization and stylization of console output. Included in the
9061library are the @code{Code} module, which defines ANSI codes as constants and
9062methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
9063@code{ProgressBar}, and a @code{String} subclass. The library also includes a
9064@code{Terminal} module which provides information about the current output
9065device.")
3d30c332 9066 (home-page "https://rubyworks.github.io/ansi/")
7d3a1a2d 9067 (license license:bsd-2)))
7c033c46
BW
9068
9069(define-public ruby-systemu
9070 (package
9071 (name "ruby-systemu")
9072 (version "2.6.5")
9073 (source
9074 (origin
9075 (method url-fetch)
9076 (uri (rubygems-uri "systemu" version))
9077 (sha256
9078 (base32
9079 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
9080 (build-system ruby-build-system)
9081 (arguments
9082 `(#:phases
9083 (modify-phases %standard-phases
9084 (add-before 'check 'set-version
9085 (lambda _
9086 (setenv "VERSION" ,version)
9087 #t)))))
9088 (synopsis "Capture of stdout/stderr and handling of child processes")
9089 (description
9090 "Systemu can be used on any platform to return status, stdout, and stderr
9091of any command. Unlike other methods like @code{open3} and @code{popen4}
9092there is no danger of full pipes or threading issues hanging your process or
9093subprocess.")
9094 (home-page "https://github.com/ahoward/systemu")
9095 (license license:ruby)))
3d84a99e
BW
9096
9097(define-public ruby-bio-commandeer
9098 (package
9099 (name "ruby-bio-commandeer")
37b08547 9100 (version "0.4.0")
3d84a99e
BW
9101 (source
9102 (origin
9103 (method url-fetch)
9104 (uri (rubygems-uri "bio-commandeer" version))
9105 (sha256
9106 (base32
37b08547 9107 "0khpfw1yl5l3d2m8nxpkk32ybc4c3pa5hic3agd160jdfjjjnlni"))))
3d84a99e
BW
9108 (build-system ruby-build-system)
9109 (arguments
9110 `(#:phases
9111 (modify-phases %standard-phases
9112 (replace 'check
9113 ;; Run test without calling 'rake' so that jeweler is
9114 ;; not required as an input.
9115 (lambda _
9923d5a4 9116 (invoke "rspec" "spec/bio-commandeer_spec.rb"))))))
3d84a99e
BW
9117 (propagated-inputs
9118 `(("ruby-bio-logger" ,ruby-bio-logger)
9119 ("ruby-systemu" ,ruby-systemu)))
9120 (native-inputs
9121 `(("bundler" ,bundler)
9122 ("ruby-rspec" ,ruby-rspec)))
9123 (synopsis "Simplified running of shell commands from within Ruby")
9124 (description
9125 "Bio-commandeer provides an opinionated method of running shell commands
9126from within Ruby. The advantage of bio-commandeer over other methods of
9127running external commands is that when something goes wrong, messages printed
9128to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
9129detail to ease debugging.")
7bf837fd 9130 (home-page "https://github.com/wwood/bioruby-commandeer")
3d84a99e 9131 (license license:expat)))
7c8131c7
BW
9132
9133(define-public ruby-rubytest
9134 (package
9135 (name "ruby-rubytest")
9136 (version "0.8.1")
9137 (source
9138 (origin
9139 (method url-fetch)
9140 (uri (rubygems-uri "rubytest" version))
9141 (sha256
9142 (base32
9143 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
9144 (build-system ruby-build-system)
9145 (arguments
9146 ;; Disable regular testing to break the cycle rubytest, qed, brass,
9147 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
9148 ;; simply test that the library can be require'd.
9149 `(#:phases
9150 (modify-phases %standard-phases
9151 (replace 'check
9152 (lambda _
9923d5a4 9153 (invoke "ruby" "-Ilib" "-r" "rubytest"))))))
7c8131c7
BW
9154 (propagated-inputs
9155 `(("ruby-ansi" ,ruby-ansi)))
9156 (synopsis "Universal test harness for Ruby")
9157 (description
9158 "Rubytest is a testing meta-framework for Ruby. It can handle any
9159compliant test framework and can run tests from multiple frameworks in a
9160single pass.")
2f3800e5 9161 (home-page "https://rubyworks.github.io/rubytest")
7c8131c7 9162 (license license:bsd-2)))
90fcedf2
BW
9163
9164(define-public ruby-brass
9165 (package
9166 (name "ruby-brass")
9167 (version "1.2.1")
9168 (source
9169 (origin
9170 (method url-fetch)
9171 (uri (rubygems-uri "brass" version))
9172 (sha256
9173 (base32
9174 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
9175 (build-system ruby-build-system)
9176 (arguments
9177 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
9178 ;; Instead simply test that the library can be require'd.
9179 `(#:phases
9180 (modify-phases %standard-phases
9181 (replace 'check
9182 (lambda _
9923d5a4 9183 (invoke "ruby" "-Ilib" "-r" "brass"))))))
90fcedf2
BW
9184 (synopsis "Basic foundational assertions framework")
9185 (description
9186 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
9187foundational assertions framework for other assertion and test frameworks to
9188make use of.")
2f3800e5 9189 (home-page "https://rubyworks.github.io/brass")
90fcedf2 9190 (license license:bsd-2)))
120fc74b
BW
9191
9192(define-public ruby-qed
9193 (package
9194 (name "ruby-qed")
9195 (version "2.9.2")
9196 (source
9197 (origin
9198 (method url-fetch)
9199 (uri (rubygems-uri "qed" version))
9200 (sha256
9201 (base32
9202 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
9203 (build-system ruby-build-system)
9204 (arguments
9205 ;; Disable testing to break the cycle qed, ansi, qed, among others.
9206 ;; Instead simply test that the executable runs using --copyright.
9207 `(#:phases
9208 (modify-phases %standard-phases
9209 (replace 'check
9210 (lambda _
9923d5a4 9211 (invoke "ruby" "-Ilib" "bin/qed" "--copyright"))))))
120fc74b
BW
9212 (propagated-inputs
9213 `(("ruby-ansi" ,ruby-ansi)
9214 ("ruby-brass" ,ruby-brass)))
9215 (synopsis "Test framework utilizing literate programming techniques")
9216 (description
9217 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
9218@dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
9219Development} (BDD) utilizing Literate Programming techniques. QED sits
9220somewhere between lower-level testing tools like @code{Test::Unit} and
9221requirement specifications systems like Cucumber.")
2f3800e5 9222 (home-page "https://rubyworks.github.io/qed")
120fc74b 9223 (license license:bsd-2)))
9273ee8f 9224
dbbe88d3
CB
9225(define-public ruby-que
9226 (package
9227 (name "ruby-que")
9228 (version "1.0.0.beta3")
9229 (source
9230 (origin
9231 (method url-fetch)
9232 (uri (rubygems-uri "que" version))
9233 (sha256
9234 (base32
9235 "0gr9pb814d4qj3ds98g6cjrdk7wv0yg8aqbm7c1lmgl87jkg8q04"))))
9236 (build-system ruby-build-system)
9237 (arguments
9238 '(#:tests? #f)) ; No included tests
9239 (synopsis "Job queue using PostgreSQL written in Ruby")
9240 (description
9241 "This package provides a job queue that uses PostgreSQL for storing jobs
9242and locking between worker processes.")
9243 (home-page "https://github.com/chanks/que")
9244 (license license:expat)))
9245
9273ee8f
BW
9246(define-public ruby-ae
9247 (package
9248 (name "ruby-ae")
9249 (version "1.8.2")
9250 (source
9251 (origin
11d1b318 9252 (method git-fetch)
9273ee8f 9253 ;; Fetch from github so tests are included.
11d1b318
EF
9254 (uri (git-reference
9255 (url "https://github.com/rubyworks/ae")
9256 (commit version)))
9257 (file-name (git-file-name name version))
9273ee8f
BW
9258 (sha256
9259 (base32
11d1b318 9260 "11299jj5ma8mi7b4majkyjy70y6zlqpgl8aql1c5lvfjavlpwmlp"))))
9273ee8f
BW
9261 (build-system ruby-build-system)
9262 (arguments
9263 `(#:phases
9264 (modify-phases %standard-phases
9265 (replace 'check
9923d5a4 9266 (lambda _ (invoke "qed")))
de6f6efd
MB
9267 (add-before 'validate-runpath 'replace-broken-symlink
9268 (lambda* (#:key outputs #:allow-other-keys)
9269 (let* ((out (assoc-ref outputs "out"))
3cb3fa67
CB
9270 (file (string-append
9271 out "/lib/ruby/vendor_ruby/gems/ae-"
9272 ,version "/lib/ae.yml")))
de6f6efd
MB
9273 ;; XXX: This symlink is broken since ruby 2.4.
9274 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9275 (delete-file file)
9276 (symlink "../.index" file)
9277 #t))))))
9273ee8f
BW
9278 (propagated-inputs
9279 `(("ruby-ansi" ,ruby-ansi)))
9280 (native-inputs
9281 `(("ruby-qed" ,ruby-qed)))
9282 (synopsis "Assertions library")
9283 (description
9284 "Assertive Expressive (AE) is an assertions library specifically designed
9285for reuse by other test frameworks.")
11d1b318 9286 (home-page "https://rubyworks.github.io/ae/")
9273ee8f 9287 (license license:bsd-2)))
78bb471f
BW
9288
9289(define-public ruby-lemon
9290 (package
9291 (name "ruby-lemon")
9292 (version "0.9.1")
9293 (source
9294 (origin
9295 (method url-fetch)
9296 (uri (rubygems-uri "lemon" version))
9297 (sha256
9298 (base32
9299 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
9300 (build-system ruby-build-system)
9301 (arguments
9302 `(#:phases
9303 (modify-phases %standard-phases
9923d5a4 9304 (replace 'check (lambda _ (invoke "qed"))))))
78bb471f
BW
9305 (propagated-inputs
9306 `(("ruby-ae" ,ruby-ae)
9307 ("ruby-ansi" ,ruby-ansi)
9308 ("ruby-rubytest" ,ruby-rubytest)))
9309 (native-inputs
9310 `(("ruby-qed" ,ruby-qed)))
9311 (synopsis "Test framework correlating code structure and test unit")
9312 (description
9313 "Lemon is a unit testing framework that enforces highly formal
9314case-to-class and unit-to-method test construction. This enforcement can help
9315focus concern on individual units of behavior.")
2f3800e5 9316 (home-page "https://rubyworks.github.io/lemon")
78bb471f 9317 (license license:bsd-2)))
0832804e
BW
9318
9319(define-public ruby-rubytest-cli
9320 (package
9321 (name "ruby-rubytest-cli")
9322 (version "0.2.0")
9323 (source
9324 (origin
9325 (method url-fetch)
9326 (uri (rubygems-uri "rubytest-cli" version))
9327 (sha256
9328 (base32
9329 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
9330 (build-system ruby-build-system)
9331 (arguments
9332 `(#:tests? #f)) ; no tests
9333 (propagated-inputs
9334 `(("ruby-ansi" ,ruby-ansi)
9335 ("ruby-rubytest" ,ruby-rubytest)))
9336 (synopsis "Command-line interface for rubytest")
9337 (description
9338 "Rubytest CLI is a command-line interface for running tests for
9339Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
2f3800e5 9340 (home-page "https://rubyworks.github.io/rubytest-cli")
0832804e 9341 (license license:bsd-2)))
72ccbfe3
BW
9342
9343(define-public ruby-hashery
9344 (package
9345 (name "ruby-hashery")
cba96208 9346 (version "2.1.2")
72ccbfe3
BW
9347 (source
9348 (origin
9349 (method url-fetch)
9350 (uri (rubygems-uri "hashery" version))
9351 (sha256
9352 (base32
cba96208 9353 "0qj8815bf7q6q7llm5rzdz279gzmpqmqqicxnzv066a020iwqffj"))))
72ccbfe3
BW
9354 (build-system ruby-build-system)
9355 (arguments
9356 `(#:phases
9357 (modify-phases %standard-phases
9358 (replace 'check
9359 (lambda _
9923d5a4
TGR
9360 (invoke "qed")
9361 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
72ccbfe3
BW
9362 (native-inputs
9363 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
9364 ("ruby-qed" ,ruby-qed)
9365 ("ruby-lemon" ,ruby-lemon)))
9366 (synopsis "Hash-like classes with extra features")
9367 (description
9368 "The Hashery is a tight collection of @code{Hash}-like classes.
9369Included are the auto-sorting @code{Dictionary} class, the efficient
9370@code{LRUHash}, the flexible @code{OpenHash} and the convenient
9371@code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
9372defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
9373standard @code{Hash} making it possible to subclass and augment to fit any
9374specific use case.")
2f3800e5 9375 (home-page "https://rubyworks.github.io/hashery")
72ccbfe3 9376 (license license:bsd-2)))
1f1d71e0
BW
9377
9378(define-public ruby-rc4
9379 (package
9380 (name "ruby-rc4")
9381 (version "0.1.5")
9382 (source
9383 (origin
9384 (method url-fetch)
9385 (uri (rubygems-uri "ruby-rc4" version))
9386 (sha256
9387 (base32
9388 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
9389 (build-system ruby-build-system)
9390 (arguments
9391 `(#:phases
9392 (modify-phases %standard-phases
9393 (replace 'check
9394 (lambda _
9923d5a4 9395 (invoke "rspec" "spec/rc4_spec.rb"))))))
1f1d71e0
BW
9396 (native-inputs
9397 `(("ruby-rspec" ,ruby-rspec-2)))
9398 (synopsis "Implementation of the RC4 algorithm")
9399 (description
9400 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
9401 (home-page "https://github.com/caiges/Ruby-RC4")
9402 (license license:expat)))
f3e085a8
BW
9403
9404(define-public ruby-afm
9405 (package
9406 (name "ruby-afm")
9407 (version "0.2.2")
9408 (source
9409 (origin
9410 (method url-fetch)
9411 (uri (rubygems-uri "afm" version))
9412 (sha256
9413 (base32
9414 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
9415 (build-system ruby-build-system)
9416 (native-inputs
9417 `(("bundler" ,bundler)))
9418 (synopsis "Read Adobe Font Metrics (afm) files")
9419 (description
9420 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
9421files and use the data therein.")
7bf837fd 9422 (home-page "https://github.com/halfbyte/afm")
f3e085a8 9423 (license license:expat)))
acb6be42
BW
9424
9425(define-public ruby-ascii85
9426 (package
9427 (name "ruby-ascii85")
5854082a 9428 (version "1.0.3")
acb6be42
BW
9429 (source
9430 (origin
9431 (method url-fetch)
9432 (uri (rubygems-uri "Ascii85" version))
9433 (sha256
9434 (base32
5854082a 9435 "0658m37jjjn6drzqg1gk4p6c205mgp7g1jh2d00n4ngghgmz5qvs"))))
acb6be42
BW
9436 (build-system ruby-build-system)
9437 (native-inputs
9438 `(("bundler" ,bundler)))
9439 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
9440 (description
9441 "This library provides methods to encode and decode Ascii85
9442binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
9443@dfn{Portable Document Format} (PDF) file formats.")
9444 (home-page "https://github.com/datawraith/ascii85gem")
9445 (license license:expat)))
edf8caae
BW
9446
9447(define-public ruby-ttfunk
9448 (package
9449 (name "ruby-ttfunk")
4179ed93 9450 (version "1.6.2.1")
edf8caae
BW
9451 (source
9452 (origin
4e110825 9453 (method git-fetch)
edf8caae 9454 ;; fetch from github as the gem does not contain testing code
4e110825
EF
9455 (uri (git-reference
9456 (url "https://github.com/prawnpdf/ttfunk")
9457 (commit version)))
9458 (file-name (git-file-name name version))
edf8caae
BW
9459 (sha256
9460 (base32
4179ed93 9461 "0rsf4j6s97wbcnjbvmmh6xrc7imw4g9lrlcvn945wh400lc8r53z"))))
edf8caae
BW
9462 (build-system ruby-build-system)
9463 (arguments
9464 `(#:test-target "spec"
9465 #:phases
9466 (modify-phases %standard-phases
afb7a3e8
JL
9467 (add-before 'build 'remove-ssh
9468 (lambda _
9469 ;; remove dependency on an ssh key pair that doesn't exist
9470 (substitute* "ttfunk.gemspec"
9471 (("spec.signing_key.*") ""))
9472 #t))
edf8caae
BW
9473 (add-before 'check 'remove-rubocop
9474 (lambda _
9475 ;; remove rubocop as a dependency as not needed for testing
9476 (substitute* "ttfunk.gemspec"
9477 (("spec.add_development_dependency\\('rubocop'.*") ""))
9478 (substitute* "Rakefile"
9479 (("require 'rubocop/rake_task'") "")
afb7a3e8 9480 (("RuboCop::RakeTask.new") ""))
edf8caae
BW
9481 #t)))))
9482 (native-inputs
9483 `(("ruby-rspec" ,ruby-rspec)
afb7a3e8 9484 ("ruby-yard" ,ruby-yard)
edf8caae
BW
9485 ("bundler" ,bundler)))
9486 (synopsis "Font metrics parser for the Prawn PDF generator")
9487 (description
9488 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
9489part of the Prawn PDF generator.")
9490 (home-page "https://github.com/prawnpdf/ttfunk")
9491 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
9492 ;; for details."
4179ed93 9493 (license %prawn-project-licenses)))
cbdd428c 9494
9270298f
BW
9495(define-public ruby-puma
9496 (package
9497 (name "ruby-puma")
63755fcd 9498 (version "3.9.1")
9270298f
BW
9499 (source
9500 (origin
a6cffe6e 9501 (method git-fetch)
9270298f 9502 ;; Fetch from GitHub because distributed gem does not contain tests.
a6cffe6e
EF
9503 (uri (git-reference
9504 (url "https://github.com/puma/puma")
9505 (commit (string-append "v" version))))
9506 (file-name (git-file-name name version))
9270298f
BW
9507 (sha256
9508 (base32
a6cffe6e 9509 "1kj75k81iik3aj73pkc9ixj9rwf95ipkyma65n28m64dgw02qi1f"))))
9270298f
BW
9510 (build-system ruby-build-system)
9511 (arguments
63755fcd
BW
9512 `(#:tests? #f ; Tests require an out-dated version of minitest.
9513 #:phases
9270298f
BW
9514 (modify-phases %standard-phases
9515 (add-before 'build 'fix-gemspec
9516 (lambda _
9517 (substitute* "puma.gemspec"
9518 (("git ls-files") "find * |sort"))
9519 #t)))))
9270298f
BW
9520 (synopsis "Simple, concurrent HTTP server for Ruby/Rack")
9521 (description
9522 "Puma is a simple, fast, threaded, and highly concurrent HTTP 1.1 server
9523for Ruby/Rack applications. Puma is intended for use in both development and
9524production environments. In order to get the best throughput, it is highly
9525recommended that you use a Ruby implementation with real threads like Rubinius
9526or JRuby.")
a6cffe6e 9527 (home-page "https://puma.io/")
9270298f
BW
9528 (license license:expat)))
9529
b0813490
BW
9530(define-public ruby-hoe-git
9531 (package
9532 (name "ruby-hoe-git")
9533 (version "1.6.0")
9534 (source
9535 (origin
9536 (method url-fetch)
9537 (uri (rubygems-uri "hoe-git" version))
9538 (sha256
9539 (base32
9540 "10jmmbjm0lkglwxbn4rpqghgg1ipjxrswm117n50adhmy8yij650"))))
9541 (build-system ruby-build-system)
9542 (propagated-inputs
9543 `(("ruby-hoe" ,ruby-hoe)
9544 ("git" ,git)))
9545 (synopsis "Hoe plugins for tighter Git integration")
9546 (description
9547 "This package provides a set of Hoe plugins for tighter Git integration.
9548It provides tasks to automate release tagging and pushing and changelog
9549generation.")
7bf837fd 9550 (home-page "https://github.com/jbarnette/hoe-git")
b0813490
BW
9551 (license license:expat)))
9552
cbdd428c
BW
9553(define-public ruby-sequel
9554 (package
9555 (name "ruby-sequel")
65a7f09c 9556 (version "4.49.0")
cbdd428c
BW
9557 (source
9558 (origin
9559 (method url-fetch)
9560 (uri (rubygems-uri "sequel" version))
9561 (sha256
9562 (base32
65a7f09c 9563 "010p4a60npppvgbyw7pq5xia8aydpgxdlhh3qjm2615kwjsw3fl8"))))
cbdd428c
BW
9564 (build-system ruby-build-system)
9565 (arguments
9566 '(#:tests? #f)) ; Avoid dependency loop with ruby-minitest-hooks.
9567 (synopsis "Database toolkit for Ruby")
9568 (description "Sequel provides thread safety, connection pooling and a
9569concise DSL for constructing SQL queries and table schemas. It includes a
9570comprehensive ORM layer for mapping records to Ruby objects and handling
9571associated records.")
e2b70d90 9572 (home-page "https://sequel.jeremyevans.net")
cbdd428c 9573 (license license:expat)))
3cc78097
BW
9574
9575(define-public ruby-timecop
9576 (package
9577 (name "ruby-timecop")
3d4a5eb5 9578 (version "0.9.1")
3cc78097
BW
9579 (source
9580 (origin
9581 (method url-fetch)
9582 (uri (rubygems-uri "timecop" version))
9583 (sha256
9584 (base32
3d4a5eb5 9585 "0d7mm786180v4kzvn1f77rhfppsg5n0sq2bdx63x9nv114zm8jrp"))))
3cc78097
BW
9586 (build-system ruby-build-system)
9587 (arguments
9588 `(#:phases
9589 (modify-phases %standard-phases
9590 (add-before 'check 'set-check-rubylib
9591 (lambda _
9592 ;; Set RUBYLIB so timecop tests finds its own lib.
9593 (setenv "RUBYLIB" "lib")
9594 #t)))))
9595 (native-inputs
9596 `(("bundler" ,bundler)
9597 ("ruby-minitest-rg" ,ruby-minitest-rg)
9598 ("ruby-mocha" ,ruby-mocha)
9599 ("ruby-activesupport" ,ruby-activesupport)))
66e07664 9600 (synopsis "Test mocks for time-dependent functions")
3cc78097
BW
9601 (description
9602 "Timecop provides \"time travel\" and \"time freezing\" capabilities,
9603making it easier to test time-dependent code. It provides a unified method to
9604mock @code{Time.now}, @code{Date.today}, and @code{DateTime.now} in a single
9605call.")
9606 (home-page "https://github.com/travisjeffery/timecop")
9607 (license license:expat)))
9608
dae620b8
BW
9609(define-public ruby-concurrent
9610 (package
9611 (name "ruby-concurrent")
1007640a 9612 (version "1.1.5")
dae620b8
BW
9613 (source
9614 (origin
8fcba3be 9615 (method git-fetch)
dae620b8
BW
9616 ;; Download from GitHub because the rubygems version does not contain
9617 ;; Rakefile.
8fcba3be
MB
9618 (uri (git-reference
9619 (url "https://github.com/ruby-concurrency/concurrent-ruby")
9620 (commit (string-append "v" version))))
9621 (file-name (git-file-name name version))
dae620b8
BW
9622 (sha256
9623 (base32
1007640a 9624 "193q2k47vk7qdvv9hlhmmdxgy91xl4imapyk1ijdg9vgf46knyzj"))))
dae620b8
BW
9625 (build-system ruby-build-system)
9626 (arguments
1007640a 9627 `(#:test-target "ci"
dae620b8
BW
9628 #:phases
9629 (modify-phases %standard-phases
520e89eb 9630 (add-before 'replace-git-ls-files 'remove-extra-gemspecs
dae620b8
BW
9631 (lambda _
9632 ;; Delete extra gemspec files so 'first-gemspec' chooses the
9633 ;; correct one.
9634 (delete-file "concurrent-ruby-edge.gemspec")
9635 (delete-file "concurrent-ruby-ext.gemspec")
9636 #t))
1007640a 9637 (replace 'replace-git-ls-files
520e89eb 9638 (lambda _
1007640a
MB
9639 ;; XXX: The default substitution made by this phase is not fully
9640 ;; compatible with "git ls-files". The latter produces file names
9641 ;; such as "lib/foo", whereas ruby-build-system uses "find . [...]"
9642 ;; which gives "./lib/foo". That difference in turn breaks the
9643 ;; comparison against a glob pattern in this script.
9644 (substitute* "concurrent-ruby.gemspec"
9645 (("git ls-files") "find * -type f | sort"))
9646 #t))
9647 (add-before 'build 'remove-jar-from-gemspec
520e89eb 9648 (lambda _
1007640a
MB
9649 ;; The gemspec wants to include a JAR file that we do not build
9650 ;; nor need.
9651 (substitute* "concurrent-ruby.gemspec"
9652 (("'lib/concurrent/concurrent_ruby.jar'")
9653 ""))
9654 #t))
9655 (add-before 'build 'remove-rake_compiler_dock-dependency
9656 (lambda _
9657 ;; This library is only used when building for non-MRI targets.
9658 (substitute* "Rakefile"
9659 (("require 'rake_compiler_dock'")
9660 ""))
520e89eb 9661 #t))
9019b37f
BW
9662 (add-before 'check 'remove-timecop-dependency
9663 ;; Remove timecop-dependent tests as having timecop as a depedency
9664 ;; causes circular depedencies.
9665 (lambda _
9666 (delete-file "spec/concurrent/executor/timer_set_spec.rb")
9667 (delete-file "spec/concurrent/scheduled_task_spec.rb")
9668 #t)))))
dae620b8
BW
9669 (native-inputs
9670 `(("ruby-rake-compiler" ,ruby-rake-compiler)
9019b37f 9671 ("ruby-rspec" ,ruby-rspec)))
dae620b8
BW
9672 (synopsis "Concurrency tools for Ruby")
9673 (description
9674 "This library provides modern concurrency tools including agents,
9675futures, promises, thread pools, actors, supervisors, and more. It is
9676inspired by Erlang, Clojure, Go, JavaScript, actors and classic concurrency
9677patterns.")
9678 (home-page "http://www.concurrent-ruby.com")
9679 (license license:expat)))
2de61e34
BW
9680
9681(define-public ruby-pkg-config
9682 (package
9683 (name "ruby-pkg-config")
884a80dd 9684 (version "1.2.5")
2de61e34
BW
9685 (source
9686 (origin
9687 (method url-fetch)
9688 (uri (rubygems-uri "pkg-config" version))
9689 (sha256
9690 (base32
884a80dd 9691 "056mzqdh4yjznsg36fi0xiq76f24vxlhzh2n4az919l3x5k318ar"))))
2de61e34
BW
9692 (build-system ruby-build-system)
9693 (arguments
9694 ;; Tests require extra files not included in the gem.
9695 `(#:tests? #f))
9696 (synopsis "Detect libraries for compiling Ruby native extensions")
9697 (description
9698 "@code{pkg-config} can be used in your extconf.rb to properly detect need
9699libraries for compiling Ruby native extensions.")
9700 (home-page "https://github.com/ruby-gnome2/pkg-config")
9701 (license license:lgpl2.0+)))
6689c636
MFM
9702
9703(define-public ruby-net-http-digest-auth
9704 (package
9705 (name "ruby-net-http-digest-auth")
ba074a85 9706 (version "1.4.1")
6689c636
MFM
9707 (source
9708 (origin
9709 (method url-fetch)
9710 (uri (rubygems-uri "net-http-digest_auth" version))
9711 (sha256
9712 (base32
ba074a85 9713 "1nq859b0gh2vjhvl1qh1zrk09pc7p54r9i6nnn6sb06iv07db2jb"))))
6689c636
MFM
9714 (build-system ruby-build-system)
9715 (native-inputs
9716 `(("ruby-hoe" ,ruby-hoe)))
9717 (synopsis "RFC 2617 HTTP digest authentication library")
9718 (description
9719 "This library implements HTTP's digest authentication scheme based on
9720RFC 2617. This enables the use of the digest authentication scheme instead
9721of the more insecure basic authentication scheme.")
7bf837fd 9722 (home-page "https://github.com/drbrain/net-http-digest_auth")
6689c636 9723 (license license:expat)))
06116573 9724
9725(define-public ruby-mail
9726 (package
9727 (name "ruby-mail")
04de0cb5 9728 (version "2.6.6")
06116573 9729 (source
9730 (origin
9731 (method url-fetch)
9732 (uri (rubygems-uri "mail" version))
9733 (sha256
9734 (base32
04de0cb5 9735 "0d7lhj2dw52ycls6xigkfz6zvfhc6qggply9iycjmcyj9760yvz9"))))
06116573 9736 (build-system ruby-build-system)
9737 (propagated-inputs
9738 `(("ruby-mime-types" ,ruby-mime-types)))
9739 (arguments
9740 ;; Tests require extra gems not included in the Gemfile.
9741 ;; XXX: Try enabling this for the next version with mini_mime.
9742 `(#:tests? #f))
9743 (synopsis "Mail library for Ruby")
9744 (description
9745 "Mail is an internet library for Ruby that is designed to handle email
9746generation, parsing and sending. The purpose of this library is to provide
9747a single point of access to handle all email functions, including sending
9748and receiving emails. All network type actions are done through proxy
9749methods to @code{Net::SMTP}, @code{Net::POP3} etc.
9750
9751Mail has been designed with a very simple object oriented system that
9752really opens up the email messages you are parsing, if you know what you
9753are doing, you can fiddle with every last bit of your email directly.")
9754 (home-page "https://github.com/mikel/mail")
9755 (license license:expat)))
9b4c8e1b 9756
4d372cb9
CB
9757(define-public ruby-mathn
9758 (package
9759 (name "ruby-mathn")
9760 (version "0.1.0")
9761 (source
9762 (origin
9763 (method url-fetch)
9764 (uri (rubygems-uri "mathn" version))
9765 (sha256
9766 (base32
9767 "1wn812llln9jzgybz2d7536q39z3gi99i6fi0j1dapcpzvhgrr0p"))))
9768 (build-system ruby-build-system)
9769 (native-inputs
9770 `(("bundler" ,bundler)
9771 ("ruby-rake-compiler" ,ruby-rake-compiler)))
9772 (synopsis "Extends math operations for increased precision")
9773 (description
9774 "This gem makes mathematical operations more precise in Ruby and
9775integrates other mathematical standard libraries. Prior to Ruby 2.5,
9776@code{mathn} was part of the Ruby standard library.")
9777 (home-page "https://github.com/ruby/mathn")
9778 (license license:bsd-2)))
9779
9b4c8e1b
BW
9780(define-public ruby-code-statistics
9781 (package
9782 (name "ruby-code-statistics")
9783 (version "0.2.13")
9784 (source
9785 (origin
9786 (method url-fetch)
9787 (uri (rubygems-uri "code_statistics" version))
9788 (sha256
9789 (base32
9790 "07rdpsbwbmh4vp8nxyh308cj7am2pbrfhv9v5xr2d5gq8hnnsm93"))))
9791 (build-system ruby-build-system)
9792 (arguments
9793 `(#:tests? #f)) ; Not all test code is included in gem.
9794 (synopsis "Port of the rails 'rake stats' method")
9795 (description
9796 "This gem is a port of the rails 'rake stats' method so it can be made
9797more robust and work for non rails projects.")
702a1012 9798 (home-page "https://github.com/danmayer/code_statistics")
9b4c8e1b 9799 (license license:expat)))
f90c25c1
CL
9800
9801(define-public ruby-rubypants
9802 (package
9803 (name "ruby-rubypants")
9804 (version "0.6.0")
9805 (source (origin
9806 (method url-fetch)
9807 (uri (rubygems-uri "rubypants" version))
9808 (sha256
9809 (base32
9810 "0xpqkslan2wkyal2h9qhplkr5d4sdn7q6csigrhnljjpp8j4qfsh"))))
9811 (build-system ruby-build-system)
9812 (arguments
9813 '(#:tests? #f)) ; need Codecov
9814 (synopsis "Port of the smart-quotes library SmartyPants")
9815 (description
9816 "RubyPants is a Ruby port of the smart-quotes library SmartyPants. The
9817original SmartyPants is a web publishing plug-in for Movable Type, Blosxom,
9818and BBEdit that easily translates plain ASCII punctuation characters into
9819smart typographic punctuation HTML entities.")
9820 (home-page "https://github.com/jmcnevin/rubypants")
9821 (license license:bsd-2)))
beb34835
CL
9822
9823(define-public ruby-org-ruby
9824 (package
9825 (name "ruby-org-ruby")
9826 (version "0.9.12")
9827 (source (origin
9828 (method url-fetch)
9829 (uri (rubygems-uri "org-ruby" version))
9830 (sha256
9831 (base32
9832 "0x69s7aysfiwlcpd9hkvksfyld34d8kxr62adb59vjvh8hxfrjwk"))))
9833 (build-system ruby-build-system)
9834 (arguments
9835 '(#:tests? #f)) ; no rakefile
9836 (propagated-inputs
9837 `(("ruby-rubypants" ,ruby-rubypants)))
9838 (synopsis "Org-mode parser written in Ruby")
9839 (description
9840 "Org-ruby is an org-mode parser written in Ruby. The most significant
9841thing this library does today is convert org-mode files to HTML or Textile or
9842Markdown.")
9843 (home-page "https://github.com/wallyqs/org-ruby")
9844 (license license:expat)))
670ee20a
BW
9845
9846(define-public ruby-rake
9847 (package
9848 (name "ruby-rake")
c997403a 9849 (version "13.0.1")
670ee20a
BW
9850 (source
9851 (origin
9852 (method url-fetch)
9853 (uri (rubygems-uri "rake" version))
9854 (sha256
9855 (base32
c997403a 9856 "0w6qza25bq1s825faaglkx1k6d59aiyjjk3yw3ip5sb463mhhai9"))))
670ee20a
BW
9857 (build-system ruby-build-system)
9858 (native-inputs
9859 `(("bundler" ,bundler)))
9860 (synopsis "Rake is a Make-like program implemented in Ruby")
9861 (description
9862 "Rake is a Make-like program where tasks and dependencies are specified
9863in standard Ruby syntax.")
9864 (home-page "https://github.com/ruby/rake")
9865 (license license:expat)))
45498f51 9866
51420124 9867(define-public ruby-childprocess
45498f51
DM
9868 (package
9869 (name "ruby-childprocess")
459e4a1a 9870 (version "3.0.0")
45498f51
DM
9871 (source
9872 (origin
9873 (method url-fetch)
9874 (uri (rubygems-uri "childprocess" version))
9875 (sha256
9876 (base32
459e4a1a 9877 "1ic028k8xgm2dds9mqnvwwx3ibaz32j8455zxr9f4bcnviyahya5"))))
45498f51
DM
9878 (build-system ruby-build-system)
9879 (arguments
9880 `(#:tests? #f))
9881 (native-inputs
9882 `(("bundler" ,bundler)
9883 ("ruby-rspec" ,ruby-rspec)))
9884 (propagated-inputs
9885 `(("ruby-ffi" ,ruby-ffi)))
9886 (synopsis "Control external programs running in the background, in Ruby")
9887 (description "@code{childprocess} provides a gem to control external
9888programs running in the background, in Ruby.")
459e4a1a 9889 (home-page "https://github.com/enkessler/childprocess")
45498f51 9890 (license license:expat)))
1f10e28d 9891
0d16905b
JL
9892(define-public ruby-public-suffix
9893 (package
9894 (name "ruby-public-suffix")
9de12df7 9895 (version "4.0.1")
0d16905b
JL
9896 (source (origin
9897 (method url-fetch)
9898 (uri (rubygems-uri "public_suffix" version))
9899 (sha256
9900 (base32
9de12df7 9901 "0xnfv2j2bqgdpg2yq9i2rxby0w2sc9h5iyjkpaas2xknwrgmhdb0"))))
0d16905b
JL
9902 (build-system ruby-build-system)
9903 (arguments
1f4fc125
CB
9904 '(#:phases
9905 (modify-phases %standard-phases
9906 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
9907 ;; including it as an input can lead to circular dependencies.
9908 (add-after 'unpack 'remove-rubocop-from-Rakefile
9909 (lambda _
9910 (substitute* "Rakefile"
9911 (("require \"rubocop/rake\\_task\"") "")
9912 (("RuboCop::RakeTask\\.new") ""))
9913 #t)))))
9914 (native-inputs
9915 `(("bundler" ,bundler)
9916 ("ruby-yard" ,ruby-yard)
9917 ("ruby-mocha" ,ruby-mocha)
9918 ("ruby-minitest-reporters" ,ruby-minitest-reporters)))
0d16905b
JL
9919 (home-page "https://simonecarletti.com/code/publicsuffix-ruby/")
9920 (synopsis "Domain name parser")
9921 (description "The gem @code{public_suffix} is a domain name parser,
9922written in Ruby, and based on the @dfn{Public Suffix List}. A public suffix
9923is one under which Internet users can (or historically could) directly
9924register names. Some examples of public suffixes are @code{.com},
9925@code{.co.uk} and @code{pvt.k12.ma.us}. The Public Suffix List is a list of
9926all known public suffixes.")
9927 (license license:expat)))
6f2c4efb
JL
9928
9929(define-public ruby-addressable
9930 (package
9931 (name "ruby-addressable")
91f7ee87 9932 (version "2.7.0")
6f2c4efb
JL
9933 (source (origin
9934 (method url-fetch)
9935 (uri (rubygems-uri "addressable" version))
9936 (sha256
9937 (base32
91f7ee87 9938 "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy"))))
6f2c4efb 9939 (build-system ruby-build-system)
0a794b30
CB
9940 (arguments
9941 '(#:test-target "spec"
9942 #:phases
9943 (modify-phases %standard-phases
9944 (add-after 'unpack 'remove-unnecessary-dependencies-from-Gemfile
9945 (lambda _
9946 (substitute* "Gemfile"
9947 (("git: 'https://github.com/sporkmonger/rack-mount.git',") "")
9948 ((".*launchy.*") "")
9949 ((".*rake.*") "gem 'rake'\n")
9950 ((".*redcarpet.*") ""))
9951 #t))
9952 (add-before 'check 'delete-network-dependent-test
9953 (lambda _
9954 (delete-file "spec/addressable/net_http_compat_spec.rb")
9955 #t)))))
9956 (native-inputs
9957 `(("ruby-rspec" ,ruby-rspec)
9958 ("bundler" ,bundler)
9959 ("ruby-idn-ruby" ,ruby-idn-ruby)
9960 ("ruby-sporkmonger-rack-mount" ,ruby-sporkmonger-rack-mount)
d7bd7016 9961 ("ruby-rspec-its", ruby-rspec-its-minimal)
0a794b30
CB
9962 ("ruby-yard" ,ruby-yard)
9963 ("ruby-simplecov" ,ruby-simplecov)))
6f2c4efb
JL
9964 (propagated-inputs
9965 `(("ruby-public-suffix" ,ruby-public-suffix)))
6f2c4efb
JL
9966 (home-page "https://github.com/sporkmonger/addressable")
9967 (synopsis "Alternative URI implementation")
9968 (description "Addressable is a replacement for the URI implementation that
9969is part of Ruby's standard library. It more closely conforms to RFC 3986,
9970RFC 3987, and RFC 6570 (level 4), providing support for IRIs and URI templates.")
9971 (license license:asl2.0)))
9c7f15c0 9972
305e9b33
MB
9973(define-public ruby-colorize
9974 (package
9975 (name "ruby-colorize")
9976 (version "0.8.1")
9977 (source (origin
9978 (method url-fetch)
9979 (uri (rubygems-uri "colorize" version))
9980 (sha256
9981 (base32
9982 "133rqj85n400qk6g3dhf2bmfws34mak1wqihvh3bgy9jhajw580b"))))
9983 (build-system ruby-build-system)
9984 (arguments
9985 '(#:phases (modify-phases %standard-phases
9986 (add-before 'check 'remove-codeclimate-dependency
9987 (lambda _
9988 (substitute* "test/test_colorize.rb"
9989 ;; Do not hook the tests into the online CodeClimate
9990 ;; service which is unnecessary for these tests.
9991 (("require 'codeclimate-test-reporter'")
9992 "")
9993 (("CodeClimate.*") ""))
9994 #t)))))
9995 (synopsis "Add color effects to the @code{String} class")
9996 (description
9997 "This package extends the @code{String} class and adds a
9998@code{ColorizedString} with methods to set text color, background color,
9999and text effects.")
702a1012 10000 (home-page "https://github.com/fazibear/colorize")
305e9b33
MB
10001 (license license:gpl2+)))
10002
9c7f15c0
JL
10003(define-public ruby-colorator
10004 (package
10005 (name "ruby-colorator")
10006 (version "1.1.0")
10007 (source (origin
10008 (method url-fetch)
10009 (uri (rubygems-uri "colorator" version))
10010 (sha256
10011 (base32
10012 "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"))))
10013 (build-system ruby-build-system)
10014 (arguments
10015 ;; No test target
10016 `(#:tests? #f))
10017 (home-page "http://octopress.org/colorator/")
10018 (synopsis "Terminal color library")
10019 (description "Colorator is a Ruby gem that helps you colorize your text
10020for the terminal.")
10021 (license license:expat)))
78b9c291
JL
10022
10023(define-public ruby-command-line-reporter
10024 (package
10025 (name "ruby-command-line-reporter")
b448e408 10026 (version "4.0.1")
78b9c291
JL
10027 (source (origin
10028 (method url-fetch)
10029 (uri (rubygems-uri "command_line_reporter" version))
10030 (sha256
10031 (base32
b448e408 10032 "1l0zxkh5n9dxfw46lpkg416ljpldlq1bgdhqh0d118dk338nz4ll"))))
78b9c291
JL
10033 (build-system ruby-build-system)
10034 (arguments
10035 ;; No Rakefile
10036 `(#:tests? #f
10037 #:phases
10038 (modify-phases %standard-phases
10039 (add-before 'build 'fix-dependencies
10040 (lambda _
10041 (substitute* ".gemspec"
10042 ;; colored is unmaintained
10043 (("colored") "colorator")
10044 ;; colorator version
10045 (("= 1.2") "= 1.1"))
10046 #t)))))
10047 (propagated-inputs `(("ruby-colorator" ,ruby-colorator)))
10048 (home-page "https://github.com/wbailey/command_line_reporter")
10049 (synopsis "Report production while executing Ruby scripts")
10050 (description "This gem provides a DSL that makes it easy to write reports
10051of various types in ruby. It eliminates the need to litter your source with
10052puts statements, instead providing a more readable, expressive interface to
10053your application.")
10054 (license license:asl2.0)))
f22c0387
JL
10055
10056(define-public ruby-command-line-reporter-3
10057 (package
10058 (inherit ruby-command-line-reporter)
10059 (version "3.3.6")
10060 (source (origin
10061 (method url-fetch)
10062 (uri (rubygems-uri "command_line_reporter" version))
10063 (sha256
10064 (base32
10065 "1h39zqqxp3k4qk49ajpx0jps1vmvxgkh43mqkb6znk583bl0fv71"))))))
6bba8ecf 10066
439d47cd
MC
10067(define-public ruby-kpeg
10068 (package
10069 (name "ruby-kpeg")
10070 (version "1.1.0")
10071 (source
10072 (origin
10073 (method url-fetch)
10074 (uri (rubygems-uri "kpeg" version))
10075 (sha256
10076 (base32
10077 "0x2kpfrcagj931masm5y1kwbnc6nxl60cqdcd3lyd1d2hz7kzlia"))))
10078 (build-system ruby-build-system)
10079 (native-inputs
10080 `(("ruby-hoe" ,ruby-hoe)))
10081 (synopsis "PEG library for Ruby")
10082 (description "KPeg is a simple PEG library for Ruby. It provides an API as
10083well as native grammar to build the grammar. KPeg supports direct left
10084recursion of rules via the
10085@uref{http://www.vpri.org/pdf/tr2008003_experimenting.pdf,OMeta memoization}
10086technique.")
10087 (home-page "https://github.com/evanphx/kpeg")
10088 (license license:expat)))
10089
6bba8ecf
JL
10090(define-public ruby-rdoc
10091 (package
10092 (name "ruby-rdoc")
9304f989 10093 (version "6.2.0")
6bba8ecf 10094 (source
9304f989
MC
10095 (origin
10096 (method git-fetch)
10097 (uri (git-reference
b0e7b699 10098 (url "https://github.com/ruby/rdoc")
9304f989
MC
10099 (commit (string-append "v" version))))
10100 (file-name (git-file-name name version))
10101 (sha256
10102 (base32
10103 "0dhk29nidv93b5vnjvlm9gcixgn4i0jcyzrgxdk6pdg019bw4cj6"))))
6bba8ecf 10104 (build-system ruby-build-system)
9304f989
MC
10105 (arguments
10106 `(#:phases
10107 (modify-phases %standard-phases
10108 (add-after 'unpack 'patch-gemspec
10109 ;; TODO: Remove after next release is tagged.
10110 (lambda _
10111 (substitute* "rdoc.gemspec"
10112 (("\"lib/rdoc/generator/template/darkfish/js/\
10113jquery\\.js\", ") ""))
10114 #t))
10115 (add-before 'build 'generate
10116 ;; 'gem build' doesn't honor Rakefile dependencies (see:
10117 ;; https://github.com/ruby/rdoc/issues/432#issuecomment-650808977).
10118 (lambda _
10119 (invoke "rake" "generate"))))))
6bba8ecf 10120 (native-inputs
9304f989
MC
10121 `(("bundler" ,bundler)
10122 ("ruby-kpeg" ,ruby-kpeg)
10123 ("ruby-racc" ,ruby-racc)
10124 ("ruby-rubocop" ,ruby-rubocop)))
6bba8ecf
JL
10125 (home-page "https://ruby.github.io/rdoc/")
10126 (synopsis "HTML and command-line documentation utility")
10127 (description "RDoc produces HTML and command-line documentation for Ruby
10128projects. RDoc includes the +rdoc+ and +ri+ tools for generating and displaying
10129documentation from the command-line.")
10130 (license license:gpl2+)))
18077ffc
JL
10131
10132(define-public ruby-sass-listen
10133 (package
10134 (name "ruby-sass-listen")
10135 (version "4.0.0")
10136 (source (origin
10137 (method url-fetch)
10138 (uri (rubygems-uri "sass-listen" version))
10139 (sha256
10140 (base32
10141 "0xw3q46cmahkgyldid5hwyiwacp590zj2vmswlll68ryvmvcp7df"))))
10142 (build-system ruby-build-system)
10143 (arguments
10144 ;; No test target
10145 `(#:tests? #f))
10146 (propagated-inputs
10147 `(("ruby-rb-fsevent" ,ruby-rb-fsevent)
10148 ("ruby-rb-inotify" ,ruby-rb-inotify)))
10149 (home-page "https://github.com/sass/listen")
10150 (synopsis "File modification notification library")
10151 (description "The Listen gem listens to file modifications and notifies you
10152about the changes.")
10153 (license license:expat)))
0c8eedc1
JL
10154
10155(define-public ruby-terminfo
10156 (package
10157 (name "ruby-terminfo")
10158 (version "0.1.1")
10159 (source
10160 (origin
10161 (method url-fetch)
10162 (uri (rubygems-uri "ruby-terminfo" version))
10163 (sha256
10164 (base32
10165 "0rl4ic5pzvrpgd42z0c1s2n3j39c9znksblxxvmhkzrc0ckyg2cm"))))
10166 (build-system ruby-build-system)
10167 (arguments
10168 `(#:test-target "test"
10169 ;; Rakefile requires old packages and would need modification to
10170 ;; work with current software.
10171 #:tests? #f))
10172 (inputs
10173 `(("ncurses" ,ncurses)))
10174 (native-inputs
10175 `(("ruby-rubygems-tasks" ,ruby-rubygems-tasks)
10176 ("ruby-rdoc" ,ruby-rdoc)))
10177 (home-page "http://www.a-k-r.org/ruby-terminfo/")
10178 (synopsis "Terminfo binding for Ruby")
10179 (description "Ruby-terminfo provides terminfo binding for Ruby.")
10180 (license license:bsd-3)))
ddc3a667
JL
10181
10182(define-public ruby-diffy
10183 (package
10184 (name "ruby-diffy")
10185 (version "3.2.1")
10186 (source
10187 (origin
10188 (method url-fetch)
10189 (uri (rubygems-uri "diffy" version))
10190 (sha256
10191 (base32
10192 "119imrkn01agwhx5raxhknsi331y5i4yda7r0ws0an6905ximzjg"))))
10193 (build-system ruby-build-system)
10194 (arguments
10195 ;; No tests
10196 `(#:tests? #f))
10197 (native-inputs
10198 `(("ruby-rspec" ,ruby-rspec)))
10199 (home-page "https://github.com/samg/diffy")
10200 (synopsis "Convenient diffing in ruby")
10201 (description "Diffy provides a convenient way to generate a diff from two
10202strings or files.")
10203 (license license:expat)))
6456beef
JL
10204
10205(define-public ruby-sass-spec
10206 (package
10207 (name "ruby-sass-spec")
10208 (version "3.5.4")
11df8321
TGR
10209 (source
10210 (origin
10211 (method git-fetch)
10212 (uri (git-reference
b0e7b699 10213 (url "https://github.com/sass/sass-spec")
11df8321
TGR
10214 (commit (string-append "v" version))))
10215 (file-name (git-file-name name version))
10216 (sha256
10217 (base32 "1zsw66830w0xlc7kxz6fm4b5nyb44vdsdgm9mgy06s5aixx83pwr"))))
6456beef
JL
10218 (build-system ruby-build-system)
10219 (propagated-inputs
10220 `(("ruby-command-line-reporter-3" ,ruby-command-line-reporter-3)
10221 ("ruby-diffy" ,ruby-diffy)
10222 ("ruby-terminfo" ,ruby-terminfo)))
10223 (arguments
2c7cb711
CB
10224 `(;; This package contains tests for a sass implementation, and the to
10225 ;; avoid any circular dependencies, the tests are not run here
10226 #:tests? #f
10227 #:phases
10228 (modify-phases %standard-phases
10229 (add-after 'unpack 'patch-test
10230 (lambda _
10231 (delete-file "spec/values/colors/alpha_hex-3.5/error")
10232 (substitute* "spec/values/colors/alpha_hex-3.5/expected_output.css"
10233 (("string") "color")))))))
6456beef
JL
10234 (home-page "https://github.com/sass/sass-spec")
10235 (synopsis "Test suite for Sass")
10236 (description "Sass Spec is a test suite for Sass. Test cases are all in
10237the @file{spec} directory.")
10238 (license license:expat)))
f00f4492
JL
10239
10240(define-public ruby-sass
10241 (package
10242 (name "ruby-sass")
11ff2adc 10243 (version "3.6.0")
f00f4492
JL
10244 (source (origin
10245 (method url-fetch)
10246 (uri (rubygems-uri "sass" version))
10247 (sha256
10248 (base32
11ff2adc 10249 "18c6prbw9wl8bqhb2435pd9s0lzarl3g7xf8pmyla28zblvwxmyh"))))
f00f4492
JL
10250 (build-system ruby-build-system)
10251 (propagated-inputs
10252 `(("ruby-sass-listen" ,ruby-sass-listen)))
10253 (native-inputs
11ff2adc
CB
10254 `(("ruby-sass-spec" ,ruby-sass-spec)
10255 ("ruby-mathn" ,ruby-mathn)))
3497086b 10256 (home-page "https://sass-lang.com/")
f00f4492
JL
10257 (synopsis "CSS extension language")
10258 (description "Sass is a CSS extension language. It extends CSS with
10259features that don't exist yet like variables, nesting, mixins and inheritance.")
10260 (license license:expat)))
5e242cb4 10261
9efc888d
CB
10262(define-public ruby-sassc
10263 (package
10264 (name "ruby-sassc")
3e776b44 10265 (version "2.2.1")
9efc888d
CB
10266 (source
10267 (origin
10268 (method url-fetch)
10269 (uri (rubygems-uri "sassc" version))
10270 (sha256
10271 (base32
3e776b44 10272 "09bnid7r5z5hcin5hykvpvv8xig27wbbckxwis60z2aaxq4j9siz"))))
9efc888d
CB
10273 (build-system ruby-build-system)
10274 (arguments
3e776b44
CB
10275 '(#:modules ((guix build ruby-build-system)
10276 (guix build utils)
10277 (ice-9 textual-ports))
10278 #:phases
9efc888d
CB
10279 (modify-phases %standard-phases
10280 ;; TODO: This would be better as a snippet, but the ruby-build-system
10281 ;; doesn't seem to support that
10282 (add-after 'unpack 'remove-libsass
10283 (lambda _
10284 (delete-file-recursively "ext")
3e776b44
CB
10285 (with-atomic-file-replacement "sassc.gemspec"
10286 (lambda (in out)
10287 (let* ((gemspec (get-string-all in))
10288 (index (string-contains gemspec "libsass_dir")))
10289 (display (string-append
10290 (string-take gemspec index)
10291 "\nend\n")
10292 out))))
9efc888d
CB
10293 #t))
10294 (add-after 'unpack 'dont-check-the-libsass-version
10295 (lambda _
10296 (substitute* "test/native_test.rb"
10297 (("assert_equal.*Native\\.version") ""))
10298 #t))
10299 (add-after 'unpack 'remove-git-from-gemspec
10300 (lambda _
10301 (substitute* "sassc.gemspec"
3e776b44 10302 (("`git ls-files -z`") "`find . -type f -print0 |sort -z`"))
9efc888d
CB
10303 #t))
10304 (add-after 'unpack 'remove-extensions-from-gemspec
10305 (lambda _
10306 (substitute* "sassc.gemspec"
3e776b44 10307 (("\\[\"ext/extconf.rb\"\\]") "[]"))
9efc888d
CB
10308 #t))
10309 (add-after 'unpack 'fix-Rakefile
10310 (lambda _
10311 (substitute* "Rakefile"
3e776b44 10312 (("test: 'compile:libsass'") ":test"))
9efc888d
CB
10313 #t))
10314 (add-after 'unpack 'remove-unnecessary-dependencies
10315 (lambda _
10316 (substitute* "test/test_helper.rb"
10317 (("require \"pry\"") ""))
10318 #t))
10319 (add-before 'build 'patch-native.rb
10320 (lambda* (#:key inputs #:allow-other-keys)
10321 (substitute* "lib/sassc/native.rb"
10322 ((".*gem_root = spec.gem_dir") "")
10323 (("ffi_lib .*\n")
10324 (string-append
10325 "ffi_lib '" (assoc-ref inputs "libsass") "/lib/libsass.so'")))
10326 #t))
10327 ;; The gemspec still references the libsass files, so just keep the
10328 ;; one in the gem.
10329 (delete 'extract-gemspec))))
10330 (propagated-inputs
10331 `(("ruby-ffi" ,ruby-ffi)
10332 ("ruby-rake" ,ruby-rake)))
10333 (inputs
10334 `(("libsass" ,libsass)))
10335 (native-inputs
10336 `(("bundler" ,bundler)
3e776b44 10337 ("ruby-rake-compiler" ,ruby-rake-compiler)
9efc888d
CB
10338 ("ruby-minitest-around" ,ruby-minitest-around)
10339 ("ruby-test-construct" ,ruby-test-construct)))
10340 (synopsis "Use libsss from Ruby")
10341 (description
10342 "This library provides Ruby q@acronym{FFI, Foreign Function Interface}
10343bindings to the libsass library. This enables rendering
10344@acronym{SASS,Syntactically awesome style sheets} from Ruby code.")
10345 (home-page "https://github.com/sass/sassc-ruby")
10346 (license license:expat)))
10347
5e242cb4
JL
10348(define-public ruby-jekyll-sass-converter
10349 (package
10350 (name "ruby-jekyll-sass-converter")
10351 (version "1.5.2")
10352 (source (origin
10353 (method url-fetch)
10354 (uri (rubygems-uri "jekyll-sass-converter" version))
10355 (sha256
10356 (base32
10357 "008ikh5fk0n6ri54mylcl8jn0mq8p2nfyfqif2q3pp0lwilkcxsk"))))
10358 (build-system ruby-build-system)
10359 (propagated-inputs
10360 `(("ruby-sass" ,ruby-sass)))
10361 (arguments
10362 ;; No rakefile
10363 `(#:tests? #f))
10364 (home-page "https://github.com/jekyll/jekyll-sass-converter")
10365 (synopsis "Sass converter for Jekyll")
10366 (description "This gem provide built-in support for the Sass converter
10367in Jekyll.")
10368 (license license:expat)))
ceac6f6f
JL
10369
10370(define-public ruby-jekyll-watch
10371 (package
10372 (name "ruby-jekyll-watch")
6cbba8a3 10373 (version "2.1.2")
ceac6f6f
JL
10374 (source (origin
10375 (method url-fetch)
10376 (uri (rubygems-uri "jekyll-watch" version))
10377 (sha256
10378 (base32
6cbba8a3 10379 "1s9ly83sp8albvgdff12xy2h4xd8lm6z2fah4lzmk2yvp85jzdzv"))))
ceac6f6f
JL
10380 (build-system ruby-build-system)
10381 (propagated-inputs
6cbba8a3 10382 `(("ruby-listen" ,ruby-listen)))
ceac6f6f
JL
10383 (arguments
10384 ;; No rakefile
10385 `(#:tests? #f))
10386 (home-page "https://github.com/jekyll/jekyll-watch")
10387 (synopsis "Jekyll auto-rebuild support")
10388 (description "This gems add the @code{--watch} switch to the jekyll CLI
10389interface. It allows Jekyll to rebuild your site when a file changes.")
10390 (license license:expat)))
3224a5a8
JL
10391
10392(define-public ruby-parallel
10393 (package
10394 (name "ruby-parallel")
c41fba01
CB
10395 (version "1.13.0")
10396 (source
10397 (origin
10398 (method git-fetch)
10399 (uri (git-reference
b0e7b699 10400 (url "https://github.com/grosser/parallel")
c41fba01
CB
10401 (commit (string-append "v" version))))
10402 (file-name (git-file-name name version))
10403 (sha256
10404 (base32
10405 "1isqzbqxz2ndad4i5z3lb9ldrhaijfncj8bmffv04sq44sv87ikv"))))
3224a5a8 10406 (build-system ruby-build-system)
c41fba01
CB
10407 (arguments
10408 `(;; TODO 3 test failures
10409 ;; rspec ./spec/parallel_spec.rb:190 # Parallel.in_processes does not
10410 ;; open unnecessary pipes
10411 ;; rspec './spec/parallel_spec.rb[1:9:7]' # Parallel.each works with
10412 ;; SQLite in processes
10413 ;; rspec './spec/parallel_spec.rb[1:9:16]' # Parallel.each works with
10414 ;; SQLite in threads
10415 #:tests? #f
10416 #:test-target "rspec-rerun:spec"
10417 #:phases
10418 (modify-phases %standard-phases
10419 (add-after 'unpack 'patch-Gemfile
10420 (lambda _
10421 (substitute* "Gemfile"
10422 (("gem 'rspec-legacy_formatters'") "")
10423 (("gem 'activerecord.*$") "gem 'activerecord'\n"))))
10424 (add-before 'check 'delete-Gemfile.lock
10425 (lambda _
10426 ;; Bundler isn't being used for fetching dependendencies, so
10427 ;; delete the Gemfile.lock
10428 (delete-file "Gemfile.lock")
10429 #t))
10430 (add-before 'build 'patch-gemspec
10431 (lambda _
10432 (substitute* "parallel.gemspec"
10433 (("git ls-files") "find"))
10434 #t)))))
10435 (native-inputs
10436 `(("ruby-rspec" ,ruby-rspec)
10437 ("ruby-rspec-rerun" ,ruby-rspec-rerun)
10438 ("bundler" ,bundler)
10439 ("ruby-activerecord" ,ruby-activerecord)
10440 ("ruby-progressbar" ,ruby-progressbar)
10441 ("ruby-bump" ,ruby-bump)
10442 ("procps" ,procps)
10443 ("lsof" ,lsof)
10444 ("ruby-mysql2" ,ruby-mysql2)
10445 ("ruby-sqlite3" ,ruby-sqlite3)
10446 ("ruby-i18n" ,ruby-i18n)))
3224a5a8
JL
10447 (home-page "https://github.com/grosser/parallel")
10448 (synopsis "Parallel processing in Ruby")
10449 (description "Parallel allows you to run any code in parallel Processes
10450(to use all CPUs) or Threads(to speedup blocking operations). It is best
10451suited for map-reduce or e.g. parallel downloads/uploads.")
10452 (license license:expat)))
83d9f672
JL
10453
10454(define-public ruby-cane
10455 (package
10456 (name "ruby-cane")
10457 (version "3.0.0")
10458 (source (origin
10459 (method url-fetch)
10460 (uri (rubygems-uri "cane" version))
10461 (sha256
10462 (base32
10463 "0yf5za3l7lhrqa3g56sah73wh33lbxy5y3cb7ij0a2bp1b4kwhih"))))
10464 (build-system ruby-build-system)
10465 (arguments `(#:tests? #f)); No rakefile
10466 (home-page "https://github.com/square/cane")
10467 (propagated-inputs
10468 `(("ruby-parallel" ,ruby-parallel)))
10469 (synopsis "Code quality threshold checking")
10470 (description "Cane fails your build if code quality thresholds are not met.")
10471 (license license:asl2.0)))
00d71efc
JL
10472
10473(define-public ruby-morecane
10474 (package
10475 (name "ruby-morecane")
10476 (version "0.2.0")
10477 (source (origin
10478 (method url-fetch)
10479 (uri (rubygems-uri "morecane" version))
10480 (sha256
10481 (base32
10482 "0w70vb8z5bdhvr21h660aa43m5948pv0bd27z7ngai2iwdvqd771"))))
10483 (build-system ruby-build-system)
10484 (home-page "https://github.com/yob/morecane")
10485 (arguments `(#:tests? #f)); No rakefile
10486 (propagated-inputs
10487 `(("ruby-parallel" ,ruby-parallel)))
10488 (synopsis "Extra checks for cane")
10489 (description "The cane gem provides a great framework for running quality
10490checks over your ruby project as part of continuous integration build. It
10491comes with a few checks out of the box, but also provides an API for loading
10492custom checks. This gem provides a set of additional checks.")
10493 (license license:expat)))
abbe629c
JL
10494
10495(define-public ruby-pdf-reader
10496 (package
10497 (name "ruby-pdf-reader")
b377dd95 10498 (version "2.4.0")
abbe629c 10499 (source (origin
34796d7a
MC
10500 (method git-fetch) ;no test in distributed gem archive
10501 (uri (git-reference
10502 (url "https://github.com/yob/pdf-reader.git")
10503 (commit (string-append "v" version))))
10504 (file-name (git-file-name name version))
abbe629c
JL
10505 (sha256
10506 (base32
34796d7a 10507 "1yh8yrlssf5ppnkvk4m78vmh5r5vqwdcd0gm3lqipw162llz0rai"))))
abbe629c 10508 (build-system ruby-build-system)
34796d7a
MC
10509 (arguments `(#:test-target "spec"
10510 #:phases (modify-phases %standard-phases
10511 (add-after 'unpack 'do-not-use-bundler
10512 (lambda _
10513 (substitute* "spec/spec_helper.rb"
10514 ((".*[Bb]undler.*") ""))
10515 #t)))))
abbe629c 10516 (native-inputs
34796d7a 10517 `(("ruby-rspec" ,ruby-rspec)
abbe629c
JL
10518 ("ruby-cane" ,ruby-cane)
10519 ("ruby-morecane" ,ruby-morecane)))
10520 (propagated-inputs
10521 `(("ruby-afm" ,ruby-afm)
10522 ("ruby-ascii85" ,ruby-ascii85)
10523 ("ruby-hashery" ,ruby-hashery)
10524 ("ruby-rc4" ,ruby-rc4)
10525 ("ruby-ttfunk" ,ruby-ttfunk)))
10526 (home-page "https://github.com/yob/pdf-reader")
10527 (synopsis "PDF parser in Ruby")
10528 (description "The PDF::Reader library implements a PDF parser conforming as
10529much as possible to the PDF specification from Adobe. It provides programmatic
10530access to the contents of a PDF file with a high degree of flexibility.")
10531 (license license:gpl3+)))
461fb859
JL
10532
10533(define-public ruby-pdf-inspector
ed2f26f8
MC
10534 (let ((revision "1")
10535 (commit "00ee4c92ff917118785ebec188e81effc968abeb"))
10536 (package
10537 (name "ruby-pdf-inspector")
10538 (version (git-version "1.3.0" revision commit))
10539 (source (origin
10540 (method git-fetch)
10541 (uri (git-reference
10542 (url "https://github.com/prawnpdf/pdf-inspector.git")
10543 (commit commit)))
10544 (file-name (git-file-name name version))
10545 (sha256
10546 (base32
10547 "0h9w81ddd0gvkh5n2cvny9ddb5qiac1si0dhinkk0xxh5382qs0m"))))
10548 (build-system ruby-build-system)
10549 (arguments
10550 `(#:test-target "spec"
10551 #:phases (modify-phases %standard-phases
10552 (add-before 'build 'drop-signing-key-requirement
10553 (lambda _
10554 (substitute* "pdf-inspector.gemspec"
10555 (("spec.signing_key =.*")
10556 "spec.signing_key = nil"))
10557 #t))
10558 (replace 'check
10559 (lambda _
10560 (substitute* "pdf-inspector.gemspec"
10561 ((".*rubocop.*") "")
10562 ((".*yard.*") ""))
10563 (invoke "rspec"))))))
10564 (native-inputs
10565 `(("ruby-rspec" ,ruby-rspec)))
10566 (propagated-inputs
10567 `(("ruby-pdf-reader" ,ruby-pdf-reader)))
10568 (home-page "https://github.com/prawnpdf/pdf-inspector")
10569 (synopsis "Analysis classes for inspecting PDF output")
10570 (description "This library provides a number of PDF::Reader based tools for
461fb859
JL
10571use in testing PDF output. Presently, the primary purpose of this tool is to
10572support the tests found in Prawn, a pure Ruby PDF generation library.")
ed2f26f8 10573 (license %prawn-project-licenses))))
770e3b53
JL
10574
10575(define-public ruby-pdf-core
10576 (package
10577 (name "ruby-pdf-core")
10578 (version "0.8.1")
10579 (source (origin
10580 (method url-fetch)
10581 (uri (rubygems-uri "pdf-core" version))
10582 (sha256
10583 (base32
10584 "15d6m99bc8bbzlkcg13qfpjjzphfg5x905pjbfygvpcxsm8gnsvg"))))
10585 (build-system ruby-build-system)
10586 (arguments
10587 ; No test target
10588 `(#:tests? #f))
10589 (home-page "https://github.com/prawnpdf/pdf-core")
10590 (synopsis "Low level PDF features for Prawn")
10591 (description "This is an experimental gem that extracts low-level PDF
10592functionality from Prawn.")
10593 (license license:gpl3+)))
37fbced7 10594
7ad8dd08 10595(define-public ruby-prawn
e6c7a601
MC
10596 ;; There hasn't been a new release since 2017/03/17.
10597 (let ((revision "1")
10598 (commit "d980247be8a00e7c59cd4e5785e3aa98f9856db1"))
10599 (package
10600 (name "ruby-prawn")
10601 (version (git-version "2.2.2" revision commit))
10602 (source (origin
10603 (method git-fetch)
10604 (uri (git-reference
10605 (url "https://github.com/prawnpdf/prawn.git")
10606 (commit commit)))
10607 (file-name (git-file-name name version))
10608 (sha256
10609 (base32
10610 "0mcmvf22h8il93yq48v9f31qpy27pvjxgv9172p0f4x9lqy0imwr"))))
10611 (build-system ruby-build-system)
10612 (arguments
10613 `(#:phases
10614 (modify-phases %standard-phases
10615 (add-before 'build 'drop-signing-key-requirement
10616 (lambda _
10617 (substitute* "prawn.gemspec"
10618 (("spec.signing_key =.*")
10619 "spec.signing_key = nil"))
10620 #t))
10621 (replace 'check
10622 (lambda* (#:key tests? #:allow-other-keys)
10623 (when tests?
10624 ;; The Prawn manual test fails (see:
10625 ;; https://github.com/prawnpdf/prawn/issues/1163), so exclude
10626 ;; it.
10627 (invoke "rspec" "--exclude-pattern" "prawn_manual_spec.rb"))
10628 #t)))))
10629 (propagated-inputs
10630 `(("ruby-pdf-core" ,ruby-pdf-core)
10631 ("ruby-ttfunk" ,ruby-ttfunk)))
10632 (native-inputs
10633 `(("ruby-pdf-inspector" ,ruby-pdf-inspector)
10634 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
10635 ("ruby-rspec" ,ruby-rspec)
10636 ("ruby-simplecov" ,ruby-simplecov)
10637 ("ruby-yard" ,ruby-yard)))
10638 (home-page "https://prawnpdf.org/api-docs/2.0/")
10639 (synopsis "PDF generation for Ruby")
10640 (description "Prawn is a pure Ruby PDF generation library.")
10641 (license %prawn-project-licenses))))
197ca8ec
JL
10642
10643(define-public ruby-prawn-table
10644 (package
10645 (name "ruby-prawn-table")
10646 (version "0.2.2")
10647 (source (origin
10648 (method url-fetch)
10649 (uri (rubygems-uri "prawn-table" version))
10650 (sha256
10651 (base32
10652 "1nxd6qmxqwl850icp18wjh5k0s3amxcajdrkjyzpfgq0kvilcv9k"))))
10653 (build-system ruby-build-system)
197ca8ec 10654 (propagated-inputs
0927b039
CB
10655 `(("ruby-prawn" ,ruby-prawn)
10656 ("ruby-pdf-inspector" ,ruby-pdf-inspector)))
10657 (native-inputs
10658 `(("bundler" ,bundler)
10659 ("ruby-yard" ,ruby-yard)
10660 ("ruby-mocha" ,ruby-mocha)
10661 ("ruby-coderay" ,ruby-coderay)
10662 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
10663 ("ruby-simplecov" ,ruby-simplecov)
10664 ("ruby-rspec-2" ,ruby-rspec-2)))
10665 (arguments
10666 '(;; TODO: 1 test fails
10667 ;; Failure/Error: pdf.page_count.should == 1
10668 ;; expected: 1
10669 ;; got: 2 (using ==)
10670 ;; # ./spec/table_spec.rb:1308
10671 ;;
10672 ;; 225 examples, 1 failure
10673 #:tests? #f
10674 #:phases
10675 (modify-phases %standard-phases
10676 (add-before 'check 'patch-gemspec
10677 (lambda _
10678 (substitute* "prawn-table.gemspec"
10679 ;; Loosen the requirement for pdf-inspector
10680 (("~> 1\\.1\\.0") ">= 0")
10681 ;; Loosen the requirement for pdf-reader
10682 (("~> 1\\.2") ">= 0"))))
10683 (replace 'check
10684 (lambda* (#:key tests? #:allow-other-keys)
10685 (when tests?
10686 (invoke "rspec"))
10687 #t)))))
197ca8ec
JL
10688 (home-page "https://github.com/prawnpdf/prawn-table")
10689 (synopsis "Tables support for Prawn")
10690 (description "This gem provides tables support for Prawn.")
10691 (license license:gpl3+)))
03127069
JL
10692
10693(define-public ruby-kramdown
10694 (package
10695 (name "ruby-kramdown")
10696 (version "1.17.0")
10697 (source (origin
10698 (method url-fetch)
10699 (uri (rubygems-uri "kramdown" version))
10700 (sha256
10701 (base32
10702 "1n1c4jmrh5ig8iv1rw81s4mw4xsp4v97hvf8zkigv4hn5h542qjq"))))
10703 (build-system ruby-build-system)
10704 (arguments `(#:tests? #f)); FIXME: some test failures
10705 (native-inputs
10706 `(("ruby-prawn" ,ruby-prawn)
10707 ("ruby-prawn-table" ,ruby-prawn-table)))
10708 (home-page "https://kramdown.gettalong.org/")
10709 (synopsis "Markdown parsing and converting library")
10710 (description "Kramdown is a library for parsing and converting a superset
10711of Markdown. It is completely written in Ruby, supports standard Markdown
10712(with some minor modifications) and various extensions that have been made
10713popular by the PHP @code{Markdown Extra} package and @code{Maruku}.")
10714 (license license:expat)))
fa0063bc
JL
10715
10716(define-public ruby-http-parser.rb
10717 (package
10718 (name "ruby-http-parser.rb")
10719 (version "0.6.0")
10720 (source
10721 (origin
10722 (method url-fetch)
10723 (uri (rubygems-uri "http_parser.rb" version))
10724 (sha256
10725 (base32
10726 "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"))))
10727 (build-system ruby-build-system)
10728 (arguments
10729 ;; No tests
10730 `(#:tests? #f))
10731 (native-inputs
10732 `(("ruby-rake-compiler" ,ruby-rake-compiler)
10733 ("ruby-rspec" ,ruby-rspec)))
10734 (home-page "https://github.com/tmm1/http_parser.rb")
10735 (synopsis "HTTP parser un Ruby")
10736 (description "This gem is a simple callback-based HTTP request/response
10737parser for writing http servers, clients and proxies.")
10738 (license license:expat)))
5e2f74bd
JL
10739
10740(define-public ruby-em-websocket
10741 (package
10742 (name "ruby-em-websocket")
10743 (version "0.5.1")
10744 (source
10745 (origin
10746 (method url-fetch)
10747 (uri (rubygems-uri "em-websocket" version))
10748 (sha256
10749 (base32
10750 "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"))))
10751 (build-system ruby-build-system)
10752 (arguments
10753 ;; No tests
10754 `(#:tests? #f))
10755 (propagated-inputs
10756 `(("ruby-eventmachine" ,ruby-eventmachine)
10757 ("ruby-http-parser.rb" ,ruby-http-parser.rb)))
10758 (native-inputs
10759 `(("bundler" ,bundler)
10760 ("ruby-rspec" ,ruby-rspec)))
10761 (home-page "https://github.com/igrigorik/em-websocket")
10762 (synopsis "EventMachine based WebSocket server")
10763 (description "Em-websocket is an EventMachine based WebSocket server
10764implementation.")
10765 (license license:expat)))
4ce0414b
JL
10766
10767(define-public ruby-rouge
10768 (package
10769 (name "ruby-rouge")
22d6b534 10770 (version "3.21.0")
4ce0414b
JL
10771 (source (origin
10772 (method url-fetch)
10773 (uri (rubygems-uri "rouge" version))
10774 (sha256
10775 (base32
22d6b534 10776 "1agrrmj88k9jkk36ra1ml2c1jffpp595pkxmcla74ac9ia09vn3s"))))
4ce0414b
JL
10777 (build-system ruby-build-system)
10778 (arguments `(#:tests? #f)); No rakefile
10779 (home-page "http://rouge.jneen.net/")
10780 (synopsis "Code highlighter")
10781 (description "Rouge is a code highlighter written in Ruby. It supports more
10782than 100 languages and outputs HTML or ANSI 256-color text. Its HTML output
10783is compatible with stylesheets designed for pygments.")
10784 (license (list
10785 ;; rouge is licensed under expat
10786 license:expat
10787 ;; pygments is licensed under bsd-2
10788 license:bsd-2))))
2c5028bd
JL
10789
10790(define-public ruby-rouge-2
10791 (package
10792 (inherit ruby-rouge)
10793 (version "2.2.1")
10794 (source (origin
10795 (method url-fetch)
10796 (uri (rubygems-uri "rouge" version))
10797 (sha256
10798 (base32
10799 "02kpahk5nkc33yxnn75649kzxaz073wvazr2zyg491nndykgnvcs"))))))
2e072e37
JL
10800
10801(define-public ruby-hashie
10802 (package
10803 (name "ruby-hashie")
10804 (version "3.6.0")
10805 (source (origin
10806 (method url-fetch)
10807 (uri (rubygems-uri "hashie" version))
10808 (sha256
10809 (base32
10810 "13bdzfp25c8k51ayzxqkbzag3wj5gc1jd8h7d985nsq6pn57g5xh"))))
10811 (build-system ruby-build-system)
10812 (native-inputs
10813 `(("bundler" ,bundler)))
10814 (arguments `(#:tests? #f)); FIXME: Could not locate Gemfile or .bundle/ directory
10815 (home-page "https://github.com/intridea/hashie")
10816 (synopsis "Extensions to Ruby Hashes")
10817 (description "Hashie is a collection of classes and mixins that make Ruby
10818hashes more powerful.")
10819 (license license:expat)))
73bfc125
JL
10820
10821(define-public ruby-heredoc-unindent
10822 (package
10823 (name "ruby-heredoc-unindent")
10824 (version "1.2.0")
10825 (source (origin
10826 (method url-fetch)
10827 (uri (rubygems-uri "heredoc_unindent" version))
10828 (sha256
10829 (base32
10830 "14ijr2fsjwhrkjkcaz81d5xnfa4vvgvcflrff83avqw9klm011yw"))))
10831 (build-system ruby-build-system)
10832 (native-inputs
10833 `(("ruby-hoe" ,ruby-hoe)))
10834 (home-page "https://github.com/adrianomitre/heredoc_unindent")
10835 (synopsis "Heredoc indentation cleaner")
10836 (description "This gem removes common margin from indented strings, such
10837as the ones produced by indented heredocs. In other words, it strips out
4f66ae28 10838leading whitespace chars at the beginning of each line, but only as much as
73bfc125
JL
10839the line with the smallest margin.
10840
10841It is acknowledged that many strings defined by heredocs are just code and
10842fact is that most parsers are insensitive to indentation. If, however, the
10843strings are to be used otherwise, be it for printing or testing, the extra
10844indentation will probably be an issue and hence this gem.")
10845 (license license:expat)))
f8ae2ee5
JL
10846
10847(define-public ruby-safe-yaml
10848 (package
10849 (name "ruby-safe-yaml")
7fa83fa8 10850 (version "1.0.5")
28cf8dab
CB
10851 (source
10852 (origin
28cf8dab
CB
10853 (method git-fetch)
10854 (uri (git-reference
b0e7b699 10855 (url "https://github.com/dtao/safe_yaml")
28cf8dab
CB
10856 (commit version)))
10857 (file-name (git-file-name name version))
10858 (sha256
10859 (base32
7fa83fa8 10860 "1a0wh7y3va2m7bjza95na2snw0vrdh9syz40mpjvjphbc4ph3pzg"))))
f8ae2ee5
JL
10861 (build-system ruby-build-system)
10862 (native-inputs
10863 `(("ruby-rspec" ,ruby-rspec)
10864 ("ruby-hashie" ,ruby-hashie)
10865 ("ruby-heredoc-unindent" ,ruby-heredoc-unindent)))
28cf8dab
CB
10866 (arguments
10867 '(#:test-target "spec"
10868 #:phases
10869 (modify-phases %standard-phases
10870 (add-before 'check 'set-TZ
10871 (lambda _
10872 ;; This test is dependent on the timezone
10873 ;; spec/transform/to_date_spec.rb:35
10874 ;; # SafeYAML::Transform::ToDate converts times to the local
10875 ;; timezone
10876 (setenv "TZ" "UTC-11")
10877 #t)))))
f8ae2ee5
JL
10878 (home-page "https://github.com/dtao/safe_yaml")
10879 (synopsis "YAML parser")
10880 (description "The SafeYAML gem provides an alternative implementation of
10881YAML.load suitable for accepting user input in Ruby applications.")
10882 (license license:expat)))
f1ec4d76
JL
10883
10884(define-public ruby-mercenary
10885 (package
10886 (name "ruby-mercenary")
10887 (version "0.3.6")
10888 (source (origin
10889 (method url-fetch)
10890 (uri (rubygems-uri "mercenary" version))
10891 (sha256
10892 (base32
10893 "10la0xw82dh5mqab8bl0dk21zld63cqxb1g16fk8cb39ylc4n21a"))))
10894 (build-system ruby-build-system)
10895 (arguments `(#:test-target "spec"))
10896 (native-inputs
10897 `(("bundler" ,bundler)))
10898 (home-page "https://github.com/jekyll/mercenary")
10899 (synopsis "Command-line apps library in Ruby")
10900 (description "Mercenary is a lightweight and flexible library for writing
10901command-line apps in Ruby.")
10902 (license license:expat)))
a13d451e
JL
10903
10904(define-public ruby-liquid
10905 (package
10906 (name "ruby-liquid")
10907 (version "4.0.0")
10908 (source (origin
10909 (method url-fetch)
10910 (uri (rubygems-uri "liquid" version))
10911 (sha256
10912 (base32
10913 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))
10914 (build-system ruby-build-system)
10915 (arguments `(#:tests? #f)); No rakefile
10916 (home-page "https://shopify.github.io/liquid/")
10917 (synopsis "Template language")
10918 (description "Liquid is a template language written in Ruby. It is used
10919to load dynamic content on storefronts.")
10920 (license license:expat)))
49395112
JL
10921
10922(define-public ruby-forwardable-extended
10923 (package
10924 (name "ruby-forwardable-extended")
10925 (version "2.6.0")
10926 (source (origin
10927 (method url-fetch)
10928 (uri (rubygems-uri "forwardable-extended" version))
10929 (sha256
10930 (base32
10931 "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"))))
10932 (build-system ruby-build-system)
10933 (arguments `(#:tests? #f)); Cyclic dependency on luna-rspec-formatters
10934 (home-page "https://github.com/envygeeks/forwardable-extended")
10935 (synopsis "Delegation to hashes and instance variables in Forwardable")
10936 (description "Forwardable Extended provides more @code{Forwardable}
10937methods for your source as @code{Forwardable::Extended}.")
10938 (license license:expat)))
37296113
JL
10939
10940(define-public ruby-pathutil
10941 (package
10942 (name "ruby-pathutil")
feaaa603 10943 (version "0.16.2")
37296113
JL
10944 (source (origin
10945 (method url-fetch)
10946 (uri (rubygems-uri "pathutil" version))
10947 (sha256
10948 (base32
feaaa603 10949 "12fm93ljw9fbxmv2krki5k5wkvr7560qy8p4spvb9jiiaqv78fz4"))))
37296113
JL
10950 (build-system ruby-build-system)
10951 (propagated-inputs
10952 `(("ruby-forwardable-extended" ,ruby-forwardable-extended)))
10953 (native-inputs
10954 `(("bundler" ,bundler)
10955 ("ruby-rspec" ,ruby-rspec)))
10956 ;; Fails with: cannot load such file --
10957 ;; /tmp/guix-build-ruby-pathutil-0.16.0.drv-0/gem/benchmark/support/task
10958 (arguments `(#:tests? #f))
10959 (home-page "https://github.com/envygeeks/pathutil")
10960 (synopsis "Extended implementation of Pathname")
10961 (description "Pathutil tries to be a faster pure Ruby implementation of
10962Pathname.")
10963 (license license:expat)))
49e1dde5
JL
10964
10965(define-public jekyll
10966 (package
10967 (name "jekyll")
fcf82fd3 10968 (version "3.8.6")
49e1dde5
JL
10969 (source (origin
10970 (method url-fetch)
10971 (uri (rubygems-uri "jekyll" version))
10972 (sha256
10973 (base32
fcf82fd3 10974 "1ph1jjjl25vmzif7bvxzviq7azjm384pm7ba4k24cah94285bzhz"))))
49e1dde5
JL
10975 (build-system ruby-build-system)
10976 (arguments
fcf82fd3 10977 ;; No rakefile, but a test subdirectory.
49e1dde5
JL
10978 `(#:tests? #f
10979 #:phases
10980 (modify-phases %standard-phases
10981 (add-before 'build 'fix-i18n
10982 (lambda _
10983 (substitute* ".gemspec"
10984 (("~> 0.7") ">= 0.7"))
10985 #t)))))
10986 (propagated-inputs
10987 `(("ruby-addressable" ,ruby-addressable)
10988 ("ruby-colorator" ,ruby-colorator)
10989 ("ruby-em-websocket" ,ruby-em-websocket)
10990 ("ruby-i18n" ,ruby-i18n)
10991 ("ruby-jekyll-sass-converter" ,ruby-jekyll-sass-converter)
10992 ("ruby-jekyll-watch" ,ruby-jekyll-watch)
10993 ("ruby-kramdown" ,ruby-kramdown)
10994 ("ruby-liquid" ,ruby-liquid)
10995 ("ruby-mercenary" ,ruby-mercenary)
10996 ("ruby-pathutil" ,ruby-pathutil)
10997 ("ruby-rouge" ,ruby-rouge-2)
10998 ("ruby-safe-yaml" ,ruby-safe-yaml)))
10999 (home-page "https://jekyllrb.com/")
11000 (synopsis "Static site generator")
11001 (description "Jekyll is a simple, blog aware, static site generator.")
11002 (license license:expat)))
37a0f470
JL
11003
11004(define-public ruby-jekyll-paginate-v2
11005 (package
11006 (name "ruby-jekyll-paginate-v2")
11007 (version "2.0.0")
11008 (source (origin
11009 (method url-fetch)
11010 (uri (rubygems-uri "jekyll-paginate-v2" version))
11011 (sha256
11012 (base32
11013 "154bfpyml6abxww9868hhyfvxasl8qhsc5zy2q30c7dxaj0igdib"))))
11014 (build-system ruby-build-system)
11015 (propagated-inputs
11016 `(("jekyll" ,jekyll)))
11017 (home-page "https://github.com/sverrirs/jekyll-paginate-v2")
11018 (synopsis "Pagination Generator for Jekyll 3")
11019 (description "The Pagination Generator forms the core of the pagination
11020logic in Jekyll. It calculates and generates the pagination pages.")
11021 (license license:expat)))
909eae21
CB
11022
11023(define-public ruby-faraday
11024 (package
11025 (name "ruby-faraday")
11026 (version "0.15.4")
11027 (source
11028 (origin
11029 (method url-fetch)
11030 (uri (rubygems-uri "faraday" version))
11031 (sha256
11032 (base32
11033 "0s72m05jvzc1pd6cw1i289chas399q0a14xrwg4rvkdwy7bgzrh0"))))
11034 (build-system ruby-build-system)
11035 (arguments
11036 '(#:tests? #f))
11037 (propagated-inputs
11038 `(("ruby-multipart-post" ,ruby-multipart-post)))
11039 (synopsis "Ruby HTTP/REST API client library")
11040 (description
11041 "Faraday is a HTTP/REST API client library which provides a common
11042interface over different adapters.")
11043 (home-page "https://github.com/lostisland/faraday")
11044 (license license:expat)))
a058cbfd
CB
11045
11046(define-public ruby-nio4r
11047 (package
11048 (name "ruby-nio4r")
7923b9bf 11049 (version "2.5.2")
a058cbfd
CB
11050 (source
11051 (origin
11052 (method url-fetch)
11053 (uri (rubygems-uri "nio4r" version))
11054 (sha256
11055 (base32
7923b9bf 11056 "0gnmvbryr521r135yz5bv8354m7xn6miiapfgpg1bnwsvxz8xj6c"))))
a058cbfd
CB
11057 (build-system ruby-build-system)
11058 (arguments
11059 '(#:phases
11060 (modify-phases %standard-phases
11061 (add-after 'unpack 'remove-unnecessary-dependencies
11062 (lambda _
11063 (substitute* "spec/spec_helper.rb"
11064 ;; Coveralls is for uploading test coverage information to an
11065 ;; online service, and thus unnecessary for building the Guix
11066 ;; package
11067 (("require \"coveralls\"") "")
11068 (("Coveralls\\.wear!") "")
11069 ;; Remove rspec/retry as we are not retrying the tests
11070 (("require \"rspec/retry\"") "")
11071 (("config\\.display_try_failure_messages = true") "")
11072 (("config\\.verbose_retry = true") ""))
11073 #t))
11074 (add-before 'check 'compile
11075 (lambda _
11076 (invoke "rake" "compile")
11077 #t))
11078 (replace 'check
11079 (lambda* (#:key tests? #:allow-other-keys)
11080 (when tests?
11081 (invoke "rspec"))
11082 #t)))))
11083 (native-inputs
11084 `(("bundler" ,bundler)
11085 ("ruby-rake-compiler" ,ruby-rake-compiler)
11086 ("ruby-rspec" ,ruby-rspec)
11087 ("ruby-rubocop" ,ruby-rubocop)))
11088 (synopsis "New I/O for Ruby")
11089 (description
11090 "@code{nio} provides cross-platform asynchronous I/O primitives in Ruby
11091for scalable network clients and servers.")
11092 (home-page "https://github.com/socketry/nio4r")
11093 (license license:expat)))
f9da1ada
CB
11094
11095(define-public ruby-globalid
11096 (package
11097 (name "ruby-globalid")
11098 (version "0.4.2")
11099 (source
11100 (origin
11101 (method url-fetch)
11102 (uri (rubygems-uri "globalid" version))
11103 (sha256
11104 (base32
11105 "1zkxndvck72bfw235bd9nl2ii0lvs5z88q14706cmn702ww2mxv1"))))
11106 (build-system ruby-build-system)
11107 (arguments
11108 '(;; No included tests
11109 #:tests? #f))
11110 (propagated-inputs
11111 `(("ruby-activesupport" ,ruby-activesupport)))
11112 (synopsis "Generate URIs idenfitying model instances in Ruby")
11113 (description
11114 "@code{GlobalID} provides a way to generate URIs from a model in Ruby that
11115uniquely identify it.")
11116 (home-page "https://rubyonrails.org/")
11117 (license license:expat)))
15606d98
CB
11118
11119(define-public ruby-sprockets
11120 (package
11121 (name "ruby-sprockets")
11122 (version "3.7.2")
11123 (source
11124 (origin
11125 (method url-fetch)
11126 (uri (rubygems-uri "sprockets" version))
11127 (sha256
11128 (base32
11129 "182jw5a0fbqah5w9jancvfmjbk88h8bxdbwnl4d3q809rpxdg8ay"))))
11130 (build-system ruby-build-system)
11131 (arguments
11132 '(;; No included tests
11133 #:tests? #f))
11134 (propagated-inputs
11135 `(("ruby-concurrent" ,ruby-concurrent)
11136 ("ruby-rack" ,ruby-rack)))
11137 (synopsis "Sprockets is a Rack-based asset packaging system")
11138 (description
11139 "Sprockets is a Rack-based asset packaging system that concatenates and
11140serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.")
11141 (home-page "https://github.com/rails/sprockets")
11142 (license license:expat)))
acb9e3d8
PN
11143
11144(define-public ruby-mustermann
11145 (package
11146 (name "ruby-mustermann")
11147 (version "1.0.3")
11148 (source
11149 (origin
11150 (method url-fetch)
11151 (uri (rubygems-uri "mustermann" version))
11152 (sha256
11153 (base32
11154 "0lycgkmnyy0bf29nnd2zql5a6pcf8sp69g9v4xw0gcfcxgpwp7i1"))))
11155 (build-system ruby-build-system)
11156 (arguments
11157 ;; No tests.
11158 '(#:tests? #f))
11159 (synopsis "Library implementing patterns that behave like regular expressions")
11160 (description "Given a string pattern, Mustermann will turn it into an
11161object that behaves like a regular expression and has comparable performance
11162characteristics.")
11163 (home-page "https://github.com/sinatra/mustermann")
11164 (license license:expat)))
3bb094e2 11165
7bddb6aa
BL
11166(define-public ruby-htmlentities
11167 (package
11168 (name "ruby-htmlentities")
11169 (version "4.3.4")
11170 (source
11171 (origin
11172 (method url-fetch)
11173 (uri (rubygems-uri "htmlentities" version))
11174 (sha256
11175 (base32
11176 "1nkklqsn8ir8wizzlakncfv42i32wc0w9hxp00hvdlgjr7376nhj"))))
11177 (build-system ruby-build-system)
11178 (arguments
11179 `(#:phases
11180 (modify-phases %standard-phases
11181 (replace 'check
11182 (lambda _
11183 (map (lambda (file)
11184 (invoke "ruby" "-Itest" file))
11185 (find-files "./test" ".*_test\\.rb")))))))
11186 (synopsis "Encode and decode (X)HTML entities")
11187 (description
11188 "This package provides a module for encoding and decoding (X)HTML
11189entities.")
11190 (home-page "https://github.com/threedaymonk/htmlentities")
11191 (license license:expat)))
11192
3bb094e2
PN
11193(define-public ruby-sinatra
11194 (package
11195 (name "ruby-sinatra")
7af92924 11196 (version "2.0.8.1")
3bb094e2
PN
11197 (source
11198 (origin
11199 (method url-fetch)
11200 (uri (rubygems-uri "sinatra" version))
11201 (sha256
11202 (base32
7af92924 11203 "0riy3hwjab1mr73jcqx3brmbmwspnw3d193j06a5f0fy1w35z15q"))))
3bb094e2 11204 (build-system ruby-build-system)
7af92924
MC
11205 (arguments
11206 `(#:phases
11207 (modify-phases %standard-phases
11208 ;; See: https://github.com/sinatra/sinatra/issues/1578.
11209 (add-after 'extract-gemspec 'fix-slow-doc-generation
11210 (lambda _
11211 (substitute* "sinatra.gemspec"
11212 (("\"README.rdoc\"\\.freeze," all)
11213 (string-append all " \"--exclude=.*\\.md\".freeze,")))
11214 #t)))))
3bb094e2
PN
11215 (propagated-inputs
11216 `(("ruby-mustermann" ,ruby-mustermann)
11217 ("ruby-rack" ,ruby-rack)
11218 ("ruby-rack-protection" ,ruby-rack-protection)
11219 ("ruby-tilt" ,ruby-tilt)))
11220 (synopsis "DSL for quick web applications creation in Ruby")
11221 (description
11222 "Sinatra is a DSL for quickly creating web applications in Ruby with
11223minimal effort.")
11224 (home-page "http://sinatrarb.com/")
11225 (license license:expat)))
6e87695b
PN
11226
11227(define-public ruby-thin
11228 (package
11229 (name "ruby-thin")
11230 (version "1.7.2")
11231 (source
11232 (origin
11233 (method url-fetch)
11234 (uri (rubygems-uri "thin" version))
11235 (sha256
11236 (base32
11237 "0nagbf9pwy1vg09k6j4xqhbjjzrg5dwzvkn4ffvlj76fsn6vv61f"))))
11238 (build-system ruby-build-system)
11239 (arguments
11240 ;; No tests.
11241 '(#:tests? #f))
11242 (propagated-inputs
11243 `(("ruby-daemons" ,ruby-daemons)
11244 ("ruby-eventmachine" ,ruby-eventmachine)
11245 ("ruby-rack" ,ruby-rack)))
11246 (synopsis "Thin and fast web server for Ruby")
11247 (description "Thin is a Ruby web server that glues together 3 Ruby libraries:
11248@itemize
11249@item the Mongrel parser,
11250@item Event Machine, a network I/O library with high scalability, performance
11251and stability,
11252@item Rack, a minimal interface between webservers and Ruby frameworks.
11253@end itemize\n")
60783303 11254 (home-page "https://github.com/macournoyer/thin")
6e87695b 11255 (license license:ruby)))
be6016db
PN
11256
11257(define-public ruby-skinny
11258 (package
11259 (name "ruby-skinny")
11260 (version "0.2.4")
11261 (source
11262 (origin
11263 (method url-fetch)
11264 (uri (rubygems-uri "skinny" version))
11265 (sha256
11266 (base32
11267 "1y3yvx88ylgz4d2s1wskjk5rkmrcr15q3ibzp1q88qwzr5y493a9"))))
11268 (build-system ruby-build-system)
11269 (arguments
11270 '(#:tests? #f ; No included tests
11271 #:phases
11272 (modify-phases %standard-phases
11273 (add-before 'build 'patch-gemspec
11274 (lambda _
11275 (substitute* ".gemspec"
11276 (("<eventmachine>.freeze, \\[\\\"~> 1.0.0\"")
11277 "<eventmachine>, [\">= 1.0.0\"")
11278 (("<thin>.freeze, \\[\\\"< 1.7\", ") "<thin>, ["))
11279 #t)))))
11280 (propagated-inputs
11281 `(("ruby-eventmachine" ,ruby-eventmachine)
11282 ("ruby-thin" ,ruby-thin)))
11283 (synopsis "Simple, upgradable WebSockets for Ruby Thin")
11284 (description "Skinny is a simple, upgradable WebSockets for Ruby, using
11285the Thin library.")
11286 (home-page "https://github.com/sj26/skinny")
11287 (license license:expat)))
df747c8d 11288
9c566d1b
MB
11289(define-public ruby-sys-filesystem
11290 (package
11291 (name "ruby-sys-filesystem")
11292 (version "1.3.4")
11293 (source (origin
11294 (method url-fetch)
11295 (uri (rubygems-uri "sys-filesystem" version))
11296 (sha256
11297 (base32
11298 "0mizqnsiagagmracadr16s5na2ks2j3ih1w0f3gp4ssrda6szl01"))))
11299 (build-system ruby-build-system)
11300 (arguments
11301 '(#:phases (modify-phases %standard-phases
11302 (add-before 'check 'set-HOME
11303 (lambda _
11304 ;; Some tests attempt to stat $HOME. Let them.
11305 (setenv "HOME" "/tmp")
11306 #t)))))
11307 (propagated-inputs
11308 `(("ruby-ffi" ,ruby-ffi)))
11309 (native-inputs
11310 `(("ruby-mkmf-lite" ,ruby-mkmf-lite)))
11311 (synopsis "Gather file system information")
11312 (description
11313 "The @code{sys-filesystem} library provides a cross-platform interface
11314for gathering file system information, such as disk space and mount points.")
11315 (home-page "https://github.com/djberg96/sys-filesystem")
11316 (license license:asl2.0)))
11317
df747c8d
PN
11318(define-public mailcatcher
11319 (package
11320 (name "mailcatcher")
11321 (version "0.7.1")
11322 (source
11323 (origin
11324 (method url-fetch)
11325 (uri (rubygems-uri "mailcatcher" version))
11326 (sha256
11327 (base32
11328 "02w1ycyfv7x0sh9799lz7xa65p5qvl5z4pa8a7prb68h2zwkfq0n"))))
11329 (build-system ruby-build-system)
11330 (arguments
11331 ;; Tests require web/assets which is not included in the output. We
11332 ;; might be able to fix this by adding the Git repository to the GEM_PATH
11333 ;; of the tests. See ruby-mysql2.
11334 '(#:tests? #f
11335 #:phases
11336 (modify-phases %standard-phases
11337 (add-before 'build 'patch-gemspec
11338 (lambda _
11339 (substitute* ".gemspec"
11340 (("<eventmachine>.freeze, \\[\\\"= 1.0.9.1")
11341 "<eventmachine>, [\">= 1.0.9.1")
11342 (("<rack>.freeze, \\[\\\"~> 1.5") "<rack>, [\">= 1.5")
11343 (("<thin>.freeze, \\[\\\"~> 1.5.0") "<thin>, [\">= 1.5.0")
11344 (("<sinatra>.freeze, \\[\\\"~> 1.2") "<sinatra>, [\">= 1.2"))
11345 #t))
11346 (add-before 'build 'loosen-dependency-contraint
11347 (lambda _
11348 (substitute* "lib/mail_catcher.rb"
11349 (("\"eventmachine\", \"1.0.9.1\"") "\"eventmachine\", \">= 1.0.9.1\"")
11350 (("\"rack\", \"~> 1.5\"") "\"rack\", \">= 1.5\"")
11351 (("\"thin\", \"~> 1.5.0\"") "\"thin\", \">= 1.5.0\"")
11352 (("\"sinatra\", \"~> 1.2\"") "\"sinatra\", \">= 1.2\""))
11353 #t)))))
11354 (inputs
11355 `(("ruby-eventmachine" ,ruby-eventmachine)
11356 ("ruby-mail" ,ruby-mail)
11357 ("ruby-rack" ,ruby-rack)
11358 ("ruby-sinatra" ,ruby-sinatra)
11359 ("ruby-skinny" ,ruby-skinny)
11360 ("ruby-sqlite3" ,ruby-sqlite3)
11361 ("ruby-thin" ,ruby-thin)))
11362 (synopsis "SMTP server which catches messages to display them a browser")
11363 (description
11364 "MailCatcher runs a super simple SMTP server which catches any message
11365sent to it to display in a web interface. Run mailcatcher, set your favourite
11366app to deliver to smtp://127.0.0.1:1025 instead of your default SMTP server,
11367then check out http://127.0.0.1:1080 to see the mail.")
11368 (home-page "https://mailcatcher.me")
11369 (license license:expat)))
fc4f7c45
MK
11370
11371(define-public ruby-backport
11372 (package
11373 (name "ruby-backport")
b62863b8 11374 (version "1.1.2")
fc4f7c45
MK
11375 (source
11376 (origin
b62863b8 11377 ;; The gem does not include test code, so fetch from the Git repository.
fc4f7c45
MK
11378 (method git-fetch)
11379 (uri (git-reference
b0e7b699 11380 (url "https://github.com/castwide/backport")
fc4f7c45
MK
11381 (commit (string-append "v" version))))
11382 (file-name (git-file-name name version))
11383 (sha256
b62863b8 11384 (base32 "18fpg1n7n2z02ykz9v1x1q0cqa2lvivf8ygka768s01q1r9wfwv2"))))
fc4f7c45
MK
11385 (build-system ruby-build-system)
11386 (arguments
11387 `(#:test-target "spec"))
11388 (native-inputs
11389 `(("bundler" ,bundler)
11390 ("ruby-rspec" ,ruby-rspec)))
11391 (inputs
11392 `(("ruby-simplecov" ,ruby-simplecov)))
11393 (synopsis "Pure Ruby library for event-driven IO")
11394 (description
11395 "This package provides a pure Ruby library for event-driven IO.")
11396 (home-page "https://github.com/castwide/backport")
11397 (license license:expat)))
369faa59
JL
11398
11399(define-public ruby-json-schema
11400 (package
11401 (name "ruby-json-schema")
11402 (version "2.8.1")
11403 (source
11404 (origin
11405 (method url-fetch)
11406 (uri (rubygems-uri "json-schema" version))
11407 (sha256
11408 (base32
11409 "1yv5lfmr2nzd14af498xqd5p89f3g080q8wk0klr3vxgypsikkb5"))))
11410 (build-system ruby-build-system)
11411 (arguments
11412 `(#:tests? #f ; no tests
11413 #:phases
11414 (modify-phases %standard-phases
11415 (replace 'build
11416 (lambda _
11417 (invoke "gem" "build" ".gemspec"))))))
11418 (propagated-inputs
11419 `(("ruby-addressable" ,ruby-addressable)))
11420 (synopsis "Ruby JSON Schema Validator")
11421 (description "This library provides Ruby with an interface for validating
11422JSON objects against a JSON schema conforming to JSON Schema Draft 4. Legacy
11423support for JSON Schema Draft 3, JSON Schema Draft 2, and JSON Schema Draft 1
11424is also included.")
11425 (home-page "https://github.com/ruby-json-schema/json-schema")
11426 (license license:expat)))
44881cad
JL
11427
11428(define-public swagger-diff
11429 (package
11430 (name "swagger-diff")
11431 (version "1.1.2")
11432 (source
11433 (origin
11434 (method url-fetch)
11435 (uri (rubygems-uri "swagger-diff" version))
11436 (sha256
11437 (base32
11438 "1hxx50nga1bqn254iqjcdwkc9c72364ks9lyjyw10ajz0l0ly7sn"))))
11439 (build-system ruby-build-system)
11440 (arguments
11441 `(#:test-target "spec"
11442 #:phases
11443 (modify-phases %standard-phases
11444 ;; Don't run or require rubocop, the code linting tool, as this is a
11445 ;; bit unnecessary.
11446 (add-after 'unpack 'dont-run-rubocop
11447 (lambda _
11448 (substitute* "Rakefile"
11449 ((".*rubocop.*") "")
11450 ((".*RuboCop.*") ""))
11451 #t)))))
11452 (propagated-inputs
11453 `(("ruby-json-schema" ,ruby-json-schema)))
11454 (native-inputs
11455 `(("bundler" ,bundler)
11456 ("ruby-rspec-core" ,ruby-rspec-core)
11457 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
11458 (synopsis
11459 "Compare Open API Initiative specification files")
11460 (description
11461 "Swagger::Diff is a utility for comparing two different Open API
11462Initiative (OAI) specifications (formerly known as Swagger specifications).
11463It is intended to determine whether a newer API specification is
11464backwards-compatible with an older API specification.")
11465 (home-page "https://github.com/civisanalytics/swagger-diff")
11466 (license license:bsd-3)))
9e065a8a
BL
11467
11468(define-public ruby-reverse-markdown
11469 (package
11470 (name "ruby-reverse-markdown")
11471 (version "1.1.0")
11472 (source
11473 (origin
11474 (method url-fetch)
11475 (uri (rubygems-uri "reverse_markdown" version))
11476 (sha256
11477 (base32
11478 "0w7y5n74daajvl9gixr91nh8670d7mkgspkk3ql71m8azq3nffbg"))))
11479 (build-system ruby-build-system)
11480 (propagated-inputs
11481 `(("ruby-nokogiri" ,ruby-nokogiri)))
11482 (native-inputs
11483 `(("bundler" ,bundler)
11484 ("ruby-rspec" ,ruby-rspec)
11485 ("ruby-kramdown" ,ruby-kramdown)
11486 ("ruby-simplecov" ,ruby-simplecov)))
11487 (arguments
11488 `(#:phases
11489 (modify-phases %standard-phases
11490 (replace 'check
11491 (lambda* (#:key tests? #:allow-other-keys)
11492 (when tests?
11493 (invoke "rspec"))
11494 #t)))))
11495 (synopsis "Convert HTML into Markdown")
11496 (description
11497 "This Ruby module allows you to map simple HTML back into
11498Markdown---e.g., if you want to import existing HTML data in your
11499application.")
11500 (home-page "https://github.com/xijo/reverse_markdown")
11501 (license license:wtfpl2)))
11502
a9e2de7e
BL
11503(define-public ruby-solargraph
11504 (package
11505 (name "ruby-solargraph")
11506 (version "0.36.0")
11507 (source
11508 (origin
11509 (method url-fetch)
11510 (uri (rubygems-uri "solargraph" version))
11511 (sha256
11512 (base32
11513 "0b93xzkgd1h06da9gdnwivj1mzbil8lc072y2838dy6i7bxgpy9i"))))
11514 (build-system ruby-build-system)
11515 (propagated-inputs
11516 `(("ruby-backport" ,ruby-backport)
11517 ("bundler" ,bundler)
11518 ("ruby-htmlentities" ,ruby-htmlentities)
11519 ("ruby-jaro-winkler" ,ruby-jaro-winkler)
11520 ("ruby-maruku" ,ruby-maruku)
11521 ("ruby-nokogiri" ,ruby-nokogiri)
11522 ("ruby-parser" ,ruby-parser)
11523 ("ruby-reverse-markdown" ,ruby-reverse-markdown)
11524 ("ruby-rubocop" ,ruby-rubocop)
11525 ("ruby-thor" ,ruby-thor)
11526 ("ruby-tilt" ,ruby-tilt)
11527 ("ruby-yard" ,ruby-yard)))
11528 (native-inputs
11529 `(("ruby-rspec" ,ruby-rspec)
11530 ("ruby-pry" ,ruby-pry)
11531 ("ruby-simplecov" ,ruby-simplecov)
11532 ("ruby-webmock" ,ruby-webmock-2)))
11533 ;; FIXME: can't figure out how to run the tests properly:
11534
11535 ;; An error occurred while loading spec_helper.
11536 ;; Failure/Error: return gem_original_require(path)
11537 ;; LoadError:
11538 ;; cannot load such file -- spec_helper
11539 (arguments
11540 '(#:tests? #f
11541 #:phases
11542 (modify-phases %standard-phases
11543 (replace 'check
11544 (lambda* (#:key tests? #:allow-other-keys)
11545 (when tests?
11546 (invoke "rspec"))
11547 #t)))))
11548 (synopsis
11549 "IDE tools for code completion, inline documentation, and static analysis")
11550 (description
11551 "Solargraph provides a comprehensive suite of tools for Ruby
11552programming: intellisense, diagnostics, inline documentation, and type
11553checking.")
11554 (home-page "https://solargraph.org/")
11555 (license license:expat)))
0c558aa9
DNB
11556
11557(define-public ruby-wayback-machine-downloader
11558 (package
11559 (name "ruby-wayback-machine-downloader")
11560 (version "2.2.1")
11561 (source
11562 (origin
11563 (method url-fetch)
11564 (uri (rubygems-uri
11565 "wayback_machine_downloader"
11566 version))
11567 (sha256
11568 (base32
11569 "12kb1qmvmmsaihqab1prn6cmynkn6cgb4vf41mgv22wkcgv5wgk2"))))
11570 (build-system ruby-build-system)
11571 (arguments
11572 '(#:tests? #f)) ; no tests
11573 (synopsis "Download archived websites from the Wayback Machine")
11574 (description
11575 "Wayback Machine Downloader is a command line tool for downloading
11576websites from the Internet Archive's Wayback Machine (archive.org).
11577It allows fine grained control over what to download by specifying
11578which snapshots to consider and what files to include.")
11579 (home-page
11580 "https://github.com/hartator/wayback-machine-downloader")
11581 (license license:expat)))
e6483f8c
MB
11582
11583(define-public ruby-wwtd
11584 (package
11585 (name "ruby-wwtd")
11586 (version "1.4.1")
702a1012 11587 (home-page "https://github.com/grosser/wwtd")
e6483f8c
MB
11588 (source (origin
11589 (method git-fetch)
11590 (uri (git-reference
11591 (url home-page)
11592 (commit (string-append "v" version))))
11593 (file-name (git-file-name name version))
11594 (sha256
11595 (base32
11596 "0gw7vfnbb41cy67yw82zji3jkhfsgmzcgzaszm99ax77y18wclf2"))
11597 (modules '((guix build utils)))
11598 (snippet
11599 '(begin
11600 ;; Remove bundled library.
11601 (delete-file "spec/rake-12.3.0.gem")
11602 #t))))
11603 (build-system ruby-build-system)
11604 (arguments
11605 '(;; XXX: Tests need multiple versions of ruby, wants to run
11606 ;; `bundle install`, etc.
11607 #:tests? #f
11608 #:phases (modify-phases %standard-phases
11609 (replace 'replace-git-ls-files
11610 (lambda _
11611 (substitute* "wwtd.gemspec"
11612 (("git ls-files lib/ bin/`")
11613 "find lib/ bin/ -type f |sort`"))
11614 #t))
11615 (add-before 'check 'remove-version-constraints
11616 (lambda _
11617 (delete-file "Gemfile.lock")
11618 #t))
11619 (replace 'check
11620 (lambda* (#:key tests? #:allow-other-keys)
11621 (if tests?
11622 (invoke "rspec" "spec/")
11623 (format #t "test suite not run~%"))
11624 #t)))))
11625 (native-inputs
11626 `(("ruby-bump" ,ruby-bump)
11627 ("ruby-rspec" ,ruby-rspec)))
11628 (synopsis "Run @file{.travis.yml} files locally")
11629 (description
11630 "WWTD is a @dfn{Travis Simulator} that lets you run test matrices
11631defined in @file{.travis.yml} on your local machine, using @code{rvm},
11632@code{rbenv}, or @code{chruby} to test different versions of Ruby.")
11633 (license license:expat)))