1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014, 2015 Pjotr Prins <pjotr.guix@thebird.nl>
3 ;;; Copyright © 2014-2017, 2021-2022 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org>
6 ;;; Copyright © 2015, 2019 Ricardo Wurmus <rekado@elephly.net>
7 ;;; Copyright © 2015, 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
8 ;;; Copyright © 2017 Nikita <nikita@n0.is>
9 ;;; Copyright © 2017, 2019-2022 Marius Bakke <marius@gnu.org>
10 ;;; Copyright © 2017, 2018, 2019, 2020, 2021, 2022 Efraim Flashner <efraim@flashner.co.il>
11 ;;; Copyright © 2017, 2018, 2020, 2021 Tobias Geerinckx-Rice <me@tobias.gr>
12 ;;; Copyright © 2017 Clément Lassieur <clement@lassieur.org>
13 ;;; Copyright © 2017, 2018, 2019 Christopher Baines <mail@cbaines.net>
14 ;;; Copyright © 2018 Vasile Dumitrascu <va511e@yahoo.com>
15 ;;; Copyright © 2018 Alex Vong <alexvong1995@gmail.com>
16 ;;; Copyright © 2019 Pierre Neidhardt <mail@ambrevar.xyz>
17 ;;; Copyright © 2019 Mikhail Kirillov <w96k.ru@gmail.com>
18 ;;; Copyright © 2019 Jelle Licht <jlicht@fsfe.org>
19 ;;; Copyright © 2019 Brian Leung <bkleung89@gmail.com>
20 ;;; Copyright © 2019 Collin J. Doering <collin@rekahsoft.ca>
21 ;;; Copyright © 2019 Diego N. Barbato <dnbarbato@posteo.de>
22 ;;; Copyright © 2019 Brett Gilio <brettg@posteo.de>
23 ;;; Copyright © 2020 Maxim Cournoyer <maxim.cournoyer@gmail.com>
24 ;;; Copyright © 2020, 2021 Nicolas Goaziou <mail@nicolasgoaziou.fr>
25 ;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
26 ;;; Copyright © 2020 Holgr Peters <holger.peters@posteo.de>
27 ;;; Copyright © 2020 Giacomo Leidi <goodoldpaul@autistici.org>
28 ;;; Copyright © 2021 EuAndreh <eu@euandre.org>
29 ;;; Copyright © 2020 Tomás Ortín Fernández <tomasortin@mailbox.org>
30 ;;; Copyright © 2021 Giovanni Biscuolo <g@xelera.eu>
31 ;;; Copyright © 2022 Philip McGrath <philip@philipmcgrath.com>
33 ;;; This file is part of GNU Guix.
35 ;;; GNU Guix is free software; you can redistribute it and/or modify it
36 ;;; under the terms of the GNU General Public License as published by
37 ;;; the Free Software Foundation; either version 3 of the License, or (at
38 ;;; your option) any later version.
40 ;;; GNU Guix is distributed in the hope that it will be useful, but
41 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
42 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
43 ;;; GNU General Public License for more details.
45 ;;; You should have received a copy of the GNU General Public License
46 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
48 (define-module (gnu packages ruby)
49 #:use-module ((guix licenses) #:prefix license:)
50 #:use-module (gnu packages)
51 #:use-module (gnu packages base)
52 #:use-module (gnu packages bison)
53 #:use-module (gnu packages c)
54 #:use-module (gnu packages check)
55 #:use-module (gnu packages compression)
56 #:use-module (gnu packages crypto)
57 #:use-module (gnu packages curl)
58 #:use-module (gnu packages databases)
59 #:use-module (gnu packages dbm)
60 #:use-module (gnu packages rails)
61 #:use-module (gnu packages readline)
62 #:use-module (gnu packages autotools)
63 #:use-module (gnu packages haskell-xyz)
64 #:use-module (gnu packages java)
65 #:use-module (gnu packages libffi)
66 #:use-module (gnu packages libidn)
67 #:use-module (gnu packages linux)
68 #:use-module (gnu packages lsof)
69 #:use-module (gnu packages man)
70 #:use-module (gnu packages maths)
71 #:use-module (gnu packages ncurses)
72 #:use-module (gnu packages networking)
73 #:use-module (gnu packages node)
74 #:use-module (gnu packages protobuf)
75 #:use-module (gnu packages python)
76 #:use-module (gnu packages python-xyz)
77 #:use-module (gnu packages ragel)
78 #:use-module (gnu packages rsync)
79 #:use-module (gnu packages sqlite)
80 #:use-module (gnu packages tls)
81 #:use-module (gnu packages version-control)
82 #:use-module (guix packages)
83 #:use-module (guix download)
84 #:use-module (guix git-download)
85 #:use-module (guix gexp)
86 #:use-module (guix utils)
87 #:use-module (guix build-system gnu)
88 #:use-module (gnu packages xml)
89 #:use-module (gnu packages web)
90 #:use-module (guix build-system ruby)
91 #:use-module ((srfi srfi-1) #:select (alist-delete)))
93 (define %prawn-project-licenses
94 ;; This set of licenses applies to most (all?) components of the Prawn
95 ;; project (it is triple licensed).
100 (define-public ruby-2.6
107 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
108 (version-major+minor version)
109 "/ruby-" version ".tar.xz"))
112 "0qhsw2mr04f3lqinkh557msr35pb5rdaqy4vdxcj91flgxqxmmnm"))
113 (modules '((guix build utils)))
115 ;; Remove bundled libffi
116 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
118 (build-system gnu-build-system)
120 `(#:test-target "test"
121 #:configure-flags '("--enable-shared") ; dynamic linking
123 (modify-phases %standard-phases
124 (add-before 'configure 'replace-bin-sh-and-remove-libffi
126 (substitute* '("Makefile.in"
131 "test/rubygems/test_gem_ext_configure_builder.rb"
132 "test/rdoc/test_rdoc_parser.rb"
133 "test/ruby/test_rubyoptions.rb"
134 "test/ruby/test_process.rb"
135 "test/ruby/test_system.rb"
137 (("/bin/sh") (which "sh")))
140 (list readline openssl libffi gdbm))
144 (list (search-path-specification
145 (variable "GEM_PATH")
146 (files (list (string-append "lib/ruby/vendor_ruby"))))))
147 (synopsis "Programming language interpreter")
148 (description "Ruby is a dynamic object-oriented programming language with
149 a focus on simplicity and productivity.")
150 (home-page "https://www.ruby-lang.org")
151 (license license:ruby)))
153 (define-public ruby-2.7
159 (inherit (package-source ruby-2.6))
160 (uri (string-append "https://cache.ruby-lang.org/pub/ruby/"
161 (version-major+minor version)
162 "/ruby-" version ".tar.gz"))
165 "0nxwkxh7snmjqf787qsp4i33mxd1rbf9yzyfiky5k230i680jhrh"))))
167 `(#:test-target "test"
168 #:configure-flags '("--enable-shared") ; dynamic linking
170 (modify-phases %standard-phases
171 (add-before 'configure 'replace-bin-sh-and-remove-libffi
173 (substitute* '("configure.ac"
174 "template/Makefile.in"
175 "lib/rubygems/installer.rb"
180 "test/rubygems/test_gem_ext_configure_builder.rb"
181 "test/rdoc/test_rdoc_parser.rb"
182 "test/ruby/test_rubyoptions.rb"
183 "test/ruby/test_process.rb"
184 "test/ruby/test_system.rb"
186 (("/bin/sh") (which "sh")))
191 (define-public ruby-3.0
198 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
199 (version-major+minor version)
200 "/ruby-" version ".tar.xz"))
203 "0h2w2ms4gx2s96v3lzdr3add94bd2qqkhdjzaycmaqhg21rpf3jp"))))))
205 (define-public ruby-3.1
212 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
213 (version-major+minor version)
214 "/ruby-" version ".tar.xz"))
217 "1akcl7vhmwfm6ybj7493kzy58ykh2r39ri9f4xfm2xmhg1msmvvs"))))))
219 (define-public ruby-2.5
226 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
227 (version-major+minor version)
228 "/ruby-" version ".tar.xz"))
231 "1w2qncacm7h3f3il1whghdabwnv9fvwmz9f1a9vcg32006ljyzx8"))))))
233 (define-public ruby-2.4
240 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
241 (version-major+minor version)
242 "/ruby-" version ".tar.xz"))
245 "1prhqlgik1zmw9lakl6hkriqslspw48pvhxff17h7ns42p8qwrnm"))
246 (modules '((guix build utils)))
248 ;; Remove bundled libffi
249 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
252 (define-public ruby ruby-2.7)
262 (url "https://github.com/mruby/mruby")
264 (file-name (git-file-name name version))
267 "0fhfv8pi7i8jn2vgk2n2rjnbnfa12nhj514v8i4k353n7q4pmkh3"))))
268 (build-system gnu-build-system)
270 `(#:test-target "test"
272 (modify-phases %standard-phases
274 (add-after 'unpack 'enable-verbose-tests
276 (substitute* "Makefile"
277 (("ruby ./minirake" m)
278 (string-append m " --verbose")))
280 (add-after 'unpack 'disable-broken-tests
282 (substitute* "mrbgems/mruby-io/test/io.rb"
283 (("assert\\('IO.popen.+$" m)
284 (string-append m "skip \"Hangs in the Guix build environment\"\n"))
285 (("assert\\('IO#isatty.+$" m)
286 (string-append m "skip \"Disable for Guix; there is no /dev/tty\"\n"))
287 ;; This one is really weird. The *expected* output is all wrong.
288 (("assert\\('`cmd`.*" m)
289 (string-append m "skip \"Disable for Guix\"\n"))
291 (string-append (which "echo") " foo")))
293 ;; There is no install target
295 (lambda* (#:key outputs #:allow-other-keys)
296 (let* ((out (assoc-ref outputs "out"))
297 (bin (string-append out "/bin"))
298 (lib (string-append out "/lib")))
300 (copy-recursively "build/host/bin" bin)
302 (copy-recursively "build/host/lib" lib))
306 (home-page "https://github.com/mruby/mruby")
307 (synopsis "Lightweight Ruby")
308 (description "mruby is the lightweight implementation of the Ruby
309 language. Its syntax is Ruby 1.9 compatible. mruby can be linked and
310 embedded within your application.")
311 (license license:expat)))
313 (define-public ruby-commander
315 (name "ruby-commander")
320 (uri (rubygems-uri "commander" version))
323 "1pxakz596fjqak3cdbha6iva1dlqis86i3kjrgg6lf3sp8i5vhwg"))))
324 (build-system ruby-build-system)
326 `(#:test-target "spec"
328 (modify-phases %standard-phases
329 ;; Don't run or require rubocop, the code linting tool, as this is a
331 (add-after 'unpack 'dont-run-rubocop
333 (substitute* "Rakefile"
335 ((".*RuboCop.*") ""))
338 (list ruby-highline))
340 (list bundler ruby-rspec-core ruby-rspec-expectations
341 ruby-rspec-mocks ruby-simplecov))
342 (home-page "https://github.com/commander-rb/commander")
343 (synopsis "Library for building Ruby command-line executables")
345 "Commander aims to be a complete solution for Ruby command-line
346 executables. Commander bridges the gap between other terminal related
347 libraries (OptionParser, HighLine), while providing many new features, and an
349 (license license:expat)))
351 (define-public ruby-highline
353 (name "ruby-highline")
358 (uri (rubygems-uri "highline" version))
361 "0gr6pckj2jayxw1gdgh9193j5jag5zrrqqlrnl4jvcwpyd3sn2zc"))))
362 (build-system ruby-build-system)
364 `(#:tests? #f)) ;; TODO: NameError: uninitialized constant SPEC
366 (list bundler ruby-code-statistics))
368 "HighLine helps you build command-line interfaces")
370 "HighLine provides a high-level IO library that provides validation,
371 type conversion, and more for command-line interfaces. HighLine also includes
372 a menu system for providing multiple options to the user.")
373 (home-page "https://github.com/JEG2/highline")
374 (license (list license:gpl2 license:ruby))))
376 (define-public ruby-hoe
382 (uri (rubygems-uri "hoe" version))
385 "0qid0n56mgsjvq5ksxajv0gb92akky8imwgvw22ajms5g4fd6nf4"))))
386 (build-system ruby-build-system)
389 (modify-phases %standard-phases
390 ;; One of the tests fails if the SOURCE_DATE_EPOCH environment
391 ;; variable is set, so unset it for the duration of the tests.
393 ;; TestHoe#test_possibly_better
394 ;; [/tmp/guix-build-ruby-hoe-3.20.0.drv-0/gem/test/test_hoe.rb:250]:
395 ;; Expected: 2019-11-12 00:00:00 UTC
396 ;; Actual: 1970-01-01 00:00:00 UTC
397 (add-before 'check 'unset-SOURCE-DATE-EPOCH
399 (unsetenv "SOURCE_DATE_EPOCH")
401 (add-after 'check 'set-SOURCE-DATE-EPOCH-again
403 (setenv "SOURCE_DATE_EPOCH" "1")
405 (synopsis "Ruby project management helper")
407 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
408 maintain, and release projects and includes a dynamic plug-in system allowing
409 for easy extensibility. Hoe ships with plug-ins for all the usual project
410 tasks including rdoc generation, testing, packaging, deployment, and
412 (home-page "https://www.zenspider.com/projects/hoe.html")
413 (license license:expat)))
415 (define-public ruby-rake-compiler
417 (name "ruby-rake-compiler")
421 (uri (rubygems-uri "rake-compiler" version))
424 "11sxgw10jrd6a4irb51jjwam9wikixn5kss11pw4b80cmh32yvpf"))))
425 (build-system ruby-build-system)
427 '(#:tests? #f)) ; needs cucumber
428 (synopsis "Building and packaging helper for Ruby native extensions")
429 (description "Rake-compiler provides a framework for building and
430 packaging native C and Java extensions in Ruby.")
431 (home-page "https://github.com/rake-compiler/rake-compiler")
432 (license license:expat)))
434 (define-public ruby-rsync
441 (uri (rubygems-uri "rsync" version))
444 "0p8b27q1gvxilqfq2528xpwglzcm2myikkjxpqk7mwbwg9r6knxv"))))
445 (build-system ruby-build-system)
447 '(#:test-target "spec"
449 (modify-phases %standard-phases
450 (add-after 'unpack 'remove-coveralls-requirement
452 (substitute* "spec/spec_helper.rb"
453 (("require 'coveralls'") "")
454 (("Coveralls.wear!") ""))
457 (list bundler rsync ruby-rspec-core ruby-rspec-expectations
459 (home-page "https://github.com/jbussdieker/ruby-rsync")
460 (synopsis "Ruby wrapper around rsync")
462 "Ruby Rsync is a Ruby library that can synchronize files between remote
463 hosts by wrapping the @file{rsync} binary.")
464 (license license:expat)))
466 (define-public ruby-i18n
472 (uri (rubygems-uri "i18n" version))
475 "0hmypvx9iyc0b4hski7aic2xzm09cg1c7q1qlpnk3k8s5acxzyhl"))))
476 (build-system ruby-build-system)
478 '(#:tests? #f)) ; no tests
479 (propagated-inputs `(("concurrent-ruby" ,ruby-concurrent)))
480 (synopsis "Internationalization library for Ruby")
481 (description "Ruby i18n is an internationalization and localization
482 solution for Ruby programs. It features translation and localization,
483 interpolation of values to translations, pluralization, customizable
484 transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
485 translation data, custom key/scope separator, custom exception handlers, and
486 an extensible architecture with a swappable backend.")
487 (home-page "https://github.com/ruby-i18n/i18n")
488 (license license:expat)))
490 (define-public ruby-iruby
497 (uri (rubygems-uri "iruby" version))
500 "1wdf2c0x8y6cya0n3y0p3p7b1sxkb2fdavdn2k58rf4rs37s7rzn"))))
501 (build-system ruby-build-system)
503 ;; TODO: Tests currently fail.
505 ;; Finished in 1.764405s, 1.1335 runs/s, 5.1009 assertions/s.
508 ;; IntegrationTest#test_interaction [/tmp/guix-build-ruby-iruby-0.3.drv-0/gem/test/integration_test.rb:25]:
511 ;; 2 runs, 9 assertions, 1 failures, 0 errors, 0 skips
514 (modify-phases %standard-phases
515 (add-after 'unpack 'patch-ipython
516 (lambda* (#:key inputs #:allow-other-keys)
517 (substitute* "lib/iruby/command.rb"
521 (assoc-ref inputs "python-ipython")
523 (("Kernel\\.exec\\('")
526 (assoc-ref inputs "python-ipython")
530 (list python-ipython))
539 (synopsis "Ruby kernel for Jupyter/IPython")
541 "This package provides a Ruby kernel for Jupyter/IPython frontends (e.g.
543 (home-page "https://github.com/SciRuby/iruby")
544 (license license:expat)))
546 ;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
547 ;; dependencies use RSpec for their test suites! To avoid these circular
548 ;; dependencies, we disable tests for all of the RSpec-related packages.
549 (define-public ruby-rspec-support
551 (name "ruby-rspec-support")
555 (uri (rubygems-uri "rspec-support" version))
558 "0p3m7drixrlhvj2zpc38b11x145bvm311x6f33jjcxmvcm0wq609"))))
559 (build-system ruby-build-system)
561 '(#:tests? #f)) ; avoid dependency cycles
562 (synopsis "RSpec support library")
563 (description "Support utilities for RSpec gems.")
564 (home-page "https://github.com/rspec/rspec-support")
565 (license license:expat)))
567 (define-public ruby-rspec-core
569 (name "ruby-rspec-core")
573 (uri (rubygems-uri "rspec-core" version))
576 "1p1s5bnbqp3sxk67y0fh0x884jjym527r0vgmhbm81w7aq6b7l4p"))))
577 (build-system ruby-build-system)
579 '(#:tests? #f)) ; avoid dependency cycles
581 (list ruby-rspec-support))
582 (synopsis "RSpec core library")
583 (description "Rspec-core provides the RSpec test runner and example
585 (home-page "https://github.com/rspec/rspec-core")
586 (license license:expat)))
588 (define-public ruby-rspec-core-2
589 (package (inherit ruby-rspec-core)
593 (uri (rubygems-uri "rspec-core" version))
596 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
597 (propagated-inputs `())))
599 (define-public ruby-diff-lcs
601 (name "ruby-diff-lcs")
605 (uri (rubygems-uri "diff-lcs" version))
608 "18w22bjz424gzafv6nzv98h0aqkwz3d9xhm7cbr1wfbyas8zayza"))))
609 (build-system ruby-build-system)
611 '(#:tests? #f)) ; avoid dependency cycles
612 (synopsis "Compute the difference between two Enumerable sequences")
613 (description "Diff::LCS computes the difference between two Enumerable
614 sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
615 It includes utilities to create a simple HTML diff output format and a
616 standard diff-like tool.")
617 (home-page "https://github.com/halostatue/diff-lcs")
618 (license license:expat)))
620 (define-public ruby-rspec-expectations
622 (name "ruby-rspec-expectations")
626 (uri (rubygems-uri "rspec-expectations" version))
629 "18l21hy1zdc2pgc2yb17k3n2al1khpfr0z6pijlm852iz6vj0dkm"))))
630 (build-system ruby-build-system)
632 '(#:tests? #f)) ; avoid dependency cycles
634 (list ruby-rspec-support ruby-diff-lcs))
635 (synopsis "RSpec expectations library")
636 (description "Rspec-expectations provides a simple API to express expected
637 outcomes of a code example.")
638 (home-page "https://github.com/rspec/rspec-expectations")
639 (license license:expat)))
641 (define-public ruby-rspec-expectations-2
642 (package (inherit ruby-rspec-expectations)
646 (uri (rubygems-uri "rspec-expectations" version))
649 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
651 (list ruby-diff-lcs))))
653 (define-public ruby-sorcerer
655 (name "ruby-sorcerer")
660 (uri (rubygems-uri "sorcerer" version))
663 "0d32ha9pp9slpmsm027pkdpbr9vc5jn2m8rl6hwwx6a87m8cr58h"))))
664 (build-system ruby-build-system)
665 (synopsis "Ripper-style abstract syntax tree to Ruby source generator")
666 (description "Sorcerer generates Ruby code from a Ripper-like abstract
667 syntax tree (i.e. S-Expressions). Sorcerer is targeted mainly at small
668 snippets of Ruby code, expressible in a single line. Longer examples may be
669 re-sourced, but they will be rendered in a single-line format.")
670 (home-page "https://github.com/rspec-given/sorcerer")
671 (license license:expat)))
673 (define-public ruby-given-core
675 (name "ruby-given-core")
680 (uri (rubygems-uri "given_core" version))
683 "1lzyqllbbv6as3qgwz2007mvy7wy247bgkch9adnmh1zfa73bkrg"))))
684 (build-system ruby-build-system)
685 (arguments '(#:tests? #f)) ;no test suite for the core package
687 (list ruby-sorcerer))
688 (synopsis "Core abstractions used by rspec-given and minitest-given")
689 (description "Given_core is the basic functionality behind rspec-given and
690 minitest-given, extensions that allow the use of Given/When/Then terminology
691 when defining specifications.")
692 (home-page "https://github.com/rspec-given/rspec-given")
693 (license license:expat)))
695 (define-public ruby-rspec-given
697 (name "ruby-rspec-given")
702 (uri (rubygems-uri "rspec-given" version))
705 "1783bazja10kbha8hk15khvybsq88siyax02cpkk688604h54nji"))))
706 (build-system ruby-build-system)
710 (modify-phases %standard-phases
711 (add-after 'unpack 'fix-rakefile
713 (substitute* '("Rakefile" "rakelib/gemspec.rake")
714 (("require '\\./lib/given/.*") "")
715 (("Given::VERSION") (format #f "~s" ,version))
716 ;; Fix the error: "cannot load such file -- example_helper"
718 "sh \"rspec -Ilib:examples"))
720 (add-after 'extract-gemspec 'delete-failing-tests
721 ;; See: https://github.com/jimweirich/rspec-given/issues/57.
723 (substitute* ".gemspec"
724 (("\"spec/lib/given/natural_assertion_spec.rb\".freeze, ")
726 (("\"examples/integration/failing_messages_spec.rb\".freeze, ")
728 (delete-file "spec/lib/given/natural_assertion_spec.rb")
729 (delete-file "examples/integration/failing_messages_spec.rb")
732 (list ruby-rspec ruby-minitest))
734 (list ruby-given-core ruby-rspec))
735 (synopsis "Given/When/Then for RSpec and Minitest")
736 (description "Given is an RSpec extension that allows the use of
737 Given/When/Then terminology when defining specifications, in a way similar to
738 the Cucumber Gherkin language.")
739 (home-page "https://github.com/rspec-given/rspec-given")
740 (license license:expat)))
742 (define-public ruby-rspec-its
744 (name "ruby-rspec-its")
750 (url "https://github.com/rspec/rspec-its")
751 (commit (string-append "v" version))))
752 (file-name (git-file-name name version))
755 "02mlsc9d4d1cjj5vahi8v3q8hyn9fyiv8nnlidhgfh186qp20g1p"))))
756 (build-system ruby-build-system)
758 `(#:test-target "spec"
760 (modify-phases %standard-phases
761 (add-after 'unpack 'dont-install-gems-from-gemfile
763 (substitute* "Gemfile"
764 (("rspec rspec-core rspec-expectations rspec-mocks rspec-support")
767 (add-before 'build 'loosen-ffi-requirement
769 ;; Accept any version of ruby-ffi.
770 (substitute* "Gemfile"
771 ((" gem 'ffi', '~> 1\\.9\\.25'")
774 (add-before 'build 'remove-unnecessary-dependency-versions-from-gemfile
776 (substitute* "rspec-its.gemspec"
777 (("rake.*") "rake'\n")
778 (("spec.add_development_dependency 'cucumber'.*")
779 "spec.add_development_dependency 'cucumber'\n")
780 (("bundler.*") "bundler'\n")
781 (("\"aruba.*") "'aruba'\n"))
784 (list ruby-rspec-core ruby-rspec-expectations))
786 (list bundler ruby-cucumber ruby-ffi ruby-aruba))
787 (synopsis "RSpec extension that provides the @code{its} method")
789 "RSpec::Its provides the its method as a short-hand to specify the expected
790 value of an attribute. For example, one can use @code{its(:size)\\{should
792 (home-page "https://github.com/rspec/rspec-its")
793 (license license:expat)))
795 ;;; This variant is used to break a cycle with ruby-protobuf.
796 (define-public ruby-rspec-its-minimal
799 (inherit ruby-rspec-its)
801 (substitute-keyword-arguments (package-arguments ruby-rspec-its)
802 ((#:tests? _ #f) #f)))
803 (native-inputs '()))))
805 (define-public ruby-rspec-mocks
807 (name "ruby-rspec-mocks")
811 (uri (rubygems-uri "rspec-mocks" version))
814 "06y508cjqycb4yfhxmb3nxn0v9xqf17qbd46l1dh4xhncinr4fyp"))))
815 (build-system ruby-build-system)
817 '(#:tests? #f)) ; avoid dependency cycles
819 (list ruby-rspec-support ruby-diff-lcs))
820 (synopsis "RSpec stubbing and mocking library")
821 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
822 support for stubbing and mocking.")
823 (home-page "https://github.com/rspec/rspec-mocks")
824 (license license:expat)))
826 (define-public ruby-rspec-mocks-2
827 (package (inherit ruby-rspec-mocks)
831 (uri (rubygems-uri "rspec-mocks" version))
834 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
836 (list ruby-diff-lcs))))
838 (define-public ruby-rspec-rerun
840 (name "ruby-rspec-rerun")
845 (uri (rubygems-uri "rspec-rerun" version))
848 "1gy7znkcaqhpccfnk2nvaqbsvgxy3q57cmjwkl9fi1zabaq5lbkj"))))
849 (build-system ruby-build-system)
851 '(;; No included tests
853 (propagated-inputs (list ruby-rspec))
854 (synopsis "Track failed RSpec tests to re-run them")
856 "This package provides an automated way to track, and then re-run failed
858 (home-page "https://github.com/dblock/rspec-rerun")
859 (license license:expat)))
861 (define-public ruby-rspec-wait
863 (name "ruby-rspec-wait")
868 (uri (rubygems-uri "rspec-wait" version))
871 "0gvj1bp5ccx001dyvcgk2j49s5sl6vs9fdaqqb08z3bd1554hsww"))))
872 (build-system ruby-build-system)
875 (modify-phases %standard-phases
878 (invoke "rake" "spec"))))))
883 (home-page "https://github.com/laserlemon/rspec-wait")
884 (synopsis "Wait for conditions in RSpec")
886 "RSpec::Wait strives to make it easier to test asynchronous or slow
888 (license license:expat)))
890 (define-public ruby-rspec
896 (uri (rubygems-uri "rspec" version))
899 "15ppasvb9qrscwlyjz67ppw1lnxiqnkzx5vkx1bd8x5n3dhikxc3"))))
900 (build-system ruby-build-system)
902 '(#:tests? #f)) ; avoid dependency cycles
904 (list ruby-rspec-core ruby-rspec-mocks ruby-rspec-expectations))
905 (synopsis "Behavior-driven development framework for Ruby")
906 (description "RSpec is a behavior-driven development (BDD) framework for
907 Ruby. This meta-package includes the RSpec test runner, along with the
908 expectations and mocks frameworks.")
909 (home-page "https://rspec.info/")
910 (license license:expat)))
912 (define-public ruby-rspec-2
913 (package (inherit ruby-rspec)
917 (uri (rubygems-uri "rspec" version))
920 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
922 (list ruby-rspec-core-2 ruby-rspec-mocks-2 ruby-rspec-expectations-2))))
924 ;; Bundler is yet another source of circular dependencies, so we must disable
925 ;; its test suite as well.
926 (define-public bundler
932 (uri (rubygems-uri "bundler" version))
935 "12glbb1357x91fvd004jgkw7ihlkpc9dwr349pd7j83isqhls0ah"))))
936 (build-system ruby-build-system)
938 '(#:tests? #f)) ; avoid dependency cycles
939 (synopsis "Ruby gem bundler")
940 (description "Bundler automatically downloads and installs a list of gems
941 specified in a \"Gemfile\", as well as their dependencies.")
942 (home-page "https://bundler.io/")
943 (license license:expat)))
945 (define-public ruby-builder
947 (name "ruby-builder")
951 (uri (rubygems-uri "builder" version))
954 "045wzckxpwcqzrjr353cxnyaxgf0qg22jh00dcx7z38cys5g1jlr"))))
955 (build-system ruby-build-system)
958 (modify-phases %standard-phases
959 (add-after 'unpack 'do-not-use-rvm
961 (substitute* "rakelib/tags.rake"
962 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
964 (synopsis "Ruby library to create structured data")
965 (description "Builder provides a number of builder objects that make it
966 easy to create structured data. Currently the following builder objects are
967 supported: XML Markup and XML Events.")
968 (home-page "https://github.com/jimweirich/builder")
969 (license license:expat)))
971 (define-public ruby-bump
978 (uri (rubygems-uri "bump" version))
981 "1xinbr9rzh6cj75x24niwgqcnbhdxc68a8bc41lk8xv6fd906fym"))))
982 (build-system ruby-build-system)
984 '(;; No included tests
986 (synopsis "Tool for working with Rubygems")
988 "Bump provides commands to manage Rubygem versioning, updating to the
989 next patch version for example.")
990 (home-page "https://github.com/gregorym/bump")
991 (license license:expat)))
993 (define-public ruby-rjb
999 (uri (rubygems-uri "rjb" version))
1002 "1ppj8rbicj3w0nhh7f73mflq19yd7pzdzkh2a91hcvphriy5b0ca"))))
1003 (build-system ruby-build-system)
1005 `(#:tests? #f ; no rakefile
1007 (modify-phases %standard-phases
1008 (add-before 'build 'set-java-home
1009 (lambda* (#:key inputs #:allow-other-keys)
1010 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
1013 `(("jdk" ,icedtea "jdk")))
1014 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
1015 (description "RJB is a bridge program that connects Ruby and Java via the
1016 Java Native Interface.")
1017 (home-page "https://www.artonx.org/collabo/backyard/?RubyJavaBridge")
1018 (license license:lgpl2.1+)))
1020 (define-public ruby-log4r
1027 (uri (rubygems-uri "log4r" version))
1030 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
1031 (build-system ruby-build-system)
1033 '(#:tests? #f)) ; no Rakefile in gem
1034 (synopsis "Flexible logging library for Ruby")
1035 (description "Comprehensive and flexible logging library written
1036 in Ruby for use in Ruby programs. It features a hierarchical logging
1037 system of any number of levels, custom level names, logger
1038 inheritance, multiple output destinations per log event, execution
1039 tracing, custom formatting, thread safteyness, XML and YAML
1040 configuration, and more.")
1041 (home-page "http://log4r.rubyforge.org/")
1042 (license license:bsd-3)))
1044 (define-public ruby-atoulme-antwrap
1046 (name "ruby-atoulme-antwrap")
1050 (uri (rubygems-uri "atoulme-Antwrap" version))
1053 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
1054 (build-system ruby-build-system)
1055 ;; Test data required for most of the tests are not included.
1056 (arguments `(#:tests? #f))
1061 (synopsis "Ruby wrapper for the Ant build tool")
1062 (description "Antwrap is a Ruby module that wraps the Apache Ant build
1063 tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
1065 (home-page "http://rubyforge.org/projects/antwrap/")
1066 (license license:expat)))
1068 (define-public ruby-atoulme-saikuro
1070 (name "ruby-atoulme-saikuro")
1074 (uri (rubygems-uri "atoulme-Saikuro" version))
1077 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
1078 (build-system ruby-build-system)
1079 ;; FIXME: There are no unit tests. The tests are demonstrations of the
1081 (arguments `(#:tests? #f))
1082 (synopsis "Cyclomatic complexity analyzer")
1083 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
1084 given Ruby source code Saikuro will generate a report listing the cyclomatic
1085 complexity of each method found. In addition, Saikuro counts the number of
1086 lines per method and can generate a listing of the number of tokens on each
1088 (home-page "http://www.github.com/atoulme/Saikuro")
1089 ;; File headers contain the BSD-3 license and the README.rdoc says that
1090 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
1091 ;; of the Expat license.
1092 (license license:bsd-3)))
1094 (define-public ruby-awesome-print
1096 (name "ruby-awesome-print")
1101 (uri (rubygems-uri "awesome_print" version))
1104 "14arh1ixfsd6j5md0agyzvksm5svfkvchb90fp32nn7y3avcmc2h"))))
1105 (build-system ruby-build-system)
1108 (modify-phases %standard-phases
1111 ;; Remove failing test.
1112 (for-each delete-file
1113 '("spec/ext/nokogiri_spec.rb"
1114 "spec/colors_spec.rb"
1115 "spec/formats_spec.rb"
1116 "spec/methods_spec.rb"
1118 "spec/objects_spec.rb"))
1119 (invoke "rspec" "-c" "spec"))))))
1121 (list ruby-nokogiri ruby-rspec ruby-simplecov))
1122 (synopsis "Pretty print Ruby objects to visualize their structure")
1124 "Ruby dubugging companion: pretty print Ruby objects to visualize their
1125 structure. Supports custom object formatting via plugins.")
1126 (home-page "https://github.com/awesome-print/awesome_print")
1127 (license license:expat)))
1129 (define-public ruby-pandoc-ruby
1131 (name "ruby-pandoc-ruby")
1135 (method git-fetch) ;the gem lacks many test files
1137 (url "https://github.com/xwmx/pandoc-ruby")
1139 (file-name (git-file-name name version))
1142 "03a11clhycyn0jhc7g9davpqd83sn60jqwjy1y145ag9sq6sp935"))))
1143 (build-system ruby-build-system)
1145 `(#:tests? #f ; Disable tests since they depend on pandoc behavior
1146 ; and there are no upstream releases.
1148 (modify-phases %standard-phases
1149 (add-after 'unpack 'patch-pandoc-path
1150 (lambda* (#:key inputs #:allow-other-keys)
1151 (let ((pandoc (search-input-file inputs "/bin/pandoc")))
1152 (substitute* "lib/pandoc-ruby.rb"
1153 (("@@pandoc_path = 'pandoc'")
1154 (format #f "@@pandoc_path = '~a'" pandoc)))
1155 (substitute* "test/test_pandoc_ruby.rb"
1156 (("('|\")pandoc" _ quote)
1157 (string-append quote pandoc))
1160 (add-after 'unpack 'adjust-tests
1161 ;; The tests expect filenames with spaces. Because they don't have
1162 ;; spaces the quotes around the output are dropped automatically.
1164 (substitute* "test/test_pandoc_ruby.rb"
1165 (("\\\\\"#\\{file\\.path\\}\\\\\"") "#{file.path}"))))
1166 (add-after 'extract-gemspec 'remove-Gemfile.lock
1168 (delete-file "Gemfile.lock")
1169 (substitute* "pandoc-ruby.gemspec"
1170 (("Gemfile\\.lock") "")))))))
1175 (synopsis "Ruby wrapper for Pandoc")
1176 (description "PandocRuby is a wrapper for Pandoc, a Haskell library with
1177 command line tools for converting one markup format to another. Pandoc can
1178 convert documents from a variety of formats including markdown,
1179 reStructuredText, textile, HTML, DocBook, LaTeX, and MediaWiki markup to a
1180 variety of other formats, including markdown, reStructuredText, HTML, LaTeX,
1181 ConTeXt, PDF, RTF, DocBook XML, OpenDocument XML, ODT, GNU Texinfo, MediaWiki
1182 markup, groff man pages, HTML slide shows, EPUB, Microsoft Word docx, and
1184 (home-page "https://github.com/xwmx/pandoc-ruby")
1185 (license license:expat)))
1187 (define-public ruby-patron
1189 (name "ruby-patron")
1194 (uri (rubygems-uri "patron" version))
1197 "0523gddx88zql2mq6655k60gy2ac8vybpzkcf90lmd9nx7wl3fi9"))))
1198 (build-system ruby-build-system)
1202 `(#:tests? #f)) ; no included tests
1203 (synopsis "Ruby HTTP client library based on @code{libcurl}")
1205 "Patron is a Ruby HTTP client library based on @code{libcurl}. It does
1206 not try to expose the full power (read complexity) of @code{libcurl} but
1207 instead tries to provide a sane API while taking advantage of @code{libcurl}
1209 (home-page "https://github.com/toland/patron")
1210 (license license:expat)))
1212 (define-public ruby-slim
1219 (uri (rubygems-uri "slim" version))
1222 "0gjx30g84c82qzg32bd7giscvb4206v7mvg56kc839w9wjagn36n"))))
1223 (build-system ruby-build-system)
1226 (modify-phases %standard-phases
1227 ;; See: https://github.com/slim-template/slim/issues/857 and
1228 ;; https://github.com/slim-template/slim/issues/858.
1229 (add-after 'unpack 'skip-broken-tests
1231 (substitute* "test/core/test_embedded_engines.rb"
1232 (("def test_render_with_markdown")
1233 "def skipped_test_render_with_markdown"))
1234 (substitute* "test/translator/test_translator.rb"
1235 (("raise (\"Missing test for.*)" _ tail)
1236 (string-append "print " tail)))
1238 ;; See: https://salsa.debian.org/ruby-team/ruby-slim/-/commit/
1239 ;; 824862bd99d1675bc699d8fc71ba965a785c1f44.
1240 (add-after 'unpack 'prevent-bundler-interference
1242 (substitute* "Rakefile"
1243 (("require 'bundler/setup'") "nil")
1244 (("Bundler::GemHelper\\.install_tasks") "nil"))
1247 (list ruby-rack-test ruby-sinatra))
1249 (list ruby-temple ruby-tilt))
1250 (synopsis "Minimalist template language for Ruby")
1251 (description "Slim is a template language for Ruby that aims to reduce the
1252 syntax to the minimum while remaining clear.")
1253 (home-page "http://slim-lang.com/")
1254 (license license:expat)))
1256 (define-public ruby-asciidoctor
1258 (name "ruby-asciidoctor")
1262 (method git-fetch) ;the gem release lacks a Rakefile
1264 (url "https://github.com/asciidoctor/asciidoctor")
1265 (commit (string-append "v" version))))
1266 (file-name (git-file-name name version))
1269 "086i17v9rxx0sxac26xp8c5v75jqba6rqjlk57x94qjvrh8vzyw2"))))
1270 (build-system ruby-build-system)
1272 `(#:test-target "test:all"
1274 (modify-phases %standard-phases
1275 (add-after 'extract-gemspec 'strip-version-requirements
1277 (delete-file "Gemfile")
1278 (substitute* "asciidoctor.gemspec"
1279 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1280 (string-append stripped "\n")))
1292 ruby-rspec-expectations
1296 (synopsis "Converter from AsciiDoc content to other formats")
1297 (description "Asciidoctor is a text processor and publishing toolchain for
1298 converting AsciiDoc content to HTML5, DocBook 5 (or 4.5), PDF, and other
1300 (home-page "https://asciidoctor.org")
1301 (license license:expat)))
1303 (define-public ruby-asciidoctor-multipage
1305 (name "ruby-asciidoctor-multipage")
1310 (url "https://github.com/owenh000/asciidoctor-multipage")
1311 (commit (string-append "v" version))))
1312 (file-name (git-file-name name version))
1315 "01qqkf00cp4sj82brz8kl02pjirydafwgld3z166slysiq78d1c5"))))
1316 (propagated-inputs (list ruby-asciidoctor ruby-slim))
1317 (build-system ruby-build-system)
1319 `(#:phases (modify-phases %standard-phases
1320 (add-after 'extract-gemspec 'strip-version-requirements
1322 (delete-file "Gemfile")
1323 (substitute* "asciidoctor-multipage.gemspec"
1324 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1325 (string-append stripped "
1328 "Asciidoctor extension for generating HTML output using multiple pages")
1330 "Asciidoctor generates single-page documents. This extension
1331 splits documents up into multiple HTML pages according to their headings, with
1332 configurable levels.")
1333 (license license:expat)
1334 (home-page "https://github.com/owenh000/asciidoctor-multipage")))
1336 (define-public ruby-prawn-icon
1338 (name "ruby-prawn-icon")
1343 (uri (rubygems-uri "prawn-icon" version))
1346 "1ivkdf8rdf92hhy97vbmc2a4w97vcvqd58jcj4z9hz3hfsb1526w"))))
1347 (build-system ruby-build-system)
1349 `(#:test-target "spec"
1350 #:phases (modify-phases %standard-phases
1351 (add-after 'unpack 'remove-unnecessary-dependencies
1353 (substitute* '("Rakefile" "spec/spec_helper.rb")
1354 ((".*[Bb]undler.*") "")
1355 (("^require 'rubocop.*") "")
1356 (("^RuboCop.*") ""))
1359 (list ruby-pdf-inspector ruby-pdf-reader ruby-rspec ruby-simplecov))
1362 (synopsis "Icon fonts for use with the Prawn PDF toolkit")
1363 (description "@code{Prawn::Icon} provides various icon fonts including
1364 FontAwesome, PaymentFont and Foundation Icons for use with the Prawn PDF
1366 (home-page "https://github.com/jessedoyle/prawn-icon/")
1367 (license %prawn-project-licenses)))
1369 (define-public ruby-css-parser
1371 (name "ruby-css-parser")
1376 (uri (rubygems-uri "css_parser" version))
1379 "04c4dl8cm5rjr50k9qa6yl9r05fk9zcb1zxh0y0cdahxlsgcydfw"))))
1380 (build-system ruby-build-system)
1381 (arguments `(#:tests? #f)) ;gem doesn't ship with test suite
1383 (list ruby-addressable))
1384 (synopsis "Ruby Cascading Style Sheets (CSS) parser")
1385 (description "This package allows loading, parsing and cascading Cascading
1386 Style Sheets (CSS) rule sets in Ruby.")
1387 (home-page "https://github.com/premailer/css_parser")
1388 (license license:expat)))
1390 (define-public ruby-prawn-svg
1392 (name "ruby-prawn-svg")
1397 (uri (rubygems-uri "prawn-svg" version))
1400 "0df3l49cy3xpwi0b73hmi2ykbjg9kjwrvhk0k3z7qhh5ghmmrn77"))))
1401 (build-system ruby-build-system)
1403 `(#:phases (modify-phases %standard-phases
1404 (add-after 'unpack 'do-not-use-bundler
1406 (substitute* "spec/spec_helper.rb"
1407 ((".*[Bb]undler.*") ""))
1410 (lambda* (#:key tests? #:allow-other-keys)
1412 (invoke "rspec" "-Ilib" "-rprawn-svg"))
1417 (list ruby-css-parser ruby-prawn))
1418 (synopsis "SVG renderer for the Prawn PDF library")
1419 (description "This library allows rendering Scalable Vector Graphics (SVG)
1420 graphics directly into a Portable Document Format (PDF) document using the
1422 (home-page "https://github.com/mogest/prawn-svg")
1423 (license license:expat)))
1425 (define-public ruby-prawn-templates
1427 (name "ruby-prawn-templates")
1433 (url "https://github.com/prawnpdf/prawn-templates")
1435 (file-name (git-file-name name version))
1438 "0wll54wxxwixpwazfn4ffbqvqbfrl01cfsv8y11vnlzy7isx5xvl"))))
1439 (build-system ruby-build-system)
1441 `(#:phases (modify-phases %standard-phases
1442 (add-after 'unpack 'do-not-use-bundler
1444 (substitute* "spec/spec_helper.rb"
1445 ((".*[Bb]undler.*") ""))
1448 (lambda* (#:key tests? #:allow-other-keys)
1453 (list ruby-pdf-inspector ruby-rspec))
1455 (list ruby-pdf-reader ruby-prawn))
1456 (synopsis "Prawn extension to include or combine PDF documents")
1457 (description "This @strong{unmaintained} package provides a Prawn
1458 extension that allows including other Portable Document Format (PDF) documents
1459 as background or combining several PDF documents into one. This functionality
1460 used to be part of Prawn itself, but was extracted from Prawn 0.15.0 because
1461 of its many longstanding issues.")
1462 (home-page "https://github.com/prawnpdf/prawn-templates")
1463 (license %prawn-project-licenses)))
1465 (define-public ruby-polyglot
1467 (name "ruby-polyglot")
1472 (uri (rubygems-uri "polyglot" version))
1475 "1bqnxwyip623d8pr29rg6m8r0hdg08fpr2yb74f46rn1wgsnxmjr"))))
1476 (build-system ruby-build-system)
1477 (arguments `(#:tests? #f)) ;no test suite
1478 (synopsis "Augment @code{require} to load non-Ruby file types")
1479 (description "The Polyglot library allows a Ruby module to register a
1480 loader for the file type associated with a filename extension, and it augments
1481 @code{require} to find and load matching files.")
1482 (home-page "https://github.com/cjheath/polyglot")
1483 (license license:expat)))
1485 (define-public ruby-treetop
1487 (name "ruby-treetop")
1491 (method git-fetch) ;no test suite in distributed gem
1493 (url "https://github.com/cjheath/treetop")
1494 (commit (string-append "v" version))))
1495 (file-name (git-file-name name version))
1498 "1dmk94z6ivhrz5hsq68vl5vgydhkz89n394rha1ymddw3rymbfcv"))))
1499 (build-system ruby-build-system)
1501 `(#:test-target "spec"))
1503 (list ruby-activesupport ruby-rr ruby-rspec))
1505 (list ruby-polyglot))
1506 (synopsis "Ruby-based parsing DSL based on parsing expression grammars")
1507 (description "This package provides a Ruby-based Parsing Expression
1508 Grammar (PEG) parser generator Domain Specific Language (DSL).")
1509 (home-page "https://github.com/cjheath/treetop")
1510 (license license:expat)))
1512 (define-public ruby-typhoeus
1514 (name "ruby-typhoeus")
1519 (uri (rubygems-uri "typhoeus" version))
1522 "1m22yrkmbj81rzhlny81j427qdvz57yk5wbcf3km0nf3bl6qiygz"))))
1523 (build-system ruby-build-system)
1525 `(#:tests? #f)) ; no included tests
1528 (synopsis "@code{libcurl} wrapper in Ruby")
1530 "Like a modern code version of the mythical beast with 100 serpent heads,
1531 Typhoeus runs HTTP requests in parallel while cleanly encapsulating handling
1533 (home-page "https://github.com/typhoeus/typhoeus")
1534 (license license:expat)))
1536 (define-public ruby-rubocop-rspec
1538 (name "ruby-rubocop-rspec")
1544 (url "https://github.com/rubocop-hq/rubocop-rspec")
1545 (commit (string-append "v" version))))
1546 (file-name (git-file-name name version))
1549 "0gdpjpympb6qc77bang759z7z6lckf14ghkx8v6614agxg8l3g5y"))))
1550 (build-system ruby-build-system)
1552 '(#:test-target "internal_investigation"
1554 (modify-phases %standard-phases
1555 (add-before 'check 'set-HOME
1557 (setenv "HOME" "/tmp")
1560 (list ruby-rubocop ruby-rubocop-ast))
1562 (list ruby-rack ruby-rspec ruby-rubocop-performance ruby-simplecov
1564 (synopsis "Code style checking for RSpec files")
1565 (description "This package provides a plugin for the RuboCop code style
1566 enforcing & linting tool.")
1567 (home-page "https://github.com/rubocop-hq/rubocop-rspec")
1568 (license license:expat)))
1570 (define-public ruby-rubocop-rspec-minimal
1573 (inherit ruby-rubocop-rspec)
1575 (substitute-keyword-arguments (package-arguments ruby-rubocop-rspec)
1576 ((#:tests? _ #f) #f)))
1577 (propagated-inputs '())
1578 (native-inputs '()))))
1580 (define-public ruby-rubocop-performance
1582 (name "ruby-rubocop-performance")
1588 (url "https://github.com/rubocop-hq/rubocop-performance")
1589 (commit (string-append "v" version))))
1590 (file-name (git-file-name name version))
1593 "04lmkmz6c0ccs5miikrww7lakp7y6xz00g7b47ay7rn7sx5j6qyf"))))
1594 (build-system ruby-build-system)
1596 `(#:tests? #f ; tests require a git checkout of rubocop's source code.
1598 (modify-phases %standard-phases
1599 (replace 'replace-git-ls-files
1601 (substitute* "rubocop-performance.gemspec"
1602 (("`git ls-files -z config lib LICENSE.txt README.md`")
1603 "`find config lib LICENSE.txt README.md -type f -print0 |sort -z`"))
1605 (add-before 'check 'set-HOME
1607 (setenv "HOME" "/tmp")
1610 (list ruby-rubocop ruby-rubocop-ast))
1612 (list ruby-bump ruby-yard))
1613 (synopsis "Performance optimizations checkers for Ruby code")
1614 (description "This package provides a collection of RuboCop cops to check
1615 for performance optimizations in Ruby code.")
1616 (home-page "https://docs.rubocop.org/rubocop-performance/")
1617 (license license:expat)))
1619 (define-public ruby-rubocop-performance-minimal
1622 (inherit ruby-rubocop-performance)
1624 (substitute-keyword-arguments (package-arguments ruby-rubocop-performance)
1625 ((#:tests? _ #f) #f)))
1626 (propagated-inputs '())
1627 (native-inputs '()))))
1629 (define-public ruby-gimme
1630 (let ((revision "1")
1631 (commit "4e71f0236f1271871916dd403261d26533db34c0"))
1634 (version (git-version "0.5.0" revision commit))
1639 (url "https://github.com/searls/gimme")
1641 (file-name (git-file-name name version))
1644 "0hrd32ygvf3i7h47ak8f623cz8ns9q7g60nnnvvlnywbggjaz3h6"))))
1645 (build-system ruby-build-system)
1647 (list ruby-coveralls ruby-cucumber ruby-pry ruby-simplecov
1650 `(;; The cucumber task fails with error: "index 3 out of matches
1651 ;; (IndexError)", apparently due to our newer Cucumber version.
1652 ;; TODO: Try the "default" task with a future release.
1653 #:test-target "spec"
1655 (modify-phases %standard-phases
1656 (add-after 'extract-gemspec 'prepare-for-tests
1658 ;; Delete failing tests (possibly due to our newer rspec
1660 (delete-file "spec/gimme/gives_class_methods_spec.rb")
1661 (delete-file "spec/gimme/rspec_adapter_spec.rb")
1662 (delete-file "spec/gimme/verifies_class_methods_spec.rb")
1663 ;; Fix duplicate version requirements and de-register files.
1664 (delete-file "Gemfile")
1665 (delete-file "Gemfile.lock")
1666 (substitute* "gimme.gemspec"
1667 ((".*\"Gemfile\".*") "")
1668 ((".*\"Gemfile\\.lock\",.*") "")
1669 ((".*(rspec|cucumber).*\">= 0\".*") "")
1670 (("\"spec/gimme/gives_class_methods_spec.rb\",") "")
1671 (("\"spec/gimme/rspec_adapter_spec.rb\",") "")
1672 (("\"spec/gimme/verifies_class_methods_spec.rb\",") "")
1673 ;; All of these gems relate to development, and are
1674 ;; unnecessary when running the tests.
1675 ((".*(add|gem).*guard-.*") "")
1676 ((".*(add|gem).*jeweler.*") "")
1677 ((".*(add|gem).*pry.*") "")
1678 ((".*(add|gem).*growl.*") "")
1679 ((".*(add|gem).*rb-fsevent.*") ""))
1681 (synopsis "Lightweight test double library for Ruby")
1682 (description "Gimme is a very lightweight test double library for Ruby,
1683 based on Mockito (a mocking framework for Java). It is an opinionated (but
1684 not noisy) means to facilitate test-driving by enabling the authors to specify
1685 only what they care about.")
1686 (home-page "https://github.com/searls/gimme")
1687 (license license:expat))))
1689 (define-public ruby-standard
1691 (name "ruby-standard")
1695 (method git-fetch) ;no test suite in distributed gem
1697 (url "https://github.com/testdouble/standard")
1698 (commit (string-append "v" version))))
1699 (file-name (git-file-name name version))
1702 "0ylx0lm2pbbgr5h7fban592w96bl3wxmvfcpcdfrhkxnpg5kiwgv"))))
1703 (build-system ruby-build-system)
1705 ;; TODO: the tests are currently broken due to using a newer Rubocop.
1708 (modify-phases %standard-phases
1709 (add-after 'unpack 'relax-version-requiremens
1711 (delete-file "Gemfile")
1712 (delete-file "Gemfile.lock")
1715 (list ruby-gimme ruby-pry ruby-simplecov))
1717 (list ruby-rubocop ruby-rubocop-performance))
1718 (synopsis "Ruby Style Guide, with linter & automatic code fixer")
1719 (description "Standard is a port of StandardJS. Like StandardJS, it aims
1720 to save time in the following ways:
1722 @item No configuration.
1723 @item Automatically format code.
1724 @item Catch style issues and programmer errors early.
1726 (home-page "https://github.com/testdouble/standard")
1727 (license license:expat)))
1729 (define-public ruby-chunky-png
1731 (name "ruby-chunky-png")
1737 (url "https://github.com/wvanbergen/chunky_png")
1738 (commit (string-append "v" version))))
1739 (file-name (git-file-name name version))
1741 (base32 "1m7y11ix38h5a2pj5v81qdmvqh980ql9hp62hk2dxwkwsa4nh22h"))))
1742 (build-system ruby-build-system)
1744 `(#:test-target "spec"
1746 (modify-phases %standard-phases
1747 (add-after 'unpack 'disable-bundler
1749 (substitute* (find-files "." "\\.rb$")
1750 (("require.*bundler/setup.*") ""))
1753 (list bundler ruby-rspec ruby-standard ruby-yard))
1754 (synopsis "Ruby library to handle PNG images")
1755 (description "ChunkyPNG is a pure Ruby library that can read and write
1756 Portable Network Graphics (PNG) images without depending on an external image
1757 library. It tries to be memory efficient and reasonably fast. It has
1761 Decoding support for any image that the PNG standard allows. This includes all
1762 standard color modes, all bit depths, all transparency, and interlacing and
1765 Encoding support for images of all color modes (true color, grayscale, and
1766 indexed) and transparency for all these color modes. The best color mode is
1767 chosen automatically, based on the amount of used colors.
1768 @item Read/write access to the image's pixels.
1769 @item Read/write access to all image metadata that is stored in chunks.
1771 Memory efficiency: @code{fixnum} are used, i.e. 4 or 8 bytes of memory per
1772 pixel, depending on the hardware).
1774 Performance: ChunkyPNG is reasonably fast for Ruby standards, by only using
1775 integer math and a highly optimized saving routine.
1776 @item Interoperability with RMagick.
1779 ChunkyPNG is vulnerable to decompression bombs and can run out of memory when
1780 loading a specifically crafted PNG file. This is hard to fix in pure Ruby.
1781 Deal with untrusted images in a separate process, e.g., by using @code{fork}
1782 or a background processing library.")
1783 (home-page "https://github.com/wvanbergen/chunky_png/wiki")
1784 (license license:expat)))
1786 (define-public ruby-text-hyphen
1788 (name "ruby-text-hyphen")
1793 (uri (rubygems-uri "text-hyphen" version))
1796 "1gj4awvs9ryf960m0iawg43jyjmfwcqgfwrbcfp890a57b9ag7q1"))))
1797 (build-system ruby-build-system)
1800 (synopsis "Ruby library to hyphenate words in various languages")
1801 (description "Text::Hyphen is a Ruby library to hyphenate words in various
1802 languages using Ruby-fied versions of TeX hyphenation patterns. It will
1803 properly hyphenate various words according to the rules of the language the
1804 word is written in. The algorithm is based on that of the TeX typesetting
1805 system by Donald E. Knuth.")
1806 (home-page "https://github.com/halostatue/text-hyphen")
1807 ;; The whole is licensed under the Expat license, but parts use various
1808 ;; versions of the LaTeX Project Public License.
1809 (license license:expat)))
1811 (define-public ruby-open-uri-cached
1813 (name "ruby-open-uri-cached")
1818 (uri (rubygems-uri "open-uri-cached" version))
1821 "13xy2vhrgz9mdxhklw5fszhamsdxh8ysf3l40g92hqm4hm288wap"))))
1822 (build-system ruby-build-system)
1824 `(#:tests? #f)) ;no test suite
1825 (synopsis "OpenURI with transparent disk caching")
1826 (description "OpenURI with transparent disk caching, which is
1827 useful to avoid making excessive queries, for example when scraping
1829 (home-page "https://github.com/tigris/open-uri-cached")
1830 (license license:expat)))
1832 (define-public ruby-asciidoctor-pdf
1834 (name "ruby-asciidoctor-pdf")
1838 (method git-fetch) ;no test suite in the distributed gem
1840 (url "https://github.com/asciidoctor/asciidoctor-pdf")
1841 (commit (string-append "v" version))))
1842 (file-name (git-file-name name version))
1845 "1iyfy6n9d3rkyrfjmnnfb44c76mq1larmkv1x8n6p5nbm33wb9sf"))))
1846 (build-system ruby-build-system)
1848 `(#:test-target "spec"
1850 (modify-phases %standard-phases
1851 (add-after 'unpack 'remove-failing-tests
1852 ;; Two tests module fail for unknown reasons, *only* when
1853 ;; ran in the build container (see:
1854 ;; https://github.com/asciidoctor/asciidoctor-pdf/issues/1725#issuecomment-658777965).
1856 (delete-file "spec/audio_spec.rb")
1857 (delete-file "spec/video_spec.rb")))
1858 (add-after 'extract-gemspec 'strip-version-requirements
1860 (substitute* "asciidoctor-pdf.gemspec"
1861 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
1862 (string-append stripped "\n")))))
1863 ;; The tests rely on the Gem being installed, so move the check phase
1864 ;; after the install phase.
1866 (add-after 'install 'check
1867 (lambda* (#:key outputs tests? #:allow-other-keys)
1868 (let ((new-gem (string-append (assoc-ref outputs "out")
1869 "/lib/ruby/vendor_ruby")))
1871 (string-append (getenv "GEM_PATH") ":" new-gem))
1873 (invoke "rspec" "-t" "~visual" "-t" "~cli" "-t" "~network"))))))))
1875 (list ruby-chunky-png ruby-coderay ruby-pdf-inspector ruby-rouge
1878 `(("ruby-asciidoctor" ,ruby-asciidoctor)
1879 ("ruby-concurrent-ruby" ,ruby-concurrent)
1880 ("ruby-open-uri-cached" ,ruby-open-uri-cached)
1881 ("ruby-prawn" ,ruby-prawn)
1882 ("ruby-prawn-icon" ,ruby-prawn-icon)
1883 ("ruby-prawn-svg" ,ruby-prawn-svg)
1884 ("ruby-prawn-table" ,ruby-prawn-table)
1885 ("ruby-prawn-templates" ,ruby-prawn-templates)
1886 ("ruby-safe-yaml" ,ruby-safe-yaml)
1887 ("ruby-text-hyphen" ,ruby-text-hyphen)
1888 ("ruby-thread-safe" ,ruby-thread-safe)
1889 ("ruby-treetop" ,ruby-treetop)
1890 ("ruby-ttfunk" ,ruby-ttfunk)))
1891 (synopsis"AsciiDoc to Portable Document Format (PDF)} converter")
1892 (description "Asciidoctor PDF is an extension for Asciidoctor that
1893 converts AsciiDoc documents to Portable Document Format (PDF) using the Prawn
1894 PDF library. It has features such as:
1896 @item Direct AsciiDoc to PDF conversion
1897 @item Configuration-driven theme (style and layout)
1898 @item Scalable Vector Graphics (SVG) support
1899 @item PDF document outline (i.e., bookmarks)
1900 @item Table of contents page(s)
1901 @item Document metadata (title, authors, subject, keywords, etc.)
1902 @item Internal cross reference links
1903 @item Syntax highlighting with Rouge, Pygments, or CodeRay
1904 @item Page numbering
1905 @item Customizable running content (header and footer)
1907 “Keep together” blocks (i.e., page breaks avoided in certain block content)
1908 @item Orphaned section titles avoided
1909 @item Autofit verbatim blocks (as permitted by base_font_size_min setting)
1910 @item Table border settings honored
1911 @item Font-based icons
1912 @item Custom TrueType (TTF) fonts
1913 @item Double-sided printing mode (margins alternate on recto and verso pages)
1915 (home-page "https://asciidoctor.org/docs/asciidoctor-pdf")
1916 (license license:expat)))
1918 (define-public ruby-ast
1924 (method git-fetch) ;no test included in gem from v2.4.1
1926 (url "https://github.com/whitequark/ast")
1927 (commit (string-append "v" version))))
1928 (file-name (git-file-name name version))
1931 "0vm94yml8rknr7z034vg6s3fpx6lml2prz9fn3hr67cx0143bb4h"))))
1932 (build-system ruby-build-system)
1935 (modify-phases %standard-phases
1936 (add-after 'unpack 'remove-coveralls-requirement
1938 (substitute* "test/helper.rb"
1939 (("require 'coveralls'") "")
1940 (("Coveralls::SimpleCov::Formatter") ""))
1942 (add-after 'extract-gemspec 'remove-unnecessary-requirements
1943 (lambda* (#:key inputs #:allow-other-keys)
1944 (substitute* "ast.gemspec"
1945 ((".*coveralls.*") "\n")
1946 (("%q<rest-client>.*") "%q<rest-client>.freeze, [\">= 0\"])\n")
1947 (("%q<mime-types>.*") "%q<mime-types>.freeze, [\">= 0\"])\n")
1948 (("%q<rake>.*") "%q<rake>.freeze, [\">= 0\"])\n")
1949 (("12\\.3") "13.0"))
1954 ruby-bacon-colored-output
1962 (synopsis "Library for working with Abstract Syntax Trees")
1964 "@code{ast} is a Ruby library for working with Abstract Syntax Trees.
1965 It does this through immutable data structures.")
1966 (home-page "https://whitequark.github.io/ast/")
1967 (license license:expat)))
1969 (define-public ruby-sporkmonger-rack-mount
1970 ;; Testing the addressable gem requires a newer commit than that released, so
1971 ;; use an up to date version.
1972 (let ((revision "1")
1973 (commit "076aa2c47d9a4c081f1e9bcb56a826a9e72bd5c3"))
1975 (name "ruby-sporkmonger-rack-mount")
1976 (version (git-version "0.8.3" revision commit))
1980 (url "https://github.com/sporkmonger/rack-mount")
1982 (file-name (git-file-name name version))
1985 "1scx273g3xd93424x9lxc4zyvcp2niknbw5mkz6wkivpf7xsyxdq"))))
1986 (build-system ruby-build-system)
1988 ;; Tests currently fail so disable them.
1989 ;; https://github.com/sporkmonger/rack-mount/pull/1
1991 (propagated-inputs (list ruby-rack))
1992 (synopsis "Stackable dynamic tree based Rack router")
1994 "@code{Rack::Mount} supports Rack's @code{X-Cascade} convention to
1995 continue trying routes if the response returns pass. This allows multiple
1996 routes to be nested or stacked on top of each other.")
1997 (home-page "https://github.com/sporkmonger/rack-mount")
1998 (license license:expat))))
2000 (define-public ruby-ci-reporter
2002 (name "ruby-ci-reporter")
2006 (uri (rubygems-uri "ci_reporter" version))
2009 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
2010 (build-system ruby-build-system)
2012 `(#:test-target "rspec"))
2014 (list ruby-builder))
2016 (list bundler ruby-rspec))
2017 (synopsis "Generate XML reports of runs test")
2019 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
2020 you to generate XML reports of your test runs. The resulting files can be
2021 read by a continuous integration system that understands Ant's JUnit report
2023 (home-page "https://github.com/nicksieger/ci_reporter")
2024 (license license:expat)))
2026 (define-public ruby-contracts
2028 (name "ruby-contracts")
2033 (uri (rubygems-uri "contracts" version))
2036 "119f5p1n6r5svbx8h09za6a4vrsnj5i1pzr9cqdn9hj3wrxvyl3a"))))
2037 (build-system ruby-build-system)
2039 '(#:test-target "spec"
2041 (modify-phases %standard-phases
2042 ;; Don't run or require rubocop, the code linting tool, as this is a
2044 (add-after 'unpack 'dont-run-rubocop
2046 (substitute* "Rakefile"
2047 ((".*rubocop.*") "")
2048 ((".*RuboCop.*") ""))
2052 (synopsis "Method contracts for Ruby")
2054 "This library provides contracts for Ruby. A contract describes the
2055 correct inputs and output for a method, and will raise an error if a incorrect
2057 (home-page "https://github.com/egonSchiele/contracts.ruby")
2058 (license license:bsd-2)))
2060 (define-public ruby-crack
2067 (uri (rubygems-uri "crack" version))
2070 "1cr1kfpw3vkhysvkk3wg7c54m75kd68mbm9rs5azdjdq57xid13r"))))
2071 (build-system ruby-build-system)
2074 (modify-phases %standard-phases
2076 (lambda* (#:key tests? #:allow-other-keys)
2078 (for-each (lambda (file)
2079 (display file)(display "\n")
2080 (invoke "ruby" "-Ilib" "-Itest" "-rrubygems" file))
2081 (find-files "test" ".*rb$")))
2083 (synopsis "Simple JSON and XML parsing for Ruby")
2085 "@code{crack} provides really simple JSON and XML parsing, extracted from
2086 code in Merb and Rails.")
2087 (home-page "https://github.com/jnunemaker/crack")
2088 (license license:expat)))
2090 (define-public ruby-cliver
2092 (name "ruby-cliver")
2097 (uri (rubygems-uri "cliver" version))
2100 "096f4rj7virwvqxhkavy0v55rax10r4jqf8cymbvn4n631948xc7"))))
2101 (build-system ruby-build-system)
2104 (modify-phases %standard-phases
2105 ;; Avoid a incompatibility between rspec@2 and rake. Using rspec@3
2106 ;; would be nice, but the tests look to be incompatible:
2108 ;; NoMethodError: undefined method `last_comment'
2110 (lambda* (#:key tests? #:allow-other-keys)
2115 (list bundler ruby-rspec-2))
2116 (synopsis "Assertions for command-line dependencies in Ruby")
2118 "@code{cliver} provides a way to detect missing command-line
2119 dependencies, including versions.")
2120 (home-page "https://github.com/yaauie/cliver")
2121 (license license:expat)))
2123 (define-public ruby-czmq-ffi-gen
2125 (name "ruby-czmq-ffi-gen")
2130 (uri (rubygems-uri "czmq-ffi-gen" version))
2133 "1yf719dmf4mwks1hqdsy6i5kzfvlsha69sfnhb2fr2cgk2snbys3"))))
2134 (build-system ruby-build-system)
2136 '(#:tests? #f ;; Tests are not included in the release on rubygems.org
2138 (modify-phases %standard-phases
2139 (add-after 'unpack 'patch-lib_dirs
2140 (lambda* (#:key inputs #:allow-other-keys)
2141 (substitute* "lib/czmq-ffi-gen/czmq/ffi.rb"
2142 (("lib\\_dirs = \\[.*\\]")
2143 (string-append "lib_dirs = ['"
2144 (assoc-ref inputs "czmq") "/lib"
2146 (substitute* "lib/czmq-ffi-gen/libzmq.rb"
2147 (("lib\\_dirs = \\[.*\\]")
2148 (string-append "lib_dirs = ['"
2149 (assoc-ref inputs "zeromq") "/lib"
2153 (propagated-inputs (list ruby-ffi))
2154 (synopsis "Low-level Ruby bindings for CZMQ (generated using zproject)")
2156 "These Ruby bindings are not intended to be directly used, but rather
2157 used by higher level bindings like those provided by CZTop.")
2159 "https://github.com/paddor/czmq-ffi-gen")
2160 (license license:isc)))
2162 (define-public ruby-cztop
2169 (uri (rubygems-uri "cztop" version))
2172 "0yqbpaiw5d7f271d73lyrsh8xpx6n4zi6xqwfgi00dacxrq3s3fa"))))
2173 (build-system ruby-build-system)
2175 '(#:test-target "spec"
2177 (modify-phases %standard-phases
2178 (add-after 'unpack 'patch-lib_paths
2179 (lambda* (#:key inputs #:allow-other-keys)
2180 (substitute* "lib/cztop/poller/zmq.rb"
2181 (("lib\\_paths = \\[.*\\]")
2182 (string-append "lib_paths = ['"
2183 (assoc-ref inputs "zeromq") "/lib"
2186 (list bundler ruby-rspec))
2190 (list ruby-czmq-ffi-gen))
2191 (synopsis "CZMQ Ruby bindings")
2193 "CZMQ Ruby bindings, based on the generated low-level FFI bindings of
2194 CZMQ. The focus of of CZTop is on being easy to use and providing first class
2195 support for security mechanisms.")
2196 (home-page "https://github.com/paddor/cztop")
2197 (license license:isc)))
2199 (define-public ruby-saikuro-treemap
2201 (name "ruby-saikuro-treemap")
2205 (uri (rubygems-uri "saikuro_treemap" version))
2208 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
2209 (build-system ruby-build-system)
2210 ;; Some of the tests fail because the generated JSON has keys in a
2211 ;; different order. This is a problem with the test suite rather than any
2212 ;; of the involved libraries.
2213 (arguments `(#:tests? #f))
2215 (list ruby-json-pure ruby-atoulme-saikuro))
2216 (synopsis "Generate complexity treemap based on saikuro analysis")
2218 "This gem generates a treemap showing the complexity of Ruby code on
2219 which it is run. It uses Saikuro under the covers to analyze Ruby code
2221 (home-page "https://github.com/ThoughtWorksStudios/saikuro_treemap")
2222 (license license:expat)))
2224 (define-public ruby-oauth2
2226 (name "ruby-oauth2")
2231 (uri (rubygems-uri "oauth2" version))
2233 (base32 "15i9z4j5pcjkr30lkcd79xzbr4kpmy0bqgwa436fqyqk646fv036"))))
2234 (build-system ruby-build-system)
2236 '(#:tests? #f)) ; no included tests
2238 (list ruby-faraday ruby-jwt ruby-multi-json ruby-multi-xml
2240 (synopsis "Ruby wrapper for the OAuth 2.0")
2242 "This package provides a Ruby wrapper for the OAuth 2.0 protocol built
2243 with a similar style to the original OAuth spec.")
2244 (home-page "https://github.com/oauth-xx/oauth2")
2245 (license license:expat)))
2247 (define-public ruby-omniauth
2249 (name "ruby-omniauth")
2254 (uri (rubygems-uri "omniauth" version))
2256 (base32 "105mzgvmn2kjaacxw01h4wqv33r7hfn5z8fxlkk3jcjar14j71bh"))))
2257 (build-system ruby-build-system)
2259 (list ruby-hashie ruby-rack ruby-rack-protection))
2262 (synopsis "Generalized Rack framework for multiple-provider authentication")
2264 "This package provides a generalized Rack framework for multiple-provider
2266 (home-page "https://github.com/omniauth/omniauth")
2267 (license license:expat)))
2269 (define-public ruby-omniauth-oauth2
2271 (name "ruby-omniauth-oauth2")
2276 (uri (rubygems-uri "omniauth-oauth2" version))
2279 "10fr2b58sp7l6nfdvxpbi67374hkrvsf507cvda89jjs0jacy319"))))
2280 (build-system ruby-build-system)
2283 (modify-phases %standard-phases
2284 (add-after 'unpack 'remove-unnecessary-dependencies
2286 ;; The coveralls gem submits coverage information to an online
2287 ;; service, and is unnecessary when running the tests
2288 (substitute* "Gemfile"
2289 ((".*coveralls\"") ""))
2290 (substitute* "spec/helper.rb"
2291 (("require \"coveralls\"") "")
2292 (("Coveralls::SimpleCov::Formatter") ""))
2295 (list ruby-oauth2 ruby-omniauth))
2297 (list bundler ruby-rspec ruby-simplecov ruby-rack-test ruby-webmock))
2298 (synopsis "Abstract OAuth2 strategy for OmniAuth")
2300 "This library provides a generic OAuth2 strategy for OmniAuth. It
2301 doesn't provide a way to gather user information, so should be used as a
2302 building block for authentication strategies.")
2303 (home-page "https://github.com/omniauth/omniauth-oauth2")
2304 (license license:expat)))
2306 (define-public ruby-open4
2313 (uri (rubygems-uri "open4" version))
2316 "1cgls3f9dlrpil846q0w7h66vsc33jqn84nql4gcqkk221rh7px1"))))
2317 (build-system ruby-build-system)
2320 (modify-phases %standard-phases
2321 (add-after 'unpack 'patch
2323 (substitute* "rakefile"
2324 ;; Update the Rakefile so it works
2325 (("-rubygems") "-rrubygems")
2326 (("Config") "RbConfig"))
2328 (add-before 'check 'set-LIB
2330 ;; This is used in the rakefile when running the tests
2331 (setenv "LIB" "open4")
2333 (synopsis "Open child processes from Ruby and manage them easily")
2335 "@code{Open4} is a Ruby library to run child processes and manage their
2337 (home-page "https://github.com/ahoward/open4")
2338 (license license:ruby)))
2340 (define-public ruby-options
2342 (name "ruby-options")
2347 (uri (rubygems-uri "options" version))
2350 "1s650nwnabx66w584m1cyw82icyym6hv5kzfsbp38cinkr5klh9j"))))
2351 (build-system ruby-build-system)
2353 '(#:tests? #f ;; TODO: NameError: uninitialized constant Config
2355 (modify-phases %standard-phases
2356 (add-before 'check 'set-LIB
2358 ;; This is used in the Rakefile, and setting it avoids an issue
2359 ;; with running the tests.
2360 (setenv "LIB" "options")
2362 (synopsis "Ruby library to parse options from *args cleanly")
2364 "The @code{options} library helps with parsing keyword options in Ruby
2366 (home-page "https://github.com/ahoward/options")
2367 (license license:ruby)))
2369 (define-public ruby-erubi
2376 (uri (rubygems-uri "erubi" version))
2379 "1kagnf6ziahj0d781s6ryy6fwqwa3ad4xbzzj84p9m4nv4c2jir1"))))
2380 (build-system ruby-build-system)
2381 (synopsis "ERB template engine for Ruby")
2383 "Erubi is a ERB template engine for Ruby. It is a simplified fork of
2385 (home-page "https://github.com/jeremyevans/erubi")
2386 (license license:expat)))
2388 (define-public ruby-erubis
2390 (name "ruby-erubis")
2395 (uri (rubygems-uri "erubis" version))
2398 "1fj827xqjs91yqsydf0zmfyw9p4l2jz5yikg3mppz6d7fi8kyrb3"))))
2399 (build-system ruby-build-system)
2401 '(#:tests? #f)) ; tests do not run properly with Ruby 2.0
2402 (synopsis "Implementation of embedded Ruby (eRuby)")
2404 "Erubis is a fast implementation of embedded Ruby (eRuby) with several
2405 features such as multi-language support, auto escaping, auto trimming spaces
2406 around @code{<% %>}, a changeable embedded pattern, and Ruby on Rails
2408 (home-page "http://www.kuwata-lab.com/erubis/")
2409 (license license:expat)))
2411 (define-public ruby-ethon
2418 (uri (rubygems-uri "ethon" version))
2421 "0gggrgkcq839mamx7a8jbnp2h7x2ykfn34ixwskwb0lzx2ak17g9"))))
2422 (build-system ruby-build-system)
2424 `(#:tests? #f)) ; no included tests
2429 (synopsis "Very lightweight @code{libcurl} wrapper")
2431 "Ethon is a very basic @code{libcurl} wrapper using ffi.")
2432 (home-page "https://github.com/typhoeus/ethon")
2433 (license license:expat)))
2435 (define-public ruby-execjs
2437 (name "ruby-execjs")
2441 ;; fetch from github as the gem does not contain testing code
2444 (url "https://github.com/rails/execjs")
2445 (commit (string-append "v" version))))
2446 (file-name (git-file-name name version))
2449 "0c0vd2mmqq3ar4plbwi2wsbr31vn4h45i19r5km66skydnnbp1y6"))))
2450 (build-system ruby-build-system)
2453 ;; The test suite tests all the available backends. Currenly, this just
2454 ;; means the node backend.
2456 ;; PASSED: test:node
2457 ;; SKIPPED: test:duktape, ;; test:javascriptcore, test:jscript,
2458 ;; test:miniracer, test:rubyracer, ;; test:rubyrhino, test:v8
2460 (synopsis "Run JavaScript code from Ruby")
2462 "ExecJS lets you run JavaScript code from Ruby. It automatically picks a
2463 runtime to evaluate your JavaScript program, then returns the result to you as
2465 (home-page "https://github.com/rails/execjs")
2466 (license license:expat)))
2468 (define-public ruby-fakefs
2470 (name "ruby-fakefs")
2472 (home-page "https://github.com/fakefs/fakefs")
2474 ;; The Rubygems release does not contain tests.
2478 (commit (string-append "v" version))))
2479 (file-name (git-file-name name version))
2482 "008dq9knyip2bfbl0mrk8b8r7bv0k3bf128wcfqsgy1rqal4mgwk"))))
2483 (build-system ruby-build-system)
2485 '(#:phases (modify-phases %standard-phases
2486 (replace 'replace-git-ls-files
2488 (substitute* "fakefs.gemspec"
2489 (("`git ls-files lib README.md LICENSE`")
2490 "`find lib README.md LICENSE -type f | sort`"))
2492 (add-before 'check 'remove-version-constraints
2494 ;; Drop hard version requirements for test dependencies.
2495 (substitute* "fakefs.gemspec"
2496 (("(.*add_development_dependency .*), .*" _ dep)
2497 (string-append dep "\n")))
2500 (list ruby-bump ruby-maxitest ruby-rubocop ruby-rspec))
2501 (synopsis "Fake file system for Ruby")
2503 "This package provides a fake file system for use in test suites. It
2504 avoids the need for manually creating temporary directories, or dealing
2505 with platform intricacies in @code{File} and @code{FileUtils}.")
2506 (license license:expat)))
2508 (define-public ruby-orderedhash
2510 (name "ruby-orderedhash")
2514 (uri (rubygems-uri "orderedhash" version))
2517 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
2518 (build-system ruby-build-system)
2520 '(#:tests? #f)) ; no test suite
2521 (synopsis "Ruby library providing an order-preserving hash")
2522 (description "Orderedhash is a Ruby library providing a hash
2523 implementation that preserves the order of items and features some array-like
2525 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
2526 (license license:public-domain)))
2528 (define-public ruby-libxml
2530 (name "ruby-libxml")
2535 (uri (rubygems-uri "libxml-ruby" version))
2538 "0xy8wmjwjcnv36zi042678ncjzpxvy351ccbv7mzkns2n3kxfp54"))))
2539 (build-system ruby-build-system)
2541 (list zlib libxml2))
2543 '(#:tests? #f ; test suite hangs for unknown reason
2545 (list "--no-document" ; TODO: Re-enable when documentation
2548 (string-append "--with-xml2-include="
2549 (assoc-ref %build-inputs "libxml2")
2550 "/include/libxml2" ))))
2551 (synopsis "Ruby bindings for GNOME Libxml2")
2552 (description "The Libxml-Ruby project provides Ruby language bindings for
2553 the GNOME Libxml2 XML toolkit.")
2554 (home-page "https://xml4r.github.com/libxml-ruby")
2555 (license license:expat)))
2557 (define-public ruby-lino
2564 (uri (rubygems-uri "lino" version))
2567 "11d29g0fk372b9fcpyr0k6hxm2b4j4igpysmi542hgbbgqgp9cd3"))))
2568 (build-system ruby-build-system)
2570 '(#:tests? #f)) ; No included tests
2572 (list ruby-hamster ruby-open4))
2573 (synopsis "Build and execute commands in Ruby")
2575 "@code{Lino} provides an interface to run external commands. It provides
2576 an interface to add options as well as managing the standard input, output and
2578 (home-page "https://github.com/tobyclemson/lino")
2579 (license license:expat)))
2581 (define-public ruby-xml-simple
2583 (name "ruby-xml-simple")
2587 (uri (rubygems-uri "xml-simple" version))
2590 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
2591 (build-system ruby-build-system)
2593 '(#:tests? #f)) ; no test suite
2594 (synopsis "Simple Ruby library for XML processing")
2595 (description "This library provides a simple API for XML processing in
2597 (home-page "https://github.com/maik/xml-simple")
2598 (license license:ruby)))
2600 (define-public ruby-thor
2605 ;; Pull from git because the gem has no tests.
2608 (url "https://github.com/erikhuda/thor")
2609 (commit (string-append "v" version))))
2610 (file-name (git-file-name name version))
2613 "1anrx5vynk57hn5c8ig5pgkmcsbj9q5mvckd5rviw1jid7n89k57"))))
2614 (build-system ruby-build-system)
2616 '(#:phases (modify-phases %standard-phases
2617 (add-after 'unpack 'fix-readline-tests
2619 ;; Ensure Readline is initialized before running the
2620 ;; test to avoid a type clash with the mock ::Readline.
2621 ;; See <https://github.com/erikhuda/thor/pull/717>.
2622 (substitute* "spec/line_editor/readline_spec.rb"
2623 (("unless defined\\? ::Readline" all)
2624 (string-append "Thor::LineEditor::Readline.available?\n"
2627 (add-after 'unpack 'remove-coveralls-dependency
2629 ;; Do not hook the test suite into the online
2630 ;; coveralls service.
2631 (substitute* "Gemfile"
2632 ((".*coveralls.*") ""))
2633 (substitute* "spec/helper.rb"
2634 (("require \"coveralls\"") "")
2635 (("Coveralls::SimpleCov::Formatter") "")
2636 ;; Also drop the WebMock dependency which is only
2637 ;; present to allow a coveralls.io connection, and
2638 ;; would otherwise introduce a circular dependency.
2639 (("require \"webmock/rspec\"") "")
2640 (("WebMock\\.disable_net_connect.*") ""))
2642 (add-after 'unpack 'disable-network-tests
2644 ;; These tests attempt to look up example.com.
2645 (substitute* "spec/actions/file_manipulation_spec.rb"
2646 (("it \"accepts (https?) remote sources" _ proto)
2647 (string-append "xit \"accepts " proto " remote sources")))
2649 (add-after 'unpack 'disable-quality-tests
2651 ;; These tests attempt to check the git repository for
2652 ;; tabs vs spaces, double vs single quotes, etc, and
2653 ;; depend on the git checkout.
2654 (delete-file "spec/quality_spec.rb")
2656 (add-before 'check 'make-files-writable
2658 ;; The tests needs rw access to the test suite.
2659 (for-each make-file-writable (find-files "spec"))
2663 (invoke "rspec" "spec"))))))
2665 (list ruby-rspec ruby-simplecov))
2666 (synopsis "Ruby toolkit for building command-line interfaces")
2667 (description "Thor is a toolkit for building powerful command-line
2669 (home-page "http://whatisthor.com/")
2670 (license license:expat)))
2672 (define-public ruby-lumberjack
2674 (name "ruby-lumberjack")
2678 (uri (rubygems-uri "lumberjack" version))
2681 "06im7gcg42x77yhz2w5da2ly9xz0n0c36y5ks7xs53v0l9g0vf5n"))))
2682 (build-system ruby-build-system)
2684 (list ruby-rspec ruby-timecop))
2685 (synopsis "Logging utility library for Ruby")
2686 (description "Lumberjack is a simple logging utility that can be a drop in
2687 replacement for Logger or ActiveSupport::BufferedLogger. It provides support
2688 for automatically rolling log files even with multiple processes writing the
2690 (home-page "https://github.com/bdurand/lumberjack")
2691 (license license:expat)))
2693 (define-public ruby-rbnacl
2695 (name "ruby-rbnacl")
2700 (uri (rubygems-uri "rbnacl" version))
2703 "0ajxy5kj2jw09wdsla3jmha8w07vj5l14288xr9djpl327g3lzhn"))))
2704 (build-system ruby-build-system)
2707 (modify-phases %standard-phases
2708 (add-after 'unpack 'remove-unnecessary-dependencies
2710 ;; Coveralls relates to a network service, and Rubocop to code
2711 ;; linting and both are unnecessary to run the tests
2712 (substitute* "Gemfile"
2713 ((".*rubocop.*") "\n")
2714 ((".*guard-rspec.*") "\n")
2715 ((".*coveralls.*") "\n"))
2716 (substitute* "spec/spec_helper.rb"
2717 (("require \"coveralls\"") "")
2718 (("Coveralls.wear!") ""))
2720 (add-after 'unpack 'use-libsodium-from-store
2721 (lambda* (#:key inputs #:allow-other-keys)
2722 (substitute* '("lib/rbnacl/init.rb"
2723 "lib/rbnacl/sodium.rb")
2724 (("ffi_lib \\[.+\\]")
2725 (string-append "ffi_lib [\""
2726 (assoc-ref inputs "libsodium") "/lib/libsodium.so"
2729 ;; Run Rspec directly to avoid the Rubocop dependency in the Rakefile
2731 (lambda* (#:key tests? #:allow-other-keys)
2740 (list bundler ruby-rspec))
2741 (synopsis "Ruby FFI binding to libsodium")
2743 "This package provides Ruby FFI bindings to the Networking and
2744 Cryptography (NaCl) library, also known as libsodium. This provides a
2745 high-level toolkit for building cryptographic systems and protocols.")
2746 (home-page "https://github.com/crypto-rb/rbnacl")
2747 (license license:expat)))
2749 (define-public ruby-hkdf
2757 (url "https://github.com/jtdowney/hkdf")
2758 (commit (string-append "v" version))))
2759 (file-name (git-file-name name version))
2762 "1xqwdmxfnhagivwgb5v9ilwpb4jxlsqwj7pnj43d65zzg5m8p9r5"))))
2763 (build-system ruby-build-system)
2765 `(#:test-target "default"))
2768 (synopsis "HMAC-based Key Derivation Function")
2770 "This package provides a Ruby implementation of RFC5869: @acronym{HKDF,
2771 HMAC-based Extract-and-Expand Key Derivation Function}. The goal of HKDF is to
2772 take some source key material and generate suitable cryptographic keys from it.")
2773 (home-page "https://github.com/jtdowney/hkdf")
2774 (license license:expat)))
2776 (define-public ruby-nenv
2782 (uri (rubygems-uri "nenv" version))
2785 "0r97jzknll9bhd8yyg2bngnnkj8rjhal667n7d32h8h7ny7nvpnr"))))
2786 (build-system ruby-build-system)
2788 `(#:tests? #f)) ; no tests included
2790 (list ruby-rspec bundler))
2791 (synopsis "Ruby interface for modifying the environment")
2792 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
2793 and inspect the environment.")
2794 (home-page "https://github.com/e2/nenv")
2795 (license license:expat)))
2797 (define-public ruby-ptools
2799 (name "ruby-ptools")
2803 (uri (rubygems-uri "ptools" version))
2806 "1jb1h1nsk9zwykpniw8filbsk26kjsdlpk5wz6w0zyamcd41h87j"))))
2807 (build-system ruby-build-system)
2809 '(#:phases (modify-phases %standard-phases
2810 (add-after 'unpack 'patch-/bin/ls
2812 (substitute* "test/test_binary.rb"
2816 (add-before 'install 'create-gem
2818 ;; Do not attempt to sign the gem.
2819 (substitute* "Rakefile"
2820 (("spec\\.signing_key = .*")
2822 (invoke "rake" "gem:create"))))))
2823 (synopsis "Extra methods for Ruby's @code{File} class")
2825 "The @dfn{ptools} (power tools) library extends Ruby's core @code{File}
2826 class with many additional methods modelled after common POSIX tools, such as
2827 @code{File.which} for finding executables, @code{File.tail} to print the last
2828 lines of a file, @code{File.wc} to count words, and so on.")
2829 (home-page "https://github.com/djberg96/ptools")
2830 (license license:artistic2.0)))
2832 (define-public ruby-permutation
2834 (name "ruby-permutation")
2838 (uri (rubygems-uri "permutation" version))
2841 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
2842 (build-system ruby-build-system)
2845 (modify-phases %standard-phases
2846 (add-after 'unpack 'fix-rakefile
2848 (substitute* "Rakefile"
2849 (("require 'rake/gempackagetask'")
2850 "require 'rubygems/package_task'")
2851 (("include Config") ""))
2855 (invoke "ruby" "-Ilib" "test/test.rb"))))))
2856 (synopsis "Library to perform operations with sequence permutations")
2857 (description "This package provides a Ruby library to perform different
2858 operations with permutations of sequences, such as strings and arrays.")
2859 (home-page "https://flori.github.io/permutation")
2860 (license license:gpl2))) ; GPL 2 only
2862 (define-public ruby-shellany
2864 (name "ruby-shellany")
2868 (uri (rubygems-uri "shellany" version))
2871 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
2872 (build-system ruby-build-system)
2874 `(#:test-target "default"
2876 (modify-phases %standard-phases
2877 (add-after 'unpack 'fix-version-test
2879 (substitute* "spec/shellany_spec.rb"
2880 (("^RSpec") "require \"shellany\"\nRSpec"))
2883 (list ruby-rspec ruby-nenv bundler))
2884 (synopsis "Capture command output")
2885 (description "Shellany is a Ruby library providing functions to capture
2886 the output produced by running shell commands.")
2887 (home-page "https://rubygems.org/gems/shellany")
2888 (license license:expat)))
2890 (define-public ruby-notiffany
2892 (name "ruby-notiffany")
2896 (uri (rubygems-uri "notiffany" version))
2899 "0f47h3bmg1apr4x51szqfv3rh2vq58z3grh4w02cp3bzbdh6jxnk"))))
2900 (build-system ruby-build-system)
2901 ;; Tests are not included in the gem.
2902 (arguments `(#:tests? #f))
2904 (list ruby-shellany ruby-nenv))
2907 (synopsis "Wrapper library for notification libraries")
2908 (description "Notiffany is a Ruby wrapper library for notification
2909 libraries such as Libnotify.")
2910 (home-page "https://github.com/guard/notiffany")
2911 (license license:expat)))
2913 (define-public ruby-forking-test-runner
2915 (name "ruby-forking-test-runner")
2917 (home-page "https://github.com/grosser/forking_test_runner")
2920 (uri (git-reference (url home-page)
2921 (commit (string-append "v" version))))
2922 (file-name (git-file-name name version))
2925 "1mrglzkj2nrgisccf2f30zbfmcs0awv1g3lw994b2az90fl39x8m"))))
2926 (build-system ruby-build-system)
2928 '(#:test-target "spec"
2929 ;; FIXME: ActiveRecord depends on sqlite3 1.3.6, but Guix has
2930 ;; 1.4.1, which in turn breaks the tests that use ActiveRecord.
2932 #:phases (modify-phases %standard-phases
2933 (replace 'replace-git-ls-files
2935 (substitute* "forking_test_runner.gemspec"
2936 (("`git ls-files lib/ bin/ MIT-LICENSE`")
2937 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
2939 (add-before 'check 'remove-version-constraints
2941 ;; Ignore hard coded version constraints for the tests.
2942 (delete-file "Gemfile.lock")
2944 (add-before 'check 'set-HOME
2946 ;; Many tests invoke Bundler, and fails when Bundler
2947 ;; warns that /homeless-shelter does not exist.
2948 (setenv "HOME" "/tmp")
2951 (list ruby-activerecord ruby-bump ruby-rspec ruby-sqlite3 ruby-wwtd))
2953 (list ruby-parallel-tests))
2954 (synopsis "Run every test in a fork")
2956 "This package is a wrapper around @code{parallel_tests} that runs every
2957 test in a fork to avoid pollution and get clean output per test.")
2958 (license license:expat)))
2960 (define-public ruby-formatador
2962 (name "ruby-formatador")
2966 (uri (rubygems-uri "formatador" version))
2969 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
2970 (build-system ruby-build-system)
2971 ;; Circular dependency: Tests require ruby-shindo, which requires
2972 ;; ruby-formatador at runtime.
2973 (arguments `(#:tests? #f))
2974 (synopsis "Ruby library to format text on stdout")
2975 (description "Formatador is a Ruby library to format text printed to the
2976 standard output stream.")
2977 (home-page "https://github.com/geemus/formatador")
2978 (license license:expat)))
2980 (define-public ruby-fuubar
2982 (name "ruby-fuubar")
2986 ;; Fetch from the git repository, as the gem package doesn't include
2990 (url "https://github.com/thekompanee/fuubar")
2991 (commit (string-append "releases/v" version))))
2992 (file-name (git-file-name name version))
2995 "0jm1x2xp13csbnadixaikj7mlkp5yk4byx51npm56zi13izp7259"))))
2996 (build-system ruby-build-system)
2998 '(;; TODO: Some tests fail, unsure why.
2999 ;; 21 examples, 7 failures
3002 (modify-phases %standard-phases
3003 (add-before 'build 'delete-certificate
3005 ;; Remove 's.cert_chain' as we do not build with a private key
3006 (substitute* "fuubar.gemspec"
3007 ((".*cert_chain.*") "")
3008 ((".*signing_key.*") ""))
3011 (lambda* (#:key tests? #:allow-other-keys)
3018 (list ruby-rspec-core ruby-progressbar))
3019 (synopsis "Fuubar is an RSpec formatter that uses a progress bar")
3021 "Fuubar is an RSpec formatter that uses a progress bar instead of a
3022 string of letters and dots as feedback. It also stops on the first test
3024 (home-page "https://github.com/thekompanee/fuubar")
3025 (license license:expat)))
3027 (define-public ruby-haml
3034 (uri (rubygems-uri "haml" version))
3037 "1q0a9fvqh8kn6wm97fcks6qzbjd400bv8bx748w8v87m7p4klhac"))))
3038 (build-system ruby-build-system)
3040 '(#:tests? #f)) ; No included tests
3042 (list ruby-tilt ruby-temple))
3043 (synopsis "Haml is a Ruby library to generate HTML documents")
3045 "@acronym{Haml, HTML Abstraction Markup Language} is a layer on top of
3046 HTML or XML that is designed to express the structure of documents using
3047 indentation rather than closing tags. It was originally envisioned as a
3048 plugin for Ruby on Rails, but it can function as a stand-alone templating
3050 (home-page "https://haml.info/")
3051 (license license:expat)))
3053 (define-public ruby-hamster
3055 (name "ruby-hamster")
3060 (uri (rubygems-uri "hamster" version))
3063 "1n1lsh96vnyc1pnzyd30f9prcsclmvmkdb3nm5aahnyizyiy6lar"))))
3064 (build-system ruby-build-system)
3067 (modify-phases %standard-phases
3068 (add-after 'unpack 'remove-unnecessary-dependencies
3070 ;; pry is a debugging tool, and is unnecessary when running the
3072 (substitute* "spec/lib/hamster/vector/insert_spec.rb"
3073 (("require 'pry'") ""))
3074 (substitute* "spec/spec_helper.rb"
3075 (("require \"pry\"") "")
3076 ;; CodeClimate is an online service, and is unnecessary for
3077 ;; running the tests
3078 (("require \"codeclimate-test-reporter\"") "")
3079 (("CodeClimate.*\n") ""))
3081 ;; No Rakefile is included, so run rspec directly.
3083 (lambda* (#:key tests? #:allow-other-keys)
3088 (list ruby-concurrent))
3091 (synopsis "Efficient, immutable, thread-safe collection classes for Ruby")
3093 "Hamster provides 6 persistent data structures: @code{Hash}, @code{Vector},
3094 @code{Set}, @code{SortedSet}, @code{List}, and @code{Deque} (which works as an
3095 immutable queue or stack).")
3096 (home-page "https://github.com/hamstergem/hamster")
3097 (license license:expat)))
3099 (define-public ruby-hashdiff
3101 (name "ruby-hashdiff")
3106 (uri (rubygems-uri "hashdiff" version))
3109 "1nynpl0xbj0nphqx1qlmyggq58ms1phf5i03hk64wcc0a17x1m1c"))))
3110 (build-system ruby-build-system)
3113 (modify-phases %standard-phases
3114 ;; Run tests directly via rspec to avoid depending on rubocop.
3116 (lambda* (#:key tests? #:allow-other-keys)
3121 (list bundler ruby-rspec-2))
3122 (synopsis "HashDiff computes the smallest difference between two hashes")
3124 "HashDiff is a Ruby library to compute the smallest difference between
3126 (home-page "https://github.com/liufengyun/hashdiff")
3127 (license license:expat)))
3129 (define-public ruby-hydra-minimal
3131 (let ((commit "5abfa378743756ae4d9306cc134bcc482f5c9525")
3134 (name "ruby-hydra-minimal")
3135 (version (git-version "0.0" revision commit))
3136 (home-page "https://github.com/hyphenation/hydra")
3139 (uri (git-reference (url home-page) (commit commit)))
3140 (file-name (git-file-name name version))
3141 ;; byebug is a non-essential debugging utility that brings in
3142 ;; many dependencies.
3143 (patches (search-patches "ruby-hydra-minimal-no-byebug.patch"))
3146 "1cik398l2765y3d9sdhjzki3303hkry58ac6jlkiy7iy62nm529f"))))
3147 (build-system ruby-build-system)
3149 ;; Avoid rspec dependency.
3151 (synopsis "Ruby hyphenation patterns")
3153 "ruby-hydra-minimal is a Ruby library for working with hyphenation patterns.
3154 It is a low-dependency variant of ruby-hydra.")
3155 (license license:expat))))
3157 (define-public ruby-hydra
3159 (inherit ruby-hydra-minimal)
3162 '(#:phases (modify-phases %standard-phases
3163 (add-after 'unpack 'make-files-writable
3165 (for-each make-file-writable (find-files "."))
3169 (invoke "rspec"))))))
3175 "ruby-hydra is a Ruby library for working with hyphenation patterns.")))
3177 (define-public ruby-shindo
3179 (name "ruby-shindo")
3183 (uri (rubygems-uri "shindo" version))
3186 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
3187 (build-system ruby-build-system)
3189 `(#:test-target "shindo_tests"
3191 (modify-phases %standard-phases
3192 (add-after 'unpack 'fix-tests
3194 (substitute* "tests/tests_helper.rb"
3196 (substitute* "Rakefile"
3197 (("system \"shindo") "system \"./bin/shindo")
3198 ;; This test doesn't work, so we disable it.
3199 (("fail \"The build_error test should fail") "#")
3200 ((" -rubygems") ""))
3203 (list ruby-formatador))
3204 (synopsis "Simple depth first Ruby testing")
3205 (description "Shindo is a simple depth first testing library for Ruby.")
3206 (home-page "https://github.com/geemus/shindo")
3207 (license license:expat)))
3209 (define-public ruby-rubygems-tasks
3211 (name "ruby-rubygems-tasks")
3215 (uri (rubygems-uri "rubygems-tasks" version))
3218 "1x3sz3n2dlknd3v7w1mrq6f0ag6pwzhjvg7z29p75w3p42ma1gbx"))))
3219 (build-system ruby-build-system)
3220 ;; Tests need Internet access.
3221 (arguments `(#:tests? #f))
3223 (list ruby-rspec ruby-yard))
3224 (synopsis "Rake tasks for managing and releasing Ruby Gems")
3225 (description "Rubygems-task provides Rake tasks for managing and releasing
3227 (home-page "https://github.com/postmodern/rubygems-tasks")
3228 (license license:expat)))
3230 (define-public ruby-rubyzip
3232 (name "ruby-rubyzip")
3237 (uri (rubygems-uri "rubyzip" version))
3240 "06js4gznzgh8ac2ldvmjcmg9v1vg9llm357yckkpylaj6z456zqz"))))
3241 (build-system ruby-build-system)
3244 (modify-phases %standard-phases
3245 (add-before 'check 'patch-tests
3246 (lambda* (#:key inputs #:allow-other-keys)
3247 (substitute* "test/gentestfiles.rb"
3250 (assoc-ref inputs "zip") "/bin/zip")))
3251 (substitute* "test/input_stream_test.rb"
3252 (("/usr/bin/env ruby") (which "ruby")))
3255 (list bundler ruby-simplecov zip unzip))
3256 (synopsis "Ruby module is for reading and writing zip files")
3258 "The rubyzip module provides ways to read from and create zip files.")
3259 (home-page "https://github.com/rubyzip/rubyzip")
3260 (license license:bsd-2)))
3262 (define-public ruby-simplecov-html
3264 (name "ruby-simplecov-html")
3268 (uri (rubygems-uri "simplecov-html" version))
3271 "1lihraa4rgxk8wbfl77fy9sf0ypk31iivly8vl3w04srd7i0clzn"))))
3272 (build-system ruby-build-system)
3273 (arguments `(#:tests? #f)) ; there are no tests
3276 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
3277 (description "This package provides the default HTML formatter for
3278 the SimpleCov code coverage tool for Ruby version 1.9 and above.")
3279 (home-page "https://github.com/colszowka/simplecov-html")
3280 (license license:expat)))
3282 (define-public ruby-simplecov
3284 (name "ruby-simplecov")
3288 (uri (rubygems-uri "simplecov" version))
3291 "1135k46nik05sdab30yxb8264lqiz01c8v000g16cl9pjc4mxrdw"))))
3292 (build-system ruby-build-system)
3293 ;; Simplecov depends on rubocop for code style checking at build time.
3294 ;; Rubocop needs simplecov at build time.
3295 (arguments `(#:tests? #f))
3297 (list ruby-json ruby-docile ruby-simplecov-html))
3300 (synopsis "Code coverage framework for Ruby")
3301 (description "SimpleCov is a code coverage framework for Ruby with a
3302 powerful configuration library and automatic merging of coverage across test
3304 (home-page "https://github.com/colszowka/simplecov")
3305 (license license:expat)))
3307 (define-public ruby-useragent
3309 (name "ruby-useragent")
3313 (uri (rubygems-uri "useragent" version))
3316 "1fv5kvq494swy0p17h9qya9r50w15xsi9zmvhzb8gh55kq6ki50p"))))
3317 (build-system ruby-build-system)
3319 '(#:tests? #f)) ; no test suite
3320 (synopsis "HTTP user agent parser for Ruby")
3321 (description "UserAgent is a Ruby library that parses and compares HTTP
3323 (home-page "https://github.com/gshutler/useragent")
3324 (license license:expat)))
3326 (define-public ruby-backports
3328 (name "ruby-backports")
3333 (uri (rubygems-uri "backports" version))
3336 "1hshjxww2h7s0dk57njrygq4zpp0nlqrjfya7zwm27iq3rhc3y8g"))))
3337 (build-system ruby-build-system)
3339 '(;; TODO: This should be default, but there is one test failure
3340 #:test-target "all_spec"))
3342 (list ruby-mspec ruby-activesupport))
3343 (synopsis "Backports of the features in newer Ruby versions")
3345 "Backports enables more compatibility across Ruby versions by providing
3346 backports of some features.")
3347 (home-page "https://github.com/marcandre/backports")
3348 (license license:expat)))
3350 (define-public ruby-bacon
3356 (uri (rubygems-uri "bacon" version))
3359 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
3360 (build-system ruby-build-system)
3361 (synopsis "Small RSpec clone")
3362 (description "Bacon is a small RSpec clone providing all essential
3364 (home-page "https://github.com/chneukirchen/bacon")
3365 (license license:expat)))
3367 (define-public ruby-bacon-bits
3369 (name "ruby-bacon-bits")
3374 (uri (rubygems-uri "bacon-bits" version))
3377 "1ghpj8ja94lhi8rgi872hqk4fd2amz2k7g9znd64z5dj7v6l0dmx"))))
3378 (build-system ruby-build-system)
3382 (propagated-inputs (list ruby-bacon))
3383 (synopsis "Extensions to Bacon, for disabling tests, before and after
3386 "This extends the bacon testing framework with useful extensions to
3387 disable tests, have before and after blocks that run once and more.")
3388 (home-page "https://github.com/cldwalker/bacon-bits")
3389 (license license:expat)))
3391 (define-public ruby-bacon-colored-output
3393 (name "ruby-bacon-colored-output")
3398 (uri (rubygems-uri "bacon-colored_output" version))
3401 "1znyh3vkfdlmf19p3k4zip88ibym41dn5g4p4n5hmks2iznb7qpx"))))
3402 (build-system ruby-build-system)
3404 '(;; No included tests
3408 (synopsis "Colored output for Bacon test framework")
3410 "This package adds color through ANSI escape codes to Bacon test
3412 (home-page "https://github.com/whitequark/bacon-colored_output")
3413 (license license:expat)))
3415 (define-public ruby-connection-pool
3417 (name "ruby-connection-pool")
3421 (uri (rubygems-uri "connection_pool" version))
3424 "0lflx29mlznf1hn0nihkgllzbj8xp5qasn8j7h838465pi399k68"))))
3425 (build-system ruby-build-system)
3428 (synopsis "Generic connection pool for Ruby")
3429 (description "Connection_pool provides a generic connection pooling
3430 interface for Ruby programs.")
3431 (home-page "https://github.com/mperham/connection_pool")
3432 (license license:expat)))
3434 (define-public ruby-fast-gettext
3436 (name "ruby-fast-gettext")
3438 (home-page "https://github.com/grosser/fast_gettext")
3441 (uri (git-reference (url home-page)
3442 (commit (string-append "v" version))))
3443 (file-name (git-file-name name version))
3446 "1dg14apq5sfjshhcq0idphhs7aq9ikzswhqmn689p1h76mxqr1v6"))))
3447 (build-system ruby-build-system)
3449 '(#:test-target "spec"
3450 #:phases (modify-phases %standard-phases
3451 (add-before 'check 'remove-version-constraints
3453 (delete-file "Gemfile.lock")
3455 (add-before 'check 'remove-activerecord-test
3457 ;; FIXME: This test fails because ActiveRecord depends on
3458 ;; a different version of ruby-sqlite than the currently
3461 "spec/fast_gettext/translation_repository/db_spec.rb")
3463 (add-before 'check 'disable-i18n-test
3465 ;; XXX: This test checks i18n intricasies with Rails 3 and
3466 ;; automatically disables itself for Rails 4.0, but does
3467 ;; not know about newer versions as it has not been updated
3468 ;; since 2014. Disable for later versions of Rails too.
3469 (substitute* "spec/fast_gettext/vendor/string_spec.rb"
3470 (((string-append "ActiveRecord::VERSION::MAJOR == 4 and "
3471 "ActiveRecord::VERSION::MINOR == 0"))
3472 "ActiveRecord::VERSION::MAJOR >= 4"))
3479 ruby-forking-test-runner
3486 (synopsis "Fast implementation of @code{GetText}")
3488 "This package provides an alternative implementation of the Ruby
3489 @code{GetText} library that is approximately 12x faster yet thread safe.")
3490 ;; Some parts are covered by the Ruby license, see file headers.
3491 (license (list license:expat license:ruby))))
3493 (define-public ruby-net-http-persistent
3495 (name "ruby-net-http-persistent")
3499 (uri (rubygems-uri "net-http-persistent" version))
3502 "156rv95bgxfz6qw5y1r7c7bswr77918hygl8dyl14qzbqc5vyp18"))))
3503 (build-system ruby-build-system)
3505 (list ruby-connection-pool ruby-hoe))
3506 (synopsis "Persistent HTTP connection manager")
3507 (description "Net::HTTP::Persistent manages persistent HTTP connections
3508 using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
3509 (home-page "https://github.com/drbrain/net-http-persistent")
3510 (license license:expat)))
3512 (define-public ruby-power-assert
3514 (name "ruby-power-assert")
3518 (uri (rubygems-uri "power_assert" version))
3521 "1dii0wkfa0jm8sk9b20zl1z4980dmrjh0zqnii058485pp3ws10s"))))
3522 (build-system ruby-build-system)
3524 '(#:tests? #f)) ; No included tests
3527 (synopsis "Assert library with descriptive assertion messages")
3528 (description "Power-assert is an assertion library providing descriptive
3529 assertion messages for tests.")
3530 (home-page "https://github.com/k-tsj/power_assert")
3531 (license (list license:bsd-2 license:ruby))))
3533 (define-public ruby-powerpack
3535 (name "ruby-powerpack")
3540 (uri (rubygems-uri "powerpack" version))
3543 "1r51d67wd467rpdfl6x43y84vwm8f5ql9l9m85ak1s2sp3nc5hyv"))))
3544 (build-system ruby-build-system)
3546 '(#:test-target "spec"))
3548 (list bundler ruby-rspec ruby-yard))
3549 (synopsis "Useful extensions to core Ruby classes")
3551 "This package provides a few useful extensions to core Ruby classes,
3552 including @code{Array}, @code{Enumerable}, @code{Hash}, @code{Numeric}, and
3554 (home-page "https://github.com/bbatsov/powerpack")
3555 (license license:expat)))
3557 (define-public ruby-locale
3559 (name "ruby-locale")
3563 (uri (rubygems-uri "locale" version))
3566 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
3567 (build-system ruby-build-system)
3568 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3569 ;; which needs ruby-gettext, which needs ruby-locale. To break the
3570 ;; dependency cycle we disable tests.
3571 (arguments `(#:tests? #f))
3573 (list bundler ruby-yard))
3574 (synopsis "Ruby library providing basic localization APIs")
3576 "Ruby-Locale is the pure ruby library which provides basic APIs for
3578 (home-page "https://github.com/ruby-gettext/locale")
3579 (license (list license:lgpl3+ license:ruby))))
3581 (define-public ruby-temple
3583 (name "ruby-temple")
3588 (uri (rubygems-uri "temple" version))
3591 "060zzj7c2kicdfk6cpnn40n9yjnhfrr13d0rsbdhdij68chp2861"))))
3592 (build-system ruby-build-system)
3594 (list ruby-tilt ruby-bacon ruby-erubis))
3595 (synopsis "Template compilation framework in Ruby")
3597 "Temple is an abstraction and framework for compiling templates to pure
3599 (home-page "https://github.com/judofyr/temple")
3600 (license license:expat)))
3602 (define-public ruby-text
3608 (uri (rubygems-uri "text" version))
3611 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
3612 (build-system ruby-build-system)
3613 (synopsis "Collection of text algorithms for Ruby")
3615 "This package provides a collection of text algorithms: Levenshtein,
3616 Soundex, Metaphone, Double Metaphone, Porter Stemming.")
3617 (home-page "https://github.com/threedaymonk/text")
3618 (license license:expat)))
3620 (define-public ruby-gettext
3622 (name "ruby-gettext")
3626 (uri (rubygems-uri "gettext" version))
3629 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
3630 (build-system ruby-build-system)
3631 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
3632 ;; which needs ruby-gettext. To break the dependency cycle we disable
3634 (arguments `(#:tests? #f))
3636 (list ruby-locale ruby-text))
3638 (list bundler ruby-yard))
3639 (synopsis "GNU gettext-like program for Ruby")
3641 "Gettext is a GNU gettext-like program for Ruby. The catalog
3642 file (po-file) used is the same as that used by GNU gettext, allowing you to
3643 use GNU gettext tools for maintenance.")
3644 (home-page "https://ruby-gettext.github.com/")
3645 (license (list license:lgpl3+ license:ruby))))
3647 (define-public ruby-packnga
3649 (name "ruby-packnga")
3653 (uri (rubygems-uri "packnga" version))
3656 "1vv2j0i43s4xid2km5hgrrxqlqpwgq8nlm8kaxfg2531c1vwfsd4"))))
3657 (build-system ruby-build-system)
3658 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
3659 ;; To break the dependency cycle we disable tests.
3660 (arguments `(#:tests? #f))
3662 (list ruby-gettext ruby-yard))
3665 (synopsis "Utility library to package internationalized libraries")
3667 "Packnga is a library to translate to many languages using YARD.")
3668 (home-page "http://ranguba.org/packnga/")
3669 (license license:lgpl2.0+)))
3671 (define-public ruby-test-construct
3673 (name "ruby-test-construct")
3678 (uri (rubygems-uri "test_construct" version))
3681 "1a2ym3l068d0pxzzr95kvqx87zpdsarxslz9ygd4qfm9frrz0kgj"))))
3682 (build-system ruby-build-system)
3684 (list bundler ruby-mocha ruby-rspec))
3685 (synopsis "Creates temporary files and directories for testing")
3687 "TestConstruct is a @acronym{DSL, Domain Specific Language} for creating
3688 temporary files and directories during tests.")
3689 (home-page "https://github.com/bhb/test_construct")
3690 (license license:expat)))
3692 (define-public ruby-test-unit
3694 (name "ruby-test-unit")
3698 (uri (rubygems-uri "test-unit" version))
3701 "15isy7vhppbfd0032klirj9gxp65ygkzjdwrmm28xpirlcsk6qpd"))))
3702 (build-system ruby-build-system)
3704 (list ruby-power-assert))
3706 (list bundler ruby-packnga ruby-yard))
3707 (synopsis "Unit testing framework for Ruby")
3708 (description "@code{Test::Unit} is unit testing framework for Ruby, based
3709 on xUnit principles. These were originally designed by Kent Beck, creator of
3710 extreme programming software development methodology, for Smalltalk's SUnit.
3711 It allows writing tests, checking results and automated testing in Ruby.")
3712 (home-page "https://test-unit.github.io/")
3713 (license (list license:psfl license:ruby))))
3715 (define-public ruby-markaby
3717 (name "ruby-markaby")
3722 (uri (rubygems-uri "markaby" version))
3725 "1j4jc31ycydbkh5h3q6zwidzpavg3g5mbb5lqyaczd3jrq78rd7i"))))
3726 (build-system ruby-build-system)
3729 (modify-phases %standard-phases
3730 ;; Run rspec manually without using the Rakefile, as the versions of
3731 ;; Rake and RSpec 2 are incompatible:
3733 ;; NoMethodError: undefined method `last_comment'
3735 (lambda* (#:key tests? #:allow-other-keys)
3740 (list ruby-builder))
3742 (list bundler ruby-rspec-2))
3743 (synopsis "Write HTML pages in pure Ruby")
3745 "Markaby allows writing HTML packages in pure Ruby. This is similar to
3746 the functionality provided by @acronym{ERB, Embedded Ruby}, but without the
3747 mixture of HTML and additional ERB syntax.")
3748 (home-page "https://markaby.github.io/")
3749 (license license:expat)))
3751 (define-public ruby-maruku
3753 (name "ruby-maruku")
3758 (uri (rubygems-uri "maruku" version))
3761 "1r7bxpgnx2hp3g12bjrmdrpv663dfqxsdp0af69kjhxmaxpia56x"))))
3762 (build-system ruby-build-system)
3764 '(;; TODO: 3 tests seem to fail due to HTML encoding issues
3767 (modify-phases %standard-phases
3769 (lambda* (#:key tests? #:allow-other-keys)
3774 (list ruby-rspec ruby-simplecov ruby-nokogiri-diff))
3775 (synopsis "Markdown interpreter in Ruby")
3777 "Maruku is a Markdown interpreter in Ruby. It can export Markdown to
3778 HTML, and PDF through LaTeX.")
3779 (home-page "https://github.com/bhollis/maruku")
3780 (license license:expat)))
3782 (define-public ruby-metaclass
3784 (name "ruby-metaclass")
3788 (uri (rubygems-uri "metaclass" version))
3791 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
3792 (build-system ruby-build-system)
3795 (modify-phases %standard-phases
3796 (add-after 'unpack 'add-test-unit-to-search-path
3797 (lambda* (#:key inputs #:allow-other-keys)
3798 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
3799 (substitute* "Rakefile"
3800 (("t\\.libs << \"test\"" line)
3801 (string-append line "; t.libs << \""
3802 test-unit "/lib/ruby/vendor_ruby"
3804 ,(package-version ruby-test-unit)
3808 (list bundler ruby-test-unit))
3809 (synopsis "Ruby library adding metaclass method to all objects")
3811 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
3813 (home-page "https://github.com/floehopper/metaclass")
3814 (license license:expat)))
3816 (define-public ruby-mkmf-lite
3818 (name "ruby-mkmf-lite")
3822 (uri (rubygems-uri "mkmf-lite" version))
3825 "0br9k6zijj1zc25n8p7f2j1mwl58nfgdknf3q13h9k156jvrir06"))))
3826 (build-system ruby-build-system)
3829 (synopsis "Lightweight alternative to @code{mkmf}")
3831 "@code{mkmf-lite} is a light version of Ruby's @code{mkmf.rb} designed
3832 for use as a library. It does not create packages, builds, or log files of
3833 any kind. Instead, it provides mixin methods that you can use in FFI or tests
3834 to check for the presence of header files, constants, and so on.")
3835 (home-page "https://github.com/djberg96/mkmf-lite")
3836 (license license:asl2.0)))
3838 (define-public ruby-mspec
3845 (uri (rubygems-uri "mspec" version))
3848 "0wmyh2n40m4srwdx9z6h6g6p46k02pzyhcsja3hqcw5h5b0hfmhd"))))
3849 (build-system ruby-build-system)
3851 '(;; TODO: 3 test failures
3852 ;; ./spec/mocks/mock_spec.rb:82
3853 ;; ./spec/utils/name_map_spec.rb:151
3854 ;; ./spec/utils/name_map_spec.rb:155
3857 (modify-phases %standard-phases
3858 (add-after 'extract-gemspec 'change-dependency-constraints
3860 (substitute* "mspec.gemspec"
3861 (("rake.*") "rake>)\n")
3862 (("rspec.*") "rspec>)\n"))
3865 (lambda* (#:key tests? #:allow-other-keys)
3867 (invoke "rspec" "spec"))
3870 (list bundler ruby-rake ruby-rspec))
3871 (synopsis "MSpec is a specialized framework for RubySpec")
3873 "MSpec is a specialized framework that is syntax-compatible with RSpec 2
3874 for basic features. MSpec contains additional features that assist in writing
3875 specs for Ruby implementations in ruby/spec.")
3876 (home-page "http://rubyspec.org")
3877 (license license:expat)))
3879 (define-public ruby-mysql2
3881 (name "ruby-mysql2")
3887 (url "https://github.com/brianmario/mysql2")
3889 (file-name (git-file-name name version))
3892 "11lvfgc2rmvkm52jp0nbi6pvhk06klznghr7llldfw8basl9n5wv"))))
3893 (build-system ruby-build-system)
3895 '(;; TODO: Tests require a running MySQL/MariaDB service
3898 (modify-phases %standard-phases
3899 (replace 'replace-git-ls-files
3901 (substitute* "mysql2.gemspec"
3902 (("git ls-files .*`") "find . -type f |sort`"))
3904 (add-before 'install 'set-MAKEFLAGS
3905 (lambda* (#:key outputs #:allow-other-keys)
3909 "prefix=" (assoc-ref outputs "out")))
3911 ;; Move the 'check phase to after 'install, as then you can test
3912 ;; using the installed mysql2 gem in the store.
3914 (add-after 'install 'check
3915 (lambda* (#:key outputs tests? #:allow-other-keys)
3920 (assoc-ref outputs "out") "/lib/ruby/vendor_ruby"))
3925 `(("mariadb-dev" ,mariadb "dev")
3928 (list ruby-rspec ruby-rake-compiler))
3929 (synopsis "MySQL library for Ruby, binding to libmysql")
3931 "This package provides a simple, fast MySQL library for Ruby, binding to
3933 (home-page "https://github.com/brianmario/mysql2")
3934 (license license:expat)))
3936 (define-public ruby-blankslate
3938 (name "ruby-blankslate")
3942 (uri (rubygems-uri "blankslate" version))
3945 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
3946 (build-system ruby-build-system)
3949 (modify-phases %standard-phases
3951 (lambda _ (invoke "rspec" "spec/"))))))
3953 (list bundler ruby-rspec))
3954 (synopsis "Abstract base class with no predefined methods")
3956 "BlankSlate provides an abstract base class with no predefined
3957 methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
3958 as a base class when writing classes that depend upon
3959 @code{method_missing} (e.g. dynamic proxies).")
3960 (home-page "https://github.com/masover/blankslate")
3961 (license license:expat)))
3963 (define-public ruby-bond
3970 (uri (rubygems-uri "bond" version))
3973 "1r19ifc4skyl2gxnifrxa5jvbbay9fb2in79ppgv02b6n4bhsw90"))))
3974 (build-system ruby-build-system)
3976 ;; The test suite fails (see:
3977 ;; https://github.com/cldwalker/bond/issues/46).
3980 (list ruby-bacon ruby-bacon-bits ruby-mocha-on-bacon))
3981 (synopsis "Bond can provide custom autocompletion for arguments, methods
3984 "Bond can autocomplete argument(s) to methods, uniquely completing per
3985 module, per method and per argument. Bond provides a configuration system and
3986 a DSL for creating custom completions and completion rules. Bond can also
3987 load completions that ship with gems. Bond is able to offer more than irb's
3988 completion since it uses the full line of input when completing as opposed to
3989 irb's last-word approach.")
3990 (home-page "http://tagaholic.me/bond/")
3991 (license license:expat)))
3993 (define-public ruby-idn-ruby
3995 (name "ruby-idn-ruby")
4000 (uri (rubygems-uri "idn-ruby" version))
4003 "07vblcyk3g72sbq12xz7xj28snpxnh3sbcnxy8bglqbfqqhvmawr"))))
4004 (build-system ruby-build-system)
4007 (modify-phases %standard-phases
4009 (add-after 'install 'check
4010 (lambda* (#:key tests? outputs #:allow-other-keys)
4012 (let* ((gem-file (cadr (find-files "." "\\.gem")))
4013 (name-and-version (basename gem-file ".gem")))
4017 (assoc-ref outputs "out")
4018 "/lib/ruby/vendor_ruby/gems/"
4021 (find-files "./test" ".*\\.rb"))))
4025 (synopsis "Ruby Bindings for the GNU LibIDN library")
4027 "Ruby Bindings for the GNU LibIDN library, an implementation of the
4028 Stringprep, Punycode and IDNA specifications. These are used to encode and
4029 decode internationalized domain + names according to the IDNA2003
4032 Included are the most important parts of the Stringprep, Punycode and IDNA
4033 APIs like performing Stringprep processings, encoding to and decoding from
4034 Punycode strings and converting entire domain names to and from the ACE
4036 (home-page "https://github.com/deepfryed/idn-ruby")
4037 (license license:asl2.0)))
4039 (define-public ruby-instantiator
4041 (name "ruby-instantiator")
4045 (uri (rubygems-uri "instantiator" version))
4048 "0w07w3gkyqr7m0vz5h13vm8b411660qywjm2xxxgdjv4wb3fazbr"))))
4049 (build-system ruby-build-system)
4052 (modify-phases %standard-phases
4053 (add-after 'unpack 'add-test-unit-to-search-path
4054 (lambda* (#:key inputs #:allow-other-keys)
4055 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
4056 (substitute* "Rakefile"
4057 (("t\\.libs << \"test\"" line)
4058 (string-append line "; t.libs << \""
4059 test-unit "/lib/ruby/vendor_ruby"
4061 ,(package-version ruby-test-unit)
4065 (list ruby-blankslate))
4067 (list bundler ruby-test-unit))
4068 (synopsis "Instantiate an arbitrary Ruby class")
4070 "Instantiator lets you instantiate an arbitrary Ruby class without
4071 knowing anything about the constructor.")
4072 (home-page "https://github.com/floehopper/instantiator")
4073 (license license:expat)))
4075 (define-public ruby-introspection
4077 (name "ruby-introspection")
4081 (uri (rubygems-uri "introspection" version))
4084 "1y2nbijkc0zlfmn9ss6588ilarq2kbn2i7w7pwwsli66dj84zgca"))))
4085 (build-system ruby-build-system)
4088 (modify-phases %standard-phases
4089 (add-after 'unpack 'add-test-unit-to-search-path
4090 (lambda* (#:key inputs #:allow-other-keys)
4091 (let* ((test-unit (assoc-ref inputs "ruby-test-unit")))
4092 (substitute* "Rakefile"
4093 (("t\\.libs << \"test\"" line)
4094 (string-append line "; t.libs << \""
4095 test-unit "/lib/ruby/vendor_ruby"
4097 ,(package-version ruby-test-unit)
4101 (list ruby-instantiator ruby-metaclass))
4103 (list bundler ruby-blankslate ruby-test-unit))
4104 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
4106 "Introspection provides tools to inspect the hierarchy of method
4107 definitions on a Ruby object.")
4108 (home-page "https://github.com/floehopper/introspection")
4109 (license license:expat)))
4111 (define-public ruby-redcarpet
4113 (name "ruby-redcarpet")
4117 (uri (rubygems-uri "redcarpet" version))
4120 "0skcyx1h8b5ms0rp2zm3ql6g322b8c1adnkwkqyv7z3kypb4bm7k"))))
4121 (build-system ruby-build-system)
4124 (modify-phases %standard-phases
4125 ;; The gem archive does not include the conformance tests.
4126 (add-after 'unpack 'disable-conformance-tests
4128 (substitute* "Rakefile"
4129 (("task :test => %w\\[test:unit test:conformance\\]")
4130 "task :test => %w[test:unit]"))
4133 (list bundler ruby-test-unit ruby-rake-compiler))
4134 (synopsis "Extensible Markdown to (X)HTML converter")
4136 "Redcarpet is an extensible Ruby library for Markdown processing and
4137 conversion to (X)HTML.")
4138 (home-page "https://github.com/vmg/redcarpet")
4139 (license license:expat)))
4141 (define-public ruby-rerun
4148 (uri (rubygems-uri "rerun" version))
4151 "1cskvxk8z8vmfail8na7hj91hs0qnvds9nydj04zi3dbddgnbmvz"))))
4152 (build-system ruby-build-system)
4154 '(#:tests? #f)) ; No included tests
4157 (synopsis "Run a process, and restart when some monitored files change")
4159 "Rerun is a tool to launch programs, then monitor the file system, and
4160 restart the program when any of the monitored files change. It's written in
4161 Ruby, but can be used for all programs.")
4162 (home-page "https://github.com/alexch/rerun/")
4163 (license license:expat)))
4165 (define-public ruby-maxitest
4167 (name "ruby-maxitest")
4169 (home-page "https://github.com/grosser/maxitest")
4171 ;; Pull from git because the gem does not contain tests.
4175 (commit (string-append "v" version))))
4176 (file-name (git-file-name name version))
4179 "07b3j0bv3dx5j42jlvpvl07aaxplyi6wq688y3jl8y528ww2hjz8"))))
4180 (build-system ruby-build-system)
4182 '(#:test-target "default"
4183 #:phases (modify-phases %standard-phases
4184 (replace 'replace-git-ls-files
4186 (substitute* "maxitest.gemspec"
4187 (("`git ls-files lib/ bin/ MIT-LICENSE Readme.md`")
4188 "`find lib/ bin/ MIT-LICENSE Readme.md -type f | sort`"))
4190 (add-before 'check 'remove-version-constraints
4192 ;; Don't use specific versions of dependencies, instead
4193 ;; take whatever is available in Guix.
4194 (delete-file "Gemfile.lock")
4196 (add-before 'check 'add-mtest-on-PATH
4198 ;; Tests use 'mtest' which is not automatically added on
4200 (setenv "PATH" (string-append (getcwd) "/bin:"
4205 ("ruby-bump" ,ruby-bump)
4206 ("ruby-byebug" ,ruby-byebug)
4207 ("ruby-rspec" ,ruby-rspec)
4208 ("ruby-wwtd" ,ruby-wwtd)))
4210 (list ruby-minitest))
4211 (synopsis "Minitest with extra features")
4213 "Maxitest is a wrapper around Minitest with extra functionality such
4214 as timeouts, an @command{mtest} executable that can run tests by line
4215 number, support for interrupted tests, better backtraces, and more.")
4216 (license license:expat)))
4218 (define-public ruby-mocha
4224 (uri (rubygems-uri "mocha" version))
4227 "15s53ggsykk69kxqvs4416s8yxdhz6caggva55n8sjgy4ixzwp10"))))
4228 (build-system ruby-build-system)
4231 (modify-phases %standard-phases
4232 (add-before 'check 'remove-rubocop-dependency
4234 ;; Disable dependency on Rubocop, which is just a linter,
4235 ;; and would introduce a circular dependency.
4236 (substitute* "mocha.gemspec"
4241 (list ruby-introspection))
4242 (synopsis "Mocking and stubbing library for Ruby")
4244 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
4245 allows mocking and stubbing of methods on real (non-mock) classes.")
4246 (home-page "https://mocha.jamesmead.org/")
4247 ;; Mocha can be used with either license at the users choice.
4248 (license (list license:expat license:ruby))))
4250 (define-public ruby-mocha-on-bacon
4252 (name "ruby-mocha-on-bacon")
4257 (uri (rubygems-uri "mocha-on-bacon" version))
4260 "1h49b33rq889hn8x3wp9byczl91va16jh1w4d2wyy4yj23icdrcp"))))
4261 (build-system ruby-build-system)
4263 ;; rubygems.org release missing tests
4265 (propagated-inputs (list ruby-mocha))
4266 (synopsis "Mocha adapter for Bacon")
4268 "This package provides a Mocha adapter for Bacon, allowing you to use the
4269 Mocha stubbing and mocking library with Bacon, a small RSpec clone.")
4271 "https://github.com/alloy/mocha-on-bacon")
4272 (license license:expat)))
4274 (define-public ruby-net-ssh
4276 (name "ruby-net-ssh")
4280 (uri (rubygems-uri "net-ssh" version))
4283 "07c4v97zl1daabmri9zlbzs6yvkl56z1q14bw74d53jdj0c17nhx"))))
4284 (build-system ruby-build-system)
4286 (list bundler ruby-mocha ruby-test-unit))
4287 (synopsis "Ruby implementation of the SSH2 client protocol")
4288 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
4289 client protocol. It allows you to write programs that invoke and interact
4290 with processes on remote servers, via SSH2.")
4291 (home-page "https://github.com/net-ssh/net-ssh")
4292 (license license:expat)))
4294 (define-public ruby-net-scp
4296 (name "ruby-net-scp")
4297 ;; The 1.2.1 release would be incompatible with ruby-net-ssh >= 4.
4298 (version "1.2.2.rc2")
4303 (url "https://github.com/net-ssh/net-scp")
4304 (commit (string-append "v" version))))
4305 (file-name (git-file-name name version))
4307 (base32 "1nyn17sy71fn7zs3y6wbgcn35318c10flqgc0582409095x4h0sx"))))
4308 (build-system ruby-build-system)
4310 (list bundler ruby-test-unit ruby-mocha))
4312 (list ruby-net-ssh))
4313 (synopsis "Pure-Ruby SCP client library")
4314 (description "@code{Net::SCP} is a pure-Ruby implementation of the SCP
4316 (home-page "https://github.com/net-ssh/net-scp")
4317 (license license:expat)))
4319 (define-public ruby-minitest
4321 (name "ruby-minitest")
4325 (uri (rubygems-uri "minitest" version))
4328 "19z7wkhg59y8abginfrm2wzplz7py3va8fyngiigngqvsws6cwgl"))))
4329 (build-system ruby-build-system)
4332 (synopsis "Small test suite library for Ruby")
4333 (description "Minitest provides a complete suite of Ruby testing
4334 facilities supporting TDD, BDD, mocking, and benchmarking.")
4335 (home-page "https://github.com/seattlerb/minitest")
4336 (license license:expat)))
4338 ;; This is the last release of Minitest 4, which is used by some packages.
4339 (define-public ruby-minitest-4
4340 (package (inherit ruby-minitest)
4344 (uri (rubygems-uri "minitest" version))
4347 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
4350 (modify-phases %standard-phases
4351 (add-after 'unpack 'remove-unsupported-method
4353 (substitute* "Rakefile"
4354 (("self\\.rubyforge_name = .*") ""))
4356 (add-after 'build 'exclude-failing-tests
4358 ;; Some tests are failing on Ruby 2.4 due to the deprecation of
4360 (delete-file "test/minitest/test_minitest_spec.rb")
4363 (define-public ruby-minitest-around
4365 (name "ruby-minitest-around")
4370 (uri (rubygems-uri "minitest-around" version))
4373 "15ywnqx0719jl9c25yqfshmwcir57i5f4hr1ra9v9vay9ylcwndr"))))
4374 (build-system ruby-build-system)
4377 (modify-phases %standard-phases
4378 (add-after 'extract-gemspec 'remove-unnecessary-dependency-versions
4380 (substitute* "minitest-around.gemspec"
4381 (("%q<cucumber>.*") "%q<cucumber>, [\">= 0\"])\n"))
4384 (list ruby-minitest))
4386 (list bundler ruby-cucumber ruby-bump ruby-test-construct))
4387 (synopsis "Run code around tests in Minitest")
4389 "This library provides a way to run code around tests in Minitest,
4390 written using either the unit test or spec style.")
4391 (home-page "https://github.com/splattael/minitest-around")
4392 (license license:expat)))
4394 (define-public ruby-minitest-sprint
4396 (name "ruby-minitest-sprint")
4400 (uri (rubygems-uri "minitest-sprint" version))
4403 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
4404 (build-system ruby-build-system)
4406 (list ruby-hoe ruby-minitest))
4407 (synopsis "Fast test suite runner for minitest")
4408 (description "Minitest-sprint is a test runner for minitest that makes it
4409 easier to re-run individual failing tests.")
4410 (home-page "https://github.com/seattlerb/minitest-sprint")
4411 (license license:expat)))
4413 (define-public ruby-minitest-bacon
4415 (name "ruby-minitest-bacon")
4419 (uri (rubygems-uri "minitest-bacon" version))
4422 "0zhdwcl6bgha61qiyfvr7zs7ywaxc33wmj9xhxl8jdmpdvifvfaj"))))
4423 (build-system ruby-build-system)
4427 (list ruby-minitest))
4428 (synopsis "Bacon compatibility library for minitest")
4429 (description "Minitest-bacon extends minitest with bacon-like
4430 functionality, making it easier to migrate test suites from bacon to minitest.")
4431 (home-page "https://github.com/seattlerb/minitest-bacon")
4432 (license license:expat)))
4434 (define-public ruby-minitest-focus
4436 (name "ruby-minitest-focus")
4441 (uri (rubygems-uri "minitest-focus" version))
4444 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
4445 (build-system ruby-build-system)
4447 (list ruby-minitest))
4450 (synopsis "Allows a few specific tests to be focused on")
4452 "@code{minitest-focus} gives the ability focus on a few tests with ease
4453 without having to use command-line arguments. It introduces a @code{focus}
4454 class method for use in testing classes, specifying that the next defined test
4456 (home-page "https://github.com/seattlerb/minitest-focus")
4457 (license license:expat)))
4459 (define-public ruby-minitest-pretty-diff
4460 ;; Use git reference because gem is out of date and does not contain testing
4461 ;; script. There are no releases on GitHub.
4462 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
4464 (name "ruby-minitest-pretty-diff")
4465 (version (string-append "0.1-1." (string-take commit 8)))
4469 (url "https://github.com/adammck/minitest-pretty_diff")
4471 (file-name (string-append name "-" version "-checkout"))
4474 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
4475 (build-system ruby-build-system)
4478 (modify-phases %standard-phases
4481 (invoke "script/test"))))))
4483 (list bundler ruby-turn))
4484 (synopsis "Pretty-print hashes and arrays in MiniTest")
4486 "@code{minitest-pretty_diff} monkey-patches
4487 @code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
4488 diffing them. This makes it easier to spot differences between nested
4489 structures when tests fail.")
4490 (home-page "https://github.com/adammck/minitest-pretty_diff")
4491 (license license:expat))))
4493 (define-public ruby-minitest-moar
4495 (name "ruby-minitest-moar")
4500 (uri (rubygems-uri "minitest-moar" version))
4503 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
4504 (build-system ruby-build-system)
4507 (modify-phases %standard-phases
4508 (add-before 'check 'clean-dependencies
4510 ;; Remove all gems defined in the Gemfile because these are not
4512 (substitute* "Gemfile"
4514 ;; Remove byebug as not needed to run tests.
4515 (substitute* "test/test_helper.rb"
4516 (("require 'byebug'") ""))
4519 (list bundler ruby-minitest))
4520 (synopsis "Extra features and changes to MiniTest")
4521 (description "@code{MiniTest Moar} add some additional features and
4522 changes some default behaviours in MiniTest. For instance, Moar replaces the
4523 MiniTest @code{Object#stub} with a global @code{stub} method.")
4524 (home-page "https://github.com/dockyard/minitest-moar")
4525 (license license:expat)))
4527 (define-public ruby-minitest-bonus-assertions
4529 (name "ruby-minitest-bonus-assertions")
4534 (uri (rubygems-uri "minitest-bonus-assertions" version))
4537 "1hbq9jk904xkz868yha1bqcm6azm7kmjsll2k4pn2nrcib508h2a"))))
4538 (build-system ruby-build-system)
4540 `(#:tests? #f ; Test suite has bitrotted.
4542 (modify-phases %standard-phases
4543 (add-before 'check 'clean-dependencies
4545 ;; Remove unneeded require statement that would entail another
4547 (substitute* "test/minitest_config.rb"
4548 (("require 'minitest/bisect'") ""))
4551 (list ruby-hoe ruby-minitest-pretty-diff ruby-minitest-focus
4552 ruby-minitest-moar))
4553 (synopsis "Bonus assertions for @code{Minitest}")
4555 "Minitest bonus assertions provides extra MiniTest assertions. For
4556 instance, it provides @code{assert_true}, @code{assert_false} and
4557 @code{assert_set_equal}.")
4558 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
4559 (license license:expat)))
4561 (define-public ruby-minitest-reporters
4563 (name "ruby-minitest-reporters")
4568 (uri (rubygems-uri "minitest-reporters" version))
4571 "1a3das80rwgys5rj48i5ly144nvszyqyi748bk9bss74jblcf5ay"))))
4572 (build-system ruby-build-system)
4575 (modify-phases %standard-phases
4576 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
4577 ;; including it as an input can lead to circular dependencies.
4578 (add-after 'unpack 'remove-rubocop-from-Rakefile
4580 (substitute* "Rakefile"
4581 (("require 'rubocop/rake\\_task'") "")
4582 (("RuboCop::RakeTask\\.new\\(:rubocop\\)") "[].each"))
4584 (add-after 'extract-gemspec 'remove-rubocop-from-gemspec
4586 (substitute* "minitest-reporters.gemspec"
4587 ((".*%q<rubocop>.*") "\n"))
4590 (list ruby-ansi ruby-builder ruby-minitest ruby-progressbar))
4592 (list bundler ruby-maruku))
4593 (synopsis "Enhanced reporting for Minitest tests")
4595 "@code{minitest/reporters} provides a custom Minitest runner to improve
4596 how the test state is reported. A number of different reporters are
4597 available, including a spec reporter, progress bar reporter, a HTML
4599 (home-page "https://github.com/kern/minitest-reporters")
4600 (license license:expat)))
4602 (define-public ruby-minitest-rg
4604 (name "ruby-minitest-rg")
4609 (uri (rubygems-uri "minitest-rg" version))
4612 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
4613 (build-system ruby-build-system)
4615 ;; Some tests fail even outside Guix, so disable tests.
4616 ;; https://github.com/blowmage/minitest-rg/issues/12
4617 ;; https://github.com/blowmage/minitest-rg/pull/13
4620 (list ruby-minitest))
4621 (synopsis "Coloured output for Minitest")
4623 "@code{minitest-rg} changes the colour of the output from Minitest.")
4624 (home-page "https://blowmage.com/minitest-rg/")
4625 (license license:expat)))
4627 (define-public ruby-minitest-global-expectations
4629 (name "ruby-minitest-global-expectations")
4634 (uri (rubygems-uri "minitest-global_expectations"
4638 "1pp3k2608spj4kvqy2y16hs18an917g6vwgvphrfhjviac83090x"))))
4639 (build-system ruby-build-system)
4641 (list ruby-minitest))
4642 (synopsis "Adjust minitest behaviour for calling expectation methods")
4644 "Minitest-global_expectations allows continued use of expectation methods
4645 on all objects. Calling expectation methods on all objects was deprecated in
4646 minitest 5.12, and is planned to be removed from minitest 6.")
4647 (home-page "https://github.com/jeremyevans/minitest-global_expectations")
4648 (license license:expat)))
4650 (define-public ruby-minitest-hooks
4652 (name "ruby-minitest-hooks")
4657 (uri (rubygems-uri "minitest-hooks" version))
4660 "05z8r6sw3fz4s44fs1150ndlcmcy82vlxmhps5nncg8vk59k3gmf"))))
4661 (build-system ruby-build-system)
4663 '(#:test-target "spec"
4664 ;; Test suite is incompatible with ruby-2.7.
4665 ;; https://github.com/jeremyevans/minitest-hooks/issues/19
4668 (list ruby-sequel ruby-sqlite3))
4669 (synopsis "Hooks for the minitest framework")
4671 "Minitest-hooks adds @code{around}, @code{before_all}, @code{after_all},
4672 @code{around_all} hooks for Minitest. This allows, for instance, running each
4673 suite of specs inside a database transaction, running each spec inside its own
4674 savepoint inside that transaction. This can significantly speed up testing
4675 for specs that share expensive database setup code.")
4676 (home-page "https://github.com/jeremyevans/minitest-hooks")
4677 (license license:expat)))
4679 (define-public ruby-daemons
4681 (name "ruby-daemons")
4685 (uri (rubygems-uri "daemons" version))
4688 "15smbsg0gxb7nf0nrlnplc68y0cdy13dm6fviavpmw7c630sring"))))
4689 (build-system ruby-build-system)
4691 `(#:tests? #f)) ; no test suite
4692 (synopsis "Daemonize Ruby programs")
4693 (description "Daemons provides a way to wrap existing Ruby scripts to be
4694 run as a daemon and to be controlled by simple start/stop/restart commands.")
4695 (home-page "https://github.com/thuehlinger/daemons")
4696 (license license:expat)))
4698 (define-public ruby-data_uri
4700 (name "ruby-data_uri")
4705 (uri (rubygems-uri "data_uri" version))
4708 "0fzkxgdxrlbfl4537y3n9mjxbm28kir639gcw3x47ffchwsgdcky"))))
4709 (build-system ruby-build-system)
4710 (synopsis "URI class for parsing data URIs")
4712 "Data @acronym{URI, universal resource idenfitier}s allow resources to be
4713 embedded inside a URI. The URI::Data class provides support for parsing these
4714 URIs using the normal URI.parse method.")
4715 (home-page "https://github.com/dball/data_uri")
4716 (license license:expat)))
4718 (define-public ruby-deep-merge
4720 (name "ruby-deep-merge")
4722 (home-page "https://github.com/danielsdeleo/deep_merge")
4723 ;; The Rubygem source does not contain the gemspec required for tests.
4726 (uri (git-reference (url home-page) (commit version)))
4727 (file-name (git-file-name name version))
4730 "0c9rk23ilhc0n4489y6lda2wzphpzh6ish6fahlbpjhxn82wb931"))))
4731 (build-system ruby-build-system)
4733 (list ruby-minitest))
4734 (synopsis "Recursively merge hashes")
4736 "Deep Merge is a set of utility functions for @code{Hash}. It permits
4737 you to merge elements inside a hash together recursively.")
4738 (license license:expat)))
4740 (define-public ruby-git
4746 (uri (rubygems-uri "git" version))
4749 "1waikaggw7a1d24nw0sh8fd419gbf7awh000qhsf411valycj6q3"))))
4750 (build-system ruby-build-system)
4752 `(#:tests? #f ; no tests
4753 #:phases (modify-phases %standard-phases
4754 (add-after 'install 'patch-git-binary
4755 (lambda* (#:key inputs outputs #:allow-other-keys)
4756 ;; Make the default git binary an absolute path to the
4758 (let ((git (search-input-file inputs "/bin/git"))
4759 (config (string-append
4760 (assoc-ref outputs "out")
4761 "/lib/ruby/vendor_ruby/gems/git-"
4762 ,version "/lib/git/config.rb")))
4763 (substitute* (list config)
4765 (string-append "'" git "'")))
4769 (synopsis "Ruby wrappers for Git")
4770 (description "Ruby/Git is a Ruby library that can be used to create, read
4771 and manipulate Git repositories by wrapping system calls to the git binary.")
4772 (home-page "https://github.com/schacon/ruby-git")
4773 (license license:expat)))
4775 (define-public ruby-hocon
4779 (home-page "https://github.com/puppetlabs/ruby-hocon")
4782 (uri (git-reference (url home-page) (commit version)))
4783 (file-name (git-file-name name version))
4786 "172hh2zr0n9nnszv0qvlgwszgkrq84yahrg053m68asy79zpmbqr"))))
4787 (build-system ruby-build-system)
4789 '(#:phases (modify-phases %standard-phases
4791 (lambda* (#:key tests? #:allow-other-keys)
4794 (format #t "test suite not run~%"))
4797 (list bundler ruby-rspec))
4798 (synopsis "HOCON config library")
4800 "This package provides Ruby support for the @acronym{HOCON,
4801 Human-Optimized Config Object Notation} configuration file format. It
4802 supports parsing and modifying HOCON and JSON files, and rendering parsed
4803 objects back to a @code{String}.")
4804 (license license:asl2.0)))
4806 (define-public ruby-slop
4812 (uri (rubygems-uri "slop" version))
4815 "0bfm8535g0rkn9cbjndkckf0f7a3wj0rg4rqhrpsgxnbfdf2lm0p"))))
4816 (build-system ruby-build-system)
4818 (list ruby-minitest))
4819 (synopsis "Ruby command line option parser")
4820 (description "Slop provides a Ruby domain specific language for gathering
4821 options and parsing command line flags.")
4822 (home-page "https://github.com/leejarvis/slop")
4823 (license license:expat)))
4825 (define-public ruby-slop-3
4826 (package (inherit ruby-slop)
4830 (uri (rubygems-uri "slop" version))
4833 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
4835 (define-public ruby-multi-xml
4837 (name "ruby-multi-xml")
4842 (uri (rubygems-uri "multi_xml" version))
4845 "0lmd4f401mvravi1i1yq7b2qjjli0yq7dfc4p1nj5nwajp7r6hyj"))))
4846 (build-system ruby-build-system)
4848 '(#:tests? #f)) ; No included tests
4849 (synopsis "Swappable XML backends for Ruby")
4851 "@code{MultiXml} provides swappable XML backends utilizing either LibXML,
4852 Nokogiri, Ox, or REXML.")
4853 (home-page "https://github.com/sferik/multi_xml")
4854 (license license:expat)))
4856 (define-public ruby-multipart-post
4858 (name "ruby-multipart-post")
4862 (uri (rubygems-uri "multipart-post" version))
4865 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
4866 (build-system ruby-build-system)
4869 (synopsis "Multipart POST library for Ruby")
4870 (description "Multipart-Post Adds multipart POST capability to Ruby's
4872 (home-page "https://github.com/nicksieger/multipart-post")
4873 (license license:expat)))
4875 (define-public ruby-multi-json
4877 (name "ruby-multi-json")
4882 ;; Tests are not distributed at rubygems.org so download from GitHub
4885 (url "https://github.com/intridea/multi_json")
4886 (commit (string-append "v" version))))
4887 (file-name (git-file-name name version))
4890 "0mkdvy6i00yyksjvnv6znh7wf89j9506qzzjq6bsbmbkyqrszp4d"))))
4891 (build-system ruby-build-system)
4894 (modify-phases %standard-phases
4895 (add-before 'check 'pre-check
4897 ;; As seen in the .travis.yml file.
4898 (setenv "SKIP_ADAPTERS" "gson,jr_jackson,nsjsonserialization"))))))
4900 (list ruby-rspec ruby-json-pure ruby-oj ruby-yajl-ruby))
4901 (synopsis "Common interface to multiple JSON libraries for Ruby")
4903 "This package provides a common interface to multiple JSON libraries,
4904 including Oj, Yajl, the JSON gem (with C-extensions), the pure-Ruby JSON gem,
4905 NSJSONSerialization, gson.rb, JrJackson, and OkJson.")
4906 (home-page "https://github.com/intridea/multi_json")
4907 (license license:expat)))
4909 (define-public ruby-multi-test
4911 (name "ruby-multi-test")
4916 (uri (rubygems-uri "multi_test" version))
4919 "1sx356q81plr67hg16jfwz9hcqvnk03bd9n75pmdw8pfxjfy1yxd"))))
4920 (build-system ruby-build-system)
4922 '(;; Tests require different sets of specific gem versions to be available,
4923 ;; and there is no gemfile that specifies the newest versions of
4924 ;; dependencies to be tested.
4927 "Interface to testing libraries loaded into a running Ruby process")
4929 "@code{multi_test} provides a uniform interface onto whatever testing
4930 libraries that have been loaded into a running Ruby process to help control
4931 rogue test/unit/autorun requires.")
4932 (home-page "https://github.com/cucumber/multi_test")
4933 (license license:expat)))
4935 (define-public ruby-arel
4941 (uri (rubygems-uri "arel" version))
4944 "1jk7wlmkr61f6g36w9s2sn46nmdg6wn2jfssrhbhirv5x9n95nk0"))))
4945 (build-system ruby-build-system)
4946 (arguments '(#:tests? #f)) ; no tests
4947 (home-page "https://github.com/rails/arel")
4948 (synopsis "SQL AST manager for Ruby")
4949 (description "Arel is an SQL @dfn{Abstract Syntax Tree} (AST) manager for
4950 Ruby. It simplifies the generation of complex SQL queries and adapts to
4951 various relational database implementations.")
4952 (license license:expat)))
4954 (define-public ruby-marcel
4956 (name "ruby-marcel")
4961 (uri (rubygems-uri "marcel" version))
4964 "1nxbjmcyg8vlw6zwagf17l9y2mwkagmmkg95xybpn4bmf3rfnksx"))))
4965 (build-system ruby-build-system)
4967 '(;; No included tests
4970 (list ruby-mimemagic))
4971 (synopsis "MIME type detection using magic numbers, filenames and extensions")
4973 "@code{marcel} provides @acronym{MIME, Multipurpose Internet Mail
4974 Extensions} type detection using magic numbers, filenames, and extensions")
4975 (home-page "https://github.com/basecamp/marcel")
4976 (license license:expat)))
4978 (define-public ruby-minitar
4979 ;; We package from the GitHub source to fix the security issue reported at
4980 ;; https://github.com/halostatue/minitar/issues/16.
4981 (let ((commit "e25205ecbb6277ae8a3df1e6a306d7ed4458b6e4"))
4983 (name "ruby-minitar")
4984 (version (string-append "0.5.4-1." (string-take commit 8)))
4989 (url "https://github.com/halostatue/minitar")
4991 (file-name (string-append name "-" version "-checkout"))
4994 "1iywfx07jgjqcmixzkxk9zdwfmij1fyg1z2jlwzj15cj7s99qlfv"))))
4995 (build-system ruby-build-system)
4997 '(#:tests? #f)) ; missing a gemspec
4998 (synopsis "Ruby library and utility for handling tar archives")
5000 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
5001 that provides the ability to deal with POSIX tar archive files.")
5002 (home-page "http://www.github.com/atoulme/minitar")
5003 (license (list license:gpl2+ license:ruby)))))
5005 (define-public ruby-mini-portile
5007 (name "ruby-mini-portile")
5012 (uri (rubygems-uri "mini_portile" version))
5015 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
5016 (build-system ruby-build-system)
5018 '(#:tests? #f)) ; tests require network access
5019 (synopsis "Ports system for Ruby developers")
5020 (description "Mini-portile is a port/recipe system for Ruby developers.
5021 It provides a standard way to compile against specific versions of libraries
5022 to reproduce user environments.")
5023 (home-page "https://github.com/flavorjones/mini_portile")
5024 (license license:expat)))
5026 (define-public ruby-mini-portile-2
5027 (package (inherit ruby-mini-portile)
5031 (uri (rubygems-uri "mini_portile2" version))
5034 "15zplpfw3knqifj9bpf604rb3wc1vhq6363pd6lvhayng8wql5vy"))))))
5036 (define-public ruby-nokogiri
5038 (name "ruby-nokogiri")
5042 (uri (rubygems-uri "nokogiri" version))
5045 "1v02g7k7cxiwdcahvlxrmizn3avj2q6nsjccgilq1idc89cr081b"))))
5046 (build-system ruby-build-system)
5048 ;; Tests fail because Nokogiri can only test with an installed extension,
5049 ;; and also because many test framework dependencies are missing.
5051 #:gem-flags (list "--" "--use-system-libraries"
5052 (string-append "--with-xml2-include="
5053 (assoc-ref %build-inputs "libxml2")
5054 "/include/libxml2" ))))
5058 (list zlib libxml2 libxslt))
5060 (list ruby-mini-portile-2.6.1 ruby-pkg-config))
5061 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
5062 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
5063 both CSS3 selector and XPath 1.0 support.")
5064 (home-page "http://www.nokogiri.org/")
5065 (license license:expat)))
5067 ;; nokogiri requires this version exactly.
5068 (define-public ruby-mini-portile-2.6.1
5070 (inherit ruby-mini-portile)
5074 (uri (rubygems-uri "mini_portile2" version))
5077 "1lvxm91hi0pabnkkg47wh1siv56s6slm2mdq1idfm86dyfidfprq"))))))
5079 (define-public ruby-method-source
5081 (name "ruby-method-source")
5086 (uri (rubygems-uri "method_source" version))
5089 "1pnyh44qycnf9mzi1j6fywd5fkskv3x7nmsqrrws0rjn5dd4ayfp"))))
5090 (build-system ruby-build-system)
5092 `(#:test-target "spec"
5094 (modify-phases %standard-phases
5095 (add-after 'unpack 'remove-git-ls-files
5096 (lambda* (#:key outputs #:allow-other-keys)
5097 (substitute* "Rakefile"
5098 (("git ls-files") "find . -type f"))
5102 (synopsis "Retrieve the source code for Ruby methods")
5103 (description "Method_source retrieves the source code for Ruby methods.
5104 Additionally, it can extract source code from Proc and Lambda objects or just
5106 (home-page "https://github.com/banister/method_source")
5107 (license license:expat)))
5109 (define-public ruby-coderay
5111 (name "ruby-coderay")
5116 (uri (rubygems-uri "coderay" version))
5119 "15vav4bhcc2x3jmi3izb11l4d9f3xv8hp2fszb7iqmpsccv1pz4y"))))
5120 (build-system ruby-build-system)
5122 '(#:tests? #f)) ; missing test files
5123 (synopsis "Ruby syntax highlighting library")
5124 (description "Coderay is a Ruby library that provides syntax highlighting
5125 for select languages.")
5126 (home-page "http://coderay.rubychan.de")
5127 (license license:expat)))
5129 (define-public ruby-cuke-modeler
5131 (name "ruby-cuke-modeler")
5136 (uri (rubygems-uri "cuke_modeler" version))
5139 "19smj3g3wvz0203l549sadpcxgh0ir350a6k78gq0bmlv9cchmjb"))))
5140 (build-system ruby-build-system)
5141 (arguments `(#:tests? #f)) ;no test suite in gem
5143 (list ruby-gherkin))
5144 (synopsis "Gherkin test suite analysis tool")
5145 (description "CukeModeler facilitates modeling a test suite that is
5146 written in Gherkin (e.g. Cucumber, SpecFlow, Lettuce, etc.). It does this by
5147 providing an abstraction layer on top of the Abstract Syntax Tree (AST) that
5148 the @code{cucumber-gherkin} generates when parsing features, as well as
5149 providing models for feature files and directories in order to be able to have
5150 a fully traversable model tree of a test suite's structure. These models can
5151 then be analyzed or manipulated more easily than the underlying AST layer.")
5152 (home-page "https://github.com/enkessler/cuke_modeler")
5153 (license license:expat)))
5155 (define-public ruby-parallel-tests
5157 (name "ruby-parallel-tests")
5159 (home-page "https://github.com/grosser/parallel_tests")
5164 (commit (string-append "v" version))))
5165 (file-name (string-append name version))
5168 "08a6ndqn2dqacmc7yg48k0dh2rfrynvhkd5hiay16dl9m1r9q8pz"))))
5169 (build-system ruby-build-system)
5171 '(#:test-target "default"
5172 #:phases (modify-phases %standard-phases
5173 (add-after 'patch-source-shebangs 'patch-shell-invokations
5175 (substitute* '("lib/parallel_tests/tasks.rb"
5176 "spec/parallel_tests/tasks_spec.rb")
5177 (("/bin/sh") (which "sh"))
5178 (("/bin/bash") (which "bash")))
5180 (add-before 'check 'remove-version-constraints
5182 ;; Remove hard coded version constraints, instead just
5183 ;; use whatever versions are available in Guix.
5184 (delete-file "Gemfile.lock")
5185 (substitute* "Gemfile"
5191 (add-before 'check 'disable-rails-test
5193 ;; XXX: This test attempts to download and run the test
5194 ;; suites of multiple Rails versions(!) directly.
5195 (delete-file "spec/rails_spec.rb")
5197 (add-before 'check 'set-HOME
5199 ;; Some tests check the output of Bundler, and fail when
5200 ;; Bundler warns that /homeless-shelter does not exist.
5201 (setenv "HOME" "/tmp")
5212 (list ruby-parallel))
5213 (synopsis "Run tests in parallel")
5215 "This package can speed up @code{Test::Unit}, @code{RSpec},
5216 @code{Cucumber}, and @code{Spinach} tests by running them concurrently
5217 across multiple CPU cores.")
5218 (license license:expat)))
5220 (define-public ruby-parser
5222 (name "ruby-parser")
5227 (uri (rubygems-uri "parser" version))
5230 "1jixakyzmy0j5c1rb0fjrrdhgnyryvrr6vgcybs14jfw09akv5ml"))))
5231 (build-system ruby-build-system)
5233 '(#:tests? #f)) ; tests not included in gem
5235 (list bundler ruby-cliver ruby-simplecov ruby-racc))
5240 (synopsis "Ruby parser written in pure Ruby")
5242 "This package provides a Ruby parser written in pure Ruby.")
5243 (home-page "https://github.com/whitequark/parser")
5244 (license license:expat)))
5246 (define-public ruby-sexp-processor
5248 (name "ruby-sexp-processor")
5253 (uri (rubygems-uri "sexp_processor" version))
5256 "0d1vks77xnd0m3s94a58f9bkdwlaml5qdkmprx279m2s0pc2gv55"))))
5257 (build-system ruby-build-system)
5259 ;; TODO: Add ruby-minitest-proveit once available.
5261 (synopsis "ParseTree fork which includes generic S-exp processing tools")
5262 (description "The sexp_processor package is derived from ParseTree, but
5263 contrary to ParseTree, it includes all the generic S-exp processing tools.
5264 Amongst the included tools are @code{Sexp}, @code{SexpProcessor} and
5265 @code{Environment}")
5266 (home-page "https://github.com/seattlerb/sexp_processor")
5267 (license license:expat)))
5269 (define-public ruby-ruby-parser
5271 (name "ruby-ruby-parser")
5276 (uri (rubygems-uri "ruby_parser" version))
5279 "09qcdyjjw3p7g6cjm5m9swkms1xnv35ndiy7yw24cas16qrhha6c"))))
5280 (build-system ruby-build-system)
5282 (list ruby-hoe ruby-racc unifdef))
5284 (list ruby-sexp-processor))
5285 (home-page "https://github.com/seattlerb/ruby_parser/")
5286 (synopsis "Ruby parser written in pure Ruby")
5287 (description "The ruby_parser (RP) package provides a Ruby parser written
5288 in pure Ruby. It outputs S-expressions which can be manipulated and converted
5289 back to Ruby via the @code{ruby2ruby} library.")
5290 (license license:expat)))
5292 (define-public ruby-prawn-manual-builder
5294 (name "ruby-prawn-manual-builder")
5299 (uri (rubygems-uri "prawn-manual_builder" version))
5301 (base32 "1vlg5w7wq43g2hgpgra2nrcxj1kb4ayqliz4gmja2rhs037j2vzs"))))
5302 (build-system ruby-build-system)
5304 '(#:tests? #f ; no included tests
5306 (modify-phases %standard-phases
5307 (add-after 'extract-gemspec 'patch-gemspec
5309 (substitute* ".gemspec"
5310 ;; Loosen the requirement for pdf-inspector
5311 (("~> 1\\.0\\.7") ">= 0")))))))
5313 (list ruby-coderay))
5314 (synopsis "Tool for writing manuals for Prawn and Prawn accessories")
5316 "This package provides a tool for writing manuals for Prawn and Prawn
5318 (home-page "https://github.com/prawnpdf/prawn-manual_builder")
5319 (license %prawn-project-licenses)))
5321 (define-public ruby-progress_bar
5323 (name "ruby-progress_bar")
5328 (uri (rubygems-uri "progress_bar" version))
5331 "1qc40mr6p1z9a3vlpnsg1zfgk1qswviql2a31y63wpv3vr6b5f48"))))
5332 (build-system ruby-build-system)
5334 '(#:test-target "spec"))
5336 (list ruby-highline ruby-options))
5338 (list bundler ruby-rspec ruby-timecop))
5340 "Ruby library for displaying progress bars")
5342 "ProgressBar is a simple library for displaying progress bars. The
5343 maximum value is configurable, and additional information can be displayed
5344 like the percentage completion, estimated time remaining, elapsed time and
5346 (home-page "https://github.com/paul/progress_bar")
5347 (license license:wtfpl2)))
5349 (define-public ruby-dep
5356 (uri (rubygems-uri "ruby_dep" version))
5359 "1c1bkl97i9mkcvkn1jks346ksnvnnp84cs22gwl0vd7radybrgy5"))))
5360 (build-system ruby-build-system)
5362 '(#:tests? #f)) ; No included tests
5363 (synopsis "Creates a version constraint of supported Rubies")
5365 "This package helps create a version constraint of supported Rubies,
5366 suitable for a gemspec file.")
5367 (home-page "https://github.com/e2/ruby_dep")
5368 (license license:expat)))
5370 (define-public ruby-progressbar
5372 (name "ruby-progressbar")
5377 (uri (rubygems-uri "ruby-progressbar" version))
5379 (base32 "1k77i0d4wsn23ggdd2msrcwfy0i376cglfqypkk2q77r2l3408zf"))))
5380 (build-system ruby-build-system)
5382 '(;; TODO: There looks to be a circular dependency with ruby-fuubar.
5384 (synopsis "Text progress bar library for Ruby")
5386 "Ruby/ProgressBar is an flexible text progress bar library for Ruby.
5387 The output can be customized with a formatting system.")
5388 (home-page "https://github.com/jfelchner/ruby-progressbar")
5389 (license license:expat)))
5391 (define-public ruby-pry
5398 (uri (rubygems-uri "pry" version))
5401 "0iyw4q4an2wmk8v5rn2ghfy2jaz9vmw2nk8415nnpx2s866934qk"))))
5402 (build-system ruby-build-system)
5404 '(#:tests? #f)) ; no tests
5406 (list ruby-coderay ruby-method-source))
5407 (synopsis "Ruby REPL")
5408 (description "Pry is an IRB alternative and runtime developer console for
5409 Ruby. It features syntax highlighting, a plugin architecture, runtime
5410 invocation, and source and documentation browsing.")
5411 (home-page "https://cobaltbluemedia.com/pryrepl/")
5412 (license license:expat)))
5414 (define-public ruby-single-cov
5416 (name "ruby-single-cov")
5418 (home-page "https://github.com/grosser/single_cov")
5421 (uri (git-reference (url home-page)
5422 (commit (string-append "v" version))))
5423 (file-name (git-file-name name version))
5426 "05qdzpcai1p23a120gb9bxkfl4y73k9hicx34ch2lsk31lgi9bl7"))))
5427 (build-system ruby-build-system)
5429 '(#:test-target "default"
5430 #:phases (modify-phases %standard-phases
5431 (replace 'replace-git-ls-files
5433 (substitute* "single_cov.gemspec"
5434 (("`git ls-files lib/ bin/ MIT-LICENSE`")
5435 "`find lib/ bin/ MIT-LICENSE -type f | sort`"))
5437 (add-before 'check 'remove-version-constraints
5439 (delete-file "Gemfile.lock")
5441 (add-before 'check 'make-files-writable
5443 ;; Tests need to create local directories and open files
5444 ;; with write permissions.
5445 (for-each make-file-writable
5446 (find-files "specs" #:directories? #t))
5448 (add-before 'check 'disable-failing-test
5450 ;; XXX: This test copies assets from minitest, but can
5451 ;; not cope with the files being read-only. Just skip
5453 (substitute* "specs/single_cov_spec.rb"
5454 (("it \"complains when coverage is bad\"")
5455 "xit \"complains when coverage is bad\""))
5458 (list ruby-bump ruby-minitest ruby-rspec ruby-simplecov))
5459 (synopsis "Code coverage reporting tool")
5461 "This package provides actionable code coverage reports for Ruby
5462 projects. It has very little overhead and can be easily integrated with
5463 development tools to catch coverage problems early.")
5464 (license license:expat)))
5466 (define-public ruby-oedipus-lex
5468 (name "ruby-oedipus-lex")
5473 (uri (rubygems-uri "oedipus_lex" version))
5476 "1v1rk78khwq87ar300lwll570zxpkq9rjnpgc9mgsyd6mm9qjz4w"))))
5477 (build-system ruby-build-system)
5480 (synopsis "Ruby lexer")
5482 "Oedipus Lex is a lexer generator in the same family as Rexical and Rex.
5483 It is based primarily on generating code much like you would a hand-written
5484 lexer. It uses StrScanner within a multi-level case statement. As such,
5485 Oedipus matches on the first match, not the longest.")
5486 (home-page "https://github.com/seattlerb/oedipus_lex")
5487 (license license:expat)))
5489 (define-public ruby-guard
5495 ;; The gem does not include a Rakefile, nor does it contain a
5496 ;; gemspec file, nor does it come with the tests. This is why
5497 ;; we fetch the tarball from Github.
5499 (url "https://github.com/guard/guard")
5500 (commit (string-append "v" version))))
5501 (file-name (git-file-name name version))
5504 "16pxcszr0g2jnl3090didxh1d8z5m2mly14m3w4rspb8fmclsnjs"))))
5505 (build-system ruby-build-system)
5507 `(#:tests? #f ; tests require cucumber
5509 (modify-phases %standard-phases
5510 (add-after 'unpack 'remove-git-ls-files
5511 (lambda* (#:key outputs #:allow-other-keys)
5512 (substitute* "guard.gemspec"
5513 (("git ls-files -z") "find . -type f -print0"))
5517 (invoke "gem" "build" "guard.gemspec"))))))
5519 (list ruby-formatador
5528 (list bundler ruby-rspec))
5529 (synopsis "Tool to handle events on file system modifications")
5531 "Guard is a command line tool to easily handle events on file system
5532 modifications. Guard automates various tasks by running custom rules whenever
5533 file or directories are modified.")
5534 (home-page "https://guardgem.org/")
5535 (license license:expat)))
5537 (define-public ruby-spinach
5539 (name "ruby-spinach")
5541 (home-page "https://github.com/codegram/spinach")
5544 (uri (rubygems-uri "spinach" version))
5547 "1mv053mqz9c8ngqa6wp1ymk2fax6j0yqzax6918akrdr7c3fx3c6"))))
5548 (build-system ruby-build-system)
5550 ;; FIXME: Disable tests altogether because they depend on 'capybara'
5551 ;; which in turn depends on many other unpackaged gems. Enable once
5552 ;; capybara is available.
5555 (list ruby-colorize ruby-gherkin-ruby ruby-json))
5556 (synopsis "Gherkin-based BDD framework")
5558 "Spinach is a high-level @acronym{BDD, Behavior-driven development}
5559 framework that leverages the expressive @code{Gherkin} language to help you
5560 define executable specifications of your code.")
5561 (license license:expat)))
5563 (define-public ruby-tilt
5569 (method git-fetch) ;the distributed gem lacks tests
5571 (url "https://github.com/rtomayko/tilt")
5572 (commit (string-append "v" version))))
5573 (file-name (git-file-name name version))
5576 "0adb7fg7925n2rd9a8kkqz3mgylw2skp9hkh9qc1rnph72mqsm6r"))))
5577 (build-system ruby-build-system)
5580 (modify-phases %standard-phases
5581 (add-after 'unpack 'remove-some-dependencies
5583 (substitute* "Gemfile"
5584 ;; TODO ronn is used for generating the manual
5585 (("gem 'ronn'.*") "\n")
5586 ;; ruby-haml has a runtime dependency on ruby-tilt, so don't
5587 ;; pass it in as a native-input
5588 (("gem 'haml'.*") "\n")
5589 ;; TODO Not all of these gems are packaged for Guix yet:
5590 ;; less, coffee-script, livescript, babel-transpiler,
5592 (("if can_execjs") "if false")
5593 ;; Disable the secondary group to reduce the number of
5594 ;; dependencies. None of the normal approaches work, so patch
5595 ;; the Gemfile instead.
5596 (("group :secondary") "[].each"))
5599 (list ruby-pandoc-ruby ruby-sassc))
5601 (list bundler ruby-yard ruby-builder ruby-erubis ruby-markaby))
5602 (synopsis "Generic interface to multiple Ruby template engines")
5604 "Tilt is a thin interface over a number of different Ruby template
5605 engines in an attempt to make their usage as generic as possible.")
5606 (home-page "https://github.com/rtomayko/tilt/")
5607 (license license:expat)))
5609 (define-public ruby-thread-safe
5611 (name "ruby-thread-safe")
5616 (uri (rubygems-uri "thread_safe" version))
5619 "0nmhcgq6cgz44srylra07bmaw99f5271l0dpsvl5f75m44l0gmwy"))))
5620 (build-system ruby-build-system)
5622 '(#:tests? #f)) ; needs simplecov, among others
5623 (synopsis "Thread-safe utilities for Ruby")
5624 (description "The thread_safe library provides thread-safe collections and
5625 utilities for Ruby.")
5626 (home-page "https://github.com/ruby-concurrency/thread_safe")
5627 (license license:asl2.0)))
5629 (define-public ruby-tzinfo
5631 (name "ruby-tzinfo")
5637 ;; Pull from git because the gem has no tests.
5638 (url "https://github.com/tzinfo/tzinfo")
5639 (commit (string-append "v" version))))
5640 (file-name (git-file-name name version))
5643 "0jaq1givdaz5jxz47xngyj3j315n872rk97mnpm5njwm48wy45yh"))))
5644 (build-system ruby-build-system)
5647 (modify-phases %standard-phases
5648 (add-after 'unpack 'skip-safe-tests
5650 (substitute* "test/test_utils.rb"
5651 (("def safe_test\\(options = \\{\\}\\)")
5652 "def safe_test(options = {})
5653 skip('The Guix build environment has an unsafe load path')"))
5655 (add-before 'check 'pre-check
5657 (setenv "HOME" (getcwd))
5658 (substitute* "Gemfile"
5659 (("simplecov.*") "simplecov'\n"))
5662 (lambda* (#:key tests? test-target #:allow-other-keys)
5664 (invoke "bundler" "exec" "rake" test-target))
5667 `(("ruby-concurrent-ruby" ,ruby-concurrent)))
5669 (list ruby-simplecov))
5670 (synopsis "Time zone library for Ruby")
5671 (description "TZInfo is a Ruby library that provides daylight savings
5672 aware transformations between times in different time zones.")
5673 (home-page "https://tzinfo.github.io")
5674 (license license:expat)))
5676 (define-public ruby-tzinfo-data
5678 (name "ruby-tzinfo-data")
5679 (version "1.2021.1")
5683 ;; Download from GitHub because the rubygems version does not contain
5684 ;; Rakefile or tests.
5686 (url "https://github.com/tzinfo/tzinfo-data")
5687 (commit (string-append "v" version))))
5688 (file-name (git-file-name name version))
5691 "0yzyr3rf8qaw6kxfc0gwpxsb7gl3rhfpx9g1c2z15vapyminhi60"))))
5692 (build-system ruby-build-system)
5695 (modify-phases %standard-phases
5696 (add-after 'unpack 'patch-source
5697 (lambda* (#:key inputs #:allow-other-keys)
5698 (substitute* "Rakefile"
5699 (("https://data.iana.org/time-zones/releases")
5700 (assoc-ref inputs "tzdata")))
5702 (add-before 'check 'pre-check
5704 (setenv "HOME" (getcwd))
5705 (substitute* "Rakefile"
5706 ;; Don't need gpg, and it may break after a time.
5708 ((" sh\\(\\\"make -C" text)
5709 (string-append " sh(\"sed -i 's@/bin/sh@sh@' #{tzdb_combined_path}/Makefile \")\n"
5710 " sh(\"sed -i 's@cc=@cc?=@' #{tzdb_combined_path}/Makefile \")\n" text)))
5711 (setenv "cc" ,(cc-for-target))
5717 ,(file-union "tzdata-for-ruby-tzdata-info"
5718 `(("tzdata2021a.tar.gz"
5721 (uri "https://data.iana.org/time-zones/releases/tzdata2021a.tar.gz")
5724 "022fn6gkmp7pamlgab04x0dm5hnyn2m2fcnyr3pvm36612xd5rrr"))))
5725 ("tzdata2021a.tar.gz.asc"
5728 (uri "https://data.iana.org/time-zones/releases/tzdata2021a.tar.gz.asc")
5731 "0n7h2w8ji1lrxpk0d44wyfshlhr7c9jmwj6lqbxlyvqnfi3gbicx"))))
5732 ("tzcode2021a.tar.gz"
5735 (uri "https://data.iana.org/time-zones/releases/tzcode2021a.tar.gz")
5738 "1l02b0jiwp3fl0xd6227i69d26rmx3yrnq0ssq9vvdmm4jhvyipb"))))
5739 ("tzcode2021a.tar.gz.asc"
5742 (uri "https://data.iana.org/time-zones/releases/tzcode2021a.tar.gz.asc")
5745 "1qhlj4lr810s47s1lwcvv1sgvg2sflf98w4sbg1lc8wzv5qxxv7g")))))
5747 ;; XXX: Explicitly depend on 'guile-final', which was previously
5748 ;; implied via the '%guile-for-build' fluid but not explicit.
5749 ;; TODO: Remove this argument on the next rebuild cycle.
5750 #:guile (module-ref (resolve-interface
5751 '(gnu packages commencement))
5753 (synopsis "Data from the IANA Time Zone database")
5755 "This library provides @code{TZInfo::Data}, which contains data from the
5756 IANA Time Zone database packaged as Ruby modules for use with @code{TZInfo}.")
5757 (home-page "https://tzinfo.github.io")
5758 (license license:expat)))
5760 (define-public ruby-rb-inotify
5762 (name "ruby-rb-inotify")
5767 (uri (rubygems-uri "rb-inotify" version))
5770 "0yfsgw5n7pkpyky6a9wkf1g9jafxb0ja7gz0qw0y14fd2jnzfh71"))))
5771 (build-system ruby-build-system)
5773 '(#:tests? #f ; there are no tests
5775 (modify-phases %standard-phases
5776 ;; Building the gemspec with rake is not working here since it is
5777 ;; generated with Jeweler. It is also unnecessary because the
5778 ;; existing gemspec does not use any development tools to generate a
5782 (invoke "gem" "build" "rb-inotify.gemspec"))))))
5787 (synopsis "Ruby wrapper for Linux's inotify")
5788 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
5789 kernel subsystem for monitoring changes to files and directories.")
5790 (home-page "https://github.com/nex3/rb-inotify")
5791 (license license:expat)))
5793 (define-public ruby-pry-editline
5795 (name "ruby-pry-editline")
5799 (uri (rubygems-uri "pry-editline" version))
5802 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
5803 (build-system ruby-build-system)
5804 (arguments `(#:tests? #f)) ; no tests included
5807 (synopsis "Open the current REPL line in an editor")
5809 "This gem provides a plugin for the Ruby REPL to enable opening the
5810 current line in an external editor.")
5811 (home-page "https://github.com/tpope/pry-editline")
5812 (license license:expat)))
5814 (define-public ruby-sdoc
5820 (uri (rubygems-uri "sdoc" version))
5823 "1am73dldx1fqlw2xny5vyk00pgkisg6bvs0pa8jjd7c19drjczrd"))))
5824 (build-system ruby-build-system)
5827 (modify-phases %standard-phases
5828 (add-before 'check 'set-rubylib-and-patch-gemfile
5830 (setenv "RUBYLIB" "lib")
5831 (substitute* "sdoc.gemspec"
5832 (("s.add_runtime_dependency.*") "\n")
5833 (("s.add_dependency.*") "\n"))
5834 (substitute* "Gemfile"
5836 "gem 'rake'\ngem 'rdoc'\ngem 'json'\n"))
5841 (list bundler ruby-minitest ruby-hoe))
5842 (synopsis "Generate searchable RDoc documentation")
5844 "SDoc is an RDoc documentation generator to build searchable HTML
5845 documentation for Ruby code.")
5846 (home-page "https://github.com/voloko/sdoc")
5847 (license license:expat)))
5849 (define-public ruby-tins
5855 (uri (rubygems-uri "tins" version))
5858 "0nzp88y19rqlcizp1nw8m44fvfxs9g3bhjpscz44dwfawfrmr0cb"))))
5859 (build-system ruby-build-system)
5860 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
5861 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
5864 `(#:tests? #f ; there are no tests
5866 (modify-phases %standard-phases
5869 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
5871 (substitute* "tins.gemspec"
5872 (("\"lib/spruz\", ") ""))
5873 (invoke "gem" "build" "tins.gemspec"))))))
5876 (synopsis "Assorted tools for Ruby")
5877 (description "Tins is a Ruby library providing assorted tools.")
5878 (home-page "https://github.com/flori/tins")
5879 (license license:expat)))
5881 (define-public ruby-gem-hadar
5883 (name "ruby-gem-hadar")
5887 (uri (rubygems-uri "gem_hadar" version))
5890 "160abb3l4n3gkhd86f22n981bhqxkbf5ym6fhsk796pix6696pd5"))))
5891 (build-system ruby-build-system)
5892 ;; This gem needs itself at development time. We disable rebuilding of the
5893 ;; gemspec to avoid this loop.
5895 `(#:tests? #f ; there are no tests
5897 (modify-phases %standard-phases
5900 (invoke "gem" "build" "gem_hadar.gemspec"))))))
5902 (list git ruby-tins ruby-yard))
5903 (synopsis "Library for the development of Ruby gems")
5905 "This library contains some useful functionality to support the
5906 development of Ruby gems.")
5907 (home-page "https://github.com/flori/gem_hadar")
5908 (license license:expat)))
5910 (define-public ruby-minitest-tu-shim
5912 (name "ruby-minitest-tu-shim")
5916 (uri (rubygems-uri "minitest_tu_shim" version))
5919 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
5920 (build-system ruby-build-system)
5923 (modify-phases %standard-phases
5924 (add-after 'unpack 'fix-test-include-path
5925 (lambda* (#:key inputs #:allow-other-keys)
5926 (let* ((minitest (assoc-ref inputs "ruby-minitest-4")))
5927 (substitute* "Rakefile"
5928 (("Hoe\\.add_include_dirs .*")
5929 (string-append "Hoe.add_include_dirs \""
5930 minitest "/lib/ruby/vendor_ruby"
5932 ,(package-version ruby-minitest-4)
5935 (add-before 'check 'fix-test-assumptions
5937 ;; The test output includes the file name, so a couple of tests
5938 ;; fail. Changing the regular expressions slightly fixes this
5940 (substitute* "test/test_mini_test.rb"
5941 (("output.sub!\\(.*, 'FILE:LINE'\\)")
5942 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
5943 (("gsub\\(/.*, 'FILE:LINE'\\)")
5944 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
5947 `(("ruby-minitest-4" ,ruby-minitest-4)))
5950 (synopsis "Adapter library between minitest and test/unit")
5952 "This library bridges the gap between the small and fast minitest and
5953 Ruby's large and slower test/unit.")
5954 (home-page "https://rubygems.org/gems/minitest_tu_shim")
5955 (license license:expat)))
5957 (define-public ruby-term-ansicolor
5959 (name "ruby-term-ansicolor")
5963 (uri (rubygems-uri "term-ansicolor" version))
5966 "1xq5kci9215skdh27npyd3y55p812v4qb4x2hv3xsjvwqzz9ycwj"))))
5967 (build-system ruby-build-system)
5968 ;; Rebuilding the gemspec seems to require git, even though this is not a
5969 ;; git repository, so we just build the gem from the existing gemspec.
5972 (modify-phases %standard-phases
5973 (add-after 'unpack 'fix-test
5975 (substitute* "tests/hsl_triple_test.rb"
5980 (invoke "gem" "build" "term-ansicolor.gemspec"))))))
5984 (list ruby-gem-hadar ruby-minitest-tu-shim))
5985 (synopsis "Ruby library to control the attributes of terminal output")
5987 "This Ruby library uses ANSI escape sequences to control the attributes
5988 of terminal output.")
5989 (home-page "https://flori.github.io/term-ansicolor/")
5990 ;; There is no mention of the "or later" clause.
5991 (license license:gpl2)))
5993 (define-public ruby-terraform
5995 (name "ruby-terraform")
6000 (uri (rubygems-uri "ruby-terraform" version))
6003 "13zjkp71cd19j2ds2h9rqwcfr1zdg5nsh63p89l6qcsc9z39z324"))))
6004 (build-system ruby-build-system)
6006 '(#:tests? #f)) ; No included tests
6009 (synopsis "Ruby wrapper around the Terraform command line interface")
6011 "This package provides a Ruby wrapper around the Terraform command line
6012 interface so that Terraform can be more easily invoked from Ruby code.")
6013 (home-page "https://github.com/infrablocks/ruby_terraform")
6014 (license license:expat)))
6016 (define-public ruby-pstree
6018 (name "ruby-pstree")
6022 (uri (rubygems-uri "pstree" version))
6025 "0ld3ng37y92kv9vqnachw1l3n07hsc8hrnjs9d840liw0mysf1vp"))))
6026 (build-system ruby-build-system)
6028 (list ruby-gem-hadar bundler))
6029 (synopsis "Create a process tree data structure")
6031 "This library uses the output of the @code{ps} command to create a
6032 process tree data structure for the current host.")
6033 (home-page "https://github.com/flori/pstree")
6034 ;; There is no mention of the "or later" clause.
6035 (license license:gpl2)))
6037 (define-public ruby-utils
6043 (uri (rubygems-uri "utils" version))
6046 "196zhgcygrnx09bb9mh22qas03rl9avzx8qs0wnxznpin4pffwcl"))))
6047 (build-system ruby-build-system)
6049 (list ruby-tins ruby-term-ansicolor ruby-pstree ruby-pry-editline))
6051 (list ruby-gem-hadar bundler))
6052 (synopsis "Command line tools for working with Ruby")
6054 "This package provides assorted command line tools that may be useful
6055 when working with Ruby code.")
6056 (home-page "https://github.com/flori/utils")
6057 ;; There is no mention of the "or later" clause.
6058 (license license:gpl2)))
6060 (define-public ruby-jaro-winkler
6062 (name "ruby-jaro-winkler")
6067 (uri (rubygems-uri "jaro_winkler" version))
6069 (base32 "1y8l6k34svmdyqxya3iahpwbpvmn3fswhwsvrz0nk1wyb8yfihsh"))))
6070 (build-system ruby-build-system)
6072 '(#:tests? #f)) ; no included tests
6073 (synopsis "Ruby implementation of Jaro-Winkler distance algorithm")
6075 "@code{jaro_winkler} is an implementation of Jaro-Winkler distance
6076 algorithm. It is written as a C extension and will fallback to a pure Ruby
6077 implementation on platforms where this is unsupported.")
6078 (home-page "https://github.com/tonytonyjan/jaro_winkler")
6079 (license license:expat)))
6081 (define-public ruby-json
6088 (uri (rubygems-uri "json" version))
6091 "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp"))))
6092 (build-system ruby-build-system)
6093 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
6094 (synopsis "JSON library for Ruby")
6095 (description "This Ruby library provides a JSON implementation written as
6096 a native C extension.")
6097 (home-page "http://json-jruby.rubyforge.org/")
6098 (license (list license:ruby license:gpl2)))) ; GPL2 only
6100 (define-public ruby-json-pure
6102 (name "ruby-json-pure")
6106 (uri (rubygems-uri "json_pure" version))
6109 "00pziwkfqwk8vj19s65sdki31q1wvmf5v9b3sfglxm94qfvas1lx"))))
6110 (build-system ruby-build-system)
6113 (modify-phases %standard-phases
6114 (add-after 'unpack 'fix-rakefile
6116 (substitute* "Rakefile"
6117 ;; Since this is not a git repository, do not call 'git'.
6118 (("`git ls-files`") "`find . -type f |sort`")))))))
6120 (list bundler ragel ruby-simplecov ruby-test-unit which))
6121 (synopsis "JSON implementation in pure Ruby")
6123 "This package provides a JSON implementation written in pure Ruby.")
6124 (home-page "https://flori.github.com/json/")
6125 (license license:ruby)))
6127 (define-public ruby-jwt
6134 (uri (rubygems-uri "jwt" version))
6137 "1w0kaqrbl71cq9sbnixc20x5lqah3hs2i93xmhlfdg2y3by7yzky"))))
6138 (build-system ruby-build-system)
6140 '(#:test-target "test"
6142 (modify-phases %standard-phases
6143 (add-after 'unpack 'remove-unnecessary-dependencies
6145 (substitute* "spec/spec_helper.rb"
6146 (("require 'simplecov.*") "\n")
6147 ;; Use [].each to disable running the SimpleCov configuration
6149 (("SimpleCov\\.configure") "[].each")
6150 (("require 'codeclimate-test-reporter'") "")
6151 (("require 'codacy-coverage'") "")
6152 (("Codacy::Reporter\\.start") ""))
6155 (list bundler ruby-rspec ruby-rbnacl))
6156 (synopsis "Ruby implementation of the JSON Web Token standard")
6158 "This package provides a pure Ruby implementation of the RFC 7519 OAuth
6159 @acronym{JWT, JSON Web Token} standard.")
6160 (home-page "https://github.com/jwt/ruby-jwt")
6161 (license license:expat)))
6163 ;; Even though this package only provides bindings for a Mac OSX API it is
6164 ;; required by "ruby-listen" at runtime.
6165 (define-public ruby-rb-fsevent
6167 (name "ruby-rb-fsevent")
6171 (uri (rubygems-uri "rb-fsevent" version))
6174 "1lm1k7wpz69jx7jrc92w3ggczkjyjbfziq5mg62vjnxmzs383xx8"))))
6175 (build-system ruby-build-system)
6176 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
6177 ;; "listen", which needs "rb-fsevent" at runtime.
6178 (arguments `(#:tests? #f))
6179 (synopsis "FSEvents API with signals catching")
6181 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
6182 (home-page "https://rubygems.org/gems/rb-fsevent")
6183 (license license:expat)))
6185 (define-public ruby-listen
6187 (name "ruby-listen")
6191 ;; The gem does not include a Rakefile, so fetch from the Git
6195 (url "https://github.com/guard/listen")
6196 (commit (string-append "v" version))))
6197 (file-name (git-file-name name version))
6200 "1hkp1g6hk5clsmbd001gkc12ma6s459x820piajyasv61m87if24"))))
6201 (build-system ruby-build-system)
6203 `(#:test-target "spec"
6205 (modify-phases %standard-phases
6206 (add-after 'unpack 'fix-files-in-gemspec
6208 (substitute* "listen.gemspec"
6209 (("`git ls-files -z`") "`find . -type f -printf '%P\\\\0' |sort -z`"))
6211 (add-before 'check 'remove-unnecessary-dependencies'
6213 (substitute* "Rakefile"
6214 ;; Rubocop is for code linting, and is unnecessary for running
6216 ((".*rubocop.*") ""))
6219 (list bundler ruby-rspec))
6221 (list ;; ruby-thor is used for the command line interface, and is referenced
6222 ;; in the wrapper, and therefore just needs to be an input.
6225 (list ruby-rb-fsevent ruby-rb-inotify ruby-dep))
6226 (synopsis "Listen to file modifications")
6227 (description "The Listen gem listens to file modifications and notifies
6228 you about the changes.")
6229 (home-page "https://github.com/guard/listen")
6230 (license license:expat)))
6232 (define-public ruby-loofah
6234 (name "ruby-loofah")
6236 (home-page "https://github.com/flavorjones/loofah")
6239 ;; Build from git because the gem lacks tests.
6241 (uri (git-reference (url home-page)
6242 (commit (string-append "v" version))))
6243 (file-name (git-file-name name version))
6246 "0rmsm7mckiq0gslfqdl02yvn500n42v84gq28qjqn4yq9jwfs9ga"))))
6247 (build-system ruby-build-system)
6249 (list ruby-hoe ruby-hoe-markdown ruby-rr))
6251 (list ruby-nokogiri ruby-crass))
6252 (synopsis "Ruby library for manipulating and transforming HTML/XML")
6254 "Loofah is a general library for manipulating and transforming HTML/XML
6255 documents and fragments. It's built on top of Nokogiri and libxml2.")
6256 (license license:expat)))
6258 (define-public ruby-activesupport
6260 (name "ruby-activesupport")
6265 (uri (rubygems-uri "activesupport" version))
6268 "00a4db64g8w5yyk6hzak2nqrmdfvyh5zc9cvnm9gglwbi87ss28h"))))
6269 (build-system ruby-build-system)
6272 (modify-phases %standard-phases
6275 ;; There are no tests, instead attempt to load the library.
6276 (invoke "ruby" "-Ilib" "-r" "active_support"))))))
6278 (list ruby-concurrent
6284 (synopsis "Ruby on Rails utility library")
6285 (description "ActiveSupport is a toolkit of support libraries and Ruby
6286 core extensions extracted from the Rails framework. It includes support for
6287 multibyte strings, internationalization, time zones, and testing.")
6288 (home-page "https://www.rubyonrails.org")
6289 (license license:expat)))
6291 (define-public ruby-crass
6295 (home-page "https://github.com/rgrove/crass")
6297 ;; The gem does not contain tests, so pull from git.
6301 (commit (string-append "v" version))))
6302 (file-name (git-file-name name version))
6305 "1gbsb81psgb6xhnwpx4s409jc0mk0gijh039sy5xyi8jpaaadp40"))))
6306 (build-system ruby-build-system)
6307 (synopsis "Pure Ruby CSS parser")
6309 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
6310 (license license:expat)))
6312 (define-public ruby-nokogumbo
6314 (name "ruby-nokogumbo")
6317 ;; We use the git reference, because there's no Rakefile in the
6318 ;; published gem and the tarball on Github is outdated.
6321 (url "https://github.com/rubys/nokogumbo")
6322 (commit (string-append "v" version))))
6323 (file-name (string-append name "-" version "-checkout"))
6326 "1qg0iyw450lw6d0j1ghzg79a6l60nm1m4qmrzwzybi585861jxcx"))))
6327 (build-system ruby-build-system)
6329 (list ruby-rake-compiler))
6331 (list gumbo-parser))
6333 (list ruby-nokogiri))
6334 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
6336 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
6337 access the result as a Nokogiri parsed document.")
6338 (home-page "https://github.com/rubys/nokogumbo/")
6339 (license license:asl2.0)))
6341 (define-public ruby-sanitize
6343 (name "ruby-sanitize")
6345 (home-page "https://github.com/rgrove/sanitize")
6348 ;; The gem does not include the Rakefile, so we download the
6349 ;; source from Github.
6352 (commit (string-append "v" version))))
6353 (file-name (git-file-name name version))
6354 (patches (search-patches "ruby-sanitize-system-libxml.patch"))
6357 "0lj0q9yhjp0q0in5majkshnki07mw8m2vxgndx4m5na6232aszl0"))))
6358 (build-system ruby-build-system)
6360 (list ruby-crass ruby-nokogiri ruby-nokogumbo))
6362 (list ruby-minitest))
6363 (synopsis "Whitelist-based HTML and CSS sanitizer")
6365 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
6366 acceptable elements, attributes, and CSS properties, Sanitize will remove all
6367 unacceptable HTML and/or CSS from a string.")
6368 (license license:expat)))
6370 (define-public ruby-sync
6377 (uri (rubygems-uri "sync" version))
6380 "1z9qlq4icyiv3hz1znvsq1wz2ccqjb1zwd6gkvnwg6n50z65d0v6"))))
6381 (build-system ruby-build-system)
6382 (synopsis "Ruby module with a two-phase lock and counter")
6383 (description "This package provides a Ruby module that provides a two-phase
6384 lock with a counter.")
6385 (home-page "https://github.com/ruby/sync")
6386 (license license:bsd-2)))
6388 (define-public ruby-oj
6395 ;; Version on rubygems.org does not contain Rakefile, so download from
6398 (url "https://github.com/ohler55/oj")
6399 (commit (string-append "v" version))))
6400 (file-name (git-file-name name version))
6403 "0a24zd28y58nyhjxgrpn2k9p72vzj3zbmdrcsbhwbdycj7nn9fpd"))))
6404 (build-system ruby-build-system)
6406 '(#:test-target "test_all"
6408 (modify-phases %standard-phases
6409 (add-before 'check 'disable-bundler
6411 (substitute* "Rakefile"
6412 (("Bundler\\.with_clean_env") "1.times")
6413 (("bundle exec ") "")))))))
6415 (list bundler ruby-rspec ruby-rake-compiler))
6416 (synopsis "JSON parser for Ruby optimized for speed")
6418 "Oj is a JSON parser and generator for Ruby, where the encoding and
6419 decoding of JSON is implemented as a C extension to Ruby.")
6420 (home-page "http://www.ohler.com/oj/")
6421 (license (list license:expat ; Ruby code
6422 license:bsd-3)))) ; extension code
6424 (define-public ruby-ox
6431 (uri (rubygems-uri "ox" version))
6434 "0fmk62b1h2i79dfzjj8wmf8qid1rv5nhwfc17l489ywnga91xl83"))))
6435 (build-system ruby-build-system)
6437 '(#:tests? #f)) ; no tests
6438 (synopsis "Optimized XML library for Ruby")
6440 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
6441 written as a native C extension. It was designed to be an alternative to
6442 Nokogiri and other Ruby XML parsers for generic XML parsing and as an
6443 alternative to Marshal for Object serialization.")
6444 (home-page "http://www.ohler.com/ox")
6445 (license license:expat)))
6447 (define-public ruby-redcloth
6449 (name "ruby-redcloth")
6453 (uri (rubygems-uri "RedCloth" version))
6456 "0m9dv7ya9q93r8x1pg2gi15rxlbck8m178j1fz7r5v6wr1avrrqy"))))
6457 (build-system ruby-build-system)
6459 `(#:tests? #f ; no tests
6461 (modify-phases %standard-phases
6462 ;; Redcloth has complicated rake tasks to build various versions for
6463 ;; multiple targets using RVM. We don't want this so we just use the
6464 ;; existing gemspec.
6467 (invoke "gem" "build" "redcloth.gemspec"))))))
6469 `(("bundler" ,bundler)
6470 ("ruby-diff-lcs" ,ruby-diff-lcs)
6471 ("ruby-rspec-2" ,ruby-rspec-2)))
6472 (synopsis "Textile markup language parser for Ruby")
6474 "RedCloth is a Ruby parser for the Textile markup language.")
6475 (home-page "http://redcloth.org")
6476 (license license:expat)))
6478 (define-public ruby-pg
6482 (home-page "https://github.com/ged/ruby-pg")
6488 (commit (string-append "v" version))))
6489 (file-name (git-file-name name version))
6492 "0c2k2cibd5wwdhva68j5hhfpybm3wmvn2ym4ppn5mqmddwkjkvnk"))))
6493 (build-system ruby-build-system)
6496 #:test-target "spec"
6498 #~(modify-phases %standard-phases
6499 (add-after 'unpack 'disable-failing-tests
6501 ;; These tests fail because DNS is unavailable, giving an
6502 ;; unexpected fallback executable in the connection string.
6503 (substitute* "spec/pg/connection_spec.rb"
6504 (("it (\"accepts an URI and adds( proper)? hostaddr\")" test)
6505 (string-append "xit " test))
6506 (("it \"can create a connection option string from an option\
6507 string and a hash\"" test)
6508 (string-append "xit " test)))))
6509 (add-before 'build 'compile
6511 (invoke "rake" "compile")))
6512 ;; Some tests rely on postgresql_lib_path.rb, but it is not
6513 ;; available until the gem is installed. Run tests after
6514 ;; installing to work around it.
6516 (add-after 'install 'check
6517 (lambda* (#:key tests? #:allow-other-keys)
6518 (let ((new-gem (string-append #$output
6519 "/lib/ruby/vendor_ruby")))
6521 (string-append (getenv "GEM_PATH") ":" new-gem))
6523 (invoke "rspec"))))))))
6525 (list ruby-rake-compiler ruby-hoe ruby-rspec))
6528 (synopsis "Ruby interface to PostgreSQL")
6529 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
6530 with PostgreSQL 9.0 and later.")
6531 (license license:ruby)))
6533 (define-public ruby-byebug
6535 (name "ruby-byebug")
6541 (url "https://github.com/deivid-rodriguez/byebug")
6542 (commit (string-append "v" version))))
6543 (file-name (git-file-name name version))
6546 "0vyy3k2s7dcndngj6m8kxhs1vxc2c93dw8b3yyand3srsg9ffpij"))
6547 (modules '((guix build utils)))
6550 ;; Remove wrappers that try to setup a bundle environment.
6551 (with-directory-excursion "bin"
6552 (for-each delete-file '("bundle" "rake" "rubocop"))
6553 ;; ruby-minitest doesn't come with a launcher, so fix the one
6555 (substitute* "minitest"
6556 (("load File\\.expand_path\\(\"bundle\".*") "")
6557 (("require \"bundler/setup\".*") "")))
6559 (build-system ruby-build-system)
6562 (modify-phases %standard-phases
6563 (add-after 'unpack 'skip-tmp-path-sensitive-test
6565 (substitute* "test/commands/where_test.rb"
6566 (("unless /cygwin\\|mswin\\|mingw\\|darwin/.*")
6569 (add-before 'build 'compile
6571 (invoke "rake" "compile")))
6572 (add-before 'check 'disable-misbehaving-test
6573 ;; Expects 5, gets 162. From a file containing ~10 lines.
6575 (substitute* "test/commands/finish_test.rb"
6576 (("test_finish_inside_autoloaded_files")
6577 "finish_inside_autoloaded_files"))))
6578 (add-before 'check 'set-home
6580 (setenv "HOME" (getcwd))
6590 (synopsis "Debugger for Ruby 2")
6591 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
6592 TracePoint C API for execution control and the Debug Inspector C API for call
6593 stack navigation. The core component provides support that front-ends can
6594 build on. It provides breakpoint handling and bindings for stack frames among
6595 other things and it comes with a command line interface.")
6596 (home-page "https://github.com/deivid-rodriguez/byebug")
6597 (license license:bsd-2)))
6599 (define-public ruby-netrc
6605 (uri (rubygems-uri "netrc" version))
6608 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
6609 (build-system ruby-build-system)
6612 (modify-phases %standard-phases
6614 ;; There is no Rakefile and minitest can only run one file at once,
6615 ;; so we have to iterate over all test files.
6617 (for-each (lambda (file)
6618 (invoke "ruby" "-Itest" file))
6619 (find-files "./test" "test_.*\\.rb"))))
6620 (add-before 'check 'patch-tests-for-newer-ruby
6622 (substitute* "test/test_netrc.rb"
6623 (("Dir.pwd, '.netrc'") "Netrc.home_path, '.netrc'")))))))
6625 (list ruby-minitest))
6626 (synopsis "Library to read and update netrc files")
6628 "This library can read and update netrc files, preserving formatting
6629 including comments and whitespace.")
6630 (home-page "https://github.com/geemus/netrc")
6631 (license license:expat)))
6633 (define-public ruby-unf-ext
6635 (name "ruby-unf-ext")
6639 (uri (rubygems-uri "unf_ext" version))
6642 "1ll6w64ibh81qwvjx19h8nj7mngxgffg7aigjx11klvf5k2g4nxf"))))
6643 (build-system ruby-build-system)
6646 (modify-phases %standard-phases
6647 (add-after 'build 'build-ext
6648 (lambda _ (invoke "rake" "compile:unf_ext")))
6649 (add-before 'check 'lose-rake-compiler-dock-dependency
6651 ;; rake-compiler-dock is listed in the gemspec, but only
6652 ;; required when cross-compiling.
6653 (substitute* "unf_ext.gemspec"
6654 ((".*rake-compiler-dock.*") ""))
6657 (list bundler ruby-rake-compiler ruby-test-unit))
6658 (synopsis "Unicode normalization form support library")
6660 "This package provides unicode normalization form support for Ruby.")
6661 (home-page "https://github.com/knu/ruby-unf_ext")
6662 (license license:expat)))
6664 (define-public ruby-tdiff
6665 ;; Use a newer than released snapshot so that rspec-2 is not required.
6666 (let ((commit "b662a6048f08abc45c1a834e5f34dd1c662935e2"))
6669 (version (string-append "0.3.3-1." (string-take commit 8)))
6673 (url "https://github.com/postmodern/tdiff")
6675 (file-name (string-append name "-" version "-checkout"))
6678 "0n3gq8rx49f7ln6zqlshqfg2mgqyy30rsdjlnki5mv307ykc7ad4"))))
6679 (build-system ruby-build-system)
6681 (list ruby-rspec ruby-yard ruby-rubygems-tasks))
6682 (synopsis "Calculate the differences between two tree-like structures")
6684 "This library provides functions to calculate the differences between two
6685 tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
6686 (home-page "https://github.com/postmodern/tdiff")
6687 (license license:expat))))
6689 (define-public ruby-nokogiri-diff
6690 ;; Use a newer than released snapshot so that rspec-2 is not required.
6691 (let ((commit "a38491e4d8709b7406f2cae11a50226d927d06f5"))
6693 (name "ruby-nokogiri-diff")
6694 (version (string-append "0.2.0-1." (string-take commit 8)))
6698 (url "https://github.com/postmodern/nokogiri-diff")
6700 (file-name (string-append name "-" version "-checkout"))
6703 "1ah2sfjh9n1p0ln2wkqzfl448ml7j4zfy6dhp1qgzq2m41php6rf"))))
6704 (build-system ruby-build-system)
6709 (list ruby-rspec ruby-yard ruby-rubygems-tasks))
6710 (synopsis "Calculate the differences between two XML/HTML documents")
6712 "@code{Nokogiri::Diff} adds the ability to calculate the
6713 differences (added or removed nodes) between two XML/HTML documents.")
6714 (home-page "https://github.com/postmodern/nokogiri-diff")
6715 (license license:expat))))
6717 (define-public ruby-racc
6724 (uri (rubygems-uri "racc" version))
6727 "178k7r0xn689spviqzhvazzvxfq6fyjldxb3ywjbgipbfi4s8j1g"))))
6728 (build-system ruby-build-system)
6730 `(#:tests? #f)) ; Fails while parsing test instructions.
6732 (list ruby-hoe ruby-rake-compiler))
6733 (synopsis "LALR(1) parser generator for Ruby")
6735 "Racc is a LALR(1) parser generator. It is written in Ruby itself, and
6736 generates Ruby program.")
6737 (home-page "https://i.loveruby.net/en/projects/racc/")
6739 ;; Generally licensed under the LGPL2.1, and some files also
6740 ;; available under the same license as Ruby.
6744 (define-public ruby-rack
6751 ;; Download from GitHub so that the snippet can be applied and tests run.
6753 (url "https://github.com/rack/rack")
6755 (file-name (git-file-name name version))
6758 "1qrm5z5v586738bnkr9188dvz0s25nryw6sgvx18jjlkizayw1g4"))
6759 ;; Ignore test which fails inside the build environment but works
6761 (modules '((guix build utils)))
6763 '(begin (substitute* "test/spec_files.rb"
6764 (("res.body.must_equal expected_body") ""))
6766 (build-system ruby-build-system)
6769 (modify-phases %standard-phases
6770 (add-before 'check 'fix-tests
6772 ;; A few of the tests use the length of a file on disk for
6773 ;; Content-Length and Content-Range headers. However, this file
6774 ;; has a shebang in it which an earlier phase patches, growing
6775 ;; the file size from 193 to 239 bytes when the store prefix is
6777 (let ((size-diff (- (string-length (which "ruby"))
6778 (string-length "/usr/bin/env ruby"))))
6779 (substitute* '("test/spec_files.rb")
6781 (number->string (+ (string->number bytes) size-diff)))
6782 (("bytes(.)22-33" all delimiter)
6783 (string-append "bytes"
6785 (number->string (+ 22 size-diff))
6787 (number->string (+ 33 size-diff))))))
6790 (list ruby-minitest ruby-minitest-global-expectations))
6791 (synopsis "Unified web application interface for Ruby")
6792 (description "Rack provides a minimal, modular and adaptable interface for
6793 developing web applications in Ruby. By wrapping HTTP requests and responses,
6794 it unifies the API for web servers, web frameworks, and software in between
6795 into a single method call.")
6796 (home-page "https://rack.github.io/")
6797 (license license:expat)))
6799 (define-public ruby-rack-test
6801 (name "ruby-rack-test")
6806 (uri (rubygems-uri "rack-test" version))
6809 "14ij39zywvr1i9f6jsixfg4zxi2q1m1n1nydvf47f0b6sfc9mv1g"))))
6810 (build-system ruby-build-system)
6812 ;; Disable tests because of circular dependencies: requires sinatra,
6813 ;; which requires rack-protection, which requires rack-test. Instead
6814 ;; simply require the library.
6816 (modify-phases %standard-phases
6819 (invoke "ruby" "-Ilib" "-r" "rack/test"))))))
6822 (synopsis "Testing API for Rack applications")
6824 "Rack::Test is a small, simple testing API for Rack applications. It can
6825 be used on its own or as a reusable starting point for Web frameworks and
6826 testing libraries to build on.")
6827 (home-page "https://github.com/rack-test/rack-test")
6828 (license license:expat)))
6830 (define-public ruby-rack-protection
6832 (name "ruby-rack-protection")
6837 (uri (rubygems-uri "rack-protection" version))
6840 "1zyj97bfr1shfgwk4ddmdbw0mdkm4qdyh9s1hl0k7accf3kxx1yi"))))
6841 (build-system ruby-build-system)
6843 '(;; Tests missing from the gem.
6848 (list bundler ruby-rspec-2 ruby-rack-test))
6849 (synopsis "Rack middleware that protects against typical web attacks")
6850 (description "Rack middleware that can be used to protect against typical
6851 web attacks. It can protect all Rack apps, including Rails. For instance, it
6852 protects against cross site request forgery, cross site scripting,
6853 clickjacking, directory traversal, session hijacking and IP spoofing.")
6854 (home-page "https://github.com/sinatra/sinatra/tree/master/rack-protection")
6855 (license license:expat)))
6857 (define-public ruby-rainbow
6859 (name "ruby-rainbow")
6864 (uri (rubygems-uri "rainbow" version))
6867 "0bb2fpjspydr6x0s8pn1pqkzmxszvkfapv0p4627mywl7ky4zkhk"))))
6868 (build-system ruby-build-system)
6871 (modify-phases %standard-phases
6872 ;; Run rspec directly, to avoid requiring Rubocop which is used from
6875 (lambda* (#:key tests? #:allow-other-keys)
6880 (list bundler ruby-rspec))
6881 (synopsis "Colorize printed text on ANSI terminals")
6883 "@code{rainbow} provides a string presenter object to colorize strings by
6884 wrapping them in ANSI escape codes.")
6885 (home-page "https://github.com/sickill/rainbow")
6886 (license license:expat)))
6888 (define-public ruby-rr
6895 (uri (rubygems-uri "rr" version))
6898 "1n9g78ba4c2zzmz8cdb97c38h1xm0clircag00vbcxwqs4dq0ymp"))))
6899 (build-system ruby-build-system)
6901 '(#:tests? #f)) ; test files not included
6903 (list bundler ruby-rspec))
6904 (synopsis "Ruby test double framework")
6906 "RR is a test double framework that features a rich selection of double
6907 techniques and a terse syntax.")
6908 (home-page "https://rr.github.io/rr/")
6909 (license license:expat)))
6911 (define-public ruby-rest-client
6913 (name "ruby-rest-client")
6918 (uri (rubygems-uri "rest-client" version))
6921 "1hzcs2r7b5bjkf2x2z3n8z6082maz0j8vqjiciwgg3hzb63f958j"))))
6922 (build-system ruby-build-system)
6925 (modify-phases %standard-phases
6926 (add-before 'check 'remove-unnecessary-development-dependencies
6928 (substitute* "rest-client.gemspec"
6929 ;; Remove rubocop as it's unused. Rubocop also indirectly
6930 ;; depends on this package through ruby-parser and ruby-ast so
6931 ;; this avoids a dependency loop.
6932 ((".*rubocop.*") "\n")
6933 ;; Remove pry as it's unused, it's a debugging tool
6935 ;; Remove an unnecessarily strict rdoc dependency
6936 ((".*rdoc.*") "\n"))
6938 (add-before 'check 'delete-network-dependent-tests
6940 (delete-file "spec/integration/request_spec.rb")
6941 (delete-file "spec/integration/httpbin_spec.rb")
6944 (list ruby-http-cookie ruby-mime-types ruby-netrc))
6946 (list bundler ruby-webmock-2 ruby-rspec))
6947 (synopsis "Simple HTTP and REST client for Ruby")
6949 "@code{rest-client} provides a simple HTTP and REST client for Ruby,
6950 inspired by the Sinatra microframework style of specifying actions:
6951 @code{get}, @code{put}, @code{post}, @code{delete}.")
6952 (home-page "https://github.com/rest-client/rest-client")
6953 (license license:expat)))
6955 (define-public ruby-rubocop-ast
6957 (name "ruby-rubocop-ast")
6961 (method git-fetch) ;no test suite in distributed gem
6963 (url "https://github.com/rubocop-hq/rubocop-ast")
6964 (commit (string-append "v" version))))
6965 (file-name (git-file-name name version))
6968 "1x2m7k4bn4zvvwmj7imzmv0dav6xnrbcvssad1m5lkprx7h5lzkq"))))
6969 (build-system ruby-build-system)
6971 `(#:test-target "spec"
6972 #:phases (modify-phases %standard-phases
6973 (add-before 'build 'generate-lexer
6975 (setenv "RUBOCOP_VERSION" "none")
6976 (invoke "rake" "generate")))
6977 (replace 'replace-git-ls-files
6979 (substitute* "rubocop-ast.gemspec"
6980 (("`git ls-files(.*)`" _ files)
6981 (format #f "`find ~a -type f| sort`" files)))
6993 (synopsis "RuboCop's AST extensions and NodePattern functionality")
6994 (description "Rubocop::AST extends @code{ruby-parser} with classes used
6995 by RuboCop to deal with Ruby's Abstract Syntax Tree (AST), in particular:
6997 @item @code{RuboCop::AST::Node}
6998 @item @code{RuboCop::AST::NodePattern}
7000 (home-page "https://rubocop.org/")
7001 (license license:expat)))
7003 (define-public ruby-rexml
7009 (method git-fetch) ;no tests in distributed gem
7011 (url "https://github.com/ruby/rexml")
7012 (commit (string-append "v" version))))
7013 (file-name (git-file-name name version))
7015 (base32 "13n6vaa80drqic2wri4q6k22qzvsn683vp5s8c9dllil6x04kn0x"))))
7016 (build-system ruby-build-system)
7017 (synopsis "XML toolkit for Ruby")
7018 (description "Inspired by Electric XML library for Java, REXML aims to be
7019 easy-to-use API, small and fast. It supports both tree and stream document
7021 (home-page "https://github.com/ruby/rexml")
7022 (license license:bsd-2)))
7024 (define-public ruby-character-set
7026 (name "ruby-character-set")
7031 (uri (rubygems-uri "character_set" version))
7034 "0affq9n77vwy897ri2zhmfinfagf37hcwwimrccy1bcxan9mj3h3"))))
7035 (build-system ruby-build-system)
7036 (arguments '(#:tests? #f)) ;avoid a cycle with ruby-regexp-parser
7037 (synopsis "Ruby library to manipulate Unicode")
7038 (description "CharacterSet is a C-extended Ruby library to work with sets
7039 of Unicode code points. It can read and write these sets in various formats
7040 and implements the @code{stdlib} @code{Set} interface for them. It also
7041 offers an alternate paradigm of @code{String} processing which grants much
7042 better performance than @code{Regexp} and @code{String} methods from the
7043 @code{stdlib} where applicable. Many parts can be used independently, e.g.:
7045 @item @code{CharacterSet::Character}
7046 @item @code{CharacterSet::Parser}
7047 @item @code{CharacterSet::Writer}
7048 @item @code{RangeCompressor}
7050 (home-page "https://github.com/jaynetics/character_set")
7051 (license license:expat)))
7053 (define-public ruby-range-compressor
7055 (name "ruby-range-compressor")
7061 (url "https://github.com/janosch-x/range_compressor")
7062 (commit (string-append "v" version))))
7063 (file-name (git-file-name name version))
7066 "0y8slri2msyyg2szgwgriqd6qw9hkxycssdrcl5lk2dbcq5zvn54"))))
7067 (build-system ruby-build-system)
7069 `(#:test-target "spec"
7070 #:phases (modify-phases %standard-phases
7071 (add-after 'extract-gemspec 'strip-version-requirements
7073 (substitute* "range_compressor.gemspec"
7074 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
7075 (string-append stripped "\n")))
7079 (synopsis "Simple arrays of objects to arrays of ranges compressor")
7080 (description "RangeCompresses is a tiny library that allows compressing
7081 arrays of objects into arrays of ranges. For example, it can turn the
7082 following: @code{[1, 2, 3, 4, 6, 8, 9, 10]} into @code{[1..4, 6..6, 8..10]}.")
7083 (home-page "https://github.com/janosch-x/range_compressor")
7084 (license license:expat)))
7086 (define-public ruby-regexp-property-values
7087 (let ((commit "03007a66c912949a7130b973cc0eca109c20811f")
7090 (name "ruby-regexp-property-values")
7091 (version (git-version "1.0.0" revision commit))
7095 (uri (git-reference ;no test suite in distributed gem
7096 (url "https://github.com/jaynetics/regexp_property_values")
7098 (file-name (git-file-name name version))
7101 "1zsax784p16zdkf60lyq9z924zvsafhx9ckxx9srsgkyiqrifi1s"))))
7102 (build-system ruby-build-system)
7104 '(#:test-target "default"))
7106 (list ruby-character-set ruby-rake ruby-rake-compiler
7107 ruby-range-compressor ruby-rspec))
7108 (synopsis "Inspect Ruby's regex engine property values")
7109 (description "This small library lets you see which property values are
7110 supported by the regular expression engine of the Ruby version you are running
7111 and can directly read out their code point ranges. In other words, it
7112 determines all supported values for @code{\\p{value}} expressions and what
7114 (home-page "https://github.com/jaynetics/regexp_property_values")
7115 (license license:expat))))
7117 (define-public ruby-regexp-parser
7119 (name "ruby-regexp-parser")
7123 (method git-fetch) ;bin/test missing from gem
7125 (url "https://github.com/ammar/regexp_parser")
7126 (commit (string-append "v" version))))
7127 (file-name (git-file-name name version))
7130 "09ddxdwlml30q6j4rqf06bbjj1mwx00rs0bksnyblhv85anrqz3k"))))
7131 (build-system ruby-build-system)
7133 '(#:test-target "default"
7134 #:phases (modify-phases %standard-phases
7135 (add-before 'build 'compile-scanner.rb
7137 (invoke "rake" "build")
7138 ;; XXX: This is needed otherwise the install
7139 ;; phase fails to delete the installed cached
7141 (delete-file-recursively "pkg")
7144 (list ragel ruby-regexp-property-values ruby-rspec))
7145 (synopsis "Regular expression parser library for Ruby")
7146 (description "A Ruby gem for tokenizing, parsing, and transforming regular
7147 expressions. It comprises the following components:
7149 @item A scanner/tokenizer based on Ragel,
7150 @item A lexer that produces a stream of token objects,
7151 @item A parser that produces a tree of Expression objects.
7153 (home-page "https://github.com/ammar/regexp_parser")
7154 (license license:expat)))
7156 (define-public ruby-test-queue
7158 (name "ruby-test-queue")
7163 (uri (rubygems-uri "test-queue" version))
7166 "0hvm3n1qrqxqilhqk4rjivw3gcrd08zz1i6am9qzg1ppjxv6f36f"))))
7167 (build-system ruby-build-system)
7170 (modify-phases %standard-phases
7172 (lambda* (#:key tests? #:allow-other-keys)
7178 (synopsis "Minitest/RSpec parallel test runner for CI environments")
7179 (description "The test-queue module is a parallel test runner,
7180 built using a centralized queue to ensure optimal distribution of
7181 tests between workers. It is specifically optimized for Continuous
7182 Integration (CI) environments: build statistics from each run are
7183 stored locally and used to sort the queue at the beginning of the next
7185 (home-page "https://github.com/tmm1/test-queue")
7186 (license license:expat)))
7188 (define-public ruby-rubocop
7190 (name "ruby-rubocop")
7194 (method git-fetch) ;no tests in distributed gem
7196 (url "https://github.com/rubocop-hq/rubocop")
7197 (commit (string-append "v" version))))
7198 (file-name (git-file-name name version))
7201 "0wjw9vpzr4f3nf1zf010bag71w4hdi0haybdn7r5rlmw45pmim29"))))
7202 (build-system ruby-build-system)
7204 `(#:test-target "default"
7205 ;; TODO: Figure out why test hangs.
7206 #:tests? ,(not (target-riscv64?))
7208 (modify-phases %standard-phases
7209 (add-before 'check 'set-home
7211 (setenv "HOME" (getcwd))
7213 ;; Rubocop depends on itself for tests, directly and indirectly. By
7214 ;; regenerating the TODO list we test rubocop against itself and
7215 ;; forgo adjusting the test suite to our environment each release.
7217 (lambda* (#:key tests? #:allow-other-keys)
7219 (make-file-writable ".rubocop_todo.yml")
7220 (invoke "./exe/rubocop" "--auto-gen-config"))
7222 (add-before 'check 'make-adoc-files-writable
7224 (let ((adoc-files (find-files "docs/modules/ROOT/pages"
7226 (for-each make-file-writable adoc-files))
7229 `(("ruby-bump" ,ruby-bump)
7230 ("ruby-pry" ,ruby-pry)
7231 ("ruby-rake" ,ruby-rake)
7232 ("ruby-rspec" ,ruby-rspec)
7233 ("ruby-rubocop-minimal" ,ruby-rubocop-minimal)
7234 ("ruby-rubocop-performance-minimal" ,ruby-rubocop-performance-minimal)
7235 ("ruby-rubocop-rspec-minimal" ,ruby-rubocop-rspec-minimal)
7236 ("ruby-simplecov" ,ruby-simplecov)
7237 ("ruby-stackprof" ,ruby-stackprof)
7238 ("ruby-test-queue" ,ruby-test-queue)
7239 ("ruby-webmock" ,ruby-webmock)
7240 ("ruby-yard" ,ruby-yard)))
7248 ruby-unicode-display-width))
7249 (synopsis "Ruby code style checking tool")
7251 "@code{rubocop} is a Ruby code style checking tool. It aims to enforce
7252 the community-driven Ruby Style Guide.")
7253 (home-page "https://github.com/rubocop-hq/rubocop")
7254 (license license:expat)))
7256 (define-public ruby-rubocop-minimal
7259 (inherit ruby-rubocop)
7261 (substitute-keyword-arguments (package-arguments ruby-rubocop)
7262 ((#:tests? _ #f) #f)))
7263 (propagated-inputs '())
7264 (native-inputs '()))))
7266 (define-public ruby-contest
7268 (name "ruby-contest")
7273 (uri (rubygems-uri "contest" version))
7276 "1p9f2292b7b0fbrcjswvj9v01z7ig5ig52328wyqcabgb553qsdf"))))
7277 (build-system ruby-build-system)
7278 (synopsis "Write declarative tests using nested contexts")
7280 "Contest allows writing declarative @code{Test::Unit} tests using nested
7281 contexts without performance penalties.")
7282 (home-page "https://github.com/citrusbyte/contest")
7283 (license license:expat)))
7285 (define-public ruby-creole
7287 (name "ruby-creole")
7292 (uri (rubygems-uri "creole" version))
7295 "00rcscz16idp6dx0dk5yi5i0fz593i3r6anbn5bg2q07v3i025wm"))))
7296 (build-system ruby-build-system)
7299 (synopsis "Creole markup language converter")
7301 "Creole is a lightweight markup language and this library for converting
7302 creole to @code{HTML}.")
7303 (home-page "https://github.com/minad/creole")
7304 (license license:ruby)))
7306 (define-public ruby-docile
7308 (name "ruby-docile")
7313 (uri (rubygems-uri "docile" version))
7316 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
7317 (build-system ruby-build-system)
7319 '(#:tests? #f)) ; needs github-markup, among others
7320 (synopsis "Ruby EDSL helper library")
7321 (description "Docile is a Ruby library that provides an interface for
7322 creating embedded domain specific languages (EDSLs) that manipulate existing
7324 (home-page "https://ms-ati.github.io/docile/")
7325 (license license:expat)))
7327 (define-public ruby-middleware
7329 (name "ruby-middleware")
7334 (uri (rubygems-uri "middleware" version))
7337 "0703nkf2v371wqr41c04x5qid7ww45cxqv3hnlg07if3b3xrm9xl"))))
7338 (build-system ruby-build-system)
7339 (arguments '(#:tests? #f)) ;no test suite
7340 (synopsis "Implementation of a middleware abstraction for Ruby")
7341 (description "Middleware is a generalized implementation of a middleware
7342 abstraction for Ruby.")
7343 (home-page "https://github.com/mitchellh/middleware")
7344 (license license:expat)))
7346 (define-public ruby-benchmark-ips
7348 (name "ruby-benchmark-ips")
7353 (uri (rubygems-uri "benchmark-ips" version))
7356 "1n9397j7kh4vvikfann1467qgksc679imlr50hax3lk1q3af8kdw"))))
7357 (build-system ruby-build-system)
7360 (synopsis "Iterations per second enhancement for the Ruby Benchmark module")
7361 (description "Benchmark-ips enhances the Ruby Benchmark module with the
7362 iterations per second count. For short snippets of code, it can automatically
7363 figure out how many times to run the code to get interesting data.")
7364 (home-page "https://github.com/evanphx/benchmark-ips")
7365 (license license:expat)))
7367 (define-public ruby-ffi-rzmq-core
7369 (name "ruby-ffi-rzmq-core")
7374 (uri (rubygems-uri "ffi-rzmq-core" version))
7377 "0amkbvljpjfnv0jpdmz71p1i3mqbhyrnhamjn566w0c01xd64hb5"))))
7378 (build-system ruby-build-system)
7381 (modify-phases %standard-phases
7382 (add-after 'unpack 'patch-libzmq-search-path
7383 (lambda* (#:key inputs #:allow-other-keys)
7384 (let ((zeromq (assoc-ref inputs "zeromq")))
7385 (substitute* "lib/ffi-rzmq-core/libzmq.rb"
7387 (string-append zeromq "/lib")))
7391 (invoke "rspec"))))))
7396 (propagated-inputs (list ruby-ffi))
7397 (synopsis "Low-level Ruby FFI wrapper for the ZeroMQ networking library")
7398 (description "This library only provides the FFI wrapper for the ZeroMQ
7399 networking library. It can be used to implement a Ruby API for the ZeroMQ
7401 (home-page "https://github.com/chuckremes/ffi-rzmq-core")
7402 (license license:expat)))
7404 (define-public ruby-ffi-rzmq
7406 (name "ruby-ffi-rzmq")
7411 (uri (rubygems-uri "ffi-rzmq" version))
7414 "14a5kxfnf8l3ngyk8hgmk30z07aj1324ll8i48z67ps6pz2kpsrg"))))
7415 (build-system ruby-build-system)
7416 (arguments '(#:phases (modify-phases %standard-phases
7418 (lambda* (#:key tests? #:allow-other-keys)
7420 (invoke "rspec")))))))
7424 (list ruby-ffi-rzmq-core))
7425 (synopsis "High-level Ruby wrapper for the ZeroMQ networking library")
7426 (description "This library provides a high-level API that wraps the ZeroMQ
7427 networking library using the Ruby foreign function interface (FFI). It is a
7428 pure Ruby wrapper, hence is compatible with any Ruby runtime that has support
7430 (home-page "https://github.com/chuckremes/ffi-rzmq")
7431 (license license:expat)))
7433 (define-public ruby-sawyer
7435 (name "ruby-sawyer")
7440 (uri (rubygems-uri "sawyer" version))
7443 "0yrdchs3psh583rjapkv33mljdivggqn99wkydkjdckcjn43j3cz"))))
7444 (build-system ruby-build-system)
7446 (list ruby-addressable ruby-faraday))
7447 (synopsis "Experimental hypermedia agent for Ruby")
7448 (description "Sawyer is an experimental hypermedia agent for Ruby built on
7450 (home-page "https://github.com/lostisland/sawyer")
7451 (license license:expat)))
7453 (define-public ruby-octokit
7455 (name "ruby-octokit")
7460 (uri (rubygems-uri "octokit" version))
7463 "0zvfr9njmj5svi39fcsi2b0g7pcxb0vamw9dlyas8bg814jlzhi6"))))
7464 (build-system ruby-build-system)
7465 (arguments '(#:tests? #f)) ;no test suite in the gem release
7467 (list ruby-faraday ruby-sawyer))
7468 (synopsis "Ruby toolkit for the GitHub API")
7469 (description "Octokit wraps the GitHub API in a flat API client that
7470 follows Ruby conventions and requires little knowledge of REST.")
7471 (home-page "https://github.com/octokit/octokit.rb")
7472 (license license:expat)))
7474 (define-public ruby-chandler
7476 (name "ruby-chandler")
7481 (uri (rubygems-uri "chandler" version))
7484 "1n8a4mr2jkcz5vaaps45g2rxa2pzy1wb7cylgw85xmmyyp14lnrr"))))
7485 (build-system ruby-build-system)
7487 (list ruby-rubocop))
7489 (list ruby-netrc ruby-octokit))
7490 (synopsis "Sync CHANGELOG entries to GitHub's release notes")
7491 (description "Chandler syncs a project's CHANGELOG file entries to
7492 GitHub's release notes to remove the need of manually entering release
7494 (home-page "https://github.com/mattbrictson/chandler")
7495 (license license:expat)))
7497 (define-public ruby-pry-byebug
7499 (name "ruby-pry-byebug")
7505 (url "https://github.com/deivid-rodriguez/pry-byebug")
7506 (commit (string-append "v" version))))
7507 (file-name (git-file-name name version))
7510 "1kchrwccai92068p50zyd6mh524ywqnm0jw5g3lks7iwmf0xkmgc"))))
7511 (build-system ruby-build-system)
7513 `(#:phases (modify-phases %standard-phases
7514 (add-before 'check 'set-home
7516 (setenv "HOME" (getcwd))
7519 (list ruby-chandler ruby-rubocop ruby-simplecov))
7521 (list ruby-byebug ruby-pry))
7522 (synopsis "Step-by-step debugging and stack navigation in Pry")
7523 (description "This package adds step-by-step debugging and stack
7524 navigation capabilities to @code{pry}, using @code{byebug}.")
7525 (home-page "https://github.com/deivid-rodriguez/pry-byebug")
7526 (license license:expat)))
7528 (define-public ruby-stackprof
7530 (name "ruby-stackprof")
7535 (uri (rubygems-uri "stackprof" version))
7537 (base32 "06lz70k8c0r7fyxk1nc3idh14x7nvsr21ydm1bsmbj00jyhmfzsn"))))
7538 (build-system ruby-build-system)
7541 (modify-phases %standard-phases
7542 (add-before 'check 'skip-dubious-test
7544 ,@(if (or (target-riscv64?)
7546 ;; This unreliable test can fail with "Expected 32 to be <= 25."
7547 '((substitute* "test/test_stackprof.rb"
7548 ((".*assert_operator profile\\[:missed_samples.*") "")))
7549 ;; This unreliable test can fail with "Expected 0 to be >= 1."
7550 '((substitute* "test/test_stackprof.rb"
7551 (("def test_(cputime)" _ name)
7552 (string-append "def skip_" name)))))))
7553 (add-before 'check 'build-tests
7555 (invoke "rake" "compile"))))))
7557 (list ruby-mocha ruby-rake-compiler))
7558 (synopsis "Sampling profiler for Ruby code")
7560 "@code{stackprof} is a fast sampling profiler for Ruby code, with cpu,
7561 wallclock and object allocation samplers.")
7562 (home-page "https://github.com/tmm1/stackprof")
7563 (license license:expat)))
7565 (define-public ruby-binding-of-caller
7567 (name "ruby-binding-of-caller")
7572 (uri (rubygems-uri "binding_of_caller" version))
7575 "05syqlks7463zsy1jdfbbdravdhj9hpj5pv2m74blqpv8bq4vv5g"))))
7576 (build-system ruby-build-system)
7577 ;; Attempting to run the test suite fails with a rake deprecation error
7578 ;; (see: https://github.com/banister/binding_of_caller/issues/76).
7579 (arguments '(#:tests? #f))
7581 (list ruby-debug-inspector))
7582 (synopsis "Retrieve the binding of a method's caller")
7583 (description "The @code{binding_of_caller} module provides the
7584 @code{Binding#of_caller} method. It allows accessing bindings from upper
7585 frames in the call stack and can evaluate code in that context.")
7586 (home-page "https://github.com/banister/binding_of_caller")
7587 (license license:expat)))
7589 (define-public ruby-pry-stack-explorer
7591 (name "ruby-pry-stack-explorer")
7596 (uri (rubygems-uri "pry-stack_explorer" version))
7599 "157rd2n9pfvcmmicm0xkq8z4p6famaj13syrpra6b4032qpb1wn0"))))
7600 (build-system ruby-build-system)
7601 (arguments '(#:tests? #f)) ;no test suite in gem release
7603 (list ruby-binding-of-caller ruby-pry))
7604 (synopsis "Call-stack navigation plugin for the Pry REPL")
7605 (description "@code{pry-stack_explorer} is a plugin for the Pry REPL that
7606 add support to navigate the call-stack.")
7607 (home-page "https://github.com/pry/pry-stack_explorer")
7608 (license license:expat)))
7610 (define-public ruby-varint
7612 (name "ruby-varint")
7617 (uri (rubygems-uri "varint" version))
7620 "1y0l2qc64cwsyv76ygg9bbjnk86riz2kq73kmn87gdrlmpiyrdac"))))
7621 (build-system ruby-build-system)
7622 (arguments '(#:tests? #f)) ;no test suite
7623 (synopsis "Variable length integers (varint) C extension for Ruby")
7624 (description "This package provides a small C extension to speed up
7625 variable length integers (varint) in Ruby Protocol Buffers.")
7626 (home-page "https://github.com/liquidm/varint")
7627 (license license:bsd-3)))
7629 (define-public ruby-ruby-prof
7631 (name "ruby-ruby-prof")
7636 (uri (rubygems-uri "ruby-prof" version))
7639 "1r3xalp91l07m0cwllcxjzg6nkviiqnxkcbgg5qnzsdji6rgy65m"))))
7640 (build-system ruby-build-system)
7643 (modify-phases %standard-phases
7644 (add-after 'unpack 'patch-rakefile
7645 ;; This fixes the following error: "NameError: uninitialized
7646 ;; constant Bundler::GemHelper" (see:
7647 ;; https://github.com/ruby-prof/ruby-prof/issues/274).
7649 (substitute* "Rakefile"
7650 ((".*require \"bundler/setup\".*" all)
7651 (string-append all " require 'bundler/gem_tasks'\n")))
7653 ;; The LineNumbersTest test fails non-deterministically (see:
7654 ;; https://github.com/ruby-prof/ruby-prof/issues/276).
7655 (add-after 'extract-gemspec 'delete-flaky-test
7657 (delete-file "test/line_number_test.rb")
7658 (substitute* "ruby-prof.gemspec"
7659 (("\"test/line_number_test\\.rb\"\\.freeze, ") ""))
7661 (add-before 'check 'compile
7663 (invoke "rake" "compile"))))))
7665 (list bundler ruby-minitest ruby-rake-compiler ruby-rdoc))
7666 (synopsis "Fast code profiler for Ruby")
7667 (description "RubyProf is a fast code profiler for Ruby. Its features
7671 Being a C extension, it is many times faster than the standard Ruby profiler.
7672 @item Measurement Modes
7673 It can measure program wall time, process time, object allocations and memory
7676 A variety of text and cross-referenced HTML reports can be generated.
7678 Profiling multiple threads simultaneously is supported.
7680 (home-page "https://github.com/ruby-prof/ruby-prof")
7681 (license license:bsd-2)))
7683 (define-public ruby-memory-profiler
7685 (name "ruby-memory-profiler")
7691 (url "https://github.com/SamSaffron/memory_profiler")
7692 (commit (string-append "v" version))))
7693 (file-name (git-file-name name version))
7696 "07yqv11q68xg2fqkrhs6ysngryk8b9zq6qzh24rgx9xqv6qfnj0w"))))
7697 (build-system ruby-build-system)
7698 (synopsis "Memory profiling routines for Ruby")
7700 "This package provides memory profiling routines for Ruby.")
7701 (home-page "https://github.com/SamSaffron/memory_profiler")
7702 (license license:expat)))
7704 (define-public ruby-cucumber-messages
7706 (name "ruby-cucumber-messages")
7711 (url "https://github.com/cucumber/messages-ruby")
7712 (commit "12cd07eac87bce7843fd1bb0bf64bc4da09f097c")))
7713 (file-name (git-file-name name version))
7716 "16wwqfpsq7crvxc3q08lphgyh12cl2d83p1c79p312q4jmy9cn5a"))))
7717 (build-system ruby-build-system)
7719 `(#:phases (modify-phases %standard-phases
7720 (add-after 'unpack 'patch-protobuf.rb
7722 (substitute* "rake/protobuf.rb"
7723 (("load 'protobuf/tasks/compile.rake'")
7724 "require 'protobuf/tasks'"))
7726 (add-before 'build 'compile
7728 (substitute* "Makefile"
7729 (("bundle exec ") "")
7730 (("include default.mk.*" all)
7731 (string-append "#" all)))
7735 (invoke "rspec"))))))
7737 `(("ruby-protobuf" ,ruby-protobuf-cucumber)))
7740 (home-page "https://github.com/cucumber/messages-ruby")
7741 (synopsis "Cucumber Messages for Ruby (Protocol Buffers)")
7742 (description "Cucumber Messages for Ruby is a library which allows
7743 serialization and deserialization of the protocol buffer messages used in
7745 (license license:expat)))
7747 (define-public ruby-gherkin
7749 (name "ruby-gherkin")
7754 (url "https://github.com/cucumber/gherkin-ruby")
7755 (commit (string-append "v" version))))
7756 (file-name (git-file-name name version))
7759 "1dwa8632nc6kijv8p257jl64rsjmc0fimlaqvxlkdi2h9n1nympb"))))
7760 (build-system ruby-build-system)
7762 (list ruby-cucumber-messages ruby-rspec))
7764 `(#:test-target "spec"))
7765 (synopsis "Gherkin parser for Ruby")
7766 (description "Gherkin is a parser and compiler for the Gherkin language.
7767 It is intended be used by all Cucumber implementations to parse
7768 @file{.feature} files.")
7769 (home-page "https://github.com/cucumber/gherkin-ruby")
7770 (license license:expat)))
7772 (define-public ruby-gherkin-ruby
7774 (name "ruby-gherkin-ruby")
7776 (home-page "https://github.com/codegram/gherkin-ruby")
7779 (uri (rubygems-uri "gherkin-ruby" version))
7782 "18ay7yiibf4sl9n94k7mbi4k5zj2igl4j71qcmkswv69znyx0sn1"))))
7783 (build-system ruby-build-system)
7784 (synopsis "Pure Ruby Gherkin parser")
7786 "Gherkin-ruby is a Gherkin parser written in pure Ruby and less than
7787 200 lines of code.")
7788 ;; XXX: No license information anywhere but Readme.md.
7789 (license license:expat)))
7791 (define-public ruby-aruba
7798 (uri (rubygems-uri "aruba" version))
7801 "0l2mfpdxc03gdrbwc2hv4vdhjhqhfcdp6d02j05j64ncpi9srlqn"))))
7802 (build-system ruby-build-system)
7804 '(#:test-target "spec"
7806 (modify-phases %standard-phases
7807 (add-after 'unpack 'patch
7809 (substitute* "spec/aruba/api_spec.rb"
7810 ;; This resolves some errors in the specs
7812 ;; undefined method `parse' for Time:Class
7813 (("require 'spec_helper'")
7814 "require 'spec_helper'\nrequire 'time'"))
7815 ;; Avoid shebang issues in this spec file
7816 (substitute* "spec/aruba/matchers/command_spec.rb"
7817 (("/usr/bin/env bash")
7820 (add-before 'check 'remove-unnecessary-dependencies
7822 (substitute* "Gemfile"
7823 ((".*byebug.*") "\n")
7827 ((".*kramdown.*") "\n")
7828 ((".*rubocop.*") "\n")
7829 ((".*cucumber-pro.*") "\n")
7830 ((".*cucumber.*") "\n")
7831 ((".*license_finder.*") "\n")
7832 ((".*rake.*") "gem 'rake'\n")
7833 ((".*relish.*") "\n"))
7834 (substitute* "aruba.gemspec"
7835 (("spec\\.add\\_runtime\\_dependency 'cucumber'.*")
7836 "spec.add_runtime_dependency 'cucumber'"))
7838 (add-before 'check 'set-home
7839 (lambda _ (setenv "HOME" "/tmp") #t)))))
7841 (list bundler ruby-rspec ruby-fuubar ruby-simplecov))
7843 (list ruby-childprocess
7847 ruby-rspec-expectations
7850 (synopsis "Test command-line applications with Cucumber, RSpec or Minitest")
7852 "Aruba is an extension for Cucumber, RSpec and Minitest for testing
7853 command-line applications. It supports applications written in any
7855 (home-page "https://github.com/cucumber/aruba")
7856 (license license:expat)))
7858 ;; A version of ruby-aruba without tests run so that circular dependencies can
7860 (define ruby-aruba-without-tests
7862 (inherit ruby-aruba)
7863 (arguments '(#:tests? #f))
7865 `(("ruby-cucumber" ,ruby-cucumber-without-tests)
7866 ,@(alist-delete "ruby-cucumber"
7867 (package-propagated-inputs ruby-aruba))))
7868 (native-inputs '())))
7870 (define-public ruby-sys-uname
7872 (name "ruby-sys-uname")
7877 (uri (rubygems-uri "sys-uname" version))
7880 "00p3wwvkdbg6pl38bchaagncv3i4fq4y0ks470imwykjanpy2ic0"))))
7881 (build-system ruby-build-system)
7883 `(#:test-target "spec"))
7884 (propagated-inputs (list ruby-ffi))
7885 (native-inputs (list ruby-rspec))
7886 (synopsis "Ruby interface for gathering system information")
7887 (description "The sys-uname library provides an interface for gathering
7888 information about your current platform. It allows retrieving information
7889 such as the OS name, OS version, system name, etc.")
7890 (home-page "https://github.com/djberg96/sys-uname")
7891 (license license:asl2.0)))
7893 (define-public ruby-cucumber-create-meta
7895 (name "ruby-cucumber-create-meta")
7900 (uri (rubygems-uri "cucumber-create-meta" version))
7903 "0i0i3arymjrnjk72mg79w1a11607x4d0lrqafm9sz2gq9l52zasw"))))
7904 (build-system ruby-build-system)
7906 `(#:phases (modify-phases %standard-phases
7907 (add-after 'extract-gemspec 'relax-version-requirements
7909 (substitute* ".gemspec"
7915 (invoke "rspec"))))))
7919 (list ruby-cucumber-messages ruby-sys-uname))
7920 (synopsis "Function to create @code{Meta} messages for Cucumber Ruby")
7921 (description "The @code{createMeta} utility function allows generating
7922 system-specific @code{Meta} messages for Cucumber Ruby.")
7923 (home-page "https://github.com/cucumber/cucumber/tree/master/create-meta/ruby")
7924 (license license:expat)))
7926 (define-public ruby-cucumber-html-formatter
7928 (name "ruby-cucumber-html-formatter")
7933 (uri (rubygems-uri "cucumber-html-formatter" version))
7936 "0lshj4sw9jw7687wrhknyb9kffblai3l843zgrznyqij3ga0bc62"))))
7937 (build-system ruby-build-system)
7939 `(#:phases (modify-phases %standard-phases
7942 (invoke "rspec"))))))
7946 (list ruby-cucumber-messages))
7947 (synopsis "HTML formatter for Cucumber")
7948 (description "Cucumber HTML Formatter produces a HTML report for Cucumber
7949 runs. It is built on top of cucumber-react and works with any Cucumber
7950 implementation with a protocol buffer formatter that outputs Cucumber
7952 (home-page "https://github.com/cucumber/cucumber/tree/\
7953 master/html-formatter/ruby")
7954 (license license:expat)))
7956 (define-public ruby-cucumber
7958 (name "ruby-cucumber")
7964 (url "https://github.com/cucumber/cucumber-ruby")
7965 (commit (string-append "v" version))))
7966 (file-name (git-file-name name version))
7969 "0g9rqfslbzkkrq2kvl14fgknrhfbji3bjjpjxff5nc9wzd3hd549"))))
7970 (build-system ruby-build-system)
7972 '(#:test-target "default"
7974 (modify-phases %standard-phases
7975 (add-after 'unpack 'disable-rubocop
7976 ;; Rubocop lint check fails with our more recent version.
7978 (substitute* "Rakefile"
7979 (("spec cucumber rubocop")
7982 (add-after 'extract-gemspec 'strip-version-requirements
7984 (delete-file "Gemfile") ;do not use Bundler
7985 (substitute* "cucumber.gemspec"
7986 (("(.*add_.*dependency '[_A-Za-z0-9-]+').*" _ stripped)
7987 (string-append stripped "\n")))
7989 (add-before 'check 'set-home
7991 (setenv "HOME" (getcwd))
7996 ruby-cucumber-create-meta
7997 ruby-cucumber-html-formatter
7998 ruby-cucumber-messages
8005 (list ;; Use a untested version of aruba, to avoid a circular dependency, as
8006 ;; ruby-aruba depends on ruby-cucumber.
8007 ruby-aruba-without-tests
8012 (synopsis "Describe automated tests in plain language")
8013 (description "Cucumber is a tool for running automated tests written in
8014 plain language. It's designed to support a Behaviour Driven Development (BDD)
8015 software development workflow.")
8016 (home-page "https://cucumber.io/")
8017 (license license:expat)))
8019 (define ruby-cucumber-without-tests
8020 (package (inherit ruby-cucumber)
8026 (define-public ruby-coveralls
8028 (name "ruby-coveralls")
8033 (uri (rubygems-uri "coveralls" version))
8036 "1mv4fn5lfxhy7bc2f1lpnc5yp9mvv97az77j4r7jgrxcqwn8fqxc"))))
8037 (build-system ruby-build-system)
8038 ;; The test suite depends on ruby-vcr, which cannot be included in Guix
8039 ;; because of its nonfree, Hippocratic-derived license.
8042 #:phases (modify-phases %standard-phases
8043 (add-after 'extract-gemspec 'strip-version-requirements
8044 ;; Keeping strict version requirements can cause problems
8045 ;; to users of the library, such as: Gem::ConflictError:
8046 ;; Unable to activate coveralls-0.8.23, because
8047 ;; simplecov-0.17.1 conflicts with simplecov (~> 0.16.1).
8049 (substitute* "coveralls-ruby.gemspec"
8050 (("(.*add_.*dependency\\([^,]+), .*" _ stripped)
8051 (string-append stripped ")\n")))
8054 (list ruby-json ruby-term-ansicolor ruby-thor ruby-tins))
8055 (synopsis "Ruby implementation of the Coveralls API")
8056 (description "This package provides a Ruby implementation of the Coveralls
8058 (home-page "https://coveralls.io")
8059 (license license:expat)))
8061 (define-public ruby-unindent
8063 (name "ruby-unindent")
8068 (uri (rubygems-uri "unindent" version))
8071 "1wqh3rzv8589yzibigminxx3qpmj2nqj28f90xy1sczk1pijmcrd"))))
8072 (build-system ruby-build-system)
8073 (synopsis "Ruby method to unindent strings")
8074 (description "This module provides a @code{String#unindent} Ruby method to
8075 unindent strings, which can be useful to unindent multiline strings embedded
8076 in already-indented code.")
8077 (home-page "https://github.com/mynyml/unindent")
8078 (license license:expat)))
8080 (define-public ruby-cucumber-core
8082 (name "ruby-cucumber-core")
8088 (url "https://github.com/cucumber/cucumber-ruby-core")
8089 (commit (string-append "v" version))))
8090 (file-name (git-file-name name version))
8093 "1p5wb6wbggbw37ariyag4kxpiczznvgm3c8cnz1744dmbj79q1rn"))))
8094 (build-system ruby-build-system)
8096 `(#:test-target "spec"
8098 (modify-phases %standard-phases
8099 (add-after 'extract-gemspec 'relax-version-requirements
8101 (substitute* "cucumber-core.gemspec"
8102 (("'cucumber-tag-expressions',.*")
8103 "'cucumber-tag-expressions', '>=2.0.0'\n"))
8106 (list ruby-rspec ruby-coveralls ruby-rubocop ruby-simplecov
8109 (list ruby-cucumber-messages ruby-gherkin
8110 ruby-cucumber-tag-expressions))
8111 (synopsis "Core library for the Cucumber BDD app")
8112 (description "Cucumber is a tool for running automated tests
8113 written in plain language. Because they're written in plain language,
8114 they can be read by anyone on your team. Because they can be read by
8115 anyone, you can use them to help improve communication, collaboration
8116 and trust on your team.")
8117 (home-page "https://cucumber.io/")
8118 (license license:expat)))
8120 (define-public ruby-cucumber-expressions
8122 (name "ruby-cucumber-expressions")
8128 (url "https://github.com/cucumber/cucumber-expressions-ruby")
8129 (commit (string-append "v" version))))
8130 (file-name (git-file-name name version))
8133 "1aivhcpjrmbvp9bg0y7g6zxh2swfvylvg0sapq5jc4i1y74k8npd"))))
8134 (build-system ruby-build-system)
8136 '(#:test-target "spec"))
8138 (list ruby-rspec ruby-simplecov))
8139 (synopsis "Simpler alternative to Regular Expressions")
8140 (description "Cucumber Expressions offer similar functionality to Regular
8141 Expressions, with a syntax that is easier to read and write. Cucumber
8142 Expressions are extensible with parameter types.")
8143 (home-page "https://github.com/cucumber/cucumber-expressions-ruby")
8144 (license license:expat)))
8146 (define-public ruby-cucumber-wire
8148 (name "ruby-cucumber-wire")
8153 (uri (rubygems-uri "cucumber-wire" version))
8156 "0z1n13lqv70zb2lcrvs2263lm0gsb3gz8gbv890kxzwp8cvd433k"))))
8157 (build-system ruby-build-system)
8159 '(#:tests? #f ;tests use cucumber, causing a cycle
8161 (modify-phases %standard-phases
8162 (add-after 'extract-gemspec 'relax-version-requirements
8164 (substitute* ".gemspec"
8165 ((" 10\\.1") " 10.2"))
8168 (list ruby-cucumber-core ruby-cucumber-expressions
8169 ruby-cucumber-messages))
8170 (synopsis "Cucumber wire protocol plugin")
8171 (description "Cucumber's wire protocol allows step definitions to be
8172 implemented and invoked on any platform.")
8173 (home-page "https://github.com/cucumber/cucumber-ruby-wire")
8174 (license license:expat)))
8176 (define-public ruby-cucumber-tag-expressions
8178 (name "ruby-cucumber-tag-expressions")
8184 (url "https://github.com/cucumber/tag-expressions-ruby")
8185 (commit (string-append "v" version))))
8186 (file-name (git-file-name name version))
8189 "15dw4w0npd4m6aw7zhqkjxxzngp42kswrkwfygxkxcxnhy5zl1vx"))))
8190 (build-system ruby-build-system)
8192 `(#:test-target "spec"))
8195 (synopsis "Cucumber tag expressions for Ruby")
8196 (description "Cucumber tag expression parser for Ruby. A tag expression
8197 is an infix boolean expression used by Cucumber.")
8198 (home-page "https://github.com/cucumber/tag-expressions-ruby")
8199 (license license:expat)))
8201 (define-public ruby-bindex
8203 (name "ruby-bindex")
8208 (uri (rubygems-uri "bindex" version))
8211 "1wvhf4v8sk5x8li03pcc0v0wglmyv7ikvvg05bnms83dfy7s4k8i"))))
8212 (build-system ruby-build-system)
8214 '(#:test-target "default"))
8216 (list bundler ruby-rake-compiler))
8217 (synopsis "Provides access for bindings relating to Ruby exceptions")
8219 "@code{bindex} provides a way to access the bindings that relate to
8220 exceptions in Ruby, providing more information about the context in which the
8221 exception occurred.")
8222 (home-page "https://github.com/gsamokovarov/bindex")
8223 (license license:expat)))
8225 (define-public ruby-bio-logger
8227 (name "ruby-bio-logger")
8232 (uri (rubygems-uri "bio-logger" version))
8235 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
8236 (build-system ruby-build-system)
8238 `(#:tests? #f)) ; rake errors, missing shoulda
8241 (synopsis "Log4r wrapper for Ruby")
8242 (description "Bio-logger is a wrapper around Log4r adding extra logging
8243 features such as filtering and fine grained logging.")
8244 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
8245 (license license:expat)))
8247 (define-public ruby-yajl-ruby
8249 (name "ruby-yajl-ruby")
8254 (uri (rubygems-uri "yajl-ruby" version))
8257 "16v0w5749qjp13xhjgr2gcsvjv6mf35br7iqwycix1n2h7kfcckf"))))
8258 (build-system ruby-build-system)
8260 '(#:test-target "spec"
8262 (modify-phases %standard-phases
8263 (add-before 'check 'patch-test-to-update-load-path
8265 (substitute* "spec/parsing/large_number_spec.rb"
8266 (("require \"yajl\"")
8267 "$LOAD_PATH << 'lib'; require 'yajl'"))
8270 (list ruby-rake-compiler ruby-rspec))
8271 (synopsis "Streaming JSON parsing and encoding library for Ruby")
8273 "Ruby C bindings to the Yajl JSON stream-based parser library. The API
8274 is compatible with the JSON gem, so yajl-ruby can act as a drop in
8277 A modified copy of yajl is used, and included in the package.")
8278 (home-page "https://github.com/brianmario/yajl-ruby")
8279 (license (list license:expat ; Ruby code, yajl_ext.c and yajl_ext.h
8280 license:bsd-3)))) ; Included, modified copy of yajl
8282 (define-public ruby-yard
8289 ;; Tests do not pass if we build from the distributed gem.
8291 (url "https://github.com/lsegal/yard")
8292 (commit (string-append "v" version))))
8293 (file-name (git-file-name name version))
8296 "1x7y4s557hrnq439lih7nqg1y7ximardw75jx9i92x3yzpviqqwa"))))
8297 (build-system ruby-build-system)
8299 ;; Note: Tests are willfully disabled to alleviate dependency cycle
8302 #:phases (modify-phases %standard-phases
8303 (add-after 'unpack 'do-not-set-date-in-gemspec
8304 ;; Fix a reproducibility issue (see:
8305 ;; https://github.com/lsegal/yard/issues/1343).
8307 (substitute* "yard.gemspec"
8308 ((".*s\\.date.*") ""))
8310 (synopsis "Documentation generation tool for Ruby")
8311 (description "YARD is a documentation generation tool for the Ruby
8312 programming language. It enables the user to generate consistent, usable
8313 documentation that can be exported to a number of formats very easily, and
8314 also supports extending for custom Ruby constructs such as custom class level
8316 (home-page "https://yardoc.org")
8317 (license license:expat)))
8319 (define-public ruby-yard-with-tests
8322 (name "ruby-yard-with-tests")
8324 (substitute-keyword-arguments
8325 (strip-keyword-arguments '(#:tests?) (package-arguments ruby-yard))
8326 ((#:test-target _ "default") "default")
8327 ((#:phases phases '%standard-phases)
8328 `(modify-phases ,phases
8329 (add-before 'check 'prepare-for-tests
8330 (lambda* (#:key tests? #:allow-other-keys)
8332 (substitute* "Rakefile"
8333 ((".*[Ss]amus.*") ""))
8334 ;; Delete the Gemfile to avoid errors relating to it.
8335 (delete-file "Gemfile")
8336 ;; $HOME needs to be set to somewhere writeable for tests to
8338 (setenv "HOME" "/tmp"))))))))
8339 (native-inputs (list ruby-rspec ruby-rack ruby-redcloth ruby-asciidoctor))))
8341 (define-public ruby-spectroscope
8343 (name "ruby-spectroscope")
8348 (uri (rubygems-uri "spectroscope" version))
8351 "0iiid9sm110qhx0i1zkds710cvsnmhd308wbqa7slkzbq2akrb3y"))))
8352 (build-system ruby-build-system)
8355 (modify-phases %standard-phases
8358 (with-output-to-file ".test"
8367 Test.run :default do |run|
8368 run.files << 'spec/*_spec.rb'
8370 (invoke "ruby" "-Ilib" "-rrubytest" ".test"))))))
8372 (list ruby-ae ruby-rspec))
8374 (list ruby-rubytest))
8375 (synopsis "Behavior-Driven Development (BDD) framework built on RubyTest")
8376 (description "Spectroscope is a Behavior-Driven Development (BDD)
8377 framework built on RubyTest, designed to emulate RSpec in most respects. It
8378 is assertion framework independent so any number of assertion systems can be
8379 used, such as Assay or AE.")
8380 (home-page "http://rubyworks.github.com/spectroscope/")
8381 (license license:bsd-2)))
8383 (define-public ruby-tomparse
8385 (name "ruby-tomparse")
8390 (uri (rubygems-uri "tomparse" version))
8393 "06xakk41f1kgj6j1ahkwn4r6cvidixvm4phhlrvmwb7c3pr8ygc8"))))
8394 (build-system ruby-build-system)
8395 ;; TODO: Tests require citron and rulebow, not yet packaged.
8396 (arguments '(#:tests? #f))
8397 (synopsis "TomDoc parser for Ruby")
8398 (description "TomParse is a TomDoc parser for Ruby. It takes a code
8399 comment as input and parses it into a convenient object-oriented structure in
8400 accordance with the TomDoc standard. See
8401 @url{https://github.com/mojombo/tomdoc, TomDoc} for more information about the
8403 (home-page "http://rubyworks.github.com/tomparse/")
8404 (license license:bsd-2)))
8406 (define-public ruby-yard-tomdoc
8408 (name "ruby-yard-tomdoc")
8413 (uri (rubygems-uri "yard-tomdoc" version))
8416 "1725gs8b8klpwhrvnf2wwp7dw3zxs9vz2la983l2d8c4r4fn1j2z"))))
8417 (build-system ruby-build-system)
8419 `(#:phases (modify-phases %standard-phases
8422 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
8424 (list ruby-rubytest-cli ruby-spectroscope ruby-ae))
8426 (list ruby-tomparse ruby-yard))
8427 (synopsis "TomDoc syntax for YARD")
8428 (description "This module adds support for the TomDoc documentation format
8429 to YARD, a documentation generation tool for Ruby.")
8430 (home-page "http://rubyworks.github.com/yard-tomdoc/")
8431 (license license:expat)))
8433 (define-public ruby-clap
8439 (uri (rubygems-uri "clap" version))
8442 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
8443 (build-system ruby-build-system)
8444 ;; Clap needs cutest for running tests, but cutest needs clap.
8445 (arguments `(#:tests? #f))
8446 (synopsis "Command line argument parsing for simple applications")
8448 "Clap provides command line argument parsing features. It covers the
8449 simple case of executing code based on the flags or parameters passed.")
8450 (home-page "https://github.com/djanowski/cutest")
8451 (license license:expat)))
8453 (define-public ruby-cutest
8455 (name "ruby-cutest")
8459 (uri (rubygems-uri "cutest" version))
8462 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
8463 (build-system ruby-build-system)
8466 (synopsis "Run tests in separate processes")
8468 "Cutest runs tests in separate processes to avoid shared state.")
8469 (home-page "https://github.com/djanowski/cutest")
8470 (license license:expat)))
8472 (define-public ruby-pygmentize
8474 (name "ruby-pygmentize")
8478 (uri (rubygems-uri "pygmentize" version))
8481 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
8482 (build-system ruby-build-system)
8485 (modify-phases %standard-phases
8486 (add-after 'unpack 'fix-pygmentize-path
8488 (substitute* "lib/pygmentize.rb"
8489 (("\"/usr/bin/env python.*")
8490 (string-append "\"" (which "pygmentize") "\"\n")))
8492 (add-after 'build 'do-not-use-vendor-directory
8494 ;; Remove bundled pygments sources
8495 ;; FIXME: ruby-build-system does not support snippets.
8496 (delete-file-recursively "vendor")
8497 (substitute* "pygmentize.gemspec"
8498 (("\"vendor/\\*\\*/\\*\",") ""))
8501 `(("pygments" ,python-pygments)))
8503 (list ruby-cutest ruby-nokogiri))
8504 (synopsis "Thin Ruby wrapper around pygmentize")
8506 "Pygmentize provides a simple way to call pygmentize from within a Ruby
8508 (home-page "https://github.com/djanowski/pygmentize")
8509 (license license:expat)))
8511 (define-public ruby-eventmachine
8513 (name "ruby-eventmachine")
8518 (uri (rubygems-uri "eventmachine" version))
8521 "0wh9aqb0skz80fhfn66lbpr4f86ya2z5rx6gm5xlfhd05bj1ch4r"))))
8522 (build-system ruby-build-system)
8524 '(#:tests? #f)) ; test suite tries to connect to google.com
8528 (list ruby-rake-compiler))
8529 (synopsis "Single-threaded network event framework for Ruby")
8531 "EventMachine implements a single-threaded engine for arbitrary network
8532 communications. EventMachine wraps all interactions with sockets, allowing
8533 programs to concentrate on the implementation of network protocols. It can be
8534 used to create both network servers and clients.")
8535 ;; The ‘official’ rubyeventmachine.com domain is now registrar-squatted.
8536 (home-page "https://github.com/eventmachine/eventmachine")
8537 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
8539 (define-public ruby-ruby-engine
8541 (name "ruby-ruby-engine")
8546 (uri (rubygems-uri "ruby_engine" version))
8549 "0wqdcv8gxybp1y7kjhh18g3r9dczacs62d4ahcvyhz32bih8c9fm"))))
8550 (build-system ruby-build-system)
8553 (modify-phases %standard-phases
8554 (add-after 'extract-gemspec 'clean-up
8556 (delete-file "Gemfile.lock")
8557 (substitute* "ruby_engine.gemspec"
8558 ;; Remove unnecessary imports that would entail further
8561 ((".*<rubygems-tasks.*") "")
8562 ;; Remove extraneous .gem file
8563 (("\"pkg/ruby_engine-[0-9.]+\\.gem\".freeze, ") "")
8564 (("\"Gemfile.lock\".freeze, ") "")
8565 ;; Soften rake dependency
8566 (("%q<rake>.freeze, \\[\"~> 10.0\"\\]")
8567 "%q<rake>.freeze, [\">= 10.0\"]")
8568 ;; Soften the rspec dependency
8569 (("%q<rspec>.freeze, \\[\"~> 2.4\"\\]")
8570 "%q<rspec>.freeze, [\">= 2.4\"]"))
8571 (substitute* "Rakefile"
8572 (("require 'rubygems/tasks'") "")
8573 (("Gem::Tasks.new") ""))
8574 ;; Remove extraneous .gem file that otherwise gets installed.
8575 (delete-file-recursively "pkg")
8578 (list bundler ruby-rake ruby-rspec))
8579 (synopsis "Simplifies checking for Ruby implementation")
8581 "@code{ruby_engine} provides an RubyEngine class that can be used to
8582 check which implementation of Ruby is in use. It can provide the interpreter
8583 name and provides query methods such as @{RubyEngine.mri?}.")
8584 (home-page "https://github.com/janlelis/ruby_engine")
8585 (license license:expat)))
8587 (define-public ruby-turn
8594 (uri (rubygems-uri "turn" version))
8597 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
8598 (build-system ruby-build-system)
8601 (modify-phases %standard-phases
8602 ;; Tests fail because turn changes its environment so can no longer
8603 ;; find test/unit. Instead simply test if the executable runs
8607 (invoke "ruby" "-Ilib" "bin/turn" "-h"))))))
8609 (list ruby-ansi ruby-minitest-4))
8610 (synopsis "Alternate set of alternative runners for MiniTest")
8612 "TURN provides a set of alternative runners for MiniTest which are both
8613 colorful and informative. TURN displays each test on a separate line with
8614 failures being displayed immediately instead of at the end of the tests. Note
8615 that TURN is no longer being maintained.")
8616 (home-page "https://rubygems.org/gems/turn")
8617 (license license:expat)))
8619 (define-public ruby-mimemagic
8621 (name "ruby-mimemagic")
8626 (uri (rubygems-uri "mimemagic" version))
8628 (base32 "04cp5sfbh1qx82yqxn0q75c7hlcx8y1dr5g3kyzwm4mx6wi2gifw"))))
8629 (build-system ruby-build-system)
8632 (modify-phases %standard-phases
8633 ;; This phase breaks the tests, as it patches some of the test data.
8634 (delete 'patch-source-shebangs))))
8637 (synopsis "Ruby library for MIME detection by extension or content")
8639 "@acronym{MIME, Multipurpose Internet Mail Extensions} detection by
8640 extension or content, using the freedesktop.org.xml shared-mime-info
8642 (home-page "https://github.com/minad/mimemagic")
8643 (license license:expat)))
8645 (define-public ruby-mime-types-data
8647 (name "ruby-mime-types-data")
8648 (version "3.2016.0521")
8652 (uri (rubygems-uri "mime-types-data" version))
8655 "04my3746hwa4yvbx1ranhfaqkgf6vavi1kyijjnw8w3dy37vqhkm"))))
8656 (build-system ruby-build-system)
8659 (synopsis "Registry for information about MIME media type definitions")
8661 "@code{mime-types-data} provides a registry for information about
8662 Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
8663 be used with the Ruby mime-types library or other software to determine
8664 defined filename extensions for MIME types, or to use filename extensions to
8665 look up the likely MIME type definitions.")
8666 (home-page "https://github.com/mime-types/mime-types-data/")
8667 (license license:expat)))
8669 (define-public ruby-mime-types
8671 (name "ruby-mime-types")
8676 (uri (rubygems-uri "mime-types" version))
8679 "0087z9kbnlqhci7fxh9f6il63hj1k02icq2rs0c6cppmqchr753m"))))
8680 (build-system ruby-build-system)
8682 (list ruby-mime-types-data))
8688 ruby-minitest-bonus-assertions
8689 ruby-minitest-hooks))
8690 (synopsis "Library and registry for MIME content type definitions")
8691 (description "The mime-types library provides a library and registry for
8692 information about Multipurpose Internet Mail Extensions (MIME) content type
8693 definitions. It can be used to determine defined filename extensions for MIME
8694 types, or to use filename extensions to look up the likely MIME type
8696 (home-page "https://github.com/mime-types/ruby-mime-types")
8697 (license license:expat)))
8699 (define-public ruby-mini-mime
8701 (name "ruby-mini-mime")
8706 (uri (rubygems-uri "mini_mime" version))
8709 "1axm0rxyx3ss93wbmfkm78a6x03l8y4qy60rhkkiq0aza0vwq3ha"))))
8710 (build-system ruby-build-system)
8711 (synopsis "Lightweight mime type lookup toy")
8712 (description "This package provides a lightweight mime type lookup toy.")
8713 (home-page "https://github.com/discourse/mini_mime")
8714 (license license:expat)))
8716 (define-public ruby-fivemat
8718 (name "ruby-fivemat")
8723 (uri (rubygems-uri "fivemat" version))
8726 "0pzlycasvwmg4bbx7plllpqnhd9zlmmff8l2w3yii86nrm2nvf9n"))))
8727 (build-system ruby-build-system)
8729 `(#:tests? #f)) ; no tests
8730 (synopsis "Each test file given its own line of dots")
8732 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
8733 its own line of dots during testing. It aims to provide test output that is
8734 neither too verbose nor too minimal.")
8735 (home-page "https://github.com/tpope/fivemat")
8736 (license license:expat)))
8738 (define-public ruby-sqlite3
8740 (name "ruby-sqlite3")
8745 (uri (rubygems-uri "sqlite3" version))
8748 "0lja01cp9xd5m6vmx99zwn4r7s97r1w5cb76gqd8xhbm1wxyzf78"))))
8749 (build-system ruby-build-system)
8752 (modify-phases %standard-phases
8753 (add-before 'check 'add-gemtest-file
8754 ;; This file exists in the repository but is not distributed.
8755 (lambda _ (invoke "touch" ".gemtest"))))))
8759 (list ruby-hoe ruby-rake-compiler ruby-mini-portile))
8760 (synopsis "Interface with SQLite3 databases")
8762 "This module allows Ruby programs to interface with the SQLite3 database
8765 "https://github.com/sparklemotion/sqlite3-ruby")
8766 (license license:bsd-3)))
8768 (define-public ruby-shoulda-context
8770 (name "ruby-shoulda-context")
8775 (uri (rubygems-uri "shoulda-context" version))
8778 "1l0ncsxycb4s8n47dml97kdnixw4mizljbkwqc3rh05r70csq9bc"))))
8779 (build-system ruby-build-system)
8782 (modify-phases %standard-phases
8785 ;; Do not run tests to avoid circular dependence with rails.
8786 ;; Instead just import the library to test.
8787 (invoke "ruby" "-Ilib" "-r" "shoulda-context"))))))
8788 (synopsis "Test::Unit context framework extracted from Shoulda")
8790 "@code{shoulda-context} is the context framework extracted from Shoulda.
8791 Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
8792 context, setup, and should blocks combine to produce natural test method
8794 (home-page "https://github.com/thoughtbot/shoulda-context")
8795 (license license:expat)))
8797 (define-public ruby-shoulda-matchers
8799 (name "ruby-shoulda-matchers")
8804 (uri (rubygems-uri "shoulda-matchers" version))
8807 "1zvv94pqk5b5my3w1shdz7h34xf2ldhg5k4qfdpbwi2iy0j9zw2a"))))
8808 (build-system ruby-build-system)
8811 (modify-phases %standard-phases
8814 ;; Do not run tests to avoid circular dependence with rails. Instead
8815 ;; just import the library to test.
8816 (invoke "ruby" "-Ilib" "-r" "shoulda-matchers"))))))
8818 (list ruby-activesupport))
8819 (synopsis "Collection of testing matchers extracted from Shoulda")
8821 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
8822 test common Rails functionality. These tests would otherwise be much longer,
8823 more complex, and error-prone.")
8824 (home-page "https://github.com/thoughtbot/shoulda-matchers")
8825 (license license:expat)))
8827 (define-public ruby-shoulda-matchers-2
8829 (inherit ruby-shoulda-matchers)
8833 (uri (rubygems-uri "shoulda-matchers" version))
8836 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
8838 (define-public ruby-shoulda
8840 (name "ruby-shoulda")
8845 (uri (rubygems-uri "shoulda" version))
8848 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
8849 (build-system ruby-build-system)
8852 (modify-phases %standard-phases
8854 ;; Don't run tests to avoid circular dependence with rails. Instead
8855 ;; just import the library to test.
8856 (lambda _ (invoke "ruby" "-Ilib" "-r" "shoulda"))))))
8858 (list ruby-shoulda-context ruby-shoulda-matchers-2))
8859 (synopsis "Context framework and matchers for testing")
8861 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
8862 @code{shoulda-matchers} providing tools for writing tests.")
8863 (home-page "https://github.com/thoughtbot/shoulda")
8864 (license license:expat)))
8866 (define-public ruby-unf
8873 (uri (rubygems-uri "unf" version))
8876 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
8877 (build-system ruby-build-system)
8880 (modify-phases %standard-phases
8881 (add-before 'check 'add-dependency-to-bundler
8883 ;; test-unit is required but not provided by the bundler
8884 ;; environment. This is fixed in the upstream repository but fix
8885 ;; has not been released.
8886 (substitute* "Gemfile"
8887 (("^gemspec") "gem 'test-unit'\ngemspec"))
8890 (list ruby-unf-ext))
8892 (list ruby-shoulda bundler ruby-test-unit))
8893 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
8895 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
8896 support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
8897 @code{java.text.Normalizer} on JRuby.")
8898 (home-page "https://github.com/knu/ruby-unf")
8899 (license license:bsd-2)))
8901 (define-public ruby-warden
8903 (name "ruby-warden")
8908 (uri (rubygems-uri "warden" version))
8911 "1fr9n9i9r82xb6i61fdw4xgc7zjv7fsdrr4k0njchy87iw9fl454"))))
8912 (build-system ruby-build-system)
8914 '(#:tests? #f)) ; No included tests
8917 (synopsis "Rack middleware providing authentication")
8919 "Warden is a Rack-based middleware that provides a mechanism for
8920 authentication in Ruby web applications.")
8921 (home-page "https://github.com/wardencommunity/warden")
8922 (license license:expat)))
8924 (define-public ruby-warden-oauth2
8926 (name "ruby-warden-oauth2")
8931 (uri (rubygems-uri "warden-oauth2" version))
8934 "1z9154lvzrnnfjbjkmirh4n811nygp6pm2fa6ikr7y1ysa4zv3cz"))))
8935 (build-system ruby-build-system)
8937 '(#:test-target "spec"
8939 (modify-phases %standard-phases
8940 (add-after 'unpack 'remove-unnecessary-dependencies
8942 (substitute* "Gemfile"
8943 ;; All of these gems relate to development, and are unnecessary
8944 ;; when running the tests
8945 (("gem 'guard-bundler'") "")
8946 (("gem 'guard'") "")
8947 (("gem 'guard-rspec'") "")
8948 (("gem 'rb-fsevent'") "")
8950 (("gem 'growl'") ""))
8952 ;; The test suite doesn't work with rspec@2, and this is incompatible
8953 ;; with the current version of Rake, so invoke Rspec directly
8955 (lambda* (#:key tests? #:allow-other-keys)
8957 (invoke "bundle" "exec" "rspec"))
8962 (list bundler ruby-rspec-2 ruby-rack-test))
8963 (synopsis "OAuth 2.0 strategies for Warden")
8965 "This library extends Warden to support OAuth 2.0 authorized API
8967 (home-page "https://github.com/opperator/warden-oauth2")
8968 (license license:expat)))
8970 (define-public ruby-webmock
8972 (name "ruby-webmock")
8977 (uri (rubygems-uri "webmock" version))
8980 "1hdlbvfw316lkz251qnfk79drmaay7l51kidvicz41nhvw12xz8v"))))
8981 (build-system ruby-build-system)
8983 (list bundler ruby-rspec))
8985 (list ruby-addressable ruby-crack ruby-hashdiff))
8986 (synopsis "Allows stubbing and setting expectations on HTTP requests")
8988 "WebMock allows stubbing HTTP requests and setting expectations on HTTP
8989 requests. This is useful when testing software.")
8990 (home-page "https://github.com/bblimke/webmock")
8991 (license license:expat)))
8993 (define-public ruby-webmock-2
8995 (inherit ruby-webmock)
8996 (name "ruby-webmock")
9001 (uri (rubygems-uri "webmock" version))
9004 "04hkcqsmbfnp8g237pisnc834vpgildklicbjbyikqg0bg1rwcy5"))))))
9006 (define-public ruby-unicode-display-width
9008 (name "ruby-unicode-display-width")
9013 (uri (rubygems-uri "unicode-display_width" version))
9016 "08kfiniak1pvg3gn5k6snpigzvhvhyg7slmm0s2qx5zkj62c1z2w"))))
9017 (build-system ruby-build-system)
9019 '(;; Test data not included.
9021 (synopsis "Determine the monospace display width of Ruby strings")
9023 "@code{Unicode::DisplayWidth} is a Ruby library which can determine the
9024 display width of strings in Ruby.")
9025 (home-page "https://github.com/janlelis/unicode-display_width")
9026 (license license:expat)))
9028 ;; There is another gem called 'ruby-version' so we use an underscore in this
9030 (define-public ruby_version
9032 (name "ruby_version")
9037 (uri (rubygems-uri "ruby_version" version))
9040 "0lvc7bd5ps3w2vq2wb02i0pi3vfcx2rnckx2ix4rjym1qf52kb2j"))))
9041 (build-system ruby-build-system)
9044 (modify-phases %standard-phases
9045 (add-before 'check 'fix-dependencies
9047 ;; Remove the Gemfile.lock, as we want to use Guix packages at
9048 ;; whatever versions.
9049 (delete-file "Gemfile.lock")
9050 ;; Remove the included gem files as they unnecessary.
9051 (delete-file-recursively "pkg/")
9052 ;; Accept any version of rake, rdoc and rspec
9053 (substitute* "ruby_version.gemspec"
9054 (("%q<rake.*") "%q<rake>)\n")
9055 (("%q<rdoc.*") "%q<rdoc>)\n")
9056 (("%q<rspec.*") "%q<rspec>)\n"))
9057 ;; Do not use bundler.
9058 (substitute* "Rakefile"
9059 (("Bundler\\.setup.*") "nil\n"))
9062 (list ruby-rdoc ruby-rspec ruby-rubygems-tasks))
9063 (synopsis "Ruby library to help check the Ruby version")
9064 (description "@code{ruby_version} provides a @code{RubyVersion} module to simplify
9065 checking for the right Ruby version in software.")
9066 (home-page "https://github.com/janlelis/ruby_version")
9067 (license license:expat)))
9069 (define-public ruby-websocket-driver
9071 (name "ruby-websocket-driver")
9076 (uri (rubygems-uri "websocket-driver" version))
9078 (base32 "1bxamwqldmy98hxs5pqby3andws14hl36ch78g0s81gaz9b91nj2"))))
9079 (build-system ruby-build-system)
9081 '(#:tests? #f)) ; no included tests
9083 (list ruby-websocket-extensions))
9084 (synopsis "WebSocket protocol handler with pluggable I/O")
9086 "@code{websocket-driver} provides a complete implementation of the
9087 WebSocket protocols that can be hooked up to any TCP library")
9088 (home-page "https://github.com/faye/websocket-driver-ruby")
9089 (license license:expat)))
9091 (define-public ruby-websocket-extensions
9093 (name "ruby-websocket-extensions")
9098 (uri (rubygems-uri "websocket-extensions" version))
9101 "034sdr7fd34yag5l6y156rkbhiqgmy395m231dwhlpcswhs6d270"))))
9102 (build-system ruby-build-system)
9104 '(;; No included tests
9106 (synopsis "Generic extension manager for WebSocket connections")
9108 "@code{websocket-extensions} provides a container for registering
9109 extension plugins.")
9110 (home-page "https://github.com/faye/websocket-extensions-ruby")
9111 (license license:expat)))
9113 (define-public ruby-domain-name
9115 (name "ruby-domain-name")
9116 (version "0.5.20190701")
9120 (uri (rubygems-uri "domain_name" version))
9122 (base32 "0lcqjsmixjp52bnlgzh4lg9ppsk52x9hpwdjd53k8jnbah2602h0"))))
9123 (build-system ruby-build-system)
9126 (modify-phases %standard-phases
9127 (add-before 'check 'fix-versions
9129 ;; Fix NameError that appears to already be fixed upstream.
9130 (substitute* "Rakefile"
9131 (("DomainName::VERSION")
9132 "Bundler::GemHelper.gemspec.version"))
9133 ;; Loosen unnecessarily strict test-unit version specification.
9134 (substitute* "domain_name.gemspec"
9135 (("<test-unit>.freeze, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
9140 (list ruby-shoulda bundler ruby-test-unit))
9141 (synopsis "Domain name manipulation library")
9143 "@code{domain_name} is a Domain name manipulation library. It parses a
9144 domain name ready for extracting the registered domain and TLD (Top Level
9145 Domain). It can also be used for cookie domain validation based on the Public
9147 (home-page "https://github.com/knu/ruby-domain_name")
9148 (license license:bsd-2)))
9150 (define-public ruby-http-cookie
9152 (name "ruby-http-cookie")
9157 (uri (rubygems-uri "http-cookie" version))
9160 "004cgs4xg5n6byjs7qld0xhsjq3n6ydfh897myr2mibvh6fjc49g"))))
9161 (build-system ruby-build-system)
9164 (modify-phases %standard-phases
9165 (add-before 'check 'add-dependency-to-bundler
9168 (substitute* "Rakefile"
9169 (("HTTP::Cookie::VERSION")
9170 "Bundler::GemHelper.gemspec.version"))
9173 (list ruby-domain-name))
9175 `(("rubysimplecov" ,ruby-simplecov)
9176 ("bundler" ,bundler)
9177 ("ruby-sqlite3" ,ruby-sqlite3)
9178 ("ruby-test-unit" ,ruby-test-unit)))
9179 (synopsis "Handle HTTP Cookies based on RFC 6265")
9181 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
9182 RFC 6265. It has been designed with security, standards compliance and
9183 compatibility in mind, to behave just the same as today's major web browsers.
9184 It has built-in support for the legacy @code{cookies.txt} and
9185 @code{cookies.sqlite} formats of Mozilla Firefox.")
9186 (home-page "https://github.com/sparklemotion/http-cookie")
9187 (license license:expat)))
9189 (define-public ruby-httpclient
9191 (name "ruby-httpclient")
9196 (uri (rubygems-uri "httpclient" version))
9199 "19mxmvghp7ki3klsxwrlwr431li7hm1lczhhj8z4qihl2acy8l99"))))
9200 (build-system ruby-build-system)
9202 '(;; TODO: Some tests currently fail
9204 ;; 211 tests, 729 assertions, 13 failures, 4 errors, 0 pendings,
9205 ;; 2 omissions, 0 notifications
9208 ;; 6.49 tests/s, 22.41 assertions/s
9211 (modify-phases %standard-phases
9213 (lambda* (#:key tests? #:allow-other-keys)
9222 "Make HTTP requests with support for HTTPS, Cookies, authentication and more")
9224 "The @code{httpclient} ruby library provides functionality related to
9225 HTTP. Compared to the @code{net/http} library, @{httpclient} also provides
9226 Cookie, multithreading and authentication (digest, NTLM) support.
9228 Also provided is a @command{httpclient} command, which can perform HTTP
9229 requests either using arguments or with an interactive prompt.")
9230 (home-page "https://github.com/nahi/httpclient")
9231 (license license:ruby)))
9233 (define-public ruby-ansi
9240 ;; Fetch from GitHub as the gem does not contain testing code.
9242 (url "https://github.com/rubyworks/ansi")
9244 (file-name (git-file-name name version))
9247 "1wsz7xxwl3vkh277jb7fd7akqnqqgbvalxzpjwniiqk8ghfprbi5"))))
9248 (build-system ruby-build-system)
9251 (modify-phases %standard-phases
9252 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
9253 ;; cycle ansi, qed, ansi. Instead simply test that the library can
9257 (invoke "ruby" "-Ilib" "-r" "ansi")))
9258 (add-before 'validate-runpath 'replace-broken-symlink
9259 (lambda* (#:key outputs #:allow-other-keys)
9260 (let* ((out (assoc-ref outputs "out"))
9261 (file (string-append
9262 out "/lib/ruby/vendor_ruby/gems/ansi-"
9263 ,version "/lib/ansi.yml")))
9264 ;; XXX: This symlink is broken since ruby 2.4.
9265 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9267 (symlink "../.index" file)
9269 (synopsis "ANSI escape code related libraries")
9271 "This package is a collection of ANSI escape code related libraries
9272 enabling ANSI colorization and stylization of console output. Included in the
9273 library are the @code{Code} module, which defines ANSI codes as constants and
9274 methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
9275 @code{ProgressBar}, and a @code{String} subclass. The library also includes a
9276 @code{Terminal} module which provides information about the current output
9278 (home-page "https://rubyworks.github.io/ansi/")
9279 (license license:bsd-2)))
9281 (define-public ruby-systemu
9283 (name "ruby-systemu")
9288 (uri (rubygems-uri "systemu" version))
9291 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
9292 (build-system ruby-build-system)
9295 (modify-phases %standard-phases
9296 (add-before 'check 'set-version
9298 (setenv "VERSION" ,version)
9300 (synopsis "Capture of stdout/stderr and handling of child processes")
9302 "Systemu can be used on any platform to return status, stdout, and stderr
9303 of any command. Unlike other methods like @code{open3} and @code{popen4}
9304 there is no danger of full pipes or threading issues hanging your process or
9306 (home-page "https://github.com/ahoward/systemu")
9307 (license license:ruby)))
9309 (define-public ruby-bio-commandeer
9311 (name "ruby-bio-commandeer")
9316 (uri (rubygems-uri "bio-commandeer" version))
9319 "0khpfw1yl5l3d2m8nxpkk32ybc4c3pa5hic3agd160jdfjjjnlni"))))
9320 (build-system ruby-build-system)
9323 (modify-phases %standard-phases
9325 ;; Run test without calling 'rake' so that jeweler is
9326 ;; not required as an input.
9328 (invoke "rspec" "spec/bio-commandeer_spec.rb"))))))
9330 (list ruby-bio-logger ruby-systemu))
9332 (list bundler ruby-rspec))
9333 (synopsis "Simplified running of shell commands from within Ruby")
9335 "Bio-commandeer provides an opinionated method of running shell commands
9336 from within Ruby. The advantage of bio-commandeer over other methods of
9337 running external commands is that when something goes wrong, messages printed
9338 to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
9339 detail to ease debugging.")
9340 (home-page "https://github.com/wwood/bioruby-commandeer")
9341 (license license:expat)))
9343 (define-public ruby-rubytest
9345 (name "ruby-rubytest")
9350 (uri (rubygems-uri "rubytest" version))
9353 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
9354 (build-system ruby-build-system)
9356 ;; Disable regular testing to break the cycle rubytest, qed, brass,
9357 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
9358 ;; simply test that the library can be require'd.
9360 (modify-phases %standard-phases
9363 (invoke "ruby" "-Ilib" "-r" "rubytest"))))))
9366 (synopsis "Universal test harness for Ruby")
9368 "Rubytest is a testing meta-framework for Ruby. It can handle any
9369 compliant test framework and can run tests from multiple frameworks in a
9371 (home-page "https://rubyworks.github.io/rubytest")
9372 (license license:bsd-2)))
9374 (define-public ruby-brass
9381 (uri (rubygems-uri "brass" version))
9384 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
9385 (build-system ruby-build-system)
9387 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
9388 ;; Instead simply test that the library can be require'd.
9390 (modify-phases %standard-phases
9393 (invoke "ruby" "-Ilib" "-r" "brass"))))))
9394 (synopsis "Basic foundational assertions framework")
9396 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
9397 foundational assertions framework for other assertion and test frameworks to
9399 (home-page "https://rubyworks.github.io/brass")
9400 (license license:bsd-2)))
9402 (define-public ruby-qed
9409 (uri (rubygems-uri "qed" version))
9412 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
9413 (build-system ruby-build-system)
9415 ;; Disable testing to break the cycle qed, ansi, qed, among others.
9416 ;; Instead simply test that the executable runs using --copyright.
9418 (modify-phases %standard-phases
9421 (invoke "ruby" "-Ilib" "bin/qed" "--copyright"))))))
9423 (list ruby-ansi ruby-brass))
9424 (synopsis "Test framework utilizing literate programming techniques")
9426 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
9427 @dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
9428 Development} (BDD) utilizing Literate Programming techniques. QED sits
9429 somewhere between lower-level testing tools like @code{Test::Unit} and
9430 requirement specifications systems like Cucumber.")
9431 (home-page "https://rubyworks.github.io/qed")
9432 (license license:bsd-2)))
9434 (define-public ruby-que
9437 (version "1.0.0.beta3")
9441 (uri (rubygems-uri "que" version))
9444 "0gr9pb814d4qj3ds98g6cjrdk7wv0yg8aqbm7c1lmgl87jkg8q04"))))
9445 (build-system ruby-build-system)
9447 '(#:tests? #f)) ; No included tests
9448 (synopsis "Job queue using PostgreSQL written in Ruby")
9450 "This package provides a job queue that uses PostgreSQL for storing jobs
9451 and locking between worker processes.")
9452 (home-page "https://github.com/chanks/que")
9453 (license license:expat)))
9455 (define-public ruby-ae
9462 ;; Fetch from github so tests are included.
9464 (url "https://github.com/rubyworks/ae")
9466 (file-name (git-file-name name version))
9469 "11299jj5ma8mi7b4majkyjy70y6zlqpgl8aql1c5lvfjavlpwmlp"))))
9470 (build-system ruby-build-system)
9473 (modify-phases %standard-phases
9475 (lambda _ (invoke "qed")))
9476 (add-before 'validate-runpath 'replace-broken-symlink
9477 (lambda* (#:key outputs #:allow-other-keys)
9478 (let* ((out (assoc-ref outputs "out"))
9479 (file (string-append
9480 out "/lib/ruby/vendor_ruby/gems/ae-"
9481 ,version "/lib/ae.yml")))
9482 ;; XXX: This symlink is broken since ruby 2.4.
9483 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
9485 (symlink "../.index" file)
9491 (synopsis "Assertions library")
9493 "Assertive Expressive (AE) is an assertions library specifically designed
9494 for reuse by other test frameworks.")
9495 (home-page "https://rubyworks.github.io/ae/")
9496 (license license:bsd-2)))
9498 (define-public ruby-lemon
9505 (uri (rubygems-uri "lemon" version))
9508 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
9509 (build-system ruby-build-system)
9512 (modify-phases %standard-phases
9513 (replace 'check (lambda _ (invoke "qed"))))))
9515 (list ruby-ae ruby-ansi ruby-rubytest))
9518 (synopsis "Test framework correlating code structure and test unit")
9520 "Lemon is a unit testing framework that enforces highly formal
9521 case-to-class and unit-to-method test construction. This enforcement can help
9522 focus concern on individual units of behavior.")
9523 (home-page "https://rubyworks.github.io/lemon")
9524 (license license:bsd-2)))
9526 (define-public ruby-rubytest-cli
9528 (name "ruby-rubytest-cli")
9533 (uri (rubygems-uri "rubytest-cli" version))
9536 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
9537 (build-system ruby-build-system)
9539 `(#:tests? #f)) ; no tests
9541 (list ruby-ansi ruby-rubytest))
9542 (synopsis "Command-line interface for rubytest")
9544 "Rubytest CLI is a command-line interface for running tests for
9545 Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
9546 (home-page "https://rubyworks.github.io/rubytest-cli")
9547 (license license:bsd-2)))
9549 (define-public ruby-hashery
9551 (name "ruby-hashery")
9556 (uri (rubygems-uri "hashery" version))
9559 "0qj8815bf7q6q7llm5rzdz279gzmpqmqqicxnzv066a020iwqffj"))))
9560 (build-system ruby-build-system)
9563 (modify-phases %standard-phases
9567 (invoke "rubytest" "-Ilib" "-Itest" "test/"))))))
9569 (list ruby-rubytest-cli ruby-qed ruby-lemon))
9570 (synopsis "Hash-like classes with extra features")
9572 "The Hashery is a tight collection of @code{Hash}-like classes.
9573 Included are the auto-sorting @code{Dictionary} class, the efficient
9574 @code{LRUHash}, the flexible @code{OpenHash} and the convenient
9575 @code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
9576 defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
9577 standard @code{Hash} making it possible to subclass and augment to fit any
9578 specific use case.")
9579 (home-page "https://rubyworks.github.io/hashery")
9580 (license license:bsd-2)))
9582 (define-public ruby-rc4
9589 (uri (rubygems-uri "ruby-rc4" version))
9592 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
9593 (build-system ruby-build-system)
9596 (modify-phases %standard-phases
9599 (invoke "rspec" "spec/rc4_spec.rb"))))))
9601 (list ruby-rspec-2))
9602 (synopsis "Implementation of the RC4 algorithm")
9604 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
9605 (home-page "https://github.com/caiges/Ruby-RC4")
9606 (license license:expat)))
9608 (define-public ruby-afm
9615 (uri (rubygems-uri "afm" version))
9618 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
9619 (build-system ruby-build-system)
9622 (synopsis "Read Adobe Font Metrics (afm) files")
9624 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
9625 files and use the data therein.")
9626 (home-page "https://github.com/halfbyte/afm")
9627 (license license:expat)))
9629 (define-public ruby-ascii85
9631 (name "ruby-ascii85")
9636 (uri (rubygems-uri "Ascii85" version))
9639 "0658m37jjjn6drzqg1gk4p6c205mgp7g1jh2d00n4ngghgmz5qvs"))))
9640 (build-system ruby-build-system)
9643 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
9645 "This library provides methods to encode and decode Ascii85
9646 binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
9647 @dfn{Portable Document Format} (PDF) file formats.")
9648 (home-page "https://github.com/datawraith/ascii85gem")
9649 (license license:expat)))
9651 (define-public ruby-ttfunk
9653 (name "ruby-ttfunk")
9658 ;; fetch from github as the gem does not contain testing code
9660 (url "https://github.com/prawnpdf/ttfunk")
9662 (file-name (git-file-name name version))
9665 "0rsf4j6s97wbcnjbvmmh6xrc7imw4g9lrlcvn945wh400lc8r53z"))))
9666 (build-system ruby-build-system)
9668 `(#:test-target "spec"
9670 (modify-phases %standard-phases
9671 (add-before 'build 'remove-ssh
9673 ;; remove dependency on an ssh key pair that doesn't exist
9674 (substitute* "ttfunk.gemspec"
9675 (("spec.signing_key.*") ""))
9677 (add-before 'check 'remove-rubocop
9679 ;; remove rubocop as a dependency as not needed for testing
9680 (substitute* "ttfunk.gemspec"
9681 (("spec.add_development_dependency\\('rubocop'.*") ""))
9682 (substitute* "Rakefile"
9683 (("require 'rubocop/rake_task'") "")
9684 (("RuboCop::RakeTask.new") ""))
9687 (list ruby-rspec ruby-yard bundler))
9688 (synopsis "Font metrics parser for the Prawn PDF generator")
9690 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
9691 part of the Prawn PDF generator.")
9692 (home-page "https://github.com/prawnpdf/ttfunk")
9693 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
9695 (license %prawn-project-licenses)))
9697 (define-public ruby-puma
9704 ;; Fetch from GitHub because distributed gem does not contain tests.
9706 (url "https://github.com/puma/puma")
9707 (commit (string-append "v" version))))
9708 (file-name (git-file-name name version))
9711 "1kj75k81iik3aj73pkc9ixj9rwf95ipkyma65n28m64dgw02qi1f"))))
9712 (build-system ruby-build-system)
9714 `(#:tests? #f ; Tests require an out-dated version of minitest.
9716 (modify-phases %standard-phases
9717 (add-before 'build 'fix-gemspec
9719 (substitute* "puma.gemspec"
9720 (("git ls-files") "find * |sort"))
9722 (synopsis "Simple, concurrent HTTP server for Ruby/Rack")
9724 "Puma is a simple, fast, threaded, and highly concurrent HTTP 1.1 server
9725 for Ruby/Rack applications. Puma is intended for use in both development and
9726 production environments. In order to get the best throughput, it is highly
9727 recommended that you use a Ruby implementation with real threads like Rubinius
9729 (home-page "https://puma.io/")
9730 (license license:expat)))
9732 (define-public ruby-hoe-git
9734 (name "ruby-hoe-git")
9739 (uri (rubygems-uri "hoe-git" version))
9742 "10jmmbjm0lkglwxbn4rpqghgg1ipjxrswm117n50adhmy8yij650"))))
9743 (build-system ruby-build-system)
9746 (synopsis "Hoe plugins for tighter Git integration")
9748 "This package provides a set of Hoe plugins for tighter Git integration.
9749 It provides tasks to automate release tagging and pushing and changelog
9751 (home-page "https://github.com/jbarnette/hoe-git")
9752 (license license:expat)))
9754 (define-public ruby-hoe-markdown
9756 (name "ruby-hoe-markdown")
9758 (home-page "https://github.com/flavorjones/hoe-markdown")
9764 (commit (string-append "v" version))))
9765 (file-name (git-file-name name version))
9767 (base32 "0wb0yjdx9gx9r0cahpx42pblvglgh1i9pdfxjavq7f40nan2g076"))))
9768 (build-system ruby-build-system)
9770 '(#:test-target "spec"
9771 #:phases (modify-phases %standard-phases
9772 (add-before 'check 'disable-bundler-dependency
9774 (substitute* "spec/spec_helper.rb"
9775 (("require.*bundler/setup.*")
9781 (synopsis "Hoe plugin with Markdown helpers")
9783 "This package provides a Hoe plugin with various Markdown helpers, which
9784 can be used to e.g. hyperlink Markdown documentation between project files.")
9785 (license license:expat)))
9787 (define-public ruby-sequel
9789 (name "ruby-sequel")
9794 (uri (rubygems-uri "sequel" version))
9797 "03pmhj4kc3ga75wy397l57bvd18jxxmrk3qsznjw93b993qgvj3z"))))
9798 (build-system ruby-build-system)
9800 '(#:tests? #f)) ; Avoid dependency loop with ruby-minitest-hooks.
9801 (synopsis "Database toolkit for Ruby")
9802 (description "Sequel provides thread safety, connection pooling and a
9803 concise DSL for constructing SQL queries and table schemas. It includes a
9804 comprehensive ORM layer for mapping records to Ruby objects and handling
9805 associated records.")
9806 (home-page "https://sequel.jeremyevans.net")
9807 (license license:expat)))
9809 (define-public ruby-timecop
9811 (name "ruby-timecop")
9816 (uri (rubygems-uri "timecop" version))
9819 "0d7mm786180v4kzvn1f77rhfppsg5n0sq2bdx63x9nv114zm8jrp"))))
9820 (build-system ruby-build-system)
9823 (modify-phases %standard-phases
9824 (add-before 'check 'set-check-rubylib
9826 ;; Set RUBYLIB so timecop tests finds its own lib.
9827 (setenv "RUBYLIB" "lib")
9830 (list bundler ruby-minitest-rg ruby-mocha ruby-activesupport))
9831 (synopsis "Test mocks for time-dependent functions")
9833 "Timecop provides \"time travel\" and \"time freezing\" capabilities,
9834 making it easier to test time-dependent code. It provides a unified method to
9835 mock @code{Time.now}, @code{Date.today}, and @code{DateTime.now} in a single
9837 (home-page "https://github.com/travisjeffery/timecop")
9838 (license license:expat)))
9840 (define-public ruby-concurrent
9842 (name "ruby-concurrent")
9847 ;; Download from GitHub because the rubygems version does not contain
9850 (url "https://github.com/ruby-concurrency/concurrent-ruby")
9851 (commit (string-append "v" version))))
9852 (file-name (git-file-name name version))
9855 "193q2k47vk7qdvv9hlhmmdxgy91xl4imapyk1ijdg9vgf46knyzj"))))
9856 (build-system ruby-build-system)
9858 `(#:test-target "ci"
9860 (modify-phases %standard-phases
9861 (add-before 'replace-git-ls-files 'remove-extra-gemspecs
9863 ;; Delete extra gemspec files so 'first-gemspec' chooses the
9865 (delete-file "concurrent-ruby-edge.gemspec")
9866 (delete-file "concurrent-ruby-ext.gemspec")
9868 (replace 'replace-git-ls-files
9870 ;; XXX: The default substitution made by this phase is not fully
9871 ;; compatible with "git ls-files". The latter produces file names
9872 ;; such as "lib/foo", whereas ruby-build-system uses "find . [...]"
9873 ;; which gives "./lib/foo". That difference in turn breaks the
9874 ;; comparison against a glob pattern in this script.
9875 (substitute* "concurrent-ruby.gemspec"
9876 (("git ls-files") "find * -type f | sort"))
9878 (add-before 'build 'remove-jar-from-gemspec
9880 ;; The gemspec wants to include a JAR file that we do not build
9882 (substitute* "concurrent-ruby.gemspec"
9883 (("'lib/concurrent/concurrent_ruby.jar'")
9886 (add-before 'build 'remove-rake_compiler_dock-dependency
9888 ;; This library is only used when building for non-MRI targets.
9889 (substitute* "Rakefile"
9890 (("require 'rake_compiler_dock'")
9893 (add-before 'check 'remove-timecop-dependency
9894 ;; Remove timecop-dependent tests as having timecop as a depedency
9895 ;; causes circular depedencies.
9897 (delete-file "spec/concurrent/executor/timer_set_spec.rb")
9898 (delete-file "spec/concurrent/scheduled_task_spec.rb")
9901 (list ruby-rake-compiler ruby-rspec))
9902 (synopsis "Concurrency tools for Ruby")
9904 "This library provides modern concurrency tools including agents,
9905 futures, promises, thread pools, actors, supervisors, and more. It is
9906 inspired by Erlang, Clojure, Go, JavaScript, actors and classic concurrency
9908 (home-page "http://www.concurrent-ruby.com")
9909 (license license:expat)))
9911 (define-public ruby-pkg-config
9913 (name "ruby-pkg-config")
9918 (uri (rubygems-uri "pkg-config" version))
9921 "056mzqdh4yjznsg36fi0xiq76f24vxlhzh2n4az919l3x5k318ar"))))
9922 (build-system ruby-build-system)
9924 ;; Tests require extra files not included in the gem.
9926 (synopsis "Detect libraries for compiling Ruby native extensions")
9928 "@code{pkg-config} can be used in your extconf.rb to properly detect need
9929 libraries for compiling Ruby native extensions.")
9930 (home-page "https://github.com/ruby-gnome2/pkg-config")
9931 (license license:lgpl2.0+)))
9933 (define-public ruby-net-http-digest-auth
9935 (name "ruby-net-http-digest-auth")
9940 (uri (rubygems-uri "net-http-digest_auth" version))
9943 "1nq859b0gh2vjhvl1qh1zrk09pc7p54r9i6nnn6sb06iv07db2jb"))))
9944 (build-system ruby-build-system)
9947 (synopsis "RFC 2617 HTTP digest authentication library")
9949 "This library implements HTTP's digest authentication scheme based on
9950 RFC 2617. This enables the use of the digest authentication scheme instead
9951 of the more insecure basic authentication scheme.")
9952 (home-page "https://github.com/drbrain/net-http-digest_auth")
9953 (license license:expat)))
9955 (define-public ruby-mail
9962 (uri (rubygems-uri "mail" version))
9965 "00wwz6ys0502dpk8xprwcqfwyf3hmnx6lgxaiq6vj43mkx43sapc"))))
9966 (build-system ruby-build-system)
9968 (list ruby-mini-mime))
9970 '(#:tests? #f)) ; no rakefile
9971 (synopsis "Mail library for Ruby")
9973 "Mail is an internet library for Ruby that is designed to handle email
9974 generation, parsing and sending. The purpose of this library is to provide
9975 a single point of access to handle all email functions, including sending
9976 and receiving emails. All network type actions are done through proxy
9977 methods to @code{Net::SMTP}, @code{Net::POP3} etc.
9979 Mail has been designed with a very simple object oriented system that
9980 really opens up the email messages you are parsing, if you know what you
9981 are doing, you can fiddle with every last bit of your email directly.")
9982 (home-page "https://github.com/mikel/mail")
9983 (license license:expat)))
9985 (define-public ruby-email-reply-trimmer
9987 (name "ruby-email-reply-trimmer")
9992 (uri (rubygems-uri "email_reply_trimmer" version))
9995 "1jgcxifm48xq5dz9k47q43pqm5bfnf14l62l3bqhmv8f6z8dw4ki"))))
9996 (build-system ruby-build-system)
9997 (synopsis "Trim replies from plain text email")
9998 (description "EmailReplyTrimmer is a Ruby small library to trim replies
9999 from plain text email.")
10000 (home-page "https://github.com/discourse/email_reply_trimmer")
10001 (license license:expat)))
10003 (define-public ruby-mathn
10005 (name "ruby-mathn")
10010 (uri (rubygems-uri "mathn" version))
10013 "1wn812llln9jzgybz2d7536q39z3gi99i6fi0j1dapcpzvhgrr0p"))))
10014 (build-system ruby-build-system)
10016 (list bundler ruby-rake-compiler))
10017 (synopsis "Extends math operations for increased precision")
10019 "This gem makes mathematical operations more precise in Ruby and
10020 integrates other mathematical standard libraries. Prior to Ruby 2.5,
10021 @code{mathn} was part of the Ruby standard library.")
10022 (home-page "https://github.com/ruby/mathn")
10023 (license license:bsd-2)))
10025 (define-public ruby-code-statistics
10027 (name "ruby-code-statistics")
10032 (uri (rubygems-uri "code_statistics" version))
10035 "07rdpsbwbmh4vp8nxyh308cj7am2pbrfhv9v5xr2d5gq8hnnsm93"))))
10036 (build-system ruby-build-system)
10038 `(#:tests? #f)) ; Not all test code is included in gem.
10039 (synopsis "Port of the rails 'rake stats' method")
10041 "This gem is a port of the rails 'rake stats' method so it can be made
10042 more robust and work for non rails projects.")
10043 (home-page "https://github.com/danmayer/code_statistics")
10044 (license license:expat)))
10046 (define-public ruby-rubypants
10048 (name "ruby-rubypants")
10052 (uri (rubygems-uri "rubypants" version))
10055 "0xpqkslan2wkyal2h9qhplkr5d4sdn7q6csigrhnljjpp8j4qfsh"))))
10056 (build-system ruby-build-system)
10058 '(#:tests? #f)) ; need Codecov
10059 (synopsis "Port of the smart-quotes library SmartyPants")
10061 "RubyPants is a Ruby port of the smart-quotes library SmartyPants. The
10062 original SmartyPants is a web publishing plug-in for Movable Type, Blosxom,
10063 and BBEdit that easily translates plain ASCII punctuation characters into
10064 smart typographic punctuation HTML entities.")
10065 (home-page "https://github.com/jmcnevin/rubypants")
10066 (license license:bsd-2)))
10068 (define-public ruby-org-ruby
10070 (name "ruby-org-ruby")
10074 (uri (rubygems-uri "org-ruby" version))
10077 "0x69s7aysfiwlcpd9hkvksfyld34d8kxr62adb59vjvh8hxfrjwk"))))
10078 (build-system ruby-build-system)
10080 '(#:tests? #f)) ; no rakefile
10082 (list ruby-rubypants))
10083 (synopsis "Org-mode parser written in Ruby")
10085 "Org-ruby is an org-mode parser written in Ruby. The most significant
10086 thing this library does today is convert org-mode files to HTML or Textile or
10088 (home-page "https://github.com/wallyqs/org-ruby")
10089 (license license:expat)))
10091 (define-public ruby-rake
10098 (uri (rubygems-uri "rake" version))
10101 "0w6qza25bq1s825faaglkx1k6d59aiyjjk3yw3ip5sb463mhhai9"))))
10102 (build-system ruby-build-system)
10105 (synopsis "Rake is a Make-like program implemented in Ruby")
10107 "Rake is a Make-like program where tasks and dependencies are specified
10108 in standard Ruby syntax.")
10109 (home-page "https://github.com/ruby/rake")
10110 (license license:expat)))
10112 (define-public ruby-childprocess
10114 (name "ruby-childprocess")
10119 (uri (rubygems-uri "childprocess" version))
10122 "1ic028k8xgm2dds9mqnvwwx3ibaz32j8455zxr9f4bcnviyahya5"))))
10123 (build-system ruby-build-system)
10127 (list bundler ruby-rspec))
10130 (synopsis "Control external programs running in the background, in Ruby")
10131 (description "@code{childprocess} provides a gem to control external
10132 programs running in the background, in Ruby.")
10133 (home-page "https://github.com/enkessler/childprocess")
10134 (license license:expat)))
10136 (define-public ruby-public-suffix
10138 (name "ruby-public-suffix")
10142 (uri (rubygems-uri "public_suffix" version))
10145 "0vywld400fzi17cszwrchrzcqys4qm6sshbv73wy5mwcixmrgg7g"))))
10146 (build-system ruby-build-system)
10149 (modify-phases %standard-phases
10150 ;; Remove the requirement on Rubocop, as it isn't useful to run, and
10151 ;; including it as an input can lead to circular dependencies.
10152 (add-after 'unpack 'remove-rubocop-from-Rakefile
10154 (substitute* "Rakefile"
10155 (("require \"rubocop/rake\\_task\"") "")
10156 (("RuboCop::RakeTask\\.new") ""))
10159 (list bundler ruby-yard ruby-mocha ruby-minitest-reporters))
10160 (home-page "https://simonecarletti.com/code/publicsuffix-ruby/")
10161 (synopsis "Domain name parser")
10162 (description "The gem @code{public_suffix} is a domain name parser,
10163 written in Ruby, and based on the @dfn{Public Suffix List}. A public suffix
10164 is one under which Internet users can (or historically could) directly
10165 register names. Some examples of public suffixes are @code{.com},
10166 @code{.co.uk} and @code{pvt.k12.ma.us}. The Public Suffix List is a list of
10167 all known public suffixes.")
10168 (license license:expat)))
10170 (define-public ruby-addressable
10172 (name "ruby-addressable")
10176 (uri (rubygems-uri "addressable" version))
10179 "1fvchp2rhp2rmigx7qglf69xvjqvzq7x0g49naliw29r2bz656sy"))))
10180 (build-system ruby-build-system)
10182 '(#:test-target "spec"
10184 (modify-phases %standard-phases
10185 (add-after 'unpack 'remove-unnecessary-dependencies-from-Gemfile
10187 (substitute* "Gemfile"
10188 (("git: 'https://github.com/sporkmonger/rack-mount.git',") "")
10189 ((".*launchy.*") "")
10190 ((".*rake.*") "gem 'rake'\n")
10191 ((".*redcarpet.*") ""))
10193 (add-before 'check 'delete-network-dependent-test
10195 (delete-file "spec/addressable/net_http_compat_spec.rb")
10201 ruby-sporkmonger-rack-mount
10202 ruby-rspec-its-minimal
10206 (list ruby-public-suffix))
10207 (home-page "https://github.com/sporkmonger/addressable")
10208 (synopsis "Alternative URI implementation")
10209 (description "Addressable is a replacement for the URI implementation that
10210 is part of Ruby's standard library. It more closely conforms to RFC 3986,
10211 RFC 3987, and RFC 6570 (level 4), providing support for IRIs and URI templates.")
10212 (license license:asl2.0)))
10214 (define-public ruby-colorize
10216 (name "ruby-colorize")
10220 (uri (rubygems-uri "colorize" version))
10223 "133rqj85n400qk6g3dhf2bmfws34mak1wqihvh3bgy9jhajw580b"))))
10224 (build-system ruby-build-system)
10226 '(#:phases (modify-phases %standard-phases
10227 (add-before 'check 'remove-codeclimate-dependency
10229 (substitute* "test/test_colorize.rb"
10230 ;; Do not hook the tests into the online CodeClimate
10231 ;; service which is unnecessary for these tests.
10232 (("require 'codeclimate-test-reporter'")
10234 (("CodeClimate.*") ""))
10236 (synopsis "Add color effects to the @code{String} class")
10238 "This package extends the @code{String} class and adds a
10239 @code{ColorizedString} with methods to set text color, background color,
10240 and text effects.")
10241 (home-page "https://github.com/fazibear/colorize")
10242 (license license:gpl2+)))
10244 (define-public ruby-colorator
10246 (name "ruby-colorator")
10250 (uri (rubygems-uri "colorator" version))
10253 "0f7wvpam948cglrciyqd798gdc6z3cfijciavd0dfixgaypmvy72"))))
10254 (build-system ruby-build-system)
10258 (home-page "http://octopress.org/colorator/")
10259 (synopsis "Terminal color library")
10260 (description "Colorator is a Ruby gem that helps you colorize your text
10261 for the terminal.")
10262 (license license:expat)))
10264 (define-public ruby-command-line-reporter
10266 (name "ruby-command-line-reporter")
10270 (uri (rubygems-uri "command_line_reporter" version))
10273 "1l0zxkh5n9dxfw46lpkg416ljpldlq1bgdhqh0d118dk338nz4ll"))))
10274 (build-system ruby-build-system)
10279 (modify-phases %standard-phases
10280 (add-before 'build 'fix-dependencies
10282 (substitute* ".gemspec"
10283 ;; colored is unmaintained
10284 (("colored") "colorator")
10285 ;; colorator version
10286 (("= 1.2") "= 1.1"))
10288 (propagated-inputs (list ruby-colorator))
10289 (home-page "https://github.com/wbailey/command_line_reporter")
10290 (synopsis "Report production while executing Ruby scripts")
10291 (description "This gem provides a DSL that makes it easy to write reports
10292 of various types in ruby. It eliminates the need to litter your source with
10293 puts statements, instead providing a more readable, expressive interface to
10294 your application.")
10295 (license license:asl2.0)))
10297 (define-public ruby-command-line-reporter-3
10299 (inherit ruby-command-line-reporter)
10303 (uri (rubygems-uri "command_line_reporter" version))
10306 "1h39zqqxp3k4qk49ajpx0jps1vmvxgkh43mqkb6znk583bl0fv71"))))))
10308 (define-public ruby-kpeg
10315 (uri (rubygems-uri "kpeg" version))
10318 "0x2kpfrcagj931masm5y1kwbnc6nxl60cqdcd3lyd1d2hz7kzlia"))))
10319 (build-system ruby-build-system)
10322 (synopsis "PEG library for Ruby")
10323 (description "KPeg is a simple PEG library for Ruby. It provides an API as
10324 well as native grammar to build the grammar. KPeg supports direct left
10325 recursion of rules via the
10326 @uref{http://www.vpri.org/pdf/tr2008003_experimenting.pdf,OMeta memoization}
10328 (home-page "https://github.com/evanphx/kpeg")
10329 (license license:expat)))
10331 (define-public ruby-rdoc
10338 (uri (git-reference
10339 (url "https://github.com/ruby/rdoc")
10340 (commit (string-append "v" version))))
10341 (file-name (git-file-name name version))
10344 "0dhk29nidv93b5vnjvlm9gcixgn4i0jcyzrgxdk6pdg019bw4cj6"))))
10345 (build-system ruby-build-system)
10348 (modify-phases %standard-phases
10349 (add-after 'unpack 'patch-gemspec
10350 ;; TODO: Remove after next release is tagged.
10352 (substitute* "rdoc.gemspec"
10353 (("\"lib/rdoc/generator/template/darkfish/js/\
10354 jquery\\.js\", ") ""))
10356 (add-before 'build 'generate
10357 ;; 'gem build' doesn't honor Rakefile dependencies (see:
10358 ;; https://github.com/ruby/rdoc/issues/432#issuecomment-650808977).
10360 (invoke "rake" "generate"))))))
10362 (list bundler ruby-kpeg ruby-racc ruby-rubocop))
10363 (home-page "https://ruby.github.io/rdoc/")
10364 (synopsis "HTML and command-line documentation utility")
10365 (description "RDoc produces HTML and command-line documentation for Ruby
10366 projects. RDoc includes the +rdoc+ and +ri+ tools for generating and displaying
10367 documentation from the command-line.")
10368 (license license:gpl2+)))
10370 (define-public ruby-sass-listen
10372 (name "ruby-sass-listen")
10376 (uri (rubygems-uri "sass-listen" version))
10379 "0xw3q46cmahkgyldid5hwyiwacp590zj2vmswlll68ryvmvcp7df"))))
10380 (build-system ruby-build-system)
10385 (list ruby-rb-fsevent ruby-rb-inotify))
10386 (home-page "https://github.com/sass/listen")
10387 (synopsis "File modification notification library")
10388 (description "The Listen gem listens to file modifications and notifies you
10389 about the changes.")
10390 (license license:expat)))
10392 (define-public ruby-terminfo
10394 (name "ruby-terminfo")
10399 (uri (rubygems-uri "ruby-terminfo" version))
10402 "0rl4ic5pzvrpgd42z0c1s2n3j39c9znksblxxvmhkzrc0ckyg2cm"))))
10403 (build-system ruby-build-system)
10405 `(#:test-target "test"
10406 ;; Rakefile requires old packages and would need modification to
10407 ;; work with current software.
10412 (list ruby-rubygems-tasks ruby-rdoc))
10413 (home-page "http://www.a-k-r.org/ruby-terminfo/")
10414 (synopsis "Terminfo binding for Ruby")
10415 (description "Ruby-terminfo provides terminfo binding for Ruby.")
10416 (license license:bsd-3)))
10418 (define-public ruby-diffy
10420 (name "ruby-diffy")
10425 (uri (rubygems-uri "diffy" version))
10428 "119imrkn01agwhx5raxhknsi331y5i4yda7r0ws0an6905ximzjg"))))
10429 (build-system ruby-build-system)
10435 (home-page "https://github.com/samg/diffy")
10436 (synopsis "Convenient diffing in ruby")
10437 (description "Diffy provides a convenient way to generate a diff from two
10438 strings or files.")
10439 (license license:expat)))
10441 (define-public ruby-sass-spec
10443 (name "ruby-sass-spec")
10448 (uri (git-reference
10449 (url "https://github.com/sass/sass-spec")
10450 (commit (string-append "v" version))))
10451 (file-name (git-file-name name version))
10453 (base32 "1zsw66830w0xlc7kxz6fm4b5nyb44vdsdgm9mgy06s5aixx83pwr"))))
10454 (build-system ruby-build-system)
10456 `(("ruby-command-line-reporter-3" ,ruby-command-line-reporter-3)
10457 ("ruby-diffy" ,ruby-diffy)
10458 ("ruby-terminfo" ,ruby-terminfo)))
10460 `(;; This package contains tests for a sass implementation, and the to
10461 ;; avoid any circular dependencies, the tests are not run here
10464 (modify-phases %standard-phases
10465 (add-after 'unpack 'patch-test
10467 (delete-file "spec/values/colors/alpha_hex-3.5/error")
10468 (substitute* "spec/values/colors/alpha_hex-3.5/expected_output.css"
10469 (("string") "color")))))))
10470 (home-page "https://github.com/sass/sass-spec")
10471 (synopsis "Test suite for Sass")
10472 (description "Sass Spec is a test suite for Sass. Test cases are all in
10473 the @file{spec} directory.")
10474 (license license:expat)))
10476 (define-public ruby-sass
10482 (uri (rubygems-uri "sass" version))
10485 "18c6prbw9wl8bqhb2435pd9s0lzarl3g7xf8pmyla28zblvwxmyh"))))
10486 (build-system ruby-build-system)
10488 (list ruby-sass-listen))
10490 (list ruby-sass-spec ruby-mathn ruby-cmath))
10491 (home-page "https://sass-lang.com/")
10492 (synopsis "CSS extension language")
10493 (description "Sass is a CSS extension language. It extends CSS with
10494 features that don't exist yet like variables, nesting, mixins and inheritance.")
10495 (license license:expat)))
10497 (define-public ruby-sassc
10499 (name "ruby-sassc")
10504 (uri (rubygems-uri "sassc" version))
10507 "0gpqv48xhl8mb8qqhcifcp0pixn206a7imc07g48armklfqa4q2c"))))
10508 (build-system ruby-build-system)
10510 '(#:modules ((guix build ruby-build-system)
10512 (ice-9 textual-ports))
10514 (modify-phases %standard-phases
10515 ;; TODO: This would be better as a snippet, but the ruby-build-system
10516 ;; doesn't seem to support that
10517 (add-after 'unpack 'remove-libsass
10519 (delete-file-recursively "ext")
10520 (with-atomic-file-replacement "sassc.gemspec"
10522 (let* ((gemspec (get-string-all in))
10523 (index (string-contains gemspec "libsass_dir")))
10524 (display (string-append
10525 (string-take gemspec index)
10529 (add-after 'unpack 'dont-check-the-libsass-version
10531 (substitute* "test/native_test.rb"
10532 (("assert_equal.*Native\\.version") ""))
10534 (add-after 'unpack 'remove-git-from-gemspec
10536 (substitute* "sassc.gemspec"
10537 (("`git ls-files -z`") "`find . -type f -print0 |sort -z`"))
10539 (add-after 'unpack 'remove-extensions-from-gemspec
10541 (substitute* "sassc.gemspec"
10542 (("\\[\"ext/extconf.rb\"\\]") "[]"))
10544 (add-after 'unpack 'fix-Rakefile
10546 (substitute* "Rakefile"
10547 (("test: 'compile:libsass'") ":test"))
10549 (add-after 'unpack 'remove-unnecessary-dependencies
10551 (substitute* "test/test_helper.rb"
10552 (("require \"pry\"") ""))
10554 (add-before 'build 'patch-native.rb
10555 (lambda* (#:key inputs #:allow-other-keys)
10556 (substitute* "lib/sassc/native.rb"
10557 ((".*gem_root = spec.gem_dir") "")
10560 "ffi_lib '" (assoc-ref inputs "libsass") "/lib/libsass.so'")))
10562 ;; The gemspec still references the libsass files, so just keep the
10564 (delete 'extract-gemspec))))
10566 (list ruby-ffi ruby-rake))
10570 (list bundler ruby-rake-compiler ruby-minitest-around
10571 ruby-test-construct))
10572 (synopsis "Use libsss from Ruby")
10574 "This library provides Ruby q@acronym{FFI, Foreign Function Interface}
10575 bindings to the libsass library. This enables rendering
10576 @acronym{SASS,Syntactically awesome style sheets} from Ruby code.")
10577 (home-page "https://github.com/sass/sassc-ruby")
10578 (license license:expat)))
10580 (define-public ruby-jekyll-sass-converter
10582 (name "ruby-jekyll-sass-converter")
10586 (uri (rubygems-uri "jekyll-sass-converter" version))
10589 "04ncr44wrilz26ayqwlg7379yjnkb29mvx4j04i62b7czmdrc9dv"))))
10590 (build-system ruby-build-system)
10596 (home-page "https://github.com/jekyll/jekyll-sass-converter")
10597 (synopsis "Sass converter for Jekyll")
10598 (description "This gem provide built-in support for the Sass converter
10600 (license license:expat)))
10602 (define-public ruby-jekyll-watch
10604 (name "ruby-jekyll-watch")
10608 (uri (rubygems-uri "jekyll-watch" version))
10611 "1s9ly83sp8albvgdff12xy2h4xd8lm6z2fah4lzmk2yvp85jzdzv"))))
10612 (build-system ruby-build-system)
10614 (list ruby-listen))
10618 (home-page "https://github.com/jekyll/jekyll-watch")
10619 (synopsis "Jekyll auto-rebuild support")
10620 (description "This gems add the @code{--watch} switch to the jekyll CLI
10621 interface. It allows Jekyll to rebuild your site when a file changes.")
10622 (license license:expat)))
10624 (define-public ruby-parallel
10626 (name "ruby-parallel")
10631 (uri (git-reference
10632 (url "https://github.com/grosser/parallel")
10633 (commit (string-append "v" version))))
10634 (file-name (git-file-name name version))
10637 "1xqjcvl3gq3shvrqp8wc3fbqibzh4mf1yczq6np9gd79558dwj3w"))))
10638 (build-system ruby-build-system)
10640 `(;; TODO 3 test failures
10641 ;; rspec ./spec/parallel_spec.rb:190 # Parallel.in_processes does not
10642 ;; open unnecessary pipes
10643 ;; rspec './spec/parallel_spec.rb[1:9:7]' # Parallel.each works with
10644 ;; SQLite in processes
10645 ;; rspec './spec/parallel_spec.rb[1:9:16]' # Parallel.each works with
10646 ;; SQLite in threads
10648 #:test-target "rspec-rerun:spec"
10650 (modify-phases %standard-phases
10651 (add-after 'unpack 'patch-Gemfile
10653 (substitute* "Gemfile"
10654 (("gem 'rspec-legacy_formatters'") "")
10655 (("gem 'activerecord.*$") "gem 'activerecord'\n"))))
10656 (add-before 'check 'delete-Gemfile.lock
10658 ;; Bundler isn't being used for fetching dependendencies, so
10659 ;; delete the Gemfile.lock
10660 (delete-file "Gemfile.lock")
10662 (add-before 'build 'patch-gemspec
10664 (substitute* "parallel.gemspec"
10665 (("git ls-files") "find"))
10679 (home-page "https://github.com/grosser/parallel")
10680 (synopsis "Parallel processing in Ruby")
10681 (description "Parallel allows you to run any code in parallel Processes
10682 (to use all CPUs) or Threads(to speedup blocking operations). It is best
10683 suited for map-reduce or e.g. parallel downloads/uploads.")
10684 (license license:expat)))
10686 (define-public ruby-cane
10692 (uri (rubygems-uri "cane" version))
10695 "0yf5za3l7lhrqa3g56sah73wh33lbxy5y3cb7ij0a2bp1b4kwhih"))))
10696 (build-system ruby-build-system)
10697 (arguments `(#:tests? #f)); No rakefile
10698 (home-page "https://github.com/square/cane")
10700 (list ruby-parallel))
10701 (synopsis "Code quality threshold checking")
10702 (description "Cane fails your build if code quality thresholds are not met.")
10703 (license license:asl2.0)))
10705 (define-public ruby-morecane
10707 (name "ruby-morecane")
10711 (uri (rubygems-uri "morecane" version))
10714 "0w70vb8z5bdhvr21h660aa43m5948pv0bd27z7ngai2iwdvqd771"))))
10715 (build-system ruby-build-system)
10716 (home-page "https://github.com/yob/morecane")
10717 (arguments `(#:tests? #f)); No rakefile
10719 (list ruby-parallel))
10720 (synopsis "Extra checks for cane")
10721 (description "The cane gem provides a great framework for running quality
10722 checks over your ruby project as part of continuous integration build. It
10723 comes with a few checks out of the box, but also provides an API for loading
10724 custom checks. This gem provides a set of additional checks.")
10725 (license license:expat)))
10727 (define-public ruby-pdf-reader
10729 (name "ruby-pdf-reader")
10732 (method git-fetch) ;no test in distributed gem archive
10733 (uri (git-reference
10734 (url "https://github.com/yob/pdf-reader")
10735 (commit (string-append "v" version))))
10736 (file-name (git-file-name name version))
10739 "1yh8yrlssf5ppnkvk4m78vmh5r5vqwdcd0gm3lqipw162llz0rai"))))
10740 (build-system ruby-build-system)
10741 (arguments `(#:test-target "spec"
10742 #:phases (modify-phases %standard-phases
10743 (add-after 'unpack 'do-not-use-bundler
10745 (substitute* "spec/spec_helper.rb"
10746 ((".*[Bb]undler.*") ""))
10749 (list ruby-rspec ruby-cane ruby-morecane))
10751 (list ruby-afm ruby-ascii85 ruby-hashery ruby-rc4 ruby-ttfunk))
10752 (home-page "https://github.com/yob/pdf-reader")
10753 (synopsis "PDF parser in Ruby")
10754 (description "The PDF::Reader library implements a PDF parser conforming as
10755 much as possible to the PDF specification from Adobe. It provides programmatic
10756 access to the contents of a PDF file with a high degree of flexibility.")
10757 (license license:gpl3+)))
10759 (define-public ruby-pdf-inspector
10760 (let ((revision "1")
10761 (commit "00ee4c92ff917118785ebec188e81effc968abeb"))
10763 (name "ruby-pdf-inspector")
10764 (version (git-version "1.3.0" revision commit))
10767 (uri (git-reference
10768 (url "https://github.com/prawnpdf/pdf-inspector")
10770 (file-name (git-file-name name version))
10773 "0h9w81ddd0gvkh5n2cvny9ddb5qiac1si0dhinkk0xxh5382qs0m"))))
10774 (build-system ruby-build-system)
10776 `(#:test-target "spec"
10777 #:phases (modify-phases %standard-phases
10778 (add-before 'build 'drop-signing-key-requirement
10780 (substitute* "pdf-inspector.gemspec"
10781 (("spec.signing_key =.*")
10782 "spec.signing_key = nil"))
10786 (substitute* "pdf-inspector.gemspec"
10787 ((".*rubocop.*") "")
10789 (invoke "rspec"))))))
10793 (list ruby-pdf-reader))
10794 (home-page "https://github.com/prawnpdf/pdf-inspector")
10795 (synopsis "Analysis classes for inspecting PDF output")
10796 (description "This library provides a number of PDF::Reader based tools for
10797 use in testing PDF output. Presently, the primary purpose of this tool is to
10798 support the tests found in Prawn, a pure Ruby PDF generation library.")
10799 (license %prawn-project-licenses))))
10801 (define-public ruby-pdf-core
10803 (name "ruby-pdf-core")
10807 (uri (rubygems-uri "pdf-core" version))
10810 "15d6m99bc8bbzlkcg13qfpjjzphfg5x905pjbfygvpcxsm8gnsvg"))))
10811 (build-system ruby-build-system)
10815 (home-page "https://github.com/prawnpdf/pdf-core")
10816 (synopsis "Low level PDF features for Prawn")
10817 (description "This is an experimental gem that extracts low-level PDF
10818 functionality from Prawn.")
10819 (license license:gpl3+)))
10821 (define-public ruby-prawn
10822 ;; There hasn't been a new release since 2017/03/17.
10823 (let ((revision "1")
10824 (commit "d980247be8a00e7c59cd4e5785e3aa98f9856db1"))
10826 (name "ruby-prawn")
10827 (version (git-version "2.2.2" revision commit))
10830 (uri (git-reference
10831 (url "https://github.com/prawnpdf/prawn")
10833 (file-name (git-file-name name version))
10836 "0mcmvf22h8il93yq48v9f31qpy27pvjxgv9172p0f4x9lqy0imwr"))))
10837 (build-system ruby-build-system)
10840 (modify-phases %standard-phases
10841 (add-before 'build 'drop-signing-key-requirement
10843 (substitute* "prawn.gemspec"
10844 (("spec.signing_key =.*")
10845 "spec.signing_key = nil"))
10848 (lambda* (#:key tests? #:allow-other-keys)
10850 ;; The Prawn manual test fails (see:
10851 ;; https://github.com/prawnpdf/prawn/issues/1163), so exclude
10853 (invoke "rspec" "--exclude-pattern" "prawn_manual_spec.rb"))
10856 (list ruby-pdf-core ruby-ttfunk))
10858 (list ruby-pdf-inspector ruby-prawn-manual-builder ruby-rspec
10859 ruby-simplecov ruby-yard))
10860 (home-page "https://prawnpdf.org/api-docs/2.0/")
10861 (synopsis "PDF generation for Ruby")
10862 (description "Prawn is a pure Ruby PDF generation library.")
10863 (license %prawn-project-licenses))))
10865 (define-public ruby-prawn-table
10867 (name "ruby-prawn-table")
10871 (uri (rubygems-uri "prawn-table" version))
10874 "1nxd6qmxqwl850icp18wjh5k0s3amxcajdrkjyzpfgq0kvilcv9k"))))
10875 (build-system ruby-build-system)
10877 (list ruby-prawn ruby-pdf-inspector))
10879 `(("bundler" ,bundler)
10880 ("ruby-yard" ,ruby-yard)
10881 ("ruby-mocha" ,ruby-mocha)
10882 ("ruby-coderay" ,ruby-coderay)
10883 ("ruby-prawn-manual-builder" ,ruby-prawn-manual-builder)
10884 ("ruby-simplecov" ,ruby-simplecov)
10885 ("ruby-rspec-2" ,ruby-rspec-2)))
10887 '(;; TODO: 1 test fails
10888 ;; Failure/Error: pdf.page_count.should == 1
10890 ;; got: 2 (using ==)
10891 ;; # ./spec/table_spec.rb:1308
10893 ;; 225 examples, 1 failure
10896 (modify-phases %standard-phases
10897 (add-before 'check 'patch-gemspec
10899 (substitute* "prawn-table.gemspec"
10900 ;; Loosen the requirement for pdf-inspector
10901 (("~> 1\\.1\\.0") ">= 0")
10902 ;; Loosen the requirement for pdf-reader
10903 (("~> 1\\.2") ">= 0"))))
10905 (lambda* (#:key tests? #:allow-other-keys)
10909 (home-page "https://github.com/prawnpdf/prawn-table")
10910 (synopsis "Tables support for Prawn")
10911 (description "This gem provides tables support for Prawn.")
10912 (license license:gpl3+)))
10914 (define-public ruby-kramdown
10916 (name "ruby-kramdown")
10920 (uri (rubygems-uri "kramdown" version))
10923 "0jdbcjv4v7sj888bv3vc6d1dg4ackkh7ywlmn9ln2g9alk7kisar"))))
10924 (build-system ruby-build-system)
10925 (arguments `(#:tests? #f)); FIXME: some test failures
10927 (list ruby-prawn ruby-prawn-table))
10928 (home-page "https://kramdown.gettalong.org/")
10929 (synopsis "Markdown parsing and converting library")
10930 (description "Kramdown is a library for parsing and converting a superset
10931 of Markdown. It is completely written in Ruby, supports standard Markdown
10932 (with some minor modifications) and various extensions that have been made
10933 popular by the PHP @code{Markdown Extra} package and @code{Maruku}.")
10934 (license license:expat)))
10936 (define-public ruby-kramdown-parser-gfm
10938 (name "ruby-kramdown-parser-gfm")
10943 (uri (rubygems-uri "kramdown-parser-gfm" version))
10945 (base32 "0a8pb3v951f4x7h968rqfsa19c8arz21zw1vaj42jza22rap8fgv"))))
10946 (build-system ruby-build-system)
10948 `(#:tests? #f)) ;no rakefile
10950 (list ruby-kramdown))
10951 (synopsis "Kramdown parser for the GFM dialect of Markdown")
10953 "This is a parser for kramdown that converts Markdown documents in the
10954 GFM dialect to HTML.")
10955 (home-page "https://github.com/kramdown/parser-gfm")
10956 (license license:expat)))
10958 (define-public ruby-http-parser.rb
10960 (name "ruby-http-parser.rb")
10965 (uri (rubygems-uri "http_parser.rb" version))
10968 "15nidriy0v5yqfjsgsra51wmknxci2n2grliz78sf9pga3n0l7gi"))))
10969 (build-system ruby-build-system)
10974 (list ruby-rake-compiler ruby-rspec))
10975 (home-page "https://github.com/tmm1/http_parser.rb")
10976 (synopsis "HTTP parser un Ruby")
10977 (description "This gem is a simple callback-based HTTP request/response
10978 parser for writing http servers, clients and proxies.")
10979 (license license:expat)))
10981 (define-public ruby-em-websocket
10983 (name "ruby-em-websocket")
10988 (uri (rubygems-uri "em-websocket" version))
10991 "1bsw8vjz0z267j40nhbmrvfz7dvacq4p0pagvyp17jif6mj6v7n3"))))
10992 (build-system ruby-build-system)
10997 (list ruby-eventmachine ruby-http-parser.rb))
10999 (list bundler ruby-rspec))
11000 (home-page "https://github.com/igrigorik/em-websocket")
11001 (synopsis "EventMachine based WebSocket server")
11002 (description "Em-websocket is an EventMachine based WebSocket server
11004 (license license:expat)))
11006 (define-public ruby-rouge
11008 (name "ruby-rouge")
11012 (uri (rubygems-uri "rouge" version))
11015 "197k0vskf72wxx0gzwld2jzg27bb7982xlvnzy9adlvkzp7nh8vf"))))
11016 (build-system ruby-build-system)
11017 (arguments `(#:tests? #f)); No rakefile
11018 (home-page "http://rouge.jneen.net/")
11019 (synopsis "Code highlighter")
11020 (description "Rouge is a code highlighter written in Ruby. It supports more
11021 than 100 languages and outputs HTML or ANSI 256-color text. Its HTML output
11022 is compatible with stylesheets designed for pygments.")
11024 ;; rouge is licensed under expat
11026 ;; pygments is licensed under bsd-2
11029 (define-public ruby-hashie
11031 (name "ruby-hashie")
11035 (uri (rubygems-uri "hashie" version))
11038 "13bdzfp25c8k51ayzxqkbzag3wj5gc1jd8h7d985nsq6pn57g5xh"))))
11039 (build-system ruby-build-system)
11042 (arguments `(#:tests? #f)); FIXME: Could not locate Gemfile or .bundle/ directory
11043 (home-page "https://github.com/intridea/hashie")
11044 (synopsis "Extensions to Ruby Hashes")
11045 (description "Hashie is a collection of classes and mixins that make Ruby
11046 hashes more powerful.")
11047 (license license:expat)))
11049 (define-public ruby-heredoc-unindent
11051 (name "ruby-heredoc-unindent")
11055 (uri (rubygems-uri "heredoc_unindent" version))
11058 "14ijr2fsjwhrkjkcaz81d5xnfa4vvgvcflrff83avqw9klm011yw"))))
11059 (build-system ruby-build-system)
11062 (home-page "https://github.com/adrianomitre/heredoc_unindent")
11063 (synopsis "Heredoc indentation cleaner")
11064 (description "This gem removes common margin from indented strings, such
11065 as the ones produced by indented heredocs. In other words, it strips out
11066 leading whitespace chars at the beginning of each line, but only as much as
11067 the line with the smallest margin.
11069 It is acknowledged that many strings defined by heredocs are just code and
11070 fact is that most parsers are insensitive to indentation. If, however, the
11071 strings are to be used otherwise, be it for printing or testing, the extra
11072 indentation will probably be an issue and hence this gem.")
11073 (license license:expat)))
11075 (define-public ruby-safe-yaml
11077 (name "ruby-safe-yaml")
11082 (uri (git-reference
11083 (url "https://github.com/dtao/safe_yaml")
11085 (file-name (git-file-name name version))
11088 "1a0wh7y3va2m7bjza95na2snw0vrdh9syz40mpjvjphbc4ph3pzg"))))
11089 (build-system ruby-build-system)
11091 (list ruby-rspec ruby-hashie ruby-heredoc-unindent))
11093 '(#:test-target "spec"
11095 (modify-phases %standard-phases
11096 (add-before 'check 'set-TZ
11098 ;; This test is dependent on the timezone
11099 ;; spec/transform/to_date_spec.rb:35
11100 ;; # SafeYAML::Transform::ToDate converts times to the local
11102 (setenv "TZ" "UTC-11")
11104 (home-page "https://github.com/dtao/safe_yaml")
11105 (synopsis "YAML parser")
11106 (description "The SafeYAML gem provides an alternative implementation of
11107 YAML.load suitable for accepting user input in Ruby applications.")
11108 (license license:expat)))
11110 (define-public ruby-yaml-lint
11112 (name "ruby-yaml-lint")
11117 (uri (git-reference
11118 (url "https://github.com/Pryz/yaml-lint")
11120 (file-name (git-file-name name version))
11123 "1jz26mxjkdyjbgqp7f9isnzd1i6vkizsswyj1v639nmq31hwfh0d"))))
11124 (build-system ruby-build-system)
11127 (modify-phases %standard-phases
11129 (lambda* (#:key tests? #:allow-other-keys)
11134 (list ruby-coveralls ruby-rspec ruby-simplecov))
11135 (synopsis "Simple YAML check tool")
11137 "@code{yaml-lint} will simply try to load the YAML file with the built-in
11138 Ruby yaml library.")
11139 (home-page "https://github.com/Pryz/yaml-lint")
11140 (license license:expat)))
11142 (define-public ruby-mercenary
11144 (name "ruby-mercenary")
11148 (uri (rubygems-uri "mercenary" version))
11151 "0f2i827w4lmsizrxixsrv2ssa3gk1b7lmqh8brk8ijmdb551wnmj"))))
11152 (build-system ruby-build-system)
11153 (arguments `(#:test-target "spec"))
11156 (home-page "https://github.com/jekyll/mercenary")
11157 (synopsis "Command-line apps library in Ruby")
11158 (description "Mercenary is a lightweight and flexible library for writing
11159 command-line apps in Ruby.")
11160 (license license:expat)))
11162 (define-public ruby-liquid
11164 (name "ruby-liquid")
11168 (uri (rubygems-uri "liquid" version))
11171 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))
11172 (build-system ruby-build-system)
11173 (arguments `(#:tests? #f)); No rakefile
11174 (home-page "https://shopify.github.io/liquid/")
11175 (synopsis "Template language")
11176 (description "Liquid is a template language written in Ruby. It is used
11177 to load dynamic content on storefronts.")
11178 (license license:expat)))
11180 (define-public ruby-forwardable-extended
11182 (name "ruby-forwardable-extended")
11186 (uri (rubygems-uri "forwardable-extended" version))
11189 "15zcqfxfvsnprwm8agia85x64vjzr2w0xn9vxfnxzgcv8s699v0v"))))
11190 (build-system ruby-build-system)
11191 (arguments `(#:tests? #f)); Cyclic dependency on luna-rspec-formatters
11192 (home-page "https://github.com/envygeeks/forwardable-extended")
11193 (synopsis "Delegation to hashes and instance variables in Forwardable")
11194 (description "Forwardable Extended provides more @code{Forwardable}
11195 methods for your source as @code{Forwardable::Extended}.")
11196 (license license:expat)))
11198 (define-public ruby-pathutil
11200 (name "ruby-pathutil")
11204 (uri (rubygems-uri "pathutil" version))
11207 "12fm93ljw9fbxmv2krki5k5wkvr7560qy8p4spvb9jiiaqv78fz4"))))
11208 (build-system ruby-build-system)
11210 (list ruby-forwardable-extended))
11212 (list bundler ruby-rspec))
11213 ;; Fails with: cannot load such file --
11214 ;; /tmp/guix-build-ruby-pathutil-0.16.0.drv-0/gem/benchmark/support/task
11215 (arguments `(#:tests? #f))
11216 (home-page "https://github.com/envygeeks/pathutil")
11217 (synopsis "Extended implementation of Pathname")
11218 (description "Pathutil tries to be a faster pure Ruby implementation of
11220 (license license:expat)))
11222 (define-public ruby-terminal-table
11224 (name "ruby-terminal-table")
11229 (uri (rubygems-uri "terminal-table" version))
11232 "18rbrh464ysqbdv53iwj0r8frshn65566kyj044cp3x9c2754jwh"))))
11235 (modify-phases %standard-phases
11236 (add-before 'check 'remove-gemfile-lock
11238 (delete-file "Gemfile.lock")))
11239 (add-before 'check 'remove-unnecessary-dependencies
11241 (substitute* "terminal-table.gemspec"
11242 (("s.add_runtime_dependency.*") "\n")
11243 (("s.add_development_dependency.*") "\n"))
11244 (substitute* "Gemfile"
11245 ((".*tins.*") "\n"))))
11247 (lambda* (#:key tests? #:allow-other-keys)
11249 (invoke "rspec")))))))
11250 (build-system ruby-build-system)
11252 (list ruby-unicode-display-width))
11255 (home-page "https://github.com/tj/terminal-table")
11256 (synopsis "Simple, feature rich ASCII table generation library")
11258 "Terminal Table is a fast and simple, yet feature rich
11259 table generator written in Ruby. It supports ASCII and
11260 Unicode formatted tables.")
11261 (license license:expat)))
11263 (define-public jekyll
11269 (uri (rubygems-uri "jekyll" version))
11272 "0cqkh78jw8scrajyx5nla0vwm9fvp2qql3kdcvvplcq9mazy8snq"))))
11273 (build-system ruby-build-system)
11275 ;; No rakefile, but a test subdirectory.
11278 (modify-phases %standard-phases
11279 (add-before 'build 'fix-i18n
11281 (substitute* ".gemspec"
11282 (("~> 0.7") ">= 0.7")
11283 (("~> 1.14") ">= 1.14"))
11286 `(("ruby-addressable" ,ruby-addressable)
11287 ("ruby-colorator" ,ruby-colorator)
11288 ("ruby-em-websocket" ,ruby-em-websocket)
11289 ("ruby-i18n" ,ruby-i18n)
11290 ("ruby-jekyll-sass-converter" ,ruby-jekyll-sass-converter)
11291 ("ruby-jekyll-watch" ,ruby-jekyll-watch)
11292 ("ruby-kramdown" ,ruby-kramdown-parser-gfm)
11293 ("ruby-liquid" ,ruby-liquid)
11294 ("ruby-mercenary" ,ruby-mercenary)
11295 ("ruby-pathutil" ,ruby-pathutil)
11296 ("ruby-rouge" ,ruby-rouge)
11297 ("ruby-safe-yaml" ,ruby-safe-yaml)
11298 ("ruby-sassc" ,ruby-sassc)
11299 ("ruby-terminal-table" ,ruby-terminal-table)))
11300 (home-page "https://jekyllrb.com/")
11301 (synopsis "Static site generator")
11302 (description "Jekyll is a simple, blog aware, static site generator.")
11303 (license license:expat)))
11305 (define-public ruby-jekyll-paginate-v2
11307 (name "ruby-jekyll-paginate-v2")
11311 (uri (rubygems-uri "jekyll-paginate-v2" version))
11314 "1qzlqhpiqz28624fp0ak76hfy7908w6kpx62v7z43aiwjv0yc6q0"))))
11315 (build-system ruby-build-system)
11318 (home-page "https://github.com/sverrirs/jekyll-paginate-v2")
11319 (synopsis "Pagination Generator for Jekyll 3")
11320 (description "The Pagination Generator forms the core of the pagination
11321 logic in Jekyll. It calculates and generates the pagination pages.")
11322 (license license:expat)))
11324 (define-public ruby-faraday
11326 (name "ruby-faraday")
11331 (uri (rubygems-uri "faraday" version))
11334 "0s72m05jvzc1pd6cw1i289chas399q0a14xrwg4rvkdwy7bgzrh0"))))
11335 (build-system ruby-build-system)
11339 (list ruby-multipart-post))
11340 (synopsis "Ruby HTTP/REST API client library")
11342 "Faraday is a HTTP/REST API client library which provides a common
11343 interface over different adapters.")
11344 (home-page "https://github.com/lostisland/faraday")
11345 (license license:expat)))
11347 (define-public ruby-nio4r
11349 (name "ruby-nio4r")
11354 (uri (rubygems-uri "nio4r" version))
11357 "0gnmvbryr521r135yz5bv8354m7xn6miiapfgpg1bnwsvxz8xj6c"))))
11358 (build-system ruby-build-system)
11361 (modify-phases %standard-phases
11362 (add-after 'unpack 'remove-unnecessary-dependencies
11364 (substitute* "spec/spec_helper.rb"
11365 ;; Coveralls is for uploading test coverage information to an
11366 ;; online service, and thus unnecessary for building the Guix
11368 (("require \"coveralls\"") "")
11369 (("Coveralls\\.wear!") "")
11370 ;; Remove rspec/retry as we are not retrying the tests
11371 (("require \"rspec/retry\"") "")
11372 (("config\\.display_try_failure_messages = true") "")
11373 (("config\\.verbose_retry = true") ""))
11375 (add-before 'check 'compile
11377 (invoke "rake" "compile")
11380 (lambda* (#:key tests? #:allow-other-keys)
11385 (list bundler ruby-rake-compiler ruby-rspec ruby-rubocop))
11386 (synopsis "New I/O for Ruby")
11388 "@code{nio} provides cross-platform asynchronous I/O primitives in Ruby
11389 for scalable network clients and servers.")
11390 (home-page "https://github.com/socketry/nio4r")
11391 (license license:expat)))
11393 (define-public ruby-globalid
11395 (name "ruby-globalid")
11400 (uri (rubygems-uri "globalid" version))
11403 "1zkxndvck72bfw235bd9nl2ii0lvs5z88q14706cmn702ww2mxv1"))))
11404 (build-system ruby-build-system)
11406 '(;; No included tests
11409 (list ruby-activesupport))
11410 (synopsis "Generate URIs idenfitying model instances in Ruby")
11412 "@code{GlobalID} provides a way to generate URIs from a model in Ruby that
11413 uniquely identify it.")
11414 (home-page "https://rubyonrails.org/")
11415 (license license:expat)))
11417 (define-public ruby-sprockets
11419 (name "ruby-sprockets")
11424 (uri (rubygems-uri "sprockets" version))
11427 "182jw5a0fbqah5w9jancvfmjbk88h8bxdbwnl4d3q809rpxdg8ay"))))
11428 (build-system ruby-build-system)
11430 '(;; No included tests
11433 (list ruby-concurrent ruby-rack))
11434 (synopsis "Sprockets is a Rack-based asset packaging system")
11436 "Sprockets is a Rack-based asset packaging system that concatenates and
11437 serves JavaScript, CoffeeScript, CSS, LESS, Sass, and SCSS.")
11438 (home-page "https://github.com/rails/sprockets")
11439 (license license:expat)))
11441 (define-public ruby-mustache
11443 (name "ruby-mustache")
11448 (uri (rubygems-uri "mustache" version))
11450 (base32 "1l0p4wx15mi3wnamfv92ipkia4nsx8qi132c6g51jfdma3fiz2ch"))))
11451 (build-system ruby-build-system)
11453 `(("ruby-simplecov" ,ruby-simplecov)
11455 ,(search-patch "ruby-mustache-1.1.1-fix-race-condition-tests.patch"))))
11458 (modify-phases %standard-phases
11459 (add-after 'unpack 'patch-tests
11460 (lambda* (#:key inputs #:allow-other-keys)
11461 (invoke "patch" "-p1" "--batch" "-i"
11462 (assoc-ref inputs "test-patch")))))))
11463 (synopsis "framework-agnostic way to render logic-free views")
11465 "Mustache is a framework-agnostic way to render logic-free views.
11466 Think of Mustache as a replacement for your views. Instead of views
11467 consisting of ERB or HAML with random helpers and arbitrary logic,
11468 your views are broken into two parts: a Ruby class and an HTML
11470 (home-page "https://github.com/mustache/mustache")
11471 (license license:expat)))
11473 (define-public ruby-mustermann
11475 (name "ruby-mustermann")
11480 (uri (rubygems-uri "mustermann" version))
11483 "0lycgkmnyy0bf29nnd2zql5a6pcf8sp69g9v4xw0gcfcxgpwp7i1"))))
11484 (build-system ruby-build-system)
11488 (synopsis "Library implementing patterns that behave like regular expressions")
11489 (description "Given a string pattern, Mustermann will turn it into an
11490 object that behaves like a regular expression and has comparable performance
11492 (home-page "https://github.com/sinatra/mustermann")
11493 (license license:expat)))
11495 (define-public ruby-html-proofer
11497 (name "ruby-html-proofer")
11502 (uri (git-reference
11503 (url "https://github.com/gjtorikian/html-proofer")
11504 (commit (string-append "v" version))))
11505 (file-name (git-file-name name version))
11508 "1pxb0fajb3l3lm7sqj548qwl7vx6sx3jy7n4cns9d4lqx7s9r9xb"))))
11509 (build-system ruby-build-system)
11511 `(;; FIXME: Tests depend on rubocop-standard.
11514 (list ruby-awesome-print
11518 ruby-rubocop-performance
11521 (list ruby-addressable
11528 (synopsis "Test your rendered HTML files to make sure they're accurate")
11530 "HTMLProofer is a set of tests to validate your HTML output. These
11531 tests check if your image references are legitimate, if they have alt tags,
11532 if your internal links are working, and so on. It's intended to be an
11533 all-in-one checker for your output.")
11534 (home-page "https://github.com/gjtorikian/html-proofer")
11535 (license license:expat)))
11537 (define-public ruby-htmlentities
11539 (name "ruby-htmlentities")
11544 (uri (rubygems-uri "htmlentities" version))
11547 "1nkklqsn8ir8wizzlakncfv42i32wc0w9hxp00hvdlgjr7376nhj"))))
11548 (build-system ruby-build-system)
11551 (modify-phases %standard-phases
11554 (map (lambda (file)
11555 (invoke "ruby" "-Itest" file))
11556 (find-files "./test" ".*_test\\.rb")))))))
11557 (synopsis "Encode and decode (X)HTML entities")
11559 "This package provides a module for encoding and decoding (X)HTML
11561 (home-page "https://github.com/threedaymonk/htmlentities")
11562 (license license:expat)))
11564 (define-public ruby-sinatra
11566 (name "ruby-sinatra")
11567 (version "2.0.8.1")
11571 (uri (rubygems-uri "sinatra" version))
11574 "0riy3hwjab1mr73jcqx3brmbmwspnw3d193j06a5f0fy1w35z15q"))))
11575 (build-system ruby-build-system)
11578 (modify-phases %standard-phases
11579 ;; See: https://github.com/sinatra/sinatra/issues/1578.
11580 (add-after 'extract-gemspec 'fix-slow-doc-generation
11582 (substitute* "sinatra.gemspec"
11583 (("\"README.rdoc\"\\.freeze," all)
11584 (string-append all " \"--exclude=.*\\.md\".freeze,")))
11587 (list ruby-mustermann ruby-rack ruby-rack-protection ruby-tilt))
11588 (synopsis "DSL for quick web applications creation in Ruby")
11590 "Sinatra is a DSL for quickly creating web applications in Ruby with
11592 (home-page "http://sinatrarb.com/")
11593 (license license:expat)))
11595 (define-public ruby-thin
11602 (uri (rubygems-uri "thin" version))
11605 "0nagbf9pwy1vg09k6j4xqhbjjzrg5dwzvkn4ffvlj76fsn6vv61f"))))
11606 (build-system ruby-build-system)
11611 (list ruby-daemons ruby-eventmachine ruby-rack))
11612 (synopsis "Thin and fast web server for Ruby")
11613 (description "Thin is a Ruby web server that glues together 3 Ruby libraries:
11615 @item the Mongrel parser,
11616 @item Event Machine, a network I/O library with high scalability, performance
11618 @item Rack, a minimal interface between webservers and Ruby frameworks.
11620 (home-page "https://github.com/macournoyer/thin")
11621 (license license:ruby)))
11623 (define-public ruby-skinny
11625 (name "ruby-skinny")
11630 (uri (rubygems-uri "skinny" version))
11633 "1y3yvx88ylgz4d2s1wskjk5rkmrcr15q3ibzp1q88qwzr5y493a9"))))
11634 (build-system ruby-build-system)
11636 '(#:tests? #f ; No included tests
11638 (modify-phases %standard-phases
11639 (add-before 'build 'patch-gemspec
11641 (substitute* ".gemspec"
11642 (("<eventmachine>.freeze, \\[\\\"~> 1.0.0\"")
11643 "<eventmachine>, [\">= 1.0.0\"")
11644 (("<thin>.freeze, \\[\\\"< 1.7\", ") "<thin>, ["))
11647 (list ruby-eventmachine ruby-thin))
11648 (synopsis "Simple, upgradable WebSockets for Ruby Thin")
11649 (description "Skinny is a simple, upgradable WebSockets for Ruby, using
11650 the Thin library.")
11651 (home-page "https://github.com/sj26/skinny")
11652 (license license:expat)))
11654 (define-public ruby-sys-filesystem
11656 (name "ruby-sys-filesystem")
11660 (uri (rubygems-uri "sys-filesystem" version))
11663 "0mizqnsiagagmracadr16s5na2ks2j3ih1w0f3gp4ssrda6szl01"))))
11664 (build-system ruby-build-system)
11666 '(#:phases (modify-phases %standard-phases
11667 (add-before 'check 'set-HOME
11669 ;; Some tests attempt to stat $HOME. Let them.
11670 (setenv "HOME" "/tmp")
11675 (list ruby-mkmf-lite))
11676 (synopsis "Gather file system information")
11678 "The @code{sys-filesystem} library provides a cross-platform interface
11679 for gathering file system information, such as disk space and mount points.")
11680 (home-page "https://github.com/djberg96/sys-filesystem")
11681 (license license:asl2.0)))
11683 (define-public mailcatcher
11685 (name "mailcatcher")
11690 (uri (rubygems-uri "mailcatcher" version))
11693 "02w1ycyfv7x0sh9799lz7xa65p5qvl5z4pa8a7prb68h2zwkfq0n"))))
11694 (build-system ruby-build-system)
11696 ;; Tests require web/assets which is not included in the output. We
11697 ;; might be able to fix this by adding the Git repository to the GEM_PATH
11698 ;; of the tests. See ruby-mysql2.
11701 (modify-phases %standard-phases
11702 (add-before 'build 'patch-gemspec
11704 (substitute* ".gemspec"
11705 (("<eventmachine>.freeze, \\[\\\"= 1.0.9.1")
11706 "<eventmachine>, [\">= 1.0.9.1")
11707 (("<rack>.freeze, \\[\\\"~> 1.5") "<rack>, [\">= 1.5")
11708 (("<thin>.freeze, \\[\\\"~> 1.5.0") "<thin>, [\">= 1.5.0")
11709 (("<sinatra>.freeze, \\[\\\"~> 1.2") "<sinatra>, [\">= 1.2"))
11711 (add-before 'build 'loosen-dependency-contraint
11713 (substitute* "lib/mail_catcher.rb"
11714 (("\"eventmachine\", \"1.0.9.1\"") "\"eventmachine\", \">= 1.0.9.1\"")
11715 (("\"rack\", \"~> 1.5\"") "\"rack\", \">= 1.5\"")
11716 (("\"thin\", \"~> 1.5.0\"") "\"thin\", \">= 1.5.0\"")
11717 (("\"sinatra\", \"~> 1.2\"") "\"sinatra\", \">= 1.2\""))
11720 (list ruby-eventmachine
11727 (synopsis "SMTP server which catches messages to display them a browser")
11729 "MailCatcher runs a super simple SMTP server which catches any message
11730 sent to it to display in a web interface. Run mailcatcher, set your favourite
11731 app to deliver to smtp://127.0.0.1:1025 instead of your default SMTP server,
11732 then check out http://127.0.0.1:1080 to see the mail.")
11733 (home-page "https://mailcatcher.me")
11734 (license license:expat)))
11736 (define-public ruby-backport
11738 (name "ruby-backport")
11742 ;; The gem does not include test code, so fetch from the Git repository.
11744 (uri (git-reference
11745 (url "https://github.com/castwide/backport")
11746 (commit (string-append "v" version))))
11747 (file-name (git-file-name name version))
11749 (base32 "18fpg1n7n2z02ykz9v1x1q0cqa2lvivf8ygka768s01q1r9wfwv2"))))
11750 (build-system ruby-build-system)
11752 `(#:test-target "spec"))
11754 (list bundler ruby-rspec))
11756 (list ruby-simplecov))
11757 (synopsis "Pure Ruby library for event-driven IO")
11759 "This package provides a pure Ruby library for event-driven IO.")
11760 (home-page "https://github.com/castwide/backport")
11761 (license license:expat)))
11763 (define-public ruby-json-schema
11765 (name "ruby-json-schema")
11770 (uri (rubygems-uri "json-schema" version))
11773 "1yv5lfmr2nzd14af498xqd5p89f3g080q8wk0klr3vxgypsikkb5"))))
11774 (build-system ruby-build-system)
11776 `(#:tests? #f ; no tests
11778 (modify-phases %standard-phases
11781 (invoke "gem" "build" ".gemspec"))))))
11783 (list ruby-addressable))
11784 (synopsis "Ruby JSON Schema Validator")
11785 (description "This library provides Ruby with an interface for validating
11786 JSON objects against a JSON schema conforming to JSON Schema Draft 4. Legacy
11787 support for JSON Schema Draft 3, JSON Schema Draft 2, and JSON Schema Draft 1
11788 is also included.")
11789 (home-page "https://github.com/ruby-json-schema/json-schema")
11790 (license license:expat)))
11792 (define-public swagger-diff
11794 (name "swagger-diff")
11799 (uri (rubygems-uri "swagger-diff" version))
11802 "1hxx50nga1bqn254iqjcdwkc9c72364ks9lyjyw10ajz0l0ly7sn"))))
11803 (build-system ruby-build-system)
11805 `(#:test-target "spec"
11807 (modify-phases %standard-phases
11808 ;; Don't run or require rubocop, the code linting tool, as this is a
11809 ;; bit unnecessary.
11810 (add-after 'unpack 'dont-run-rubocop
11812 (substitute* "Rakefile"
11813 ((".*rubocop.*") "")
11814 ((".*RuboCop.*") ""))
11817 (list ruby-json-schema))
11819 (list bundler ruby-rspec-core ruby-rspec-expectations))
11821 "Compare Open API Initiative specification files")
11823 "Swagger::Diff is a utility for comparing two different Open API
11824 Initiative (OAI) specifications (formerly known as Swagger specifications).
11825 It is intended to determine whether a newer API specification is
11826 backwards-compatible with an older API specification.")
11827 (home-page "https://github.com/civisanalytics/swagger-diff")
11828 (license license:bsd-3)))
11830 (define-public ruby-reverse-markdown
11832 (name "ruby-reverse-markdown")
11837 (uri (rubygems-uri "reverse_markdown" version))
11840 "0w7y5n74daajvl9gixr91nh8670d7mkgspkk3ql71m8azq3nffbg"))))
11841 (build-system ruby-build-system)
11843 (list ruby-nokogiri))
11845 (list bundler ruby-rspec ruby-kramdown ruby-simplecov))
11848 (modify-phases %standard-phases
11850 (lambda* (#:key tests? #:allow-other-keys)
11854 (synopsis "Convert HTML into Markdown")
11856 "This Ruby module allows you to map simple HTML back into
11857 Markdown---e.g., if you want to import existing HTML data in your
11859 (home-page "https://github.com/xijo/reverse_markdown")
11860 (license license:wtfpl2)))
11862 (define-public ruby-solargraph
11864 (name "ruby-solargraph")
11869 (uri (rubygems-uri "solargraph" version))
11872 "1gf049rm0yvw4r8r5yyi890idbfg8qh0dikqx5prvkh11srl73bz"))))
11873 (build-system ruby-build-system)
11875 (list ruby-backport
11881 ruby-kramdown-parser-gfm
11885 ruby-reverse-markdown
11891 (list ruby-rspec ruby-pry ruby-simplecov ruby-webmock))
11892 ;; FIXME: can't figure out how to run the tests properly:
11894 ;; An error occurred while loading spec_helper.
11895 ;; Failure/Error: return gem_original_require(path)
11897 ;; cannot load such file -- spec_helper
11901 (modify-phases %standard-phases
11903 (lambda* (#:key tests? #:allow-other-keys)
11908 "IDE tools for code completion, inline documentation, and static analysis")
11910 "Solargraph provides a comprehensive suite of tools for Ruby
11911 programming: intellisense, diagnostics, inline documentation, and type
11913 (home-page "https://solargraph.org/")
11914 (license license:expat)))
11916 (define-public ruby-wayback-machine-downloader
11918 (name "ruby-wayback-machine-downloader")
11924 "wayback_machine_downloader"
11928 "12kb1qmvmmsaihqab1prn6cmynkn6cgb4vf41mgv22wkcgv5wgk2"))))
11929 (build-system ruby-build-system)
11931 '(#:tests? #f)) ; no tests
11932 (synopsis "Download archived websites from the Wayback Machine")
11934 "Wayback Machine Downloader is a command line tool for downloading
11935 websites from the Internet Archive's Wayback Machine (archive.org).
11936 It allows fine grained control over what to download by specifying
11937 which snapshots to consider and what files to include.")
11939 "https://github.com/hartator/wayback-machine-downloader")
11940 (license license:expat)))
11942 (define-public ruby-zeitwerk
11944 (name "ruby-zeitwerk")
11949 (uri (git-reference
11950 ;; No tests in the released gem.
11951 (url "https://github.com/fxn/zeitwerk")
11952 (commit (string-append "v" version))))
11953 (file-name (git-file-name name version))
11956 "119fgdyb57gmss2yvfwfr47wcy8nny38sai72446krpihyavpizw"))))
11957 (build-system ruby-build-system)
11959 (list ruby-minitest ruby-minitest-focus ruby-minitest-reporters))
11960 (synopsis "Efficient and thread-safe code loader for Ruby")
11962 "Zeitwerk implements constant autoloading with Ruby semantics. Each gem
11963 and application may have their own independent autoloader, with its own
11964 configuration, inflector, and logger. Supports autoloading, reloading, and
11966 (home-page "https://github.com/fxn/zeitwerk")
11967 (license license:expat)))
11969 (define-public ruby-wwtd
11973 (home-page "https://github.com/grosser/wwtd")
11976 (uri (git-reference
11978 (commit (string-append "v" version))))
11979 (file-name (git-file-name name version))
11982 "0gw7vfnbb41cy67yw82zji3jkhfsgmzcgzaszm99ax77y18wclf2"))
11983 (modules '((guix build utils)))
11986 ;; Remove bundled library.
11987 (delete-file "spec/rake-12.3.0.gem")
11989 (build-system ruby-build-system)
11991 '(;; XXX: Tests need multiple versions of ruby, wants to run
11992 ;; `bundle install`, etc.
11994 #:phases (modify-phases %standard-phases
11995 (replace 'replace-git-ls-files
11997 (substitute* "wwtd.gemspec"
11998 (("git ls-files lib/ bin/`")
11999 "find lib/ bin/ -type f |sort`"))
12001 (add-before 'check 'remove-version-constraints
12003 (delete-file "Gemfile.lock")
12006 (lambda* (#:key tests? #:allow-other-keys)
12008 (invoke "rspec" "spec/")
12009 (format #t "test suite not run~%"))
12012 (list ruby-bump ruby-rspec))
12013 (synopsis "Run @file{.travis.yml} files locally")
12015 "WWTD is a @dfn{Travis Simulator} that lets you run test matrices
12016 defined in @file{.travis.yml} on your local machine, using @code{rvm},
12017 @code{rbenv}, or @code{chruby} to test different versions of Ruby.")
12018 (license license:expat)))
12020 (define-public ruby-rugged
12022 (name "ruby-rugged")
12024 (home-page "https://www.rubydoc.info/gems/rugged")
12028 (uri (rubygems-uri "rugged" version))
12030 (base32 "04aq913plcxjw71l5r62qgz3bx3466p0wvgyfqahg5n3nybmcwqy"))))
12031 (build-system ruby-build-system)
12034 #:gem-flags (list "--" "--use-system-libraries")))
12038 (list ruby-minitest ruby-pry ruby-rake-compiler))
12039 (synopsis "Ruby bindings to the libgit2 linkable C Git library")
12040 (description "Rugged is a library for accessing libgit2 in Ruby. It gives
12041 you the speed and portability of libgit2 with the beauty of the Ruby
12043 (license license:expat)))
12045 (define-public ruby-yell
12052 (uri (rubygems-uri "yell" version))
12055 "1g16kcdhdfvczn7x81jiq6afg3bdxmb73skqjyjlkp5nqcy6y5hx"))))
12056 (build-system ruby-build-system)
12059 (modify-phases %standard-phases
12062 (invoke "rake" "examples")))))) ; there is no test target.
12064 "Extensible logging library for Ruby")
12066 "Yell is a comprehensive logging replacement for Ruby. It defines
12067 multiple adapters, various log level combinations and message formatting
12069 (home-page "https://github.com/rudionrails/yell")
12070 (license license:expat)))
12072 (define-public ruby-e2mmap
12074 (name "ruby-e2mmap")
12079 (uri (rubygems-uri "e2mmap" version))
12082 "0n8gxjb63dck3vrmsdcqqll7xs7f3wk78mw8w0gdk9wp5nx6pvj5"))))
12083 (build-system ruby-build-system)
12085 `(#:tests? #f)) ;; There is a rakefile but no tests
12087 "Module for defining custom exceptions with specific messages")
12089 "Exception2MessageMapper (e2mmap) is a helper module for easily defining
12090 exceptions with predefined messages.")
12091 (home-page "https://github.com/ruby/e2mmap")
12092 (license license:bsd-2)))
12094 (define-public ruby-benchmark
12096 (name "ruby-benchmark")
12101 (uri (rubygems-uri "benchmark" version))
12104 "1jvrl7400fv7v2jjri1r7ilj3sri36hzipwwgpn5psib4c9c59c6"))))
12105 (build-system ruby-build-system)
12106 (synopsis "Performance benchmarking library")
12107 (description "This package provides methods for benchmarking Ruby code,
12108 giving detailed reports on the time taken for each task.")
12109 (home-page "https://github.com/ruby/benchmark")
12110 (license license:bsd-2)))
12112 (define-public ruby-jekyll-feed
12114 (name "ruby-jekyll-feed")
12119 (uri (rubygems-uri "jekyll-feed" version))
12122 "1zxqkrnix0xiw98531h5ga6h69jhzlx2jh9qhvcl67p8nq3sgza9"))))
12123 (build-system ruby-build-system)
12125 `(#:tests? #false)) ;there are none
12129 "Jekyll plugin to generate an Atom feed of your Jekyll posts")
12131 "This package provides a Jekyll plugin to generate an Atom feed
12132 of your Jekyll posts.")
12134 "https://github.com/jekyll/jekyll-feed")
12135 (license license:expat)))
12137 (define-public ruby-jekyll-sitemap
12139 (name "ruby-jekyll-sitemap")
12144 (uri (rubygems-uri "jekyll-sitemap" version))
12147 "0622rwsn5i0m5xcyzdn86l68wgydqwji03lqixdfm1f1xdfqrq0d"))))
12148 (build-system ruby-build-system)
12150 `(#:tests? #false)) ;there are none
12154 "Automatically generate a sitemap.xml for your Jekyll site")
12156 "This package provides a Jekyll plugin to silently generate
12157 a sitemaps.org compliant sitemap for your Jekyll site.")
12159 "https://github.com/jekyll/jekyll-sitemap")
12160 (license license:expat)))
12162 (define-public ruby-jekyll-seo-tag
12164 (name "ruby-jekyll-seo-tag")
12169 (uri (rubygems-uri "jekyll-seo-tag" version))
12172 "0fsi75hymk2wswy216fs224p5ycrzjw1kshw1bsl5czhv42wr2w3"))))
12173 (build-system ruby-build-system)
12175 `(#:tests? #false))
12179 "Jekyll plugin to add metadata tags for search engines and social networks")
12181 "This package provides a Jekyll plugin to add metadata tags for search engines
12182 and social networks to better index and display your site's content.")
12184 "https://github.com/jekyll/jekyll-seo-tag")
12185 (license license:expat)))
12187 (define-public ruby-taskjuggler
12189 (name "ruby-taskjuggler")
12194 (uri (rubygems-uri "taskjuggler" version))
12197 "1jrsajzhzpnfa8hj6lbf7adn8hls56dz3yw1gvzgz9y4zkka3k9v"))))
12198 (build-system ruby-build-system)
12199 (native-inputs (list tzdata-for-tests))
12201 (list ruby-mail ruby-term-ansicolor))
12203 '(#:phases (modify-phases %standard-phases
12204 (replace 'replace-git-ls-files
12206 (substitute* "tasks/rdoc.rake"
12207 (("`git ls-files -- lib`")
12208 "`find lib/ -type f |sort`"))
12210 (add-before 'check 'tzdir-setup
12211 (lambda* (#:key inputs #:allow-other-keys)
12213 (string-append (assoc-ref inputs "tzdata")
12214 "/share/zoneinfo"))
12216 (add-before 'check 'delete-test-BatchProcessor
12217 ;; test_BatchProcessor fails with exeption:
12218 ;; run> terminated with exception (report_on_exception is true)
12220 (delete-file "test/test_BatchProcessor.rb")
12223 "Project management command line tool with a domain specific language")
12225 "TaskJuggler (tj3) is a project management tool for project planning and
12226 tracking using a domain specific language; projects are plain text files
12227 written using your favourite text editor. It includes reporting in HTML, CSV
12228 or iCalendar format and an email based status tracking system to send and
12229 receive time sheets from collaborators.
12231 It covers the complete spectrum of project management tasks from the first
12232 idea to the completion of the project. It assists you during project scoping,
12233 resource assignment, cost and revenue planning, risk and communication
12234 management, status tracking and reporting.")
12235 (home-page "https://taskjuggler.org")
12236 (license license:gpl2)))
12238 (define-public ruby-cmath
12240 (name "ruby-cmath")
12245 (uri (rubygems-uri "cmath" version))
12248 "1xkz6xyhpkjbdvpdib8450w62rls1mjryz0gzbbnadxkxn82nb8m"))))
12249 (build-system ruby-build-system)
12251 `(#:tests? #false))
12253 (list bundler ruby-rake-compiler))
12254 (synopsis "Trigonometric functions for complex numbers")
12256 "This gem is a library that provides trigonometric and transcendental
12257 functions for complex numbers. The functions in this module accept integers,
12258 floating-point numbers or complex numbers as arguments.")
12259 (home-page "https://github.com/ruby/cmath")
12260 (license license:bsd-2)))
12262 (define-public ruby-sucker-punch
12264 (name "ruby-sucker-punch")
12269 (uri (rubygems-uri "sucker_punch" version))
12271 (base32 "0yams24wndpj7dzdysvm4z1w6ggg4xvj4snxba66prahhxvik4xl"))))
12272 (build-system ruby-build-system)
12275 (modify-phases %standard-phases
12276 (add-after 'extract-gemspec 'less-strict-dependencies
12278 (substitute* "sucker_punch.gemspec"
12279 (("1.0.0") "1.0")))))))
12286 (home-page "https://github.com/brandonhilkert/sucker_punch")
12287 (synopsis "Asynchronous processing library for Ruby")
12288 (description "Sucker Punch is a single-process Ruby asynchronous processing
12289 library. It is perfect for asynchronous processes like emailing, data crunching
12290 or social platform manipulation; and generally recommended for jobs that are
12291 fast and non-mission critical like logs, emails, etc.")
12292 (license license:expat)))
12294 (define-public ruby-countdownlatch
12296 (name "ruby-countdownlatch")
12301 (uri (rubygems-uri "countdownlatch" version))
12303 (base32 "1v6pbay6z07fp7yvnba1hmyacbicvmjndd8rn2h1b5rmpcb5s0j3"))))
12304 (build-system ruby-build-system)
12305 (home-page "https://github.com/benlangfeld/countdownlatch")
12306 (synopsis "Thread synchronization aid Ruby")
12307 (description "CountDownLatch is a synchronization aid that allows one or
12308 more threads to wait until a set of operations being performed in other threads
12310 (license license:expat)))
12312 (define-public ruby-value-semantics
12314 (name "ruby-value-semantics")
12319 (uri (rubygems-uri "value_semantics" version))
12321 (base32 "1vdwai8wf6r1fkvdpyz1vzxm89q7ghjvb3pqpg2kvwibwzd99dnx"))))
12322 (build-system ruby-build-system)
12325 (modify-phases %standard-phases
12327 (lambda* (#:key tests? #:allow-other-keys)
12329 (invoke "rspec")))))))
12333 (home-page "https://github.com/tomdalling/value_semantics")
12334 (synopsis "Ruby gem for making value classes")
12335 (description "ValueSemantics generates modules that provide conventional
12336 value semantics for a given set of attributes. The behaviour is similar to an
12337 immutable Struct class, plus extensible, lightweight validation and coercion.")
12338 (license license:expat)))
12340 (define-public ruby-promise
12342 (name "ruby-promise")
12347 (uri (rubygems-uri "promise.rb" version))
12349 (base32 "0a819sikcqvhi8hck1y10d1nv2qkjvmmm553626fmrh51h2i089d"))))
12350 (build-system ruby-build-system)
12352 `(#:test-target "spec"
12354 (modify-phases %standard-phases
12355 (add-after 'extract-gemspec 'less-strict-dependencies
12357 (substitute* "Rakefile"
12358 (("if Gem.ruby_version.*") "if false\n"))
12359 (substitute* "spec/spec_helper.rb"
12360 ((".*devtools/spec_helper.*") "\n")))))))
12367 (home-page "https://github.com/lgierth/promise.rb")
12368 (synopsis "Asynchronous operation library for Ruby")
12369 (description "Promise is a Ruby implementation of the Promises/A+
12370 specification. It provides 100% mutation coverage, tested on MRI 1.9, 2.0, 2.1,
12371 2.2, Rubinius, and JRuby.")
12372 (license license:unlicense)))
12374 (define-public ruby-multicodecs
12376 (name "ruby-multicodecs")
12381 (uri (rubygems-uri "multicodecs" version))
12383 (base32 "0drq267di57l9zqw6zvqqimilz42rbc8z7392dwkk8wslq30s7v8"))))
12384 (build-system ruby-build-system)
12385 (home-page "https://github.com/SleeplessByte/ruby-multicodec")
12386 (synopsis "Ruby implementation of multiformats/multicodec")
12387 (description "Multicodecs is the ruby implementation of
12388 multiformats/multicodec, a canonical table of of codecs used by various
12390 (license license:expat)))
12392 (define-public ruby-multihashes
12394 (name "ruby-multihashes")
12399 (uri (rubygems-uri "multihashes" version))
12401 (base32 "17wiyy3fiv8rpgdv9ca01yncsmaaf8yg15bg18wc7m9frss1vgqg"))))
12402 (build-system ruby-build-system)
12406 (home-page "https://github.com/multiformats/ruby-multihash")
12407 (synopsis "Multihash implementation for Ruby")
12408 (description "Multihashes provides a simple, low-level multihash
12409 implementation for Ruby. A multihash is a digest with an embedded hash function
12411 (license license:expat)))
12413 (define-public ruby-lazy-object
12415 (name "ruby-lazy-object")
12420 (uri (rubygems-uri "lazy_object" version))
12422 (base32 "08px15lahc28ik9smvw1hgamf792gd6gq0s4k94yq1h7jq25wjn8"))))
12423 (build-system ruby-build-system)
12425 `(#:test-target "spec"))
12426 (home-page "https://github.com/HornsAndHooves/lazy_object")
12427 (synopsis "Object wrapper that forwards all calls to the reference object")
12428 (description "LazyObject is an object wrapper that forwards all calls to the
12429 reference object. This object is not created until the first method dispatch.")
12430 (license license:expat)))
12432 (define-public ruby-citrus
12434 (name "ruby-citrus")
12439 ;; Download from GitHub because the rubygems version does not contain
12440 ;; files needed for tests.
12441 (uri (git-reference
12442 (url "https://github.com/mjackson/citrus")
12443 (commit (string-append "v" version))))
12444 (file-name (git-file-name name version))
12446 (base32 "197wrgqrddgm1xs3yvjvd8vkvil4h4mdrcp16jmd4b57rxrrr769"))))
12447 (build-system ruby-build-system)
12448 (home-page "http://mjackson.github.io/citrus/")
12449 (synopsis "Parsing Expressions for Ruby")
12450 (description "Citrus is a parsing library for Ruby that combines the
12451 expressiveness of the language with the parsing expressions.")
12452 (license license:expat)))
12454 (define-public ruby-cbor
12457 (version "0.5.9.6")
12461 (uri (rubygems-uri "cbor" version))
12463 (base32 "0511idr8xps9625nh3kxr68sdy6l3xy2kcz7r57g47fxb1v18jj3"))))
12464 (build-system ruby-build-system)
12466 `(#:test-target "spec"))
12472 (home-page "http://cbor.io/")
12473 (synopsis "Concise Binary Object Representation")
12474 (description "CBOR is a library for the
12475 @acronym{CBOR, Concise Binary Object Representation} format, based on
12476 Sadayuki Furuhashi's MessagePack library.")
12477 (license license:asl2.0)))
12479 (define-public ruby-gem-release
12481 (name "ruby-gem-release")
12486 (uri (rubygems-uri "gem-release" version))
12488 (base32 "108rrfaiayi14zrqbb6z0cbwcxh8n15am5ry2a86v7c8c3niysq9"))))
12489 (build-system ruby-build-system)
12493 (home-page "https://github.com/svenfuchs/gem-release")
12494 (synopsis "Ruby gem plugin for release management")
12495 (description "GemRelease is a gem plugin that aims at making gem development
12496 easier by automating repetitive work based on conventions, configuration, and
12498 (license license:expat)))
12500 (define-public ruby-base32
12502 (name "ruby-base32")
12507 (uri (rubygems-uri "base32" version))
12509 (base32 "1fjs0l3c5g9qxwp43kcnhc45slx29yjb6m6jxbb2x1krgjmi166b"))))
12510 (build-system ruby-build-system)
12514 (home-page "https://github.com/stesla/base32")
12515 (synopsis "Ruby extension for base32 encoding and decoding")
12516 (description "Base32 is a library which provides base32 decoding and
12518 (license license:expat)))
12520 (define-public ruby-dhall
12522 (name "ruby-dhall")
12527 (uri (rubygems-uri "dhall" version))
12529 (base32 "09wcq8xc1ynld04r2f332bx8cn7rjc4afaq8hm1dr2fc35jlpn6m"))))
12530 (build-system ruby-build-system)
12532 ;; No test in gem archive
12542 ruby-value-semantics))
12543 (home-page "https://git.sr.ht/~singpolyma/dhall-ruby")
12544 (synopsis "Ruby implementation of the Dhall configuration language")
12545 (description "Dhall.rb is a Ruby implementation of the Dhall configuration
12546 language. Dhall is a memory safe and non-Turing-complete configuration
12548 (license license:gpl3+)))
12550 (define-public ruby-money
12552 (name "ruby-money")
12557 (uri (rubygems-uri "money" version))
12559 (base32 "0jkmsj5ymadik7bvl670bqwmvhsdyv7hjr8gq9z293hq35gnyiyg"))))
12560 (build-system ruby-build-system)
12567 (home-page "https://rubymoney.github.io/money/")
12568 (synopsis "Currency conversion library for Ruby")
12569 (description "RubyMoney provides a library for dealing with money and
12570 currency conversion. Its features are:
12573 Provides a Money class which encapsulates all information about a certain
12574 amount of money, such as its value and its currency.
12576 Provides a Money::Currency class which encapsulates all information about a
12579 Represents monetary values as integers, in cents; so avoids floating point
12582 Represents currency as Money::Currency instances providing a high level of
12584 @item Provides APIs for exchanging money from one currency to another.
12586 (license license:expat)))
12588 (define-public ruby-monetize
12590 (name "ruby-monetize")
12595 (uri (rubygems-uri "monetize" version))
12597 (base32 "0cna2myxdbwfq0gn6k2hgrh368dq7wld3jklm96443ysykd0difn"))))
12598 (build-system ruby-build-system)
12600 `(#:test-target "spec"))
12607 (home-page "https://github.com/RubyMoney/monetize")
12608 (synopsis "Convert various objects into Money objects")
12609 (description "Monetize provides a library for converting various objects
12610 into Money objects.")
12611 (license license:expat)))
12613 (define-public ruby-money-open-exchange-rates
12615 (name "ruby-money-open-exchange-rates")
12620 ;; Download from GitHub because the rubygems version does not contain
12622 (uri (git-reference
12623 (url "https://github.com/spk/money-open-exchange-rates")
12624 (commit (string-append "v" version))))
12625 (file-name (git-file-name name version))
12627 (base32 "11xwqli8snr19k48yh8h77sal5vxd4snzq9gxg08v61f0574m3gw"))))
12628 (build-system ruby-build-system)
12641 (home-page "https://spk.github.io/money-open-exchange-rates/")
12642 (synopsis "Money open exchange rates for Ruby")
12643 (description "This package provides a gem that calculates the exchange rate
12644 using published rates from open-exchange-rates. Compatible with the money gem.")
12645 (license license:expat)))
12647 (define-public ruby-roda
12654 (uri (rubygems-uri "roda" version))
12656 (base32 "0nkfxnbcfnriywvx9kpamp850cwjmqv8ssajc95d0aiyjr4kdrfy"))))
12657 (build-system ruby-build-system)
12661 (propagated-inputs (list ruby-rack))
12662 (home-page "http://roda.jeremyevans.net")
12663 (synopsis "Routing Tree Web Toolkit")
12664 (description "Roda is a routing tree web toolkit, designed for building fast
12665 and maintainable web applications in ruby.")
12666 (license license:expat)))
12668 (define-public ruby-nori
12675 (uri (rubygems-uri "nori" version))
12677 (base32 "066wc774a2zp4vrq3k7k8p0fhv30ymqmxma1jj7yg5735zls8agn"))))
12678 (build-system ruby-build-system)
12680 ;; Tests require too old version of rspec
12683 (list ruby-nokogiri
12686 (home-page "https://github.com/savonrb/nori")
12687 (synopsis "XML to Hash translator")
12688 (description "Nori is a simple XML parsing ripped from Crack which in-turn
12689 ripped from Merb. It supports pluggable parsers and ships with both REXML and
12690 Nokogiri implementations.")
12691 (license license:expat)))
12693 (define-public ruby-faraday-middleware
12695 (name "ruby-faraday-middleware")
12700 (uri (rubygems-uri "faraday_middleware" version))
12702 (base32 "1bw8mfh4yin2xk7138rg3fhb2p5g2dlmdma88k82psah9mbmvlfy"))))
12703 (build-system ruby-build-system)
12708 (list ruby-faraday))
12709 (home-page "https://github.com/lostisland/faraday_middleware")
12710 (synopsis "Various middleware for Faraday")
12711 (description "Faraday_Middleware is a collection of middleware for the
12712 Faraday-based API wrappers.")
12713 (license license:expat)))
12715 (define-public ruby-bandwidth-iris
12717 (name "ruby-bandwidth-iris")
12722 (uri (rubygems-uri "ruby-bandwidth-iris" version))
12724 (base32 "1hmrxs0dif6fw5npyzcshk4nq9qr2kbmnx7mdjr5v1nhzlfr0678"))))
12725 (build-system ruby-build-system)
12727 ;; XXX: Tests don't require helper for some reason, so all fail.
12733 (list ruby-activesupport
12736 ruby-faraday-middleware
12738 (home-page "https://github.com/Bandwidth/ruby-bandwidth-iris")
12739 (synopsis "Gem for integrating to Bandwidth's Iris API")
12740 (description "Bandwidth IRIS is a Ruby SDK for Bandwidth Phone Number
12741 Dashboard. It is a Ruby Client library for IRIS / BBS API.")
12742 (license license:expat)))
12744 (define-public ruby-sentry-core
12746 (name "ruby-sentry-core")
12751 (uri (rubygems-uri "sentry-ruby-core" version))
12753 (base32 "141mrw8wghhsjvln9m6ld3hap3xc5v901jjiz007xywy25725hyd"))))
12754 (build-system ruby-build-system)
12756 ;; No rakefile in gem.
12759 (list ruby-concurrent
12761 (home-page "https://sentry.io/for/ruby/")
12762 (synopsis "Client interface for the Sentry error logger")
12763 (description "Sentry-Core provides a gem that provides a client
12764 interface for the Sentry error logger.")
12765 (license license:expat)))
12767 (define-public ruby-sentry
12769 (name "ruby-sentry")
12774 (uri (rubygems-uri "sentry-ruby" version))
12776 (base32 "0by9mvw8rklzpyx59vfija8h3ssfvxvf5nbqxfmygfy6lm1vdngz"))))
12777 (build-system ruby-build-system)
12779 ;; No rakefile in gem
12782 (list ruby-concurrent
12785 (home-page "https://sentry.io/for/ruby/")
12786 (synopsis "Client interface for the Sentry error logger")
12787 (description "Sentry provides a gem that provides a client
12788 interface for the Sentry error logger.")
12789 (license license:expat)))
12791 (define-public ruby-webrick
12793 (name "ruby-webrick")
12798 (uri (rubygems-uri "webrick" version))
12800 (base32 "1d4cvgmxhfczxiq5fr534lmizkhigd15bsx5719r5ds7k7ivisc7"))))
12801 (build-system ruby-build-system)
12802 (home-page "https://github.com/ruby/webrick")
12803 (synopsis "HTTP server toolkit")
12804 (description "WEBrick is an HTTP server toolkit that can be configured as an
12805 HTTPS server, a proxy server, and a virtual-host server.")
12806 (license license:bsd-2)))
12808 (define-public ruby-interception
12810 (name "ruby-interception")
12815 (uri (rubygems-uri "interception" version))
12817 (base32 "01vrkn28psdx1ysh5js3hn17nfp1nvvv46wc1pwqsakm6vb1hf55"))))
12818 (build-system ruby-build-system)
12819 (native-inputs (list ruby-rspec))
12820 (home-page "https://github.com/ConradIrwin/interception")
12821 (synopsis "Listen to raise in Ruby")
12822 (description "Interception provides a cross-platform ability to intercept all
12823 exceptions as they are raised.")
12824 (license license:expat)))
12826 (define-public ruby-pry-rescue
12828 (name "ruby-pry-rescue")
12833 (uri (rubygems-uri "pry-rescue" version))
12835 (base32 "1wn72y8y3d3g0ng350ld92nyjln012432q2z2iy9lhwzjc4dwi65"))))
12836 (build-system ruby-build-system)
12839 (modify-phases %standard-phases
12840 (add-after 'unpack 'nuke-bad-test
12842 (substitute* "spec/source_location_spec.rb"
12843 (("time = Time.now") "skip")))))))
12846 ruby-pry-stack-explorer))
12848 (list ruby-interception
12851 "https://github.com/ConradIrwin/pry-rescue")
12852 (synopsis "Start Pry session for rescue")
12853 (description "Pry-Rescue allows you to wrap code, to open a pry session at
12854 any unhandled exceptions.")
12855 (license license:expat)))
12857 (define-public ruby-braintree
12859 (name "ruby-braintree")
12864 ;; Download from GitHub because the rubygems version does not contain
12866 (uri (git-reference
12867 (url "https://github.com/braintree/braintree_ruby")
12869 (file-name (git-file-name name version))
12871 (base32 "1gixqf9vsjsyrk45lf9xcz0ggdydpgsk8ahknd27bbigz1j4pdf6"))))
12872 (build-system ruby-build-system)
12874 `(#:test-target "test:unit"
12876 (modify-phases %standard-phases
12877 (add-after 'unpack 'less-strict-dependencies
12879 (substitute* "Gemfile"
12880 (("gem \"libxml-ruby\", \"3.2.0\"")
12881 "gem \"libxml-ruby\", \"~> 3.0.0\"")
12882 (("gem \"rspec\", \"3.9.0\"")
12883 "gem \"rspec\", \"~> 3.8.0\"")
12884 (("gem \"rubocop\", \"~>1.12.0\"")
12885 "gem \"rubocop\", \"~> 1.10.0\"")))))))
12896 (home-page "https://www.braintreepayments.com/")
12897 (synopsis "Integration access to the Braintree Gateway")
12898 (description "Braintree provides resources and tools for developers to
12899 integrate Braintree's global payments platform.")
12900 (license license:expat)))
12902 (define-public ruby-niceogiri
12904 (name "ruby-niceogiri")
12909 (uri (rubygems-uri "niceogiri" version))
12911 (base32 "1ha93211bc9cvh23s9w89zz7rq8irpf64ccd9arvg8v1sxg2798a"))))
12912 (build-system ruby-build-system)
12914 `(#:test-target "spec"
12916 (modify-phases %standard-phases
12917 (add-after 'extract-gemspec 'less-strict-dependencies
12919 (substitute* "niceogiri.gemspec"
12920 (("2\\.7") "3.8") ;rspec
12921 ((".*dependency.*bundler.*") "\n")
12922 ((".*dependency.*guard-rspec.*") "\n")))))))
12926 (propagated-inputs (list ruby-nokogiri))
12927 (home-page "https://github.com/benlangfeld/Niceogiri")
12928 (synopsis "Supplement for Nokogiri")
12929 (description "Niceogiri provides wrappers and helpers for XML manipulation
12931 (license license:expat)))
12933 (define-public ruby-blather
12935 (name "ruby-blather")
12940 (uri (rubygems-uri "blather" version))
12942 (base32 "05ry2x835fj4pzk61282pcz86n018cr39zbgwbi213md74i90s7c"))))
12943 (build-system ruby-build-system)
12945 ;; XXX: Tests require too old version of rspec.
12948 (list ruby-countdownlatch
12954 (list ruby-activesupport
12958 ruby-sucker-punch))
12959 (home-page "https://github.com/adhearsion/blather")
12960 (synopsis "XMPP Domain Specific Language for Ruby")
12961 (description "Blather is a XMPP DSL for Ruby written on top of EventMachine
12963 (license license:expat)))
12965 (define-public ruby-wapiti
12967 (name "ruby-wapiti")
12969 ;; the gem archive lacks tests
12972 (uri (git-reference
12973 (url "https://github.com/inukshuk/wapiti-ruby")
12975 (file-name (git-file-name name version))
12978 "1kawqw45j7mqk5zmwbn67x1vxiapdgm2ypqqz2bs9l5s7nglzr5b"))))
12979 (build-system ruby-build-system)
12991 #:test-target "spec"
12993 #~(modify-phases %standard-phases
12994 (add-after 'replace-git-ls-files 'replace-another-git-ls-files
12996 (substitute* "wapiti.gemspec"
12997 (("`git ls-files spec`")
12998 "`find spec -type f | sort`"))))
12999 (add-before 'build 'compile
13001 (invoke "rake" "compile"))))))
13002 (home-page "https://github.com/inukshuk/wapiti-ruby")
13003 (synopsis "Wicked fast Conditional Random Fields for Ruby")
13005 "The Wapiti-Ruby gem provides a wicked fast linear-chain @acronym{CRF,
13006 Conditional Random Fields} API for sequence segmentation and labelling. It is
13007 based on the codebase of @url{https://wapiti.limsi.fr, Wapiti}.")
13008 (license license:bsd-2)))
13010 (define-public ruby-namae
13012 (name "ruby-namae")
13016 (uri (rubygems-uri "namae" version))
13019 "1j3nl1klkx3gymrdxfc1hlq4a8qlvhhl9aj5v1v08b9fz27sky0l"))))
13020 (build-system ruby-build-system)
13022 (list ruby-cucumber
13028 #~(modify-phases %standard-phases
13029 (add-after 'extract-gemspec 'allow-newer-cucumber
13031 (substitute* "Gemfile"
13032 (("'cucumber', '[^']*'")
13035 ;; Avoid 'rake' so we don't need jeweler.
13036 (lambda* (#:key tests? #:allow-other-keys)
13040 (find-files "spec" "_spec\\.rb$"))))))))
13041 (home-page "https://github.com/berkmancenter/namae")
13042 (synopsis "Parser for human names")
13044 "Namae (名前) is a parser for human names. It recognizes personal names
13045 of various cultural backgrounds and tries to split them into their component
13046 parts (e.g., given and family names, honorifics etc.).")
13047 (license (list license:bsd-2 license:agpl3+))))
13049 (define-public ruby-ritex
13051 (name "ruby-ritex")
13055 (uri (rubygems-uri "ritex" version))
13058 "07rlm3nyz9sxzy1srxs6a31hw81r6w7swrb85fiwi393z8npwc3a"))))
13059 (build-system ruby-build-system)
13063 ;; thanks to the Gentoo packagers for figuring this out
13066 #~(modify-phases %standard-phases
13067 (add-after 'extract-gemspec 'fix-tests
13068 (lambda* (#:key native-inputs inputs #:allow-other-keys)
13069 (substitute* "test/mathml.rb"
13071 ;; don't use the absolute path to avoid keeping a reference
13073 (("cmp ',\\\\,\\\\,,,\\\\,'" orig)
13074 (string-append "# " orig " # patched for Guix")))
13075 (substitute* "test/answer-key.yaml"
13076 (("- ,\\\\,\\\\,,,\\\\," orig)
13077 (string-append "# " orig " # patched for Guix")))))
13079 (lambda* (#:key tests? #:allow-other-keys)
13081 (invoke "ruby" "-Ilib:." "test/all.rb")))))))
13082 (home-page "https://rubygems.org/gems/ritex")
13083 (synopsis "Convert expressions from WebTeX into MathML")
13085 "Ritex converts expressions from WebTeX into MathML. WebTeX is an
13086 adaptation of TeX math syntax for web display. Ritex makes inserting math
13087 into HTML pages easy. It supports most TeX math syntax as well as macros.")
13088 ;; doesn't clearly state -only vs -or-later
13089 (license license:gpl2)))
13091 (define-public ruby-latex-decode
13093 (name "ruby-latex-decode")
13097 (uri (git-reference
13098 (url "https://github.com/inukshuk/latex-decode")
13099 (commit (string-append "v" version))))
13102 "1f5j67ayd04pjkmzvn0hk7cr8yqvn0gyg9ns6a0vhzj2gwna9ihy"))
13103 (file-name (git-file-name name version))))
13104 (build-system ruby-build-system)
13106 (list ruby-cucumber
13111 #:test-target "cucumber"
13113 #~(modify-phases %standard-phases
13114 (add-after 'extract-gemspec 'avoid-bundler
13116 (substitute* "Rakefile"
13117 (("require 'bundler" orig)
13118 (string-append "# " orig " # patched for Guix"))
13119 (("Cucumber::Rake::Task\\.new[(]:cucumber[)]" orig)
13120 (string-append orig " do |c|\n"
13121 " c.bundler = false # patched for Guix\n"
13123 (("Bundler\\.setup" orig)
13124 (string-append "true # " orig " # patched for Guix")))
13125 (substitute* "cucumber.yml"
13126 ;; thanks to avoiding bundler, we can't use this option
13127 ((" --publish-quiet")
13129 (add-after 'replace-git-ls-files 'replace-another-git-ls-files
13131 (substitute* "latex-decode.gemspec"
13132 (("`git ls-files -- [{]test,spec,features[}]/\\*`")
13133 "`find {test,spec,features} -type f | sort`")))))))
13134 (home-page "https://github.com/inukshuk/latex-decode")
13135 (synopsis "Convert LaTeX to Unicode")
13137 "This package provides a gem to convert LaTeX input to Unicode. Its
13138 original use was as an input filter for BibTeX-Ruby, but it can be used
13139 independently to decode LaTeX. Many of the patterns used by this Ruby gem are
13140 based on François Charette's equivalent Perl module @code{LaTeX::Decode}.")
13141 (license license:gpl3+)))
13143 (define-public ruby-link-header
13145 (name "ruby-link-header")
13149 (uri (rubygems-uri "link_header" version))
13152 "1yamrdq4rywmnpdhbygnkkl9fdy249fg5r851nrkkxr97gj5rihm"))))
13153 (build-system ruby-build-system)
13154 (home-page "https://github.com/asplake/link_header")
13155 (synopsis "Parse and format HTTP @code{Link} headers")
13157 "This gem provides the classes @code{LinkHeader} and
13158 @code{LinkHeader::Link}, which represent HTTP @code{Link} headers conforming
13159 to RFC 5988. Objects can be constructed from and converted to text or a
13160 JSON-friendly @code{Array} representation. They can also be used to generate
13161 corresponding HTML @code{link} elements.")
13162 (license license:expat)))
13164 (define-public ruby-rdf
13170 (uri (rubygems-uri "rdf" version))
13173 "1cj0k8ryd8hgbkgqb5swvy6fiygxny3y5bln0my5gv6dbfv3gm20"))))
13174 (build-system ruby-build-system)
13175 (propagated-inputs (list ruby-link-header))
13177 (list #:tests? #f)) ;; tests have many cyclic dependencies
13178 (home-page "https://ruby-rdf.github.io/")
13179 (synopsis "Linked Data for Ruby")
13181 "This gem contains the core algorithms and classes used for doing basic
13182 programming with @acronym{RDF, Resource Description Framework} data,
13183 implemented in pure Ruby.")
13184 (license license:unlicense)))
13186 (define-public ruby-rdf-vocab
13188 (name "ruby-rdf-vocab")
13192 (uri (rubygems-uri "rdf-vocab" version))
13195 "1bqmp9rfjvd56ajjz68ij6jla1wjf1fqg7bi4dpnjrsmn4pwaq7l"))))
13196 (build-system ruby-build-system)
13200 (list #:tests? #f)) ;; tests have many cyclic dependencies
13201 (home-page "https://github.com/ruby-rdf/rdf-vocab")
13202 (synopsis "Common RDF vocabularies")
13204 "This gem extends @code{ruby-rdf} with several common @acronym{RDF,
13205 Resource Description Framework} vocabularies.")
13206 (license license:unlicense)))
13208 (define-public ruby-bibtex-ruby
13210 (name "ruby-bibtex-ruby")
13214 (uri (rubygems-uri "bibtex-ruby" version))
13217 "0vynqa8q9hwghw6sdljr304b5gh11nqzy5nwqqwxmgy7pqyf7qw5"))))
13218 (build-system ruby-build-system)
13220 (list ruby-latex-decode
13231 #~(modify-phases %standard-phases
13232 (add-after 'extract-gemspec 'avoid-bundler
13234 (substitute* "Rakefile"
13235 (("require 'bundler" orig)
13236 (string-append "# " orig " # patched for Guix"))
13237 (("Bundler\\.setup" orig)
13238 (string-append "true # " orig " # patched for Guix"))))))))
13239 (home-page "https://github.com/inukshuk/bibtex-ruby")
13240 (synopsis "Rubyist's Swiss Army knife for all things BibTeX")
13242 "BibTeX-Ruby is the Rubyist's Swiss Army knife for all things BibTeX.
13243 It includes a parser for all common BibTeX objects and a sophisticated name
13244 parser that tokenizes correctly formatted names. BibTeX-Ruby recognizes
13245 BibTeX string replacements, joins values containing multiple strings or
13246 variables, supports cross-references, and decodes common LaTeX formatting
13247 instructions to unicode. If you are in a hurry, it also allows for easy
13248 export/conversion to formats such as YAML, JSON, CSL, and XML (BibTeXML).")
13249 (license license:gpl3+)))
13251 (define-public ruby-unicode-scripts
13253 (name "ruby-unicode-scripts")
13257 (uri (rubygems-uri "unicode-scripts" version))
13260 "1k7kbfk806zam129bp7pdiqkfb5hn51x149irzvjhs4xf22m4yvi"))))
13261 (build-system ruby-build-system)
13263 (list ruby-minitest))
13265 (list #:test-target "spec"))
13266 (home-page "https://github.com/janlelis/unicode-scripts")
13267 (synopsis "Unicode script classification library")
13269 "This gem provides a simple interface for classifying Ruby strings using
13270 the Unicode @code{Script} and @code{Script_Extensions} properties.")
13271 (license license:expat)))
13273 (define-public ruby-citeproc
13275 (name "ruby-citeproc")
13279 (uri (rubygems-uri "citeproc" version))
13282 "13vl5sjmksk5a8kjcqnjxh7kn9gn1n4f9p1rvqfgsfhs54p0m6l2"))))
13283 (build-system ruby-build-system)
13287 (list #:tests? #f)) ;; tests have a cyclic dependency
13288 (home-page "https://github.com/inukshuk/citeproc")
13289 (synopsis "Interface for Ruby citation processors")
13291 "CiteProc is a citation processor interface and citation data API based
13292 on the @acronym{CSL, Citation Style Language} specifications. To actually
13293 process citations, a dedicated processor engine is required: a pure Ruby
13294 engine is available in the @code{citeproc-ruby} gem.")
13295 (license (list license:agpl3+ license:bsd-2))))
13297 (define-public ruby-edtf
13303 (uri (git-reference
13304 (url "https://github.com/inukshuk/edtf-ruby")
13305 (commit (string-append "v" version))))
13308 "18j8xq8zmrn41cs2gpd1i87agi9905asvnjqndky2cqb5zg3q14g"))
13310 ;; remove generated file
13311 #~(delete-file "lib/edtf/parser.rb"))
13312 (file-name (git-file-name name version))))
13313 (build-system ruby-build-system)
13315 (list ruby-activesupport))
13317 (list ruby-cucumber
13322 #~(modify-phases %standard-phases
13323 (add-after 'extract-gemspec 'avoid-bundler
13325 (substitute* "Rakefile"
13326 (("require 'bundler" orig)
13327 (string-append "# " orig " # patched for Guix"))
13328 (("bundle exec racc")
13330 (("Cucumber::Rake::Task\\.new[(]:cucumber[)]" orig)
13331 (string-append orig " do |c|\n"
13332 " c.bundler = false # patched for Guix\n"
13334 (("Bundler\\.setup" orig)
13335 (string-append "true # " orig " # patched for Guix")))))
13336 (add-after 'avoid-bundler 'patch-cucumber-options
13338 (substitute* "cucumber.yml"
13339 ;; this option is not supported, at least in our configuration
13340 ((" --publish-quiet")
13342 (add-before 'build 'compile
13344 (invoke "rake" "racc")))
13346 (lambda* (#:key tests? #:allow-other-keys)
13348 (invoke "rake")))))))
13349 (home-page "https://github.com/inukshuk/edtf-ruby")
13350 (synopsis "Ruby implementation of Extended Date/Time Format")
13352 "EDTF-Ruby provides a parser and an API for the @acronym{EDTF, Extended
13353 Date/Time Format} standard, implemented as an extension to Ruby's @code{Date}
13355 (license license:bsd-2)))
13357 (define-public ruby-gli
13363 (uri (git-reference
13364 (url "https://github.com/davetron5000/gli")
13365 (commit (string-append "v" version))))
13368 "09b1r9hlx4dy2yq036nk7hc2nbswhia6q3na9v11z94yibc8mgja"))
13369 (file-name (git-file-name name version))))
13370 (build-system ruby-build-system)
13372 (list ruby-minitest
13379 #~(modify-phases %standard-phases
13380 (add-after 'extract-gemspec 'patch-gemspec-version
13382 (substitute* "gli.gemspec"
13383 ;; this trick fails in our build environment
13384 (("require File\\.join[(]\\[" orig)
13385 (string-append "# patched for Guix # " orig))
13386 (("s\\.version = GLI::VERSION")
13387 #$(string-append "s.version = '"
13388 (package-version this-package)
13389 "' # patched for Guix")))))
13390 (add-after 'replace-git-ls-files 'replace-another-git-ls-files
13392 (substitute* "gli.gemspec"
13393 (("`git ls-files -- [{]test,spec,features[}]/\\*`")
13394 "`find {test,spec,features} -type f | sort`"))))
13395 (add-after 'replace-another-git-ls-files 'fix-rubyopt
13397 (substitute* "Rakefile"
13398 (("ENV\\[\"RUBYOPT\"]")
13399 "(ENV['RUBYOPT'] || '')")))))))
13400 (home-page "https://davetron5000.github.io/gli/")
13401 (synopsis "Git-Like Interface command-line parser")
13403 "GLI allows you to create command-line applications in Ruby with Git-Like
13404 Interfaces: that is, they take subcommands in the style of @command{git} and
13405 @command{gem}. GLI uses a simple domain-specific language, but retains all
13406 the power of the built-in @code{OptionParser}.")
13407 (license license:asl2.0)))
13409 (define-public ruby-anystyle-data
13411 (name "ruby-anystyle-data")
13415 (uri (git-reference
13416 (url "https://github.com/inukshuk/anystyle-data")
13420 "025mxa7r9d7izqn6bc1wr40ijp64da0jh211prlpjl6svilgd6rm"))
13422 ;; remove pre-built file
13423 #~(delete-file "lib/anystyle/data/dict.txt.gz"))
13425 (search-patches "ruby-anystyle-data-immutable-install.patch"))
13426 (file-name (git-file-name name version))))
13427 (build-system ruby-build-system)
13430 #:tests? #f ;; there are none
13432 `((guix build ruby-build-system)
13436 #~(modify-phases %standard-phases
13437 (add-after 'replace-git-ls-files 'replace-another-git-ls-files
13439 (substitute* "anystyle-data.gemspec"
13440 (("`git ls-files lib README\\.md LICENSE`\\.split[(][^)]*[)]")
13444 (map (cut string-append "\"" <> "\"")
13447 "lib/anystyle/data.rb"
13448 "lib/anystyle/data/dict.txt.gz"
13449 "lib/anystyle/data/setup.rb"
13450 "lib/anystyle/data/version.rb"))
13453 (add-before 'build 'compile-dict
13455 (invoke "rake" "compile"))))))
13456 (home-page "https://anystyle.io")
13457 (synopsis "AnyStyle parser dictionary data")
13459 "This gem provides parser dictionary data for AnyStyle.")
13460 (license license:bsd-2)))
13462 (define-public ruby-anystyle
13463 (let ((commit "50f1dd547d28ab4b830e45d70e840cb1898a37b0")
13465 ;; Releases point to specific commits, but recent releases haven't been
13466 ;; tagged in Git. Meanwhile, the rubygems archive lacks tests.
13468 (name "ruby-anystyle")
13469 (version (git-version "1.3.14" revision commit))
13472 (uri (git-reference
13473 (url "https://github.com/inukshuk/anystyle")
13477 "0f4qcrywl1kl6qysn24lj3yp85ln4i7za7b7ld2fglyzwcggxwb0"))
13479 ;; There is an optional dependency on
13480 ;; <https://github.com/feedbackmine/language_detector>, which
13481 ;; seems like it was intended to be free software, but
13482 ;; doesn't have a clear license statement. Maybe someone can
13483 ;; do more sleuthing, or else find a replacement? See also
13484 ;; <https://github.com/inukshuk/anystyle/issues/186>. For
13485 ;; now, patch it out, but leave a pointer to follow up.
13487 (use-modules (guix build utils))
13488 (substitute* "Gemfile"
13489 (("gem 'language_detector', github: '[^']*'" orig)
13490 (string-append "# " orig " # unclear license")))
13491 (substitute* "spec/anystyle/parser_spec.rb"
13492 (("language: 'en'," orig)
13493 (string-append "# " orig " # no lanugage_detector")))))
13496 "ruby-anystyle-fix-dictionary-populate.patch"))
13497 (file-name (git-file-name name version))))
13498 (build-system ruby-build-system)
13500 (list ruby-anystyle-data
13509 ruby-unicode-scripts))
13512 #:test-target "spec"
13514 #~(modify-phases %standard-phases
13515 (add-after 'extract-gemspec 'avoid-bundler
13517 (substitute* "Rakefile"
13518 (("require 'bundler" orig)
13519 (string-append "# " orig " # patched for Guix"))
13520 (("Bundler\\.setup" orig)
13521 (string-append "true # " orig " # patched for Guix")))))
13522 (add-after 'replace-git-ls-files 'replace-another-git-ls-files
13524 (substitute* "anystyle.gemspec"
13525 (("`git ls-files spec`")
13526 "`find spec -type f | sort`"))))
13527 (add-after 'wrap 'populate-dictionaries
13529 ;; We must initiallize these files here, or they will never be
13530 ;; usable with the default settings. A more flexible approach
13531 ;; might use something like `Gem.find_files()` or
13533 (with-output-to-file "initialize-dictionaries.rb"
13536 require 'anystyle/dictionary' # must come before 'anystyle/data'
13537 require 'anystyle/data'
13538 [:marshal, :gdbm].each do |adapter|
13539 AnyStyle::Dictionary.create({adapter: adapter}).open().close()
13542 (let* ((old-gems (getenv "GEM_PATH"))
13543 (new-gems (string-append #$output
13544 "/lib/ruby/vendor_ruby:"
13548 (setenv "GEM_PATH" new-gems))
13550 (invoke "ruby" "initialize-dictionaries.rb"))
13552 (setenv "GEM_PATH" old-gems)))))))))
13553 (home-page "https://anystyle.io")
13554 (synopsis "Fast and smart citation reference parsing (Ruby library)")
13556 "AnyStyle is a very fast and smart parser for academic reference lists
13557 and bibliographies. AnyStyle uses powerful machine learning heuristics based
13558 on Conditional Random Fields and aims to make it easy to train the model with
13559 data that is relevant to your parsing needs.
13561 This package provides the Ruby module @code{AnyStyle}. AnyStyle can also be
13562 used via the @command{anystyle} command-line utility or a web application,
13563 though the later has not yet been packaged for Guix.")
13564 (license license:bsd-2))))
13566 (define-public anystyle
13572 (uri (git-reference
13573 (url "https://github.com/inukshuk/anystyle-cli")
13577 "1bazzms04cra8516q7vydmcm31yd0a7si1pxk4waffqy7lh0pksg"))
13578 (file-name (git-file-name name version))))
13579 (build-system ruby-build-system)
13581 (list ruby-anystyle
13589 `((guix build ruby-build-system)
13592 (guix build utils))
13594 #~(modify-phases %standard-phases
13595 (add-after 'extract-gemspec 'less-strict-dependencies
13597 (substitute* "anystyle-cli.gemspec"
13598 (("'bibtex-ruby', '[^']*'")
13599 "'bibtex-ruby'"))))
13600 (add-before 'build 'change-default-dictionary-adapter
13602 ;; Since we always have gdbm available, using it will give a
13603 ;; faster startup time, which is particularly worth-while for
13604 ;; a command-line tool.
13605 (substitute* "bin/anystyle"
13606 (("default_value: 'ruby',")
13607 "default_value: 'gdbm', # patched for Guix"))))
13609 (lambda* (#:key tests? #:allow-other-keys)
13610 ;; There are no tests, but let's use this opportunity to do a
13611 ;; basic test of our own that things run ok. It works especially
13612 ;; well to test this here since we know the 'ruby-anystile'
13613 ;; package is in its final, immutable installed form.
13616 `("require 'anystyle'"
13618 "pp AnyStyle.parse 'Derrida, J. (1967). L’écriture"
13619 " et la différence (1 éd.). Paris: Éditions du"
13623 (apply invoke "ruby"
13624 (fold-right (lambda (line lst)
13625 (cons* "-e" line lst))
13629 ("require 'anystyle/dictionary'"
13630 "AnyStyle::Dictionary.defaults[:adapter] = :gdbm"
13632 (add-after 'wrap 'check-cli
13633 (lambda* (#:key tests? outputs #:allow-other-keys)
13635 (with-output-to-file "check-cli.in"
13639 '("Derrida, J. (1967). L’écriture et la différence "
13640 "(1 éd.). Paris: Éditions du Seuil.\n"))))
13641 (invoke (search-input-file outputs "/bin/anystyle")
13644 (add-after 'wrap 'generate-man-page
13645 ;; generating a man page also tests that the command actually runs
13647 (define (run-with-output-file file command . args)
13648 (format (current-output-port)
13649 "running: ~s\nwith output to: ~s\n"
13650 (cons command args)
13653 (with-output-to-file file
13657 (apply open-pipe* OPEN_WRITE command args))))))
13658 (error "command failed")))
13659 (let ((anystyle (string-append #$output "/bin/anystyle")))
13660 (run-with-output-file "intro.txt"
13662 (for-each (lambda (cmd)
13663 (let ((file (string-append cmd ".txt")))
13664 (run-with-output-file file
13665 anystyle cmd "--help")
13666 ;; indent headings to create subsections
13669 (string-append " " orig)))
13670 ;; generate a section heading
13671 (call-with-output-file
13672 (string-append "section-" file)
13674 (format out "\n\n~a COMMAND\n\n"
13675 (string-upcase cmd))))))
13676 '("check" "find" "parse" "train"))
13677 (substitute* `("intro.txt"
13678 "check.txt" "find.txt" "parse.txt" "train.txt")
13679 ;; format "tag list" for txt2man"
13682 ;; restore formatting of the "name" sections
13683 (("(anystyle|check|find|parse|train) ([A-Z])" _ cmd post)
13684 (string-append cmd " - " post)))
13685 (run-with-output-file "anystyle.txt"
13688 "section-check.txt" "check.txt"
13689 "section-find.txt" "find.txt"
13690 "section-parse.txt" "parse.txt"
13691 "section-train.txt" "train.txt")
13692 (run-with-output-file
13695 "-v" "General Commands Manual" "-t" "anystyle" "-s" "1"
13696 "-r" #$(string-append "anystyle-cli "
13697 (package-version this-package))
13698 "-B" "check" "-B" "find" "-B" "parse" "-B" "train"
13700 (install-file "anystyle.1"
13701 (string-append #$output "/share/man/man1"))))))))
13702 (home-page "https://anystyle.io")
13703 (synopsis "Fast and smart citation reference parsing")
13705 "AnyStyle is a very fast and smart parser for academic reference lists
13706 and bibliographies. AnyStyle uses powerful machine learning heuristics based
13707 on Conditional Random Fields and aims to make it easy to train the model with
13708 data that is relevant to your parsing needs.
13710 This package provides the @command{anystyle} command-line utility. AnyStyle
13711 can also be used as a Ruby library or as a web application, though the later
13712 has not yet been packaged for Guix.")
13713 (license license:bsd-2)
13714 (properties `((upstream-name . "anystyle-cli")))))