1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2014, 2015 Pjotr Prins <pjotr.guix@thebird.nl>
3 ;;; Copyright © 2014, 2015, 2016, 2017 Ludovic Courtès <ludo@gnu.org>
4 ;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
5 ;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org>
6 ;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
7 ;;; Copyright © 2015, 2016, 2017 Ben Woodcroft <donttrustben@gmail.com>
8 ;;; Copyright © 2017 ng0 <contact.ng0@cryptolab.net>
9 ;;; Copyright © 2017 Marius Bakke <mbakke@fastmail.com>
11 ;;; This file is part of GNU Guix.
13 ;;; GNU Guix is free software; you can redistribute it and/or modify it
14 ;;; under the terms of the GNU General Public License as published by
15 ;;; the Free Software Foundation; either version 3 of the License, or (at
16 ;;; your option) any later version.
18 ;;; GNU Guix is distributed in the hope that it will be useful, but
19 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
20 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ;;; GNU General Public License for more details.
23 ;;; You should have received a copy of the GNU General Public License
24 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
26 (define-module (gnu packages ruby)
27 #:use-module ((guix licenses) #:prefix license:)
28 #:use-module (gnu packages)
29 #:use-module (gnu packages base)
30 #:use-module (gnu packages compression)
31 #:use-module (gnu packages databases)
32 #:use-module (gnu packages readline)
33 #:use-module (gnu packages autotools)
34 #:use-module (gnu packages java)
35 #:use-module (gnu packages libffi)
36 #:use-module (gnu packages python)
37 #:use-module (gnu packages ragel)
38 #:use-module (gnu packages tls)
39 #:use-module (gnu packages version-control)
40 #:use-module (guix packages)
41 #:use-module (guix download)
42 #:use-module (guix git-download)
43 #:use-module (guix utils)
44 #:use-module (guix build-system gnu)
45 #:use-module (gnu packages xml)
46 #:use-module (gnu packages web)
47 #:use-module (guix build-system ruby))
52 (replacement ruby-2.4.1)
57 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
58 (version-major+minor version)
59 "/ruby-" version ".tar.xz"))
62 "141nnsdk2q83c23p5kl404id8gy1ap261gin48rbjj5sbksgx1rs"))
63 (modules '((guix build utils)))
65 ;; Remove bundled libffi
66 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
68 (build-system gnu-build-system)
70 `(#:test-target "test"
72 (modify-phases %standard-phases
73 (add-before 'configure 'replace-bin-sh-and-remove-libffi
75 (substitute* '("Makefile.in"
80 "test/rubygems/test_gem_ext_configure_builder.rb"
81 "test/rdoc/test_rdoc_parser.rb"
82 "test/ruby/test_rubyoptions.rb"
83 "test/ruby/test_process.rb"
84 "test/ruby/test_system.rb"
86 (("/bin/sh") (which "sh")))
89 `(("readline" ,readline)
95 (list (search-path-specification
97 (files (list (string-append "lib/ruby/gems/"
98 (version-major+minor version)
100 (synopsis "Programming language interpreter")
101 (description "Ruby is a dynamic object-oriented programming language with
102 a focus on simplicity and productivity.")
103 (home-page "https://ruby-lang.org")
104 (license license:ruby)))
106 (define-public ruby-2.4.1
114 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
115 (version-major+minor version)
116 "/ruby-" version ".tar.xz"))
119 "0m763zf2v0jhrha3cx21g4dif6vc9gm714invs8h3sg35ncskj2g"))
120 (modules '((guix build utils)))
122 ;; Remove bundled libffi
123 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
126 (define-public ruby-2.3
133 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
134 (version-major+minor version)
135 "/ruby-" version ".tar.xz"))
138 "132p5kc1sx97svbx04g40pz5pr7p8f6jlmnq5r2prlcz5q1xj71l"))
139 (modules '((guix build utils)))
141 ;; Remove bundled libffi
142 (delete-file-recursively "ext/fiddle/libffi-3.2.1")
145 (define-public ruby-2.2
146 (package (inherit ruby)
151 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
152 (version-major+minor version)
153 "/ruby-" version ".tar.xz"))
156 "0lyb7gnbbhs3a3v9grsjgbaixm20wxz6x3h0czyrxnj3cpp8lk13"))))))
158 (define-public ruby-2.1
159 (package (inherit ruby)
164 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
165 (version-major+minor version)
166 "/ruby-" version ".tar.bz2"))
169 "1wglbd599mlwxfcb2xgqcxi2shr363pjn5dpbv11m04si9bpaim7"))))
171 `(#:test-target "test"
175 'configure 'replace-bin-sh
177 (substitute* '("Makefile.in"
182 (("/bin/sh") (which "sh"))))
185 (list (search-path-specification
186 (variable "GEM_PATH")
187 (files (list (string-append "lib/ruby/gems/"
188 (version-major+minor version)
191 (define-public ruby-1.8
192 (package (inherit ruby)
193 (version "1.8.7-p374")
197 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
198 (version-major+minor version)
199 "/ruby-" version ".tar.bz2"))
202 "1qq7khilwkayrhwmzlxk83scrmiqfi7lgsn4c63znyvz2c1lgqxl"))))
203 (native-search-paths '())
205 `(#:test-target "test"
209 'configure 'replace-bin-sh
211 (substitute* '("Makefile.in"
216 (("/bin/sh") (which "sh"))))
217 %standard-phases)))))
219 (define-public ruby-hoe
225 (uri (rubygems-uri "hoe" version))
228 "03r8nsw4n4mnia9iqiqk9kqhvrl96m2i81j4yg8cpnppd8vk7vlb"))))
229 (build-system ruby-build-system)
230 (synopsis "Ruby project management helper")
232 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
233 maintain, and release projects and includes a dynamic plug-in system allowing
234 for easy extensibility. Hoe ships with plug-ins for all the usual project
235 tasks including rdoc generation, testing, packaging, deployment, and
237 (home-page "http://www.zenspider.com/projects/hoe.html")
238 (license license:expat)))
240 (define-public ruby-rake-compiler
242 (name "ruby-rake-compiler")
246 (uri (rubygems-uri "rake-compiler" version))
249 "1lf91nf1fcnmsh54mxz06wyfmjkwh58vljr35zns5cwbg8fwmi20"))))
250 (build-system ruby-build-system)
252 '(#:tests? #f)) ; needs cucumber
253 (synopsis "Building and packaging helper for Ruby native extensions")
254 (description "Rake-compiler provides a framework for building and
255 packaging native C and Java extensions in Ruby.")
256 (home-page "https://github.com/rake-compiler/rake-compiler")
257 (license license:expat)))
259 (define-public ruby-i18n
265 (uri (rubygems-uri "i18n" version))
268 "1i5z1ykl8zhszsxcs8mzl8d0dxgs3ylz8qlzrw74jb0gplkx6758"))))
269 (build-system ruby-build-system)
271 '(#:tests? #f)) ; no tests
272 (synopsis "Internationalization library for Ruby")
273 (description "Ruby i18n is an internationalization and localization
274 solution for Ruby programs. It features translation and localization,
275 interpolation of values to translations, pluralization, customizable
276 transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
277 translation data, custom key/scope separator, custom exception handlers, and
278 an extensible architecture with a swappable backend.")
279 (home-page "https://github.com/svenfuchs/i18n")
280 (license license:expat)))
282 ;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
283 ;; dependencies use RSpec for their test suites! To avoid these circular
284 ;; dependencies, we disable tests for all of the RSpec-related packages.
285 (define ruby-rspec-support
287 (name "ruby-rspec-support")
291 (uri (rubygems-uri "rspec-support" version))
294 "10vf3k3d472y573mag2kzfsfrf6rv355s13kadnpryk8d36yq5r0"))))
295 (build-system ruby-build-system)
297 '(#:tests? #f)) ; avoid dependency cycles
298 (synopsis "RSpec support library")
299 (description "Support utilities for RSpec gems.")
300 (home-page "https://github.com/rspec/rspec-support")
301 (license license:expat)))
303 (define-public ruby-rspec-core
305 (name "ruby-rspec-core")
309 (uri (rubygems-uri "rspec-core" version))
312 "1nacs062qbr98fx6czf1vwppn1js956nv2c8vfwj6i65axdfs46i"))))
313 (build-system ruby-build-system)
315 '(#:tests? #f)) ; avoid dependency cycles
317 `(("ruby-rspec-support" ,ruby-rspec-support)))
318 (synopsis "RSpec core library")
319 (description "Rspec-core provides the RSpec test runner and example
321 (home-page "https://github.com/rspec/rspec-core")
322 (license license:expat)))
324 (define-public ruby-rspec-core-2
325 (package (inherit ruby-rspec-core)
329 (uri (rubygems-uri "rspec-core" version))
332 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
333 (propagated-inputs `())))
335 (define-public ruby-diff-lcs
337 (name "ruby-diff-lcs")
341 (uri (rubygems-uri "diff-lcs" version))
344 "1vf9civd41bnqi6brr5d9jifdw73j9khc6fkhfl1f8r9cpkdvlx1"))))
345 (build-system ruby-build-system)
347 '(#:tests? #f)) ; avoid dependency cycles
348 (synopsis "Compute the difference between two Enumerable sequences")
349 (description "Diff::LCS computes the difference between two Enumerable
350 sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
351 It includes utilities to create a simple HTML diff output format and a
352 standard diff-like tool.")
353 (home-page "https://github.com/halostatue/diff-lcs")
354 (license license:expat)))
356 (define-public ruby-rspec-expectations
358 (name "ruby-rspec-expectations")
362 (uri (rubygems-uri "rspec-expectations" version))
365 "0bbqfrb1x8gmwf8x2xhhwvvlhwbbafq4isbvlibxi6jk602f09gs"))))
366 (build-system ruby-build-system)
368 '(#:tests? #f)) ; avoid dependency cycles
370 `(("ruby-rspec-support" ,ruby-rspec-support)
371 ("ruby-diff-lcs" ,ruby-diff-lcs)))
372 (synopsis "RSpec expectations library")
373 (description "Rspec-expectations provides a simple API to express expected
374 outcomes of a code example.")
375 (home-page "https://github.com/rspec/rspec-expectations")
376 (license license:expat)))
378 (define-public ruby-rspec-expectations-2
379 (package (inherit ruby-rspec-expectations)
383 (uri (rubygems-uri "rspec-expectations" version))
386 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
388 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
390 (define-public ruby-rspec-mocks
392 (name "ruby-rspec-mocks")
396 (uri (rubygems-uri "rspec-mocks" version))
399 "0nl3ksivh9wwrjjd47z5dggrwx40v6gpb3a0gzbp1gs06a5dmk24"))))
400 (build-system ruby-build-system)
402 '(#:tests? #f)) ; avoid dependency cycles
404 `(("ruby-rspec-support" ,ruby-rspec-support)
405 ("ruby-diff-lcs" ,ruby-diff-lcs)))
406 (synopsis "RSpec stubbing and mocking library")
407 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
408 support for stubbing and mocking.")
409 (home-page "https://github.com/rspec/rspec-mocks")
410 (license license:expat)))
412 (define-public ruby-rspec-mocks-2
413 (package (inherit ruby-rspec-mocks)
417 (uri (rubygems-uri "rspec-mocks" version))
420 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
422 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
424 (define-public ruby-rspec
430 (uri (rubygems-uri "rspec" version))
433 "16g3mmih999f0b6vcz2c3qsc7ks5zy4lj1rzjh8hf6wk531nvc6s"))))
434 (build-system ruby-build-system)
436 '(#:tests? #f)) ; avoid dependency cycles
438 `(("ruby-rspec-core" ,ruby-rspec-core)
439 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
440 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
441 (synopsis "Behavior-driven development framework for Ruby")
442 (description "RSpec is a behavior-driven development (BDD) framework for
443 Ruby. This meta-package includes the RSpec test runner, along with the
444 expectations and mocks frameworks.")
445 (home-page "http://rspec.info/")
446 (license license:expat)))
448 (define-public ruby-rspec-2
449 (package (inherit ruby-rspec)
453 (uri (rubygems-uri "rspec" version))
456 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
458 `(("ruby-rspec-core" ,ruby-rspec-core-2)
459 ("ruby-rspec-mocks" ,ruby-rspec-mocks-2)
460 ("ruby-rspec-expectations" ,ruby-rspec-expectations-2)))))
462 ;; Bundler is yet another source of circular dependencies, so we must disable
463 ;; its test suite as well.
464 (define-public bundler
470 (uri (rubygems-uri "bundler" version))
473 "125amldnpzzrfw76mmr7mlx002k1k6xdyrqf5bdnzl5hajvn0s5f"))))
474 (build-system ruby-build-system)
476 '(#:tests? #f)) ; avoid dependency cycles
477 (synopsis "Ruby gem bundler")
478 (description "Bundler automatically downloads and installs a list of gems
479 specified in a \"Gemfile\", as well as their dependencies.")
480 (home-page "http://bundler.io/")
481 (license license:expat)))
483 (define-public ruby-builder
485 (name "ruby-builder")
489 (uri (rubygems-uri "builder" version))
492 "0qibi5s67lpdv1wgcj66wcymcr04q6j4mzws6a479n0mlrmh5wr1"))))
493 (build-system ruby-build-system)
496 (modify-phases %standard-phases
497 (add-after 'unpack 'do-not-use-rvm
499 (substitute* "rakelib/tags.rake"
500 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
502 (synopsis "Ruby library to create structured data")
503 (description "Builder provides a number of builder objects that make it
504 easy to create structured data. Currently the following builder objects are
505 supported: XML Markup and XML Events.")
506 (home-page "https://github.com/jimweirich/builder")
507 (license license:expat)))
509 (define-public ruby-rjb
515 (uri (rubygems-uri "rjb" version))
518 "0gzs92dagk981s4vrymnqg0vll783b9k564j0cdgp167nc5a2zg4"))))
519 (build-system ruby-build-system)
521 `(#:tests? #f ; no rakefile
523 (modify-phases %standard-phases
524 (add-before 'build 'set-java-home
525 (lambda* (#:key inputs #:allow-other-keys)
526 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
529 `(("jdk" ,icedtea "jdk")))
530 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
531 (description "RJB is a bridge program that connects Ruby and Java via the
532 Java Native Interface.")
533 (home-page "http://www.artonx.org/collabo/backyard/?RubyJavaBridge")
534 (license license:lgpl2.1+)))
536 (define-public ruby-log4r
543 (uri (rubygems-uri "log4r" version))
546 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
547 (build-system ruby-build-system)
549 '(#:tests? #f)) ; no Rakefile in gem
550 (synopsis "Flexible logging library for Ruby")
551 (description "Comprehensive and flexible logging library written
552 in Ruby for use in Ruby programs. It features a hierarchical logging
553 system of any number of levels, custom level names, logger
554 inheritance, multiple output destinations per log event, execution
555 tracing, custom formatting, thread safteyness, XML and YAML
556 configuration, and more.")
557 (home-page "http://log4r.rubyforge.org/")
558 (license license:bsd-3)))
560 (define-public ruby-atoulme-antwrap
562 (name "ruby-atoulme-antwrap")
566 (uri (rubygems-uri "atoulme-Antwrap" version))
569 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
570 (build-system ruby-build-system)
571 ;; Test data required for most of the tests are not included.
572 (arguments `(#:tests? #f))
574 `(("ruby-hoe" ,ruby-hoe)))
576 `(("ruby-rjb" ,ruby-rjb)))
577 (synopsis "Ruby wrapper for the Ant build tool")
578 (description "Antwrap is a Ruby module that wraps the Apache Ant build
579 tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
581 (home-page "http://rubyforge.org/projects/antwrap/")
582 (license license:expat)))
584 (define-public ruby-atoulme-saikuro
586 (name "ruby-atoulme-saikuro")
590 (uri (rubygems-uri "atoulme-Saikuro" version))
593 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
594 (build-system ruby-build-system)
595 ;; FIXME: There are no unit tests. The tests are demonstrations of the
597 (arguments `(#:tests? #f))
598 (synopsis "Cyclomatic complexity analyzer")
599 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
600 given Ruby source code Saikuro will generate a report listing the cyclomatic
601 complexity of each method found. In addition, Saikuro counts the number of
602 lines per method and can generate a listing of the number of tokens on each
604 (home-page "http://www.github.com/atoulme/Saikuro")
605 ;; File headers contain the BSD-3 license and the README.rdoc says that
606 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
607 ;; of the Expat license.
608 (license license:bsd-3)))
610 (define-public ruby-ci-reporter
612 (name "ruby-ci-reporter")
616 (uri (rubygems-uri "ci_reporter" version))
619 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
620 (build-system ruby-build-system)
622 `(#:test-target "rspec"))
624 `(("ruby-builder" ,ruby-builder)))
626 `(("bundler" ,bundler)
627 ("ruby-rspec" ,ruby-rspec)))
628 (synopsis "Generate XML reports of runs test")
630 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
631 you to generate XML reports of your test runs. The resulting files can be
632 read by a continuous integration system that understands Ant's JUnit report
634 (home-page "https://github.com/nicksieger/ci_reporter")
635 (license license:expat)))
637 (define-public ruby-saikuro-treemap
639 (name "ruby-saikuro-treemap")
643 (uri (rubygems-uri "saikuro_treemap" version))
646 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
647 (build-system ruby-build-system)
648 ;; Some of the tests fail because the generated JSON has keys in a
649 ;; different order. This is a problem with the test suite rather than any
650 ;; of the involved libraries.
651 (arguments `(#:tests? #f))
653 `(("ruby-json-pure" ,ruby-json-pure)
654 ("ruby-atoulme-saikuro" ,ruby-atoulme-saikuro)))
655 (synopsis "Generate complexity treemap based on saikuro analysis")
657 "This gem generates a treemap showing the complexity of Ruby code on
658 which it is run. It uses Saikuro under the covers to analyze Ruby code
660 (home-page "https://github.com/ThoughtWorksStudios/saikuro_treemap")
661 (license license:expat)))
663 (define-public ruby-orderedhash
665 (name "ruby-orderedhash")
669 (uri (rubygems-uri "orderedhash" version))
672 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
673 (build-system ruby-build-system)
675 '(#:tests? #f)) ; no test suite
676 (synopsis "Ruby library providing an order-preserving hash")
677 (description "Orderedhash is a Ruby library providing a hash
678 implementation that preserves the order of items and features some array-like
680 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
681 (license license:public-domain)))
683 (define-public ruby-libxml
690 (uri (rubygems-uri "libxml-ruby" version))
693 "1dhjqp4r9vkdp00l6h1cj8qfndzxlhlxk6b9g0w4v55gz857ilhb"))))
694 (build-system ruby-build-system)
697 ("libxml2" ,libxml2)))
699 '(#:tests? #f ; test suite hangs for unknown reason
702 (string-append "--with-xml2-include="
703 (assoc-ref %build-inputs "libxml2")
704 "/include/libxml2" ))))
705 (synopsis "Ruby bindings for GNOME Libxml2")
706 (description "The Libxml-Ruby project provides Ruby language bindings for
707 the GNOME Libxml2 XML toolkit.")
708 (home-page "http://xml4r.github.com/libxml-ruby")
709 (license license:expat)))
711 (define-public ruby-xml-simple
713 (name "ruby-xml-simple")
717 (uri (rubygems-uri "xml-simple" version))
720 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
721 (build-system ruby-build-system)
723 '(#:tests? #f)) ; no test suite
724 (synopsis "Simple Ruby library for XML processing")
725 (description "This library provides a simple API for XML processing in
727 (home-page "https://github.com/maik/xml-simple")
728 (license license:ruby)))
730 (define-public ruby-thor
736 (uri (rubygems-uri "thor" version))
739 "08p5gx18yrbnwc6xc0mxvsfaxzgy2y9i78xq7ds0qmdm67q39y4z"))))
740 (build-system ruby-build-system)
742 '(#:tests? #f)) ; no test suite
744 `(("bundler" ,bundler)))
745 (synopsis "Ruby toolkit for building command-line interfaces")
746 (description "Thor is a toolkit for building powerful command-line
748 (home-page "http://whatisthor.com/")
749 (license license:expat)))
751 (define-public ruby-lumberjack
753 (name "ruby-lumberjack")
757 (uri (rubygems-uri "lumberjack" version))
760 "0ily8j83q959w19zb7qm6m7y53sdj9afxj4x6mn2adl4i7vpdsv4"))))
761 (build-system ruby-build-system)
763 `(("ruby-rspec" ,ruby-rspec)
764 ("ruby-timecop" ,ruby-timecop)))
765 (synopsis "Logging utility library for Ruby")
766 (description "Lumberjack is a simple logging utility that can be a drop in
767 replacement for Logger or ActiveSupport::BufferedLogger. It provides support
768 for automatically rolling log files even with multiple processes writing the
770 (home-page "https://github.com/bdurand/lumberjack")
771 (license license:expat)))
773 (define-public ruby-nenv
779 (uri (rubygems-uri "nenv" version))
782 "152wxwri0afwgnxdf93gi6wjl9rr5z7vwp8ln0gpa3rddbfc27s6"))))
783 (build-system ruby-build-system)
785 `(#:tests? #f)) ; no tests included
787 `(("ruby-rspec" ,ruby-rspec)
788 ("bundler" ,bundler)))
789 (synopsis "Ruby interface for modifying the environment")
790 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
791 and inspect the environment.")
792 (home-page "https://github.com/e2/nenv")
793 (license license:expat)))
795 (define-public ruby-permutation
797 (name "ruby-permutation")
801 (uri (rubygems-uri "permutation" version))
804 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
805 (build-system ruby-build-system)
808 (modify-phases %standard-phases
809 (add-after 'unpack 'fix-rakefile
811 (substitute* "Rakefile"
812 (("require 'rake/gempackagetask'")
813 "require 'rubygems/package_task'")
814 (("include Config") ""))
818 (zero? (system* "ruby" "-Ilib" "test/test.rb")))))))
819 (synopsis "Library to perform operations with sequence permutations")
820 (description "This package provides a Ruby library to perform different
821 operations with permutations of sequences, such as strings and arrays.")
822 (home-page "http://flori.github.io/permutation")
823 (license license:gpl2))) ; GPL 2 only
825 (define-public ruby-shellany
827 (name "ruby-shellany")
831 (uri (rubygems-uri "shellany" version))
834 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
835 (build-system ruby-build-system)
837 `(#:test-target "default"
839 (modify-phases %standard-phases
840 (add-after 'unpack 'fix-version-test
842 (substitute* "spec/shellany_spec.rb"
843 (("^RSpec") "require \"shellany\"\nRSpec"))
846 `(("ruby-rspec" ,ruby-rspec)
847 ("ruby-nenv" ,ruby-nenv)
848 ("bundler" ,bundler)))
849 (synopsis "Capture command output")
850 (description "Shellany is a Ruby library providing functions to capture
851 the output produced by running shell commands.")
852 (home-page "https://rubygems.org/gems/shellany")
853 (license license:expat)))
855 (define-public ruby-notiffany
857 (name "ruby-notiffany")
861 (uri (rubygems-uri "notiffany" version))
864 "0x838fa5il0dd9zbm3lxkpbfxcf5fxv9556mayc2mxsdl5ghv8nx"))))
865 (build-system ruby-build-system)
866 ;; Tests are not included in the gem.
867 (arguments `(#:tests? #f))
869 `(("ruby-shellany" ,ruby-shellany)
870 ("ruby-nenv" ,ruby-nenv)))
872 `(("bundler" ,bundler)))
873 (synopsis "Wrapper libray for notification libraries")
874 (description "Notiffany is a Ruby wrapper libray for notification
875 libraries such as Libnotify.")
876 (home-page "https://github.com/guard/notiffany")
877 (license license:expat)))
879 (define-public ruby-formatador
881 (name "ruby-formatador")
885 (uri (rubygems-uri "formatador" version))
888 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
889 (build-system ruby-build-system)
890 ;; Circular dependency: Tests require ruby-shindo, which requires
891 ;; ruby-formatador at runtime.
892 (arguments `(#:tests? #f))
893 (synopsis "Ruby library to format text on stdout")
894 (description "Formatador is a Ruby library to format text printed to the
895 standard output stream.")
896 (home-page "https://github.com/geemus/formatador")
897 (license license:expat)))
899 (define-public ruby-shindo
905 (uri (rubygems-uri "shindo" version))
908 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
909 (build-system ruby-build-system)
911 `(#:test-target "shindo_tests"
913 (modify-phases %standard-phases
914 (add-after 'unpack 'fix-tests
916 (substitute* "Rakefile"
917 (("system \"shindo") "system \"./bin/shindo")
918 ;; This test doesn't work, so we disable it.
919 (("fail \"The build_error test should fail") "#"))
922 `(("ruby-formatador" ,ruby-formatador)))
923 (synopsis "Simple depth first Ruby testing")
924 (description "Shindo is a simple depth first testing library for Ruby.")
925 (home-page "https://github.com/geemus/shindo")
926 (license license:expat)))
928 (define-public ruby-rubygems-tasks
930 (name "ruby-rubygems-tasks")
934 (uri (rubygems-uri "rubygems-tasks" version))
937 "16cp45qlbcglnqdm4f1vj3diywdz4v024saqpgrz6palf0wmgz2j"))))
938 (build-system ruby-build-system)
939 ;; Tests need Internet access.
940 (arguments `(#:tests? #f))
942 `(("ruby-rspec" ,ruby-rspec)
943 ("ruby-yard" ,ruby-yard)))
944 (synopsis "Rake tasks for managing and releasing Ruby Gems")
945 (description "Rubygems-task provides Rake tasks for managing and releasing
947 (home-page "https://github.com/postmodern/rubygems-tasks")
948 (license license:expat)))
950 (define-public ruby-ffi
956 (uri (rubygems-uri "ffi" version))
959 "034f52xf7zcqgbvwbl20jwdyjwznvqnwpbaps9nk18v9lgb1dpx0"))))
960 (build-system ruby-build-system)
961 ;; FIXME: Before running tests the build system attempts to build libffi
963 (arguments `(#:tests? #f))
965 `(("ruby-rake-compiler" ,ruby-rake-compiler)
966 ("ruby-rspec" ,ruby-rspec)
967 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
969 `(("libffi" ,libffi)))
970 (synopsis "Ruby foreign function interface library")
971 (description "Ruby-FFI is a Ruby extension for programmatically loading
972 dynamic libraries, binding functions within them, and calling those functions
973 from Ruby code. Moreover, a Ruby-FFI extension works without changes on Ruby
975 (home-page "http://wiki.github.com/ffi/ffi")
976 (license license:bsd-3)))
978 (define-public ruby-simplecov-html
980 (name "ruby-simplecov-html")
984 (uri (rubygems-uri "simplecov-html" version))
987 "1qni8g0xxglkx25w54qcfbi4wjkpvmb28cb7rj5zk3iqynjcdrqf"))))
988 (build-system ruby-build-system)
989 (arguments `(#:tests? #f)) ; there are no tests
991 `(("bundler" ,bundler)))
992 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
993 (description "This package provides the default HTML formatter for
994 the SimpleCov code coverage tool for Ruby version 1.9 and above.")
995 (home-page "https://github.com/colszowka/simplecov-html")
996 (license license:expat)))
998 (define-public ruby-simplecov
1000 (name "ruby-simplecov")
1004 (uri (rubygems-uri "simplecov" version))
1007 "0ffhyrfnq2zm2mc1742a4hqy475g3qa1zf6yfldwg1ldh5sn3qbx"))))
1008 (build-system ruby-build-system)
1009 ;; Simplecov depends on rubocop for code style checking at build time.
1010 ;; Rubocop needs simplecov at build time.
1011 (arguments `(#:tests? #f))
1013 `(("ruby-json" ,ruby-json)
1014 ("ruby-docile" ,ruby-docile)
1015 ("ruby-simplecov-html" ,ruby-simplecov-html)))
1017 `(("bundler" ,bundler)))
1018 (synopsis "Code coverage framework for Ruby")
1019 (description "SimpleCov is a code coverage framework for Ruby with a
1020 powerful configuration library and automatic merging of coverage across test
1022 (home-page "https://github.com/colszowka/simplecov")
1023 (license license:expat)))
1025 (define-public ruby-useragent
1027 (name "ruby-useragent")
1031 (uri (rubygems-uri "useragent" version))
1034 "1139cjqyv1hk1qcw89k81ajjkqyakqgbcyvmfrsmjqi8yn9kgqhq"))))
1035 (build-system ruby-build-system)
1037 '(#:tests? #f)) ; no test suite
1038 (synopsis "HTTP user agent parser for Ruby")
1039 (description "UserAgent is a Ruby library that parses and compares HTTP
1041 (home-page "https://github.com/gshutler/useragent")
1042 (license license:expat)))
1044 (define-public ruby-bacon
1050 (uri (rubygems-uri "bacon" version))
1053 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
1054 (build-system ruby-build-system)
1055 (synopsis "Small RSpec clone")
1056 (description "Bacon is a small RSpec clone providing all essential
1058 (home-page "https://github.com/chneukirchen/bacon")
1059 (license license:expat)))
1061 (define-public ruby-connection-pool
1063 (name "ruby-connection-pool")
1067 (uri (rubygems-uri "connection_pool" version))
1070 "1b2bb3k39ni5mzcnqlv9y4yjkbin20s7dkwzp0jw2jf1rmzcgrmy"))))
1071 (build-system ruby-build-system)
1073 `(("bundler" ,bundler)))
1074 (synopsis "Generic connection pool for Ruby")
1075 (description "Connection_pool provides a generic connection pooling
1076 interface for Ruby programs.")
1077 (home-page "https://github.com/mperham/connection_pool")
1078 (license license:expat)))
1080 (define-public ruby-net-http-persistent
1082 (name "ruby-net-http-persistent")
1086 (uri (rubygems-uri "net-http-persistent" version))
1089 "1y9fhaax0d9kkslyiqi1zys6cvpaqx9a0y0cywp24rpygwh4s9r4"))))
1090 (build-system ruby-build-system)
1092 `(("ruby-connection-pool" ,ruby-connection-pool)
1093 ("ruby-hoe" ,ruby-hoe)))
1094 (synopsis "Persistent HTTP connection manager")
1095 (description "Net::HTTP::Persistent manages persistent HTTP connections
1096 using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
1097 (home-page "https://github.com/drbrain/net-http-persistent")
1098 (license license:expat)))
1100 (define-public ruby-power-assert
1102 (name "ruby-power-assert")
1106 (uri (rubygems-uri "power_assert" version))
1109 "0ka6w71lcan4wgf111xi3pcn9ma9lhakv31jg8w007nwzi0xfjbi"))))
1110 (build-system ruby-build-system)
1112 `(("bundler" ,bundler)))
1113 (synopsis "Assert library with descriptive assertion messages")
1114 (description "Power-assert is an assertion library providing descriptive
1115 assertion messages for tests.")
1116 (home-page "https://github.com/k-tsj/power_assert")
1117 (license (list license:bsd-2 license:ruby))))
1119 (define-public ruby-locale
1121 (name "ruby-locale")
1125 (uri (rubygems-uri "locale" version))
1128 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
1129 (build-system ruby-build-system)
1130 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
1131 ;; which needs ruby-gettext, which needs ruby-locale. To break the
1132 ;; dependency cycle we disable tests.
1133 (arguments `(#:tests? #f))
1135 `(("bundler" ,bundler)
1136 ("ruby-yard" ,ruby-yard)))
1137 (synopsis "Ruby library providing basic localization APIs")
1139 "Ruby-Locale is the pure ruby library which provides basic APIs for
1141 (home-page "https://github.com/ruby-gettext/locale")
1142 (license (list license:lgpl3+ license:ruby))))
1144 (define-public ruby-text
1150 (uri (rubygems-uri "text" version))
1153 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
1154 (build-system ruby-build-system)
1155 (synopsis "Collection of text algorithms for Ruby")
1157 "This package provides a collection of text algorithms: Levenshtein,
1158 Soundex, Metaphone, Double Metaphone, Porter Stemming.")
1159 (home-page "https://github.com/threedaymonk/text")
1160 (license license:expat)))
1162 (define-public ruby-gettext
1164 (name "ruby-gettext")
1168 (uri (rubygems-uri "gettext" version))
1171 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
1172 (build-system ruby-build-system)
1173 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
1174 ;; which needs ruby-gettext. To break the dependency cycle we disable
1176 (arguments `(#:tests? #f))
1178 `(("ruby-locale" ,ruby-locale)
1179 ("ruby-text" ,ruby-text)))
1181 `(("bundler" ,bundler)
1182 ("ruby-yard" ,ruby-yard)))
1183 (synopsis "GNU gettext-like program for Ruby")
1185 "Gettext is a GNU gettext-like program for Ruby. The catalog
1186 file (po-file) used is the same as that used by GNU gettext, allowing you to
1187 use GNU gettext tools for maintenance.")
1188 (home-page "http://ruby-gettext.github.com/")
1189 (license (list license:lgpl3+ license:ruby))))
1191 (define-public ruby-packnga
1193 (name "ruby-packnga")
1197 (uri (rubygems-uri "packnga" version))
1200 "1i71yhvlkvi5fp3m8jl9317cnddkbnrcy0syrmiw4y1lrq0cbncj"))))
1201 (build-system ruby-build-system)
1202 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
1203 ;; To break the dependency cycle we disable tests.
1204 (arguments `(#:tests? #f))
1206 `(("ruby-gettext" ,ruby-gettext)
1207 ("ruby-yard" ,ruby-yard)))
1209 `(("bundler" ,bundler)))
1210 (synopsis "Utility library to package internationalized libraries")
1212 "Packnga is a library to translate to many languages using YARD.")
1213 (home-page "http://ranguba.org/packnga/")
1214 (license license:lgpl2.0+)))
1216 (define-public ruby-test-unit
1218 (name "ruby-test-unit")
1222 (uri (rubygems-uri "test-unit" version))
1225 "09mb34lnffracsqxl4dav4c21p5nr4pj9hm5qy2s83k5hbjya3s7"))))
1226 (build-system ruby-build-system)
1228 `(("ruby-power-assert" ,ruby-power-assert)))
1230 `(("bundler" ,bundler)
1231 ("ruby-packnga" ,ruby-packnga)
1232 ("ruby-yard" ,ruby-yard)))
1233 (synopsis "Unit testing framework for Ruby")
1234 (description "@code{Test::Unit} is unit testing framework for Ruby, based
1235 on xUnit principles. These were originally designed by Kent Beck, creator of
1236 extreme programming software development methodology, for Smalltalk's SUnit.
1237 It allows writing tests, checking results and automated testing in Ruby.")
1238 (home-page "http://test-unit.github.io/")
1239 (license (list license:psfl license:ruby))))
1241 (define-public ruby-metaclass
1243 (name "ruby-metaclass")
1247 (uri (rubygems-uri "metaclass" version))
1250 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
1251 (build-system ruby-build-system)
1254 (modify-phases %standard-phases
1255 (add-after 'unpack 'add-test-unit-to-search-path
1256 (lambda* (#:key inputs #:allow-other-keys)
1257 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1258 (test-unit-home (gem-home test-unit
1259 ,(package-version ruby))))
1260 (substitute* "Rakefile"
1261 (("t\\.libs << \"test\"" line)
1262 (string-append line "; t.libs << \""
1265 ,(package-version ruby-test-unit)
1269 `(("bundler" ,bundler)
1270 ("ruby-test-unit" ,ruby-test-unit)))
1271 (synopsis "Ruby library adding metaclass method to all objects")
1273 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
1275 (home-page "https://github.com/floehopper/metaclass")
1276 (license license:expat)))
1278 (define-public ruby-blankslate
1280 (name "ruby-blankslate")
1284 (uri (rubygems-uri "blankslate" version))
1287 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
1288 (build-system ruby-build-system)
1291 (modify-phases %standard-phases
1293 (lambda _ (zero? (system* "rspec" "spec/")))))))
1295 `(("bundler" ,bundler)
1296 ("ruby-rspec" ,ruby-rspec)))
1297 (synopsis "Abstract base class with no predefined methods")
1299 "BlankSlate provides an abstract base class with no predefined
1300 methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
1301 as a base class when writing classes that depend upon
1302 @code{method_missing} (e.g. dynamic proxies).")
1303 (home-page "https://github.com/masover/blankslate")
1304 (license license:expat)))
1306 (define-public ruby-instantiator
1308 (name "ruby-instantiator")
1312 (uri (rubygems-uri "instantiator" version))
1315 "0mfmqhg9xrv9i8i1kmphf15ywddhivyh2z3ccl0xjw8qy54zr21i"))))
1316 (build-system ruby-build-system)
1319 (modify-phases %standard-phases
1320 (add-after 'unpack 'add-test-unit-to-search-path
1321 (lambda* (#:key inputs #:allow-other-keys)
1322 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1323 (test-unit-home (gem-home test-unit ,(package-version
1325 (substitute* "Rakefile"
1326 (("t\\.libs << \"test\"" line)
1327 (string-append line "; t.libs << \""
1330 ,(package-version ruby-test-unit)
1334 `(("ruby-blankslate" ,ruby-blankslate)))
1336 `(("bundler" ,bundler)
1337 ("ruby-test-unit" ,ruby-test-unit)))
1338 (synopsis "Instantiate an arbitrary Ruby class")
1340 "Instantiator lets you instantiate an arbitrary Ruby class without
1341 knowing anything about the constructor.")
1342 (home-page "https://github.com/floehopper/instantiator")
1343 (license license:expat)))
1345 (define-public ruby-introspection
1347 (name "ruby-introspection")
1351 (uri (rubygems-uri "introspection" version))
1354 "0g1j71sqfxbqk32wj7d0bkd3dlayfqzprfq3dbr0rq107xbxjcrr"))))
1355 (build-system ruby-build-system)
1358 (modify-phases %standard-phases
1359 (add-after 'unpack 'add-test-unit-to-search-path
1360 (lambda* (#:key inputs #:allow-other-keys)
1361 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1362 (test-unit-home (gem-home test-unit ,(package-version
1364 (substitute* "Rakefile"
1365 (("t\\.libs << \"test\"" line)
1366 (string-append line "; t.libs << \""
1369 ,(package-version ruby-test-unit)
1373 `(("ruby-instantiator" ,ruby-instantiator)
1374 ("ruby-metaclass" ,ruby-metaclass)))
1376 `(("bundler" ,bundler)
1377 ("ruby-blankslate" ,ruby-blankslate)
1378 ("ruby-test-unit" ,ruby-test-unit)))
1379 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
1381 "Introspection provides tools to inspect the hierarchy of method
1382 definitions on a Ruby object.")
1383 (home-page "https://github.com/floehopper/introspection")
1384 (license license:expat)))
1386 (define-public ruby-redcarpet
1388 (name "ruby-redcarpet")
1392 (uri (rubygems-uri "redcarpet" version))
1395 "0h9qz2hik4s9knpmbwrzb3jcp3vc5vygp9ya8lcpl7f1l9khmcd7"))))
1396 (build-system ruby-build-system)
1399 (modify-phases %standard-phases
1400 ;; The gem archive does not include the conformance tests.
1401 (add-after 'unpack 'disable-conformance-tests
1403 (substitute* "Rakefile"
1404 (("task :test => %w\\[test:unit test:conformance\\]")
1405 "task :test => %w[test:unit]"))
1408 `(("bundler" ,bundler)
1409 ("ruby-test-unit" ,ruby-test-unit)
1410 ("ruby-rake-compiler" ,ruby-rake-compiler)))
1411 (synopsis "Extensible Markdown to (X)HTML converter")
1413 "Redcarpet is an extensible Ruby library for Markdown processing and
1414 conversion to (X)HTML.")
1415 (home-page "https://github.com/vmg/redcarpet")
1416 (license license:expat)))
1418 (define-public ruby-mocha
1424 (uri (rubygems-uri "mocha" version))
1427 "107nmnngbv8lq2g7hbjpn5kplb4v2c8gs9lxrg6vs8gdbddkilzi"))))
1428 (build-system ruby-build-system)
1431 (modify-phases %standard-phases
1432 (add-after 'unpack 'add-test-unit-to-search-path
1433 (lambda* (#:key inputs #:allow-other-keys)
1434 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1435 (test-unit-home (gem-home test-unit
1436 ,(package-version ruby))))
1437 (substitute* "Rakefile"
1438 (("t\\.libs << 'test'" line)
1439 (string-append line "; t.libs << \""
1442 ,(package-version ruby-test-unit)
1445 (add-before 'check 'use-latest-redcarpet
1447 (substitute* "mocha.gemspec"
1448 (("<redcarpet>.freeze, \\[\"~> 1\"\\]")
1449 "<redcarpet>.freeze, [\">= 3\"]"))
1451 (add-before 'check 'hardcode-version
1453 ;; Mocha is undefined at build time
1454 (substitute* "Rakefile"
1455 (("#\\{Mocha::VERSION\\}") ,version))
1457 (add-before 'check 'remove-failing-test
1458 ;; FIXME: This test fails for reasons unrelated to Guix packaging.
1460 (delete-file "test/acceptance/stubbing_nil_test.rb")
1463 `(("ruby-metaclass" ,ruby-metaclass)))
1465 `(("bundler" ,bundler)
1466 ("ruby-yard" ,ruby-yard)
1467 ("ruby-introspection" ,ruby-introspection)
1468 ("ruby-test-unit" ,ruby-test-unit)
1469 ("ruby-redcarpet" ,ruby-redcarpet)))
1470 (synopsis "Mocking and stubbing library for Ruby")
1472 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
1473 allows mocking and stubbing of methods on real (non-mock) classes.")
1474 (home-page "http://gofreerange.com/mocha/docs")
1475 (license license:expat)))
1477 (define-public ruby-net-ssh
1479 (name "ruby-net-ssh")
1483 (uri (rubygems-uri "net-ssh" version))
1486 "013p5jb4wy0cq7x7036piw2a3s1i9p752ki1srx2m289mpz4ml3q"))))
1487 (build-system ruby-build-system)
1489 `(("bundler" ,bundler)
1490 ("ruby-mocha" ,ruby-mocha)
1491 ("ruby-test-unit" ,ruby-test-unit)))
1492 (synopsis "Ruby implementation of the SSH2 client protocol")
1493 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
1494 client protocol. It allows you to write programs that invoke and interact
1495 with processes on remote servers, via SSH2.")
1496 (home-page "https://github.com/net-ssh/net-ssh")
1497 (license license:expat)))
1499 (define-public ruby-minitest
1501 (name "ruby-minitest")
1505 (uri (rubygems-uri "minitest" version))
1508 "05521clw19lrksqgvg2kmm025pvdhdaniix52vmbychrn2jm7kz2"))))
1509 (build-system ruby-build-system)
1511 `(("ruby-hoe" ,ruby-hoe)))
1512 (synopsis "Small test suite library for Ruby")
1513 (description "Minitest provides a complete suite of Ruby testing
1514 facilities supporting TDD, BDD, mocking, and benchmarking.")
1515 (home-page "https://github.com/seattlerb/minitest")
1516 (license license:expat)))
1518 ;; This is the last release of Minitest 4, which is used by some packages.
1519 (define-public ruby-minitest-4
1520 (package (inherit ruby-minitest)
1524 (uri (rubygems-uri "minitest" version))
1527 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
1530 (modify-phases %standard-phases
1531 (add-after 'unpack 'remove-unsupported-method
1533 (substitute* "Rakefile"
1534 (("self\\.rubyforge_name = .*") ""))
1536 (add-after 'build 'exclude-failing-tests
1538 ;; Some tests are failing on Ruby 2.4 due to the deprecation of
1540 (delete-file "test/minitest/test_minitest_spec.rb")
1543 (define-public ruby-minitest-sprint
1545 (name "ruby-minitest-sprint")
1549 (uri (rubygems-uri "minitest-sprint" version))
1552 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
1553 (build-system ruby-build-system)
1555 `(("ruby-hoe" ,ruby-hoe)
1556 ("ruby-minitest" ,ruby-minitest)))
1557 (synopsis "Fast test suite runner for minitest")
1558 (description "Minitest-sprint is a test runner for minitest that makes it
1559 easier to re-run individual failing tests.")
1560 (home-page "https://github.com/seattlerb/minitest-sprint")
1561 (license license:expat)))
1563 (define-public ruby-minitest-bacon
1565 (name "ruby-minitest-bacon")
1569 (uri (rubygems-uri "minitest-bacon" version))
1572 "0cm7r68422743i3b6fm4rrm0r6cnnjmglq5gcmmgl1f0rk5hnf6r"))))
1573 (build-system ruby-build-system)
1575 `(("ruby-hoe" ,ruby-hoe)))
1577 `(("ruby-minitest" ,ruby-minitest)))
1578 (synopsis "Bacon compatibility library for minitest")
1579 (description "Minitest-bacon extends minitest with bacon-like
1580 functionality, making it easier to migrate test suites from bacon to minitest.")
1581 (home-page "https://github.com/seattlerb/minitest-bacon")
1582 (license license:expat)))
1584 (define-public ruby-minitest-focus
1586 (name "ruby-minitest-focus")
1591 (uri (rubygems-uri "minitest-focus" version))
1594 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
1595 (build-system ruby-build-system)
1597 `(("ruby-minitest" ,ruby-minitest)))
1599 `(("ruby-hoe" ,ruby-hoe)))
1600 (synopsis "Allows a few specific tests to be focused on")
1602 "@code{minitest-focus} gives the ability focus on a few tests with ease
1603 without having to use command-line arguments. It introduces a @code{focus}
1604 class method for use in testing classes, specifying that the next defined test
1606 (home-page "https://github.com/seattlerb/minitest-focus")
1607 (license license:expat)))
1609 (define-public ruby-minitest-pretty-diff
1610 ;; Use git reference because gem is out of date and does not contain testing
1611 ;; script. There are no releases on GitHub.
1612 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
1614 (name "ruby-minitest-pretty-diff")
1615 (version (string-append "0.1-1." (string-take commit 8)))
1619 (url "https://github.com/adammck/minitest-pretty_diff.git")
1621 (file-name (string-append name "-" version "-checkout"))
1624 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
1625 (build-system ruby-build-system)
1628 (modify-phases %standard-phases
1631 (zero? (system* "script/test")))))))
1633 `(("bundler" ,bundler)
1634 ("ruby-turn" ,ruby-turn)))
1635 (synopsis "Pretty-print hashes and arrays in MiniTest")
1637 "@code{minitest-pretty_diff} monkey-patches
1638 @code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
1639 diffing them. This makes it easier to spot differences between nested
1640 structures when tests fail.")
1641 (home-page "https://github.com/adammck/minitest-pretty_diff")
1642 (license license:expat))))
1644 (define-public ruby-minitest-moar
1646 (name "ruby-minitest-moar")
1651 (uri (rubygems-uri "minitest-moar" version))
1654 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
1655 (build-system ruby-build-system)
1658 (modify-phases %standard-phases
1659 (add-before 'check 'clean-dependencies
1661 ;; Remove all gems defined in the Gemfile because these are not
1663 (substitute* "Gemfile"
1665 ;; Remove byebug as not needed to run tests.
1666 (substitute* "test/test_helper.rb"
1667 (("require 'byebug'") ""))
1670 `(("bundler" ,bundler)
1671 ("ruby-minitest" ,ruby-minitest)))
1672 (synopsis "Extra features and changes to MiniTest")
1673 (description "@code{MiniTest Moar} add some additional features and
1674 changes some default behaviours in MiniTest. For instance, Moar replaces the
1675 MiniTest @code{Object#stub} with a global @code{stub} method.")
1676 (home-page "https://github.com/dockyard/minitest-moar")
1677 (license license:expat)))
1679 (define-public ruby-minitest-bonus-assertions
1681 (name "ruby-minitest-bonus-assertions")
1686 (uri (rubygems-uri "minitest-bonus-assertions" version))
1689 "11nrd32kwy61ndg9csk7l1ifya79ghrrv3vsrxj57k50m7na6jkm"))))
1690 (build-system ruby-build-system)
1693 (modify-phases %standard-phases
1694 (add-before 'check 'clean-dependencies
1696 ;; Remove unneeded require statement that would entail another
1698 (substitute* "test/minitest_config.rb"
1699 (("require 'minitest/bisect'") ""))
1702 `(("ruby-hoe" ,ruby-hoe)
1703 ("ruby-minitest-pretty-diff" ,ruby-minitest-pretty-diff)
1704 ("ruby-minitest-focus" ,ruby-minitest-focus)
1705 ("ruby-minitest-moar" ,ruby-minitest-moar)))
1706 (synopsis "Bonus assertions for @code{Minitest}")
1708 "Minitest bonus assertions provides extra MiniTest assertions. For
1709 instance, it provides @code{assert_true}, @code{assert_false} and
1710 @code{assert_set_equal}.")
1711 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
1712 (license license:expat)))
1714 (define-public ruby-minitest-rg
1716 (name "ruby-minitest-rg")
1721 (uri (rubygems-uri "minitest-rg" version))
1724 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
1725 (build-system ruby-build-system)
1727 ;; Some tests fail even outside Guix, so disable tests.
1728 ;; https://github.com/blowmage/minitest-rg/issues/12
1729 ;; https://github.com/blowmage/minitest-rg/pull/13
1732 `(("ruby-minitest" ,ruby-minitest)))
1733 (synopsis "Coloured output for Minitest")
1735 "@code{minitest-rg} changes the colour of the output from Minitest.")
1736 (home-page "http://blowmage.com/minitest-rg")
1737 (license license:expat)))
1739 (define-public ruby-minitest-hooks
1741 (name "ruby-minitest-hooks")
1746 (uri (rubygems-uri "minitest-hooks" version))
1749 "092fymh0c09v3a585qw3hc15b0zf159s74rxx1ga87drk5jr958z"))))
1750 (build-system ruby-build-system)
1752 '(#:test-target "spec"))
1754 `(("ruby-sequel" ,ruby-sequel)
1755 ("ruby-sqlite3" ,ruby-sqlite3)))
1756 (synopsis "Hooks for the minitest framework")
1758 "Minitest-hooks adds @code{around}, @code{before_all}, @code{after_all},
1759 @code{around_all} hooks for Minitest. This allows, for instance, running each
1760 suite of specs inside a database transaction, running each spec inside its own
1761 savepoint inside that transaction. This can significantly speed up testing
1762 for specs that share expensive database setup code.")
1763 (home-page "https://github.com/jeremyevans/minitest-hooks")
1764 (license license:expat)))
1766 (define-public ruby-daemons
1768 (name "ruby-daemons")
1772 (uri (rubygems-uri "daemons" version))
1775 "121c7vkimg3baxga69xvdkwxiq8wkmxqvdbyqi5i82vhih5d3cn3"))))
1776 (build-system ruby-build-system)
1778 `(#:tests? #f)) ; no test suite
1779 (synopsis "Daemonize Ruby programs")
1780 (description "Daemons provides a way to wrap existing Ruby scripts to be
1781 run as a daemon and to be controlled by simple start/stop/restart commands.")
1782 (home-page "https://github.com/thuehlinger/daemons")
1783 (license license:expat)))
1785 (define-public ruby-git
1791 (uri (rubygems-uri "git" version))
1794 "1sqfj8lmhl7c5zamcckkpik4izfph2zkv6krw0i8mzj5pdws5acs"))))
1795 (build-system ruby-build-system)
1797 `(#:tests? #f ; no tests
1798 #:phases (modify-phases %standard-phases
1799 (add-after 'install 'patch-git-binary
1800 (lambda* (#:key inputs outputs #:allow-other-keys)
1801 ;; Make the default git binary an absolute path to the
1803 (let ((git (string-append (assoc-ref inputs "git")
1805 (config (string-append (getenv "GEM_HOME")
1806 "/gems/git-" ,version
1807 "/lib/git/config.rb")))
1808 (substitute* (list config)
1810 (string-append "'" git "'")))
1814 (synopsis "Ruby wrappers for Git")
1815 (description "Ruby/Git is a Ruby library that can be used to create, read
1816 and manipulate Git repositories by wrapping system calls to the git binary.")
1817 (home-page "https://github.com/schacon/ruby-git")
1818 (license license:expat)))
1820 (define-public ruby-slop
1826 (uri (rubygems-uri "slop" version))
1829 "0bfm8535g0rkn9cbjndkckf0f7a3wj0rg4rqhrpsgxnbfdf2lm0p"))))
1830 (build-system ruby-build-system)
1832 `(("ruby-minitest" ,ruby-minitest)))
1833 (synopsis "Ruby command line option parser")
1834 (description "Slop provides a Ruby domain specific language for gathering
1835 options and parsing command line flags.")
1836 (home-page "https://github.com/leejarvis/slop")
1837 (license license:expat)))
1839 (define-public ruby-slop-3
1840 (package (inherit ruby-slop)
1844 (uri (rubygems-uri "slop" version))
1847 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
1849 (define-public ruby-multipart-post
1851 (name "ruby-multipart-post")
1855 (uri (rubygems-uri "multipart-post" version))
1858 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
1859 (build-system ruby-build-system)
1861 `(("bundler" ,bundler)))
1862 (synopsis "Multipart POST library for Ruby")
1863 (description "Multipart-Post Adds multipart POST capability to Ruby's
1865 (home-page "https://github.com/nicksieger/multipart-post")
1866 (license license:expat)))
1868 (define-public ruby-arel
1874 (uri (rubygems-uri "arel" version))
1877 "0nw0qbc6ph625p6n3maqq9f527vz3nbl0hk72fbyka8jzsmplxzl"))))
1878 (build-system ruby-build-system)
1879 (arguments '(#:tests? #f)) ; no tests
1880 (home-page "https://github.com/rails/arel")
1881 (synopsis "SQL AST manager for Ruby")
1882 (description "Arel is an SQL @dfn{Abstract Syntax Tree} (AST) manager for
1883 Ruby. It simplifies the generation of complex SQL queries and adapts to
1884 various relational database implementations.")
1885 (license license:expat)))
1887 (define-public ruby-minitar
1888 ;; We package from the GitHub source to fix the security issue reported at
1889 ;; https://github.com/halostatue/minitar/issues/16.
1890 (let ((commit "e25205ecbb6277ae8a3df1e6a306d7ed4458b6e4"))
1892 (name "ruby-minitar")
1893 (version (string-append "0.5.4-1." (string-take commit 8)))
1898 (url "https://github.com/halostatue/minitar.git")
1900 (file-name (string-append name "-" version "-checkout"))
1903 "1iywfx07jgjqcmixzkxk9zdwfmij1fyg1z2jlwzj15cj7s99qlfv"))))
1904 (build-system ruby-build-system)
1906 '(#:tests? #f)) ; missing a gemspec
1907 (synopsis "Ruby library and utility for handling tar archives")
1909 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
1910 that provides the ability to deal with POSIX tar archive files.")
1911 (home-page "http://www.github.com/atoulme/minitar")
1912 (license (list license:gpl2+ license:ruby)))))
1914 (define-public ruby-mini-portile
1916 (name "ruby-mini-portile")
1921 (uri (rubygems-uri "mini_portile" version))
1924 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
1925 (build-system ruby-build-system)
1927 '(#:tests? #f)) ; tests require network access
1928 (synopsis "Ports system for Ruby developers")
1929 (description "Mini-portile is a port/recipe system for Ruby developers.
1930 It provides a standard way to compile against specific versions of libraries
1931 to reproduce user environments.")
1932 (home-page "https://github.com/flavorjones/mini_portile")
1933 (license license:expat)))
1935 (define-public ruby-mini-portile-2
1936 (package (inherit ruby-mini-portile)
1940 (uri (rubygems-uri "mini_portile2" version))
1943 "0g5bpgy08q0nc0anisg3yvwc1gc3inl854fcrg48wvg7glqd6dpm"))))))
1945 (define-public ruby-nokogiri
1947 (name "ruby-nokogiri")
1951 (uri (rubygems-uri "nokogiri" version))
1954 "1nffsyx1xjg6v5n9rrbi8y1arrcx2i5f21cp6clgh9iwiqkr7rnn"))))
1955 (build-system ruby-build-system)
1957 ;; Tests fail because Nokogiri can only test with an installed extension,
1958 ;; and also because many test framework dependencies are missing.
1960 #:gem-flags (list "--" "--use-system-libraries"
1961 (string-append "--with-xml2-include="
1962 (assoc-ref %build-inputs "libxml2")
1963 "/include/libxml2" ))
1965 (modify-phases %standard-phases
1966 (add-before 'build 'patch-extconf
1967 ;; 'pkg-config' is not included in the GEM_PATH during
1968 ;; installation, so we add it directly to the load path.
1969 (lambda* (#:key inputs #:allow-other-keys)
1970 (let* ((pkg-config (assoc-ref inputs "ruby-pkg-config"))
1971 (pkg-config-home (gem-home pkg-config
1972 ,(package-version ruby))))
1973 (substitute* "ext/nokogiri/extconf.rb"
1974 (("gem 'pkg-config'.*")
1975 (string-append "$:.unshift '"
1978 ,(package-version ruby-pkg-config)
1982 `(("ruby-hoe" ,ruby-hoe)))
1985 ("libxml2" ,libxml2)
1986 ("libxslt" ,libxslt)))
1988 `(("ruby-mini-portile" ,ruby-mini-portile-2)
1989 ("ruby-pkg-config" ,ruby-pkg-config)))
1990 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
1991 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
1992 both CSS3 selector and XPath 1.0 support.")
1993 (home-page "http://www.nokogiri.org/")
1994 (license license:expat)))
1996 (define-public ruby-method-source
1998 (name "ruby-method-source")
2003 (uri (rubygems-uri "method_source" version))
2006 "1g5i4w0dmlhzd18dijlqw5gk27bv6dj2kziqzrzb7mpgxgsd1sf2"))))
2007 (build-system ruby-build-system)
2009 `(("ruby-bacon" ,ruby-bacon)
2011 (synopsis "Retrieve the source code for Ruby methods")
2012 (description "Method_source retrieves the source code for Ruby methods.
2013 Additionally, it can extract source code from Proc and Lambda objects or just
2015 (home-page "https://github.com/banister/method_source")
2016 (license license:expat)))
2018 (define-public ruby-coderay
2020 (name "ruby-coderay")
2025 (uri (rubygems-uri "coderay" version))
2028 "1x6z923iwr1hi04k6kz5a6llrixflz8h5sskl9mhaaxy9jx2x93r"))))
2029 (build-system ruby-build-system)
2031 '(#:tests? #f)) ; missing test files
2032 (synopsis "Ruby syntax highlighting library")
2033 (description "Coderay is a Ruby library that provides syntax highlighting
2034 for select languages.")
2035 (home-page "http://coderay.rubychan.de")
2036 (license license:expat)))
2038 (define-public ruby-pry
2045 (uri (rubygems-uri "pry" version))
2048 "05xbzyin63aj2prrv8fbq2d5df2mid93m81hz5bvf2v4hnzs42ar"))))
2049 (build-system ruby-build-system)
2051 '(#:tests? #f)) ; no tests
2053 `(("ruby-coderay" ,ruby-coderay)
2054 ("ruby-method-source" ,ruby-method-source)
2055 ("ruby-slop" ,ruby-slop-3)))
2056 (synopsis "Ruby REPL")
2057 (description "Pry is an IRB alternative and runtime developer console for
2058 Ruby. It features syntax highlighting, a plugin architecture, runtime
2059 invocation, and source and documentation browsing.")
2060 (home-page "http://pryrepl.org")
2061 (license license:expat)))
2063 (define-public ruby-guard
2069 ;; The gem does not include a Rakefile, nor does it contain a
2070 ;; gemspec file, nor does it come with the tests. This is why
2071 ;; we fetch the tarball from Github.
2072 (uri (string-append "https://github.com/guard/guard/archive/v"
2074 (file-name (string-append name "-" version ".tar.gz"))
2077 "1hwj0yi17k6f5axrm0k2bb7fq71dlp0zfywmd7pij9iimbppcca0"))))
2078 (build-system ruby-build-system)
2080 `(#:tests? #f ; tests require cucumber
2082 (modify-phases %standard-phases
2083 (add-after 'unpack 'remove-git-ls-files
2084 (lambda* (#:key outputs #:allow-other-keys)
2085 (substitute* "guard.gemspec"
2086 (("git ls-files -z") "find . -type f -print0"))
2090 (zero? (system* "gem" "build" "guard.gemspec")))))))
2092 `(("ruby-formatador" ,ruby-formatador)
2093 ("ruby-listen" ,ruby-listen)
2094 ("ruby-lumberjack" ,ruby-lumberjack)
2095 ("ruby-nenv" ,ruby-nenv)
2096 ("ruby-notiffany" ,ruby-notiffany)
2097 ("ruby-pry" ,ruby-pry)
2098 ("ruby-shellany" ,ruby-shellany)
2099 ("ruby-thor" ,ruby-thor)))
2101 `(("bundler" ,bundler)
2102 ("ruby-rspec" ,ruby-rspec)))
2103 (synopsis "Tool to handle events on file system modifications")
2105 "Guard is a command line tool to easily handle events on file system
2106 modifications. Guard automates various tasks by running custom rules whenever
2107 file or directories are modified.")
2108 (home-page "http://guardgem.org/")
2109 (license license:expat)))
2111 (define-public ruby-thread-safe
2113 (name "ruby-thread-safe")
2118 (uri (rubygems-uri "thread_safe" version))
2121 "1hq46wqsyylx5afkp6jmcihdpv4ynzzq9ygb6z2pb1cbz5js0gcr"))))
2122 (build-system ruby-build-system)
2124 '(#:tests? #f)) ; needs simplecov, among others
2125 (synopsis "Thread-safe utilities for Ruby")
2126 (description "The thread_safe library provides thread-safe collections and
2127 utilities for Ruby.")
2128 (home-page "https://github.com/ruby-concurrency/thread_safe")
2129 (license license:asl2.0)))
2131 (define-public ruby-tzinfo
2133 (name "ruby-tzinfo")
2138 (uri (rubygems-uri "tzinfo" version))
2141 "05r81lk7q7275rdq7xipfm0yxgqyd2ggh73xpc98ypngcclqcscl"))))
2142 (build-system ruby-build-system)
2144 `(("ruby-thread-safe" ,ruby-thread-safe)))
2145 (synopsis "Time zone library for Ruby")
2146 (description "TZInfo is a Ruby library that provides daylight savings
2147 aware transformations between times in different time zones.")
2148 (home-page "http://tzinfo.github.io")
2149 (license license:expat)))
2151 (define-public ruby-tzinfo-data
2153 (name "ruby-tzinfo-data")
2154 (version "1.2016.9")
2158 ;; Download from GitHub because the rubygems version does not contain
2159 ;; Rakefile or tests.
2161 "https://github.com/tzinfo/tzinfo-data/archive/v"
2164 (file-name (string-append name "-" version ".tar.gz"))
2167 "0i8vz2j7wmcpr4pd066qvlg4if5blscjrgxk2imavfa49nq5lp06"))
2168 ;; Remove the known test failure.
2169 ;; https://github.com/tzinfo/tzinfo-data/issues/10
2170 ;; https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1587128
2171 (patches (search-patches
2172 "ruby-tzinfo-data-ignore-broken-test.patch"))))
2173 (build-system ruby-build-system)
2175 `(("ruby-tzinfo" ,ruby-tzinfo)))
2176 (synopsis "Data from the IANA Time Zone database")
2178 "This library provides @code{TZInfo::Data}, which contains data from the
2179 IANA Time Zone database packaged as Ruby modules for use with @code{TZInfo}.")
2180 (home-page "http://tzinfo.github.io")
2181 (license license:expat)))
2183 (define-public ruby-rb-inotify
2185 (name "ruby-rb-inotify")
2190 (uri (rubygems-uri "rb-inotify" version))
2193 "0yfsgw5n7pkpyky6a9wkf1g9jafxb0ja7gz0qw0y14fd2jnzfh71"))))
2194 (build-system ruby-build-system)
2196 '(#:tests? #f ; there are no tests
2198 (modify-phases %standard-phases
2199 ;; Building the gemspec with rake is not working here since it is
2200 ;; generated with Jeweler. It is also unnecessary because the
2201 ;; existing gemspec does not use any development tools to generate a
2205 (zero? (system* "gem" "build" "rb-inotify.gemspec")))))))
2207 `(("ruby-ffi" ,ruby-ffi)))
2209 `(("ruby-yard" ,ruby-yard)))
2210 (synopsis "Ruby wrapper for Linux's inotify")
2211 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
2212 kernel subsystem for monitoring changes to files and directories.")
2213 (home-page "https://github.com/nex3/rb-inotify")
2214 (license license:expat)))
2216 (define-public ruby-pry-editline
2218 (name "ruby-pry-editline")
2222 (uri (rubygems-uri "pry-editline" version))
2225 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
2226 (build-system ruby-build-system)
2227 (arguments `(#:tests? #f)) ; no tests included
2229 `(("bundler" ,bundler)))
2230 (synopsis "Open the current REPL line in an editor")
2232 "This gem provides a plugin for the Ruby REPL to enable opening the
2233 current line in an external editor.")
2234 (home-page "https://github.com/tpope/pry-editline")
2235 (license license:expat)))
2237 (define-public ruby-sdoc
2243 (uri (rubygems-uri "sdoc" version))
2246 "0qhvy10vnmrqcgh8494m13kd5ag9c3sczzhfasv8j0294ylk679n"))))
2247 (build-system ruby-build-system)
2250 (modify-phases %standard-phases
2251 (add-before 'check 'set-rubylib-and-patch-gemfile
2253 (setenv "RUBYLIB" "lib")
2254 (substitute* "sdoc.gemspec"
2255 (("s.add_runtime_dependency.*") "\n")
2256 (("s.add_dependency.*") "\n"))
2257 (substitute* "Gemfile"
2259 "gem 'rake'\ngem 'rdoc'\ngem 'json'\n"))
2262 `(("ruby-json" ,ruby-json)))
2264 `(("bundler" ,bundler)
2265 ("ruby-minitest" ,ruby-minitest)
2266 ("ruby-hoe" ,ruby-hoe)))
2267 (synopsis "Generate searchable RDoc documentation")
2269 "SDoc is an RDoc documentation generator to build searchable HTML
2270 documentation for Ruby code.")
2271 (home-page "https://github.com/voloko/sdoc")
2272 (license license:expat)))
2274 (define-public ruby-tins
2280 (uri (rubygems-uri "tins" version))
2283 "1060h8dgnjl9az0sv1b74yrni8d4mh3x858wq6yfbfdf5dxrfl0a"))))
2284 (build-system ruby-build-system)
2285 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
2286 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
2289 `(#:tests? #f ; there are no tests
2291 (modify-phases %standard-phases
2294 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
2296 (substitute* "tins.gemspec"
2297 (("\"lib/spruz\", ") ""))
2298 (zero? (system* "gem" "build" "tins.gemspec")))))))
2299 (synopsis "Assorted tools for Ruby")
2300 (description "Tins is a Ruby library providing assorted tools.")
2301 (home-page "https://github.com/flori/tins")
2302 (license license:expat)))
2304 (define-public ruby-gem-hadar
2306 (name "ruby-gem-hadar")
2310 (uri (rubygems-uri "gem_hadar" version))
2313 "1zxvd9l95rbks7x3cxn396w0sn7nha5542bf97v8akkn4vm7nby9"))))
2314 (build-system ruby-build-system)
2315 ;; This gem needs itself at development time. We disable rebuilding of the
2316 ;; gemspec to avoid this loop.
2318 `(#:tests? #f ; there are no tests
2320 (modify-phases %standard-phases
2323 (zero? (system* "gem" "build" "gem_hadar.gemspec")))))))
2326 ("ruby-tins" ,ruby-tins)
2327 ("ruby-yard" ,ruby-yard)))
2328 (synopsis "Library for the development of Ruby gems")
2330 "This library contains some useful functionality to support the
2331 development of Ruby gems.")
2332 (home-page "https://github.com/flori/gem_hadar")
2333 (license license:expat)))
2335 (define-public ruby-minitest-tu-shim
2337 (name "ruby-minitest-tu-shim")
2341 (uri (rubygems-uri "minitest_tu_shim" version))
2344 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
2345 (build-system ruby-build-system)
2348 (modify-phases %standard-phases
2349 (add-after 'unpack 'fix-test-include-path
2350 (lambda* (#:key inputs #:allow-other-keys)
2351 (let* ((minitest (assoc-ref inputs "ruby-minitest-4"))
2352 (minitest-home (gem-home minitest
2353 ,(package-version ruby))))
2354 (substitute* "Rakefile"
2355 (("Hoe\\.add_include_dirs .*")
2356 (string-append "Hoe.add_include_dirs \""
2359 ,(package-version ruby-minitest-4)
2362 (add-before 'check 'fix-test-assumptions
2364 ;; The test output includes the file name, so a couple of tests
2365 ;; fail. Changing the regular expressions slightly fixes this
2367 (substitute* "test/test_mini_test.rb"
2368 (("output.sub!\\(.*, 'FILE:LINE'\\)")
2369 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
2370 (("gsub\\(/.*, 'FILE:LINE'\\)")
2371 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
2374 `(("ruby-minitest-4" ,ruby-minitest-4)))
2376 `(("ruby-hoe" ,ruby-hoe)))
2377 (synopsis "Adapter library between minitest and test/unit")
2379 "This library bridges the gap between the small and fast minitest and
2380 Ruby's large and slower test/unit.")
2381 (home-page "https://rubygems.org/gems/minitest_tu_shim")
2382 (license license:expat)))
2384 (define-public ruby-term-ansicolor
2386 (name "ruby-term-ansicolor")
2390 (uri (rubygems-uri "term-ansicolor" version))
2393 "0ydbbyjmk5p7fsi55ffnkq79jnfqx65c3nj8d9rpgl6sw85ahyys"))))
2394 (build-system ruby-build-system)
2395 ;; Rebuilding the gemspec seems to require git, even though this is not a
2396 ;; git repository, so we just build the gem from the existing gemspec.
2399 (modify-phases %standard-phases
2402 (zero? (system* "gem" "build" "term-ansicolor.gemspec")))))))
2404 `(("ruby-tins" ,ruby-tins)))
2406 `(("ruby-gem-hadar" ,ruby-gem-hadar)
2407 ("ruby-minitest-tu-shim" ,ruby-minitest-tu-shim)))
2408 (synopsis "Ruby library to control the attributes of terminal output")
2410 "This Ruby library uses ANSI escape sequences to control the attributes
2411 of terminal output.")
2412 (home-page "http://flori.github.io/term-ansicolor/")
2413 ;; There is no mention of the "or later" clause.
2414 (license license:gpl2)))
2416 (define-public ruby-pstree
2418 (name "ruby-pstree")
2422 (uri (rubygems-uri "pstree" version))
2425 "1mig1sv5qx1cdyhjaipy8jlh9j8pnja04vprrzihyfr54x0215p1"))))
2426 (build-system ruby-build-system)
2428 `(("ruby-gem-hadar" ,ruby-gem-hadar)
2429 ("bundler" ,bundler)))
2430 (synopsis "Create a process tree data structure")
2432 "This library uses the output of the @code{ps} command to create a
2433 process tree data structure for the current host.")
2434 (home-page "http://flori.github.com/pstree")
2435 ;; There is no mention of the "or later" clause.
2436 (license license:gpl2)))
2438 (define-public ruby-utils
2444 (uri (rubygems-uri "utils" version))
2447 "196zhgcygrnx09bb9mh22qas03rl9avzx8qs0wnxznpin4pffwcl"))))
2448 (build-system ruby-build-system)
2450 `(("ruby-tins" ,ruby-tins)
2451 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
2452 ("ruby-pstree" ,ruby-pstree)
2453 ("ruby-pry-editline" ,ruby-pry-editline)))
2455 `(("ruby-gem-hadar" ,ruby-gem-hadar)
2456 ("bundler" ,bundler)))
2457 (synopsis "Command line tools for working with Ruby")
2459 "This package provides assorted command line tools that may be useful
2460 when working with Ruby code.")
2461 (home-page "https://github.com/flori/utils")
2462 ;; There is no mention of the "or later" clause.
2463 (license license:gpl2)))
2465 (define-public ruby-json
2472 (uri (rubygems-uri "json" version))
2475 "01v6jjpvh3gnq6sgllpfqahlgxzj50ailwhj9b3cd20hi2dx0vxp"))))
2476 (build-system ruby-build-system)
2477 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
2478 (synopsis "JSON library for Ruby")
2479 (description "This Ruby library provides a JSON implementation written as
2480 a native C extension.")
2481 (home-page "http://json-jruby.rubyforge.org/")
2482 (license (list license:ruby license:gpl2)))) ; GPL2 only
2484 (define-public ruby-json-pure
2486 (name "ruby-json-pure")
2490 (uri (rubygems-uri "json_pure" version))
2493 "12yf9fmhr4c2jm3xl20vf1qyz5i63vc8a6ngz9j0f86nqwhmi2as"))))
2494 (build-system ruby-build-system)
2497 (modify-phases %standard-phases
2498 (add-after 'unpack 'fix-rakefile
2500 (substitute* "Rakefile"
2501 ;; Since this is not a git repository, do not call 'git'.
2502 (("`git ls-files`") "`find . -type f |sort`")
2503 ;; Loosen dependency constraint.
2504 (("'test-unit', '~> 2.0'") "'test-unit', '>= 2.0'"))
2506 (add-after 'replace-git-ls-files 'regenerate-gemspec
2508 ;; Regenerate gemspec so loosened dependency constraints are
2510 (zero? (system* "rake" "gemspec")))))))
2512 `(("bundler" ,bundler)
2513 ("ruby-test-unit" ,ruby-test-unit)
2514 ("ruby-simplecov" ,ruby-simplecov)))
2515 (synopsis "JSON implementation in pure Ruby")
2517 "This package provides a JSON implementation written in pure Ruby.")
2518 (home-page "http://flori.github.com/json")
2519 (license license:ruby)))
2521 ;; Even though this package only provides bindings for a Mac OSX API it is
2522 ;; required by "ruby-listen" at runtime.
2523 (define-public ruby-rb-fsevent
2525 (name "ruby-rb-fsevent")
2529 (uri (rubygems-uri "rb-fsevent" version))
2532 "1fbpmjypwxkb8r7y1kmhmyp6gawa4byw0yb3jc3dn9ly4ld9lizf"))))
2533 (build-system ruby-build-system)
2534 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
2535 ;; "listen", which needs "rb-fsevent" at runtime.
2536 (arguments `(#:tests? #f))
2537 (synopsis "FSEvents API with signals catching")
2539 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
2540 (home-page "https://rubygems.org/gems/rb-fsevent")
2541 (license license:expat)))
2543 (define-public ruby-listen
2545 (name "ruby-listen")
2550 (uri (rubygems-uri "listen" version))
2553 "10lhshjklxlrkw7999j0xl6sdxd4x32kiy8rp88jwr68kis5vq2b"))))
2554 (build-system ruby-build-system)
2555 (arguments '(#:tests? #f)) ; no tests
2557 `(("ruby-rb-inotify" ,ruby-rb-inotify)
2558 ("ruby-rb-fsevent" ,ruby-rb-fsevent)))
2559 (synopsis "Listen to file modifications")
2560 (description "The Listen gem listens to file modifications and notifies
2561 you about the changes.")
2562 (home-page "https://github.com/guard/listen")
2563 (license license:expat)))
2565 (define-public ruby-activesupport
2567 (name "ruby-activesupport")
2572 (uri (rubygems-uri "activesupport" version))
2575 "16r18n6b1nlky0xx2lw8c1f15gr2vm34xz5g4byjcxf88m1s07xh"))))
2576 (build-system ruby-build-system)
2579 (modify-phases %standard-phases
2582 ;; There is no tests, instead attempt to load the library.
2583 (zero? (system* "ruby" "-Ilib" "-r" "active_support")))))))
2585 `(("ruby-concurrent" ,ruby-concurrent)
2586 ("ruby-i18n" ,ruby-i18n)
2587 ("ruby-minitest" ,ruby-minitest)
2588 ("ruby-tzinfo" ,ruby-tzinfo)
2589 ("ruby-tzinfo-data" ,ruby-tzinfo-data)))
2590 (synopsis "Ruby on Rails utility library")
2591 (description "ActiveSupport is a toolkit of support libraries and Ruby
2592 core extensions extracted from the Rails framework. It includes support for
2593 multibyte strings, internationalization, time zones, and testing.")
2594 (home-page "http://www.rubyonrails.org")
2595 (license license:expat)))
2597 (define-public ruby-crass
2603 (uri (rubygems-uri "crass" version))
2606 "1c377r8g7m58y22803iyjgqkkvnnii0pymskda1pardxrzaighj9"))))
2607 (build-system ruby-build-system)
2609 `(("bundler" ,bundler)
2610 ("ruby-minitest" ,ruby-minitest)))
2611 (synopsis "Pure Ruby CSS parser")
2613 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
2614 (home-page "https://github.com/rgrove/crass/")
2615 (license license:expat)))
2617 (define-public ruby-nokogumbo
2618 (let ((commit "fb51ff299a1c34346837580b6d1d9a60fadf5dbd"))
2620 (name "ruby-nokogumbo")
2621 (version (string-append "1.4.7-1." (string-take commit 8)))
2623 ;; We use the git reference, because there's no Rakefile in the
2624 ;; published gem and the tarball on Github is outdated.
2627 (url "https://github.com/rubys/nokogumbo.git")
2628 (commit "d56f954d20a")))
2629 (file-name (string-append name "-" version "-checkout"))
2632 "0bnppjy96xiadrsrc9dp8y6wvdwnkfa930n7acrp0mqm4qywl2wl"))))
2633 (build-system ruby-build-system)
2635 `(#:modules ((guix build ruby-build-system)
2639 (modify-phases %standard-phases
2640 (add-after 'unpack 'build-gemspec
2642 (substitute* "Rakefile"
2643 ;; Build Makefile even without a copy of gumbo-parser sources
2644 (("'gumbo-parser/src',") "")
2645 ;; We don't bundle gumbo-parser sources
2646 (("'gumbo-parser/src/\\*',") "")
2647 (("'gumbo-parser/visualc/include/\\*',") "")
2648 ;; The definition of SOURCES will be cut in gemspec, and
2649 ;; "FileList" will be undefined.
2650 (("SOURCES \\+ FileList\\[")
2651 "['ext/nokogumboc/extconf.rb', 'ext/nokogumboc/nokogumbo.c', "))
2653 ;; Copy the Rakefile and cut out the gemspec.
2654 (copy-file "Rakefile" ".gemspec")
2655 (with-atomic-file-replacement ".gemspec"
2657 (let loop ((line (read-line in 'concat))
2659 (if (eof-object? line)
2661 (let ((skip-next? (if skipping?
2662 (not (string-prefix? "SPEC =" line))
2663 (string-prefix? "end" line))))
2664 (when (or (not skipping?)
2665 (and skipping? (not skip-next?)))
2666 (format #t "~a" line)
2668 (loop (read-line in 'concat) skip-next?))))))
2671 `(("gumbo-parser" ,gumbo-parser)))
2673 `(("ruby-nokogiri" ,ruby-nokogiri)))
2674 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
2676 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
2677 access the result as a Nokogiri parsed document.")
2678 (home-page "https://github.com/rubys/nokogumbo/")
2679 (license license:asl2.0))))
2681 (define-public ruby-sanitize
2683 (name "ruby-sanitize")
2687 ;; The gem does not include the Rakefile, so we download the
2688 ;; release tarball from Github.
2689 (uri (string-append "https://github.com/rgrove/"
2690 "sanitize/archive/v" version ".tar.gz"))
2691 (file-name (string-append name "-" version ".tar.gz"))
2694 "055xnj38l60gxnnng76kpy2l2jbrp0byjdyq17jw79w7l4b40znr"))))
2695 (build-system ruby-build-system)
2697 `(("ruby-crass" ,ruby-crass)
2698 ("ruby-nokogiri" ,ruby-nokogiri)
2699 ("ruby-nokogumbo" ,ruby-nokogumbo)))
2701 `(("bundler" ,bundler)
2702 ("ruby-minitest" ,ruby-minitest)
2703 ("ruby-redcarpet" ,ruby-redcarpet)
2704 ("ruby-yard" ,ruby-yard)))
2705 (synopsis "Whitelist-based HTML and CSS sanitizer")
2707 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
2708 acceptable elements, attributes, and CSS properties, Sanitize will remove all
2709 unacceptable HTML and/or CSS from a string.")
2710 (home-page "https://github.com/rgrove/sanitize/")
2711 (license license:expat)))
2713 (define-public ruby-ox
2720 (uri (rubygems-uri "ox" version))
2723 "0rar0xr5qn3zac1r2z18kmpapx121c2l3z8jsgh60vsddwzpdh7h"))))
2724 (build-system ruby-build-system)
2726 '(#:tests? #f)) ; no tests
2727 (synopsis "Optimized XML library for Ruby")
2729 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
2730 written as a native C extension. It was designed to be an alternative to
2731 Nokogiri and other Ruby XML parsers for generic XML parsing and as an
2732 alternative to Marshal for Object serialization. ")
2733 (home-page "http://www.ohler.com/ox")
2734 (license license:expat)))
2736 (define-public ruby-redcloth
2738 (name "ruby-redcloth")
2742 (uri (rubygems-uri "RedCloth" version))
2745 "06pahxyrckhgb7alsxwhhlx1ib2xsx33793finj01jk8i054bkxl"))))
2746 (build-system ruby-build-system)
2748 `(#:tests? #f ; no tests
2750 (modify-phases %standard-phases
2751 ;; Redcloth has complicated rake tasks to build various versions for
2752 ;; multiple targets using RVM. We don't want this so we just use the
2753 ;; existing gemspec.
2756 (zero? (system* "gem" "build" "redcloth.gemspec"))))
2757 ;; Make sure that the "redcloth" executable finds required Ruby
2759 (add-after 'install 'wrap-bin-redcloth
2760 (lambda* (#:key outputs #:allow-other-keys)
2761 (wrap-program (string-append (assoc-ref outputs "out")
2763 `("GEM_HOME" ":" prefix (,(getenv "GEM_HOME"))))
2766 `(("bundler" ,bundler)
2767 ("ruby-diff-lcs" ,ruby-diff-lcs)
2768 ("ruby-rspec-2" ,ruby-rspec-2)))
2769 (synopsis "Textile markup language parser for Ruby")
2771 "RedCloth is a Ruby parser for the Textile markup language.")
2772 (home-page "http://redcloth.org")
2773 (license license:expat)))
2775 (define-public ruby-pg
2782 (uri (rubygems-uri "pg" version))
2785 "00vhasqwc4f98qb4wxqn2h07fjwzhp5lwyi41j2gndi2g02wrdqh"))))
2786 (build-system ruby-build-system)
2788 '(#:test-target "spec"))
2790 `(("ruby-rake-compiler" ,ruby-rake-compiler)
2791 ("ruby-hoe" ,ruby-hoe)
2792 ("ruby-rspec" ,ruby-rspec)))
2794 `(("postgresql" ,postgresql)))
2795 (synopsis "Ruby interface to PostgreSQL")
2796 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
2797 with PostgreSQL 8.4 and later.")
2798 (home-page "https://bitbucket.org/ged/ruby-pg")
2799 (license license:ruby)))
2801 (define-public ruby-byebug
2803 (name "ruby-byebug")
2808 (uri (rubygems-uri "byebug" version))
2811 "1kbfcn65rgdhi72n8x9l393b89rvi5z542459k7d1ggchpb0idb0"))))
2812 (build-system ruby-build-system)
2814 '(#:tests? #f)) ; no tests
2815 (synopsis "Debugger for Ruby 2")
2816 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
2817 TracePoint C API for execution control and the Debug Inspector C API for call
2818 stack navigation. The core component provides support that front-ends can
2819 build on. It provides breakpoint handling and bindings for stack frames among
2820 other things and it comes with a command line interface.")
2821 (home-page "https://github.com/deivid-rodriguez/byebug")
2822 (license license:bsd-2)))
2824 (define-public ruby-netrc
2830 (uri (rubygems-uri "netrc" version))
2833 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
2834 (build-system ruby-build-system)
2837 (modify-phases %standard-phases
2839 ;; There is no Rakefile and minitest can only run one file at once,
2840 ;; so we have to iterate over all test files.
2842 (and (map (lambda (file)
2843 (zero? (system* "ruby" "-Itest" file)))
2844 (find-files "./test" "test_.*\\.rb"))))))))
2846 `(("ruby-minitest" ,ruby-minitest)))
2847 (synopsis "Library to read and update netrc files")
2849 "This library can read and update netrc files, preserving formatting
2850 including comments and whitespace.")
2851 (home-page "https://github.com/geemus/netrc")
2852 (license license:expat)))
2854 (define-public ruby-unf-ext
2856 (name "ruby-unf-ext")
2860 (uri (rubygems-uri "unf_ext" version))
2863 "0ly2ms6c3irmbr1575ldyh52bz2v0lzzr2gagf0p526k12ld2n5b"))))
2864 (build-system ruby-build-system)
2867 (modify-phases %standard-phases
2868 (add-after 'build 'build-ext
2869 (lambda _ (zero? (system* "rake" "compile:unf_ext")))))))
2871 `(("bundler" ,bundler)
2872 ("ruby-rake-compiler" ,ruby-rake-compiler)
2873 ("ruby-test-unit" ,ruby-test-unit)))
2874 (synopsis "Unicode normalization form support library")
2876 "This package provides unicode normalization form support for Ruby.")
2877 (home-page "https://github.com/knu/ruby-unf_ext")
2878 (license license:expat)))
2880 (define-public ruby-tdiff
2881 ;; Use a newer than released snapshot so that rspec-2 is not required.
2882 (let ((commit "b662a6048f08abc45c1a834e5f34dd1c662935e2"))
2885 (version (string-append "0.3.3-1." (string-take commit 8)))
2889 (url "https://github.com/postmodern/tdiff.git")
2891 (file-name (string-append name "-" version "-checkout"))
2894 "0n3gq8rx49f7ln6zqlshqfg2mgqyy30rsdjlnki5mv307ykc7ad4"))))
2895 (build-system ruby-build-system)
2897 `(("ruby-rspec" ,ruby-rspec)
2898 ("ruby-yard" ,ruby-yard)
2899 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
2900 (synopsis "Calculate the differences between two tree-like structures")
2902 "This library provides functions to calculate the differences between two
2903 tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
2904 (home-page "https://github.com/postmodern/tdiff")
2905 (license license:expat))))
2907 (define-public ruby-nokogiri-diff
2908 ;; Use a newer than released snapshot so that rspec-2 is not required.
2909 (let ((commit "a38491e4d8709b7406f2cae11a50226d927d06f5"))
2911 (name "ruby-nokogiri-diff")
2912 (version (string-append "0.2.0-1." (string-take commit 8)))
2916 (url "https://github.com/postmodern/nokogiri-diff.git")
2918 (file-name (string-append name "-" version "-checkout"))
2921 "1ah2sfjh9n1p0ln2wkqzfl448ml7j4zfy6dhp1qgzq2m41php6rf"))))
2922 (build-system ruby-build-system)
2924 `(("ruby-tdiff" ,ruby-tdiff)
2925 ("ruby-nokogiri" ,ruby-nokogiri)))
2927 `(("ruby-rspec" ,ruby-rspec)
2928 ("ruby-yard" ,ruby-yard)
2929 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
2930 (synopsis "Calculate the differences between two XML/HTML documents")
2932 "@code{Nokogiri::Diff} adds the ability to calculate the
2933 differences (added or removed nodes) between two XML/HTML documents.")
2934 (home-page "https://github.com/postmodern/nokogiri-diff")
2935 (license license:expat))))
2937 (define-public ruby-rack
2944 ;; Download from GitHub so that the patch can be applied.
2946 "https://github.com/rack/rack/archive/"
2949 (file-name (string-append name "-" version ".tar.gz"))
2952 "12bnqrcg43x9hsswjqg31qqwk8cwj2fh0d2m179y20bjghhn54kx"))
2953 ;; Ignore test which fails inside the build environment but works
2955 (patches (search-patches "ruby-rack-ignore-failing-test.patch"))))
2956 (build-system ruby-build-system)
2959 (modify-phases %standard-phases
2960 (add-before 'check 'fix-tests
2962 ;; A few of the tests use the length of a file on disk for
2963 ;; Content-Length and Content-Range headers. However, this file
2964 ;; has a shebang in it which an earlier phase patches, growing
2965 ;; the file size from 193 to 239 bytes when the store prefix is
2967 (let ((size-diff (- (string-length (which "ruby"))
2968 (string-length "/usr/bin/env ruby"))))
2969 (substitute* '("test/spec_file.rb")
2971 (number->string (+ 193 size-diff)))
2972 (("bytes(.)22-33" all delimiter)
2973 (string-append "bytes"
2975 (number->string (+ 22 size-diff))
2977 (number->string (+ 33 size-diff))))))
2980 `(("ruby-minitest" ,ruby-minitest)
2981 ("ruby-minitest-sprint" ,ruby-minitest-sprint)
2984 `(("ruby-concurrent" ,ruby-concurrent)))
2985 (synopsis "Unified web application interface for Ruby")
2986 (description "Rack provides a minimal, modular and adaptable interface for
2987 developing web applications in Ruby. By wrapping HTTP requests and responses,
2988 it unifies the API for web servers, web frameworks, and software in between
2989 into a single method call.")
2990 (home-page "http://rack.github.io/")
2991 (license license:expat)))
2993 (define-public ruby-docile
2995 (name "ruby-docile")
3000 (uri (rubygems-uri "docile" version))
3003 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
3004 (build-system ruby-build-system)
3006 '(#:tests? #f)) ; needs github-markup, among others
3007 (synopsis "Ruby EDSL helper library")
3008 (description "Docile is a Ruby library that provides an interface for
3009 creating embedded domain specific languages (EDSLs) that manipulate existing
3011 (home-page "https://ms-ati.github.io/docile/")
3012 (license license:expat)))
3014 (define-public ruby-gherkin
3016 (name "ruby-gherkin")
3021 (uri (rubygems-uri "gherkin" version))
3024 "1d18r8mf2qyd9jbq9xxvca8adyysdzvwdy8v9c2s5hrd6p02kg79"))))
3025 (build-system ruby-build-system)
3027 `(("bundler" ,bundler)))
3029 '(#:tests? #f)) ; needs simplecov, among others
3030 (synopsis "Gherkin parser for Ruby")
3031 (description "Gherkin is a parser and compiler for the Gherkin language.
3032 It is intended be used by all Cucumber implementations to parse '.feature'
3034 (home-page "https://github.com/cucumber/gherkin3")
3035 (license license:expat)))
3037 (define-public ruby-cucumber-core
3039 (name "ruby-cucumber-core")
3044 (uri (rubygems-uri "cucumber-core" version))
3047 "136hnvqv444qyxzcgy1k60y4i6cn3sn9lbqr4wan9dzz1yzllqbm"))))
3048 (build-system ruby-build-system)
3050 `(("ruby-gherkin" ,ruby-gherkin)))
3052 `(("bundler" ,bundler)))
3054 '(#:tests? #f)) ; needs simplecov, among others
3055 (synopsis "Core library for the Cucumber BDD app")
3056 (description "Cucumber is a tool for running automated tests
3057 written in plain language. Because they're written in plain language,
3058 they can be read by anyone on your team. Because they can be read by
3059 anyone, you can use them to help improve communication, collaboration
3060 and trust on your team.")
3061 (home-page "https://cucumber.io/")
3062 (license license:expat)))
3064 (define-public ruby-bio-logger
3066 (name "ruby-bio-logger")
3071 (uri (rubygems-uri "bio-logger" version))
3074 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
3075 (build-system ruby-build-system)
3077 `(#:tests? #f)) ; rake errors, missing shoulda
3079 `(("ruby-log4r" ,ruby-log4r)))
3080 (synopsis "Log4r wrapper for Ruby")
3081 (description "Bio-logger is a wrapper around Log4r adding extra logging
3082 features such as filtering and fine grained logging.")
3083 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
3084 (license license:expat)))
3086 (define-public ruby-yard
3093 ;; Tests do not pass if we build from the distributed gem.
3094 (uri (string-append "https://github.com/lsegal/yard/archive/v"
3096 (file-name (string-append name "-" version ".tar.gz"))
3099 "0rsz4bghgx7fryzyhlz8wlnd2m9xgyvf1xhrq58mnzfrrfm41bdg"))))
3100 (build-system ruby-build-system)
3103 (modify-phases %standard-phases
3106 ;; $HOME needs to be set to somewhere writeable for tests to run
3107 (setenv "HOME" "/tmp")
3108 ;; Run tests without using 'rake' to avoid dependencies.
3109 (zero? (system* "rspec")))))))
3111 `(("ruby-rspec" ,ruby-rspec)
3112 ("ruby-rack" ,ruby-rack)))
3113 (synopsis "Documentation generation tool for Ruby")
3115 "YARD is a documentation generation tool for the Ruby programming
3116 language. It enables the user to generate consistent, usable documentation
3117 that can be exported to a number of formats very easily, and also supports
3118 extending for custom Ruby constructs such as custom class level definitions.")
3119 (home-page "http://yardoc.org")
3120 (license license:expat)))
3122 (define-public ruby-clap
3128 (uri (rubygems-uri "clap" version))
3131 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
3132 (build-system ruby-build-system)
3133 ;; Clap needs cutest for running tests, but cutest needs clap.
3134 (arguments `(#:tests? #f))
3135 (synopsis "Command line argument parsing for simple applications")
3137 "Clap provides command line argument parsing features. It covers the
3138 simple case of executing code based on the flags or parameters passed.")
3139 (home-page "https://github.com/djanowski/cutest")
3140 (license license:expat)))
3142 (define-public ruby-cutest
3144 (name "ruby-cutest")
3148 (uri (rubygems-uri "cutest" version))
3151 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
3152 (build-system ruby-build-system)
3154 `(("ruby-clap" ,ruby-clap)))
3155 (synopsis "Run tests in separate processes")
3157 "Cutest runs tests in separate processes to avoid shared state.")
3158 (home-page "https://github.com/djanowski/cutest")
3159 (license license:expat)))
3161 (define-public ruby-pygmentize
3163 (name "ruby-pygmentize")
3167 (uri (rubygems-uri "pygmentize" version))
3170 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
3171 (build-system ruby-build-system)
3174 (modify-phases %standard-phases
3175 (add-after 'unpack 'fix-pygmentize-path
3177 (substitute* "lib/pygmentize.rb"
3178 (("\"/usr/bin/env python.*")
3179 (string-append "\"" (which "pygmentize") "\"\n")))
3181 (add-after 'build 'do-not-use-vendor-directory
3183 ;; Remove bundled pygments sources
3184 ;; FIXME: ruby-build-system does not support snippets.
3185 (delete-file-recursively "vendor")
3186 (substitute* "pygmentize.gemspec"
3187 (("\"vendor/\\*\\*/\\*\",") ""))
3190 `(("pygments" ,python-pygments)))
3192 `(("ruby-cutest" ,ruby-cutest)
3193 ("ruby-nokogiri" ,ruby-nokogiri)))
3194 (synopsis "Thin Ruby wrapper around pygmentize")
3196 "Pygmentize provides a simple way to call pygmentize from within a Ruby
3198 (home-page "https://github.com/djanowski/pygmentize")
3199 (license license:expat)))
3201 (define-public ruby-eventmachine
3203 (name "ruby-eventmachine")
3208 (uri (rubygems-uri "eventmachine" version))
3211 "1frvpk3p73xc64qkn0ymll3flvn4xcycq5yx8a43zd3gyzc1ifjp"))))
3212 (build-system ruby-build-system)
3214 '(#:tests? #f)) ; test suite tries to connect to google.com
3216 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
3217 (synopsis "Single-threaded network event framework for Ruby")
3219 "EventMachine implements a single-threaded engine for arbitrary network
3220 communications. EventMachine wraps all interactions with sockets, allowing
3221 programs to concentrate on the implementation of network protocols. It can be
3222 used to create both network servers and clients.")
3223 (home-page "http://rubyeventmachine.com")
3224 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
3226 (define-public ruby-turn
3233 (uri (rubygems-uri "turn" version))
3236 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
3237 (build-system ruby-build-system)
3240 (modify-phases %standard-phases
3241 ;; Tests fail because turn changes its environment so can no longer
3242 ;; find test/unit. Instead simply test if the executable runs
3246 (zero? (system* "ruby" "-Ilib" "bin/turn" "-h")))))))
3248 `(("ruby-ansi" ,ruby-ansi)
3249 ("ruby-minitest" ,ruby-minitest-4)))
3250 (synopsis "Alternate set of alternative runners for MiniTest")
3252 "TURN provides a set of alternative runners for MiniTest which are both
3253 colorful and informative. TURN displays each test on a separate line with
3254 failures being displayed immediately instead of at the end of the tests. Note
3255 that TURN is no longer being maintained.")
3256 (home-page "http://rubygems.org/gems/turn")
3257 (license license:expat)))
3259 (define-public ruby-mime-types-data
3261 (name "ruby-mime-types-data")
3262 (version "3.2016.0521")
3266 (uri (rubygems-uri "mime-types-data" version))
3269 "04my3746hwa4yvbx1ranhfaqkgf6vavi1kyijjnw8w3dy37vqhkm"))))
3270 (build-system ruby-build-system)
3272 `(("ruby-hoe" ,ruby-hoe)))
3273 (synopsis "Registry for information about MIME media type definitions")
3275 "@code{mime-types-data} provides a registry for information about
3276 Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
3277 be used with the Ruby mime-types library or other software to determine
3278 defined filename extensions for MIME types, or to use filename extensions to
3279 look up the likely MIME type definitions.")
3280 (home-page "https://github.com/mime-types/mime-types-data/")
3281 (license license:expat)))
3283 (define-public ruby-mime-types
3285 (name "ruby-mime-types")
3290 (uri (rubygems-uri "mime-types" version))
3293 "0087z9kbnlqhci7fxh9f6il63hj1k02icq2rs0c6cppmqchr753m"))))
3294 (build-system ruby-build-system)
3296 `(("ruby-mime-types-data" ,ruby-mime-types-data)))
3298 `(("ruby-hoe" ,ruby-hoe)
3299 ("ruby-fivemat" ,ruby-fivemat)
3300 ("ruby-minitest-focus" ,ruby-minitest-focus)
3301 ("ruby-minitest-rg" ,ruby-minitest-rg)
3302 ("ruby-minitest-bonus-assertions" ,ruby-minitest-bonus-assertions)
3303 ("ruby-minitest-hooks" ,ruby-minitest-hooks)))
3304 (synopsis "Library and registry for MIME content type definitions")
3305 (description "The mime-types library provides a library and registry for
3306 information about Multipurpose Internet Mail Extensions (MIME) content type
3307 definitions. It can be used to determine defined filename extensions for MIME
3308 types, or to use filename extensions to look up the likely MIME type
3310 (home-page "https://github.com/mime-types/ruby-mime-types")
3311 (license license:expat)))
3313 (define-public ruby-fivemat
3315 (name "ruby-fivemat")
3320 (uri (rubygems-uri "fivemat" version))
3323 "1gvw6g4yc96l2pcyvigahyfsjxpdjx21iiwzvf965zippchdh6gk"))))
3324 (build-system ruby-build-system)
3326 `(#:tests? #f)) ; no tests
3327 (synopsis "Each test file given its own line of dots")
3329 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
3330 its own line of dots during testing. It aims to provide test output that is
3331 neither too verbose nor too minimal.")
3332 (home-page "https://github.com/tpope/fivemat")
3333 (license license:expat)))
3335 (define-public ruby-sqlite3
3337 (name "ruby-sqlite3")
3342 (uri (rubygems-uri "sqlite3" version))
3345 "01ifzp8nwzqppda419c9wcvr8n82ysmisrs0hph9pdmv1lpa4f5i"))))
3346 (build-system ruby-build-system)
3349 (modify-phases %standard-phases
3350 (add-before 'check 'add-gemtest-file
3351 ;; This file exists in the repository but is not distributed.
3352 (lambda _ (zero? (system* "touch" ".gemtest")))))))
3354 `(("sqlite" ,sqlite)))
3356 `(("ruby-hoe" ,ruby-hoe)
3357 ("ruby-rake-compiler" ,ruby-rake-compiler)
3358 ("ruby-mini-portile" ,ruby-mini-portile)))
3359 (synopsis "Interface with SQLite3 databases")
3361 "This module allows Ruby programs to interface with the SQLite3 database
3364 "https://github.com/sparklemotion/sqlite3-ruby")
3365 (license license:bsd-3)))
3367 (define-public ruby-shoulda-context
3369 (name "ruby-shoulda-context")
3374 (uri (rubygems-uri "shoulda-context" version))
3377 "1l0ncsxycb4s8n47dml97kdnixw4mizljbkwqc3rh05r70csq9bc"))))
3378 (build-system ruby-build-system)
3381 (modify-phases %standard-phases
3384 ;; Do not run tests to avoid circular dependence with rails.
3385 ;; Instead just import the library to test.
3386 (zero? (system* "ruby" "-Ilib" "-r" "shoulda-context")))))))
3387 (synopsis "Test::Unit context framework extracted from Shoulda")
3389 "@code{shoulda-context} is the context framework extracted from Shoulda.
3390 Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
3391 context, setup, and should blocks combine to produce natural test method
3393 (home-page "https://github.com/thoughtbot/shoulda-context")
3394 (license license:expat)))
3396 (define-public ruby-shoulda-matchers
3398 (name "ruby-shoulda-matchers")
3403 (uri (rubygems-uri "shoulda-matchers" version))
3406 "1zvv94pqk5b5my3w1shdz7h34xf2ldhg5k4qfdpbwi2iy0j9zw2a"))))
3407 (build-system ruby-build-system)
3410 (modify-phases %standard-phases
3413 ;; Do not run tests to avoid circular dependence with rails. Instead
3414 ;; just import the library to test.
3415 (zero? (system* "ruby" "-Ilib" "-r" "shoulda-matchers")))))))
3417 `(("ruby-activesupport" ,ruby-activesupport)))
3418 (synopsis "Collection of testing matchers extracted from Shoulda")
3420 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
3421 test common Rails functionality. These tests would otherwise be much longer,
3422 more complex, and error-prone.")
3423 (home-page "https://github.com/thoughtbot/shoulda-matchers")
3424 (license license:expat)))
3426 (define-public ruby-shoulda-matchers-2
3428 (inherit ruby-shoulda-matchers)
3432 (uri (rubygems-uri "shoulda-matchers" version))
3435 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
3437 (define-public ruby-shoulda
3439 (name "ruby-shoulda")
3444 (uri (rubygems-uri "shoulda" version))
3447 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
3448 (build-system ruby-build-system)
3451 (modify-phases %standard-phases
3453 ;; Don't run tests to avoid circular dependence with rails. Instead
3454 ;; just import the library to test.
3455 (lambda _ (zero? (system* "ruby" "-Ilib" "-r" "shoulda")))))))
3457 `(("ruby-shoulda-context" ,ruby-shoulda-context)
3458 ("ruby-shoulda-matchers" ,ruby-shoulda-matchers-2)))
3459 (synopsis "Context framework and matchers for testing")
3461 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
3462 @code{shoulda-matchers} providing tools for writing tests.")
3463 (home-page "https://github.com/thoughtbot/shoulda")
3464 (license license:expat)))
3466 (define-public ruby-unf
3473 (uri (rubygems-uri "unf" version))
3476 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
3477 (build-system ruby-build-system)
3480 (modify-phases %standard-phases
3481 (add-before 'check 'add-dependency-to-bundler
3483 ;; test-unit is required but not provided by the bundler
3484 ;; environment. This is fixed in the upstream repository but fix
3485 ;; has not been released.
3486 (substitute* "Gemfile"
3487 (("^gemspec") "gem 'test-unit'\ngemspec"))
3490 `(("ruby-unf-ext" ,ruby-unf-ext)))
3492 `(("ruby-shoulda" ,ruby-shoulda)
3493 ("bundler" ,bundler)
3494 ("ruby-test-unit" ,ruby-test-unit)))
3495 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
3497 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
3498 support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
3499 @code{java.text.Normalizer} on JRuby.")
3500 (home-page "https://github.com/knu/ruby-unf")
3501 (license license:bsd-2)))
3503 (define-public ruby-domain-name
3505 (name "ruby-domain-name")
3506 (version "0.5.20170404")
3510 (uri (rubygems-uri "domain_name" version))
3513 "12hs8yijhak7p2hf1xkh98g0mnp5phq3mrrhywzaxpwz1gw5r3kf"))))
3514 (build-system ruby-build-system)
3517 (modify-phases %standard-phases
3518 (add-before 'check 'fix-versions
3520 ;; Fix NameError that appears to already be fixed upstream.
3521 (substitute* "Rakefile"
3522 (("DomainName::VERSION")
3523 "Bundler::GemHelper.gemspec.version"))
3524 ;; Loosen unnecessarily strict test-unit version specification.
3525 (substitute* "domain_name.gemspec"
3526 (("<test-unit>.freeze, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
3529 `(("ruby-unf" ,ruby-unf)))
3531 `(("ruby-shoulda" ,ruby-shoulda)
3532 ("bundler" ,bundler)
3533 ("ruby-test-unit" ,ruby-test-unit)))
3534 (synopsis "Domain name manipulation library")
3536 "@code{domain_name} is a Domain name manipulation library. It parses a
3537 domain name ready for extracting the registered domain and TLD (Top Level
3538 Domain). It can also be used for cookie domain validation based on the Public
3540 (home-page "https://github.com/knu/ruby-domain_name")
3541 (license license:bsd-2)))
3543 (define-public ruby-http-cookie
3545 (name "ruby-http-cookie")
3550 (uri (rubygems-uri "http-cookie" version))
3553 "004cgs4xg5n6byjs7qld0xhsjq3n6ydfh897myr2mibvh6fjc49g"))))
3554 (build-system ruby-build-system)
3557 (modify-phases %standard-phases
3558 (add-before 'check 'add-dependency-to-bundler
3561 (substitute* "Rakefile"
3562 (("HTTP::Cookie::VERSION")
3563 "Bundler::GemHelper.gemspec.version"))
3566 `(("ruby-domain-name" ,ruby-domain-name)))
3568 `(("rubysimplecov" ,ruby-simplecov)
3569 ("bundler" ,bundler)
3570 ("ruby-sqlite3" ,ruby-sqlite3)
3571 ("ruby-test-unit" ,ruby-test-unit)))
3572 (synopsis "Handle HTTP Cookies based on RFC 6265")
3574 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
3575 RFC 6265. It has been designed with security, standards compliance and
3576 compatibility in mind, to behave just the same as today's major web browsers.
3577 It has built-in support for the legacy @code{cookies.txt} and
3578 @code{cookies.sqlite} formats of Mozilla Firefox.")
3579 (home-page "https://github.com/sparklemotion/http-cookie")
3580 (license license:expat)))
3582 (define-public ruby-ansi
3589 ;; Fetch from GitHub as the gem does not contain testing code.
3590 (uri (string-append "https://github.com/rubyworks/ansi/archive/"
3592 (file-name (string-append name "-" version ".tar.gz"))
3595 "1zdip30hivyipi8hndhb457bhiz033awd00bgrsk5axjrwp6zhly"))))
3596 (build-system ruby-build-system)
3599 (modify-phases %standard-phases
3600 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
3601 ;; cycle ansi, qed, ansi. Instead simply test that the library can
3605 (zero? (system* "ruby" "-Ilib" "-r" "ansi"))))
3606 (add-before 'validate-runpath 'replace-broken-symlink
3607 (lambda* (#:key outputs #:allow-other-keys)
3608 (let* ((out (assoc-ref outputs "out"))
3609 (file (string-append out "/lib/ruby/gems/"
3610 ,(package-version ruby)
3611 "/gems/ansi-" ,version
3613 ;; XXX: This symlink is broken since ruby 2.4.
3614 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
3616 (symlink "../.index" file)
3618 (synopsis "ANSI escape code related libraries")
3620 "This package is a collection of ANSI escape code related libraries
3621 enabling ANSI colorization and stylization of console output. Included in the
3622 library are the @code{Code} module, which defines ANSI codes as constants and
3623 methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
3624 @code{ProgressBar}, and a @code{String} subclass. The library also includes a
3625 @code{Terminal} module which provides information about the current output
3627 (home-page "http://rubyworks.github.io/ansi")
3628 (license license:bsd-2)))
3630 (define-public ruby-systemu
3632 (name "ruby-systemu")
3637 (uri (rubygems-uri "systemu" version))
3640 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
3641 (build-system ruby-build-system)
3644 (modify-phases %standard-phases
3645 (add-before 'check 'set-version
3647 (setenv "VERSION" ,version)
3649 (synopsis "Capture of stdout/stderr and handling of child processes")
3651 "Systemu can be used on any platform to return status, stdout, and stderr
3652 of any command. Unlike other methods like @code{open3} and @code{popen4}
3653 there is no danger of full pipes or threading issues hanging your process or
3655 (home-page "https://github.com/ahoward/systemu")
3656 (license license:ruby)))
3658 (define-public ruby-bio-commandeer
3660 (name "ruby-bio-commandeer")
3665 (uri (rubygems-uri "bio-commandeer" version))
3668 "0khpfw1yl5l3d2m8nxpkk32ybc4c3pa5hic3agd160jdfjjjnlni"))))
3669 (build-system ruby-build-system)
3672 (modify-phases %standard-phases
3674 ;; Run test without calling 'rake' so that jeweler is
3675 ;; not required as an input.
3677 (zero? (system* "rspec" "spec/bio-commandeer_spec.rb")))))))
3679 `(("ruby-bio-logger" ,ruby-bio-logger)
3680 ("ruby-systemu" ,ruby-systemu)))
3682 `(("bundler" ,bundler)
3683 ("ruby-rspec" ,ruby-rspec)))
3684 (synopsis "Simplified running of shell commands from within Ruby")
3686 "Bio-commandeer provides an opinionated method of running shell commands
3687 from within Ruby. The advantage of bio-commandeer over other methods of
3688 running external commands is that when something goes wrong, messages printed
3689 to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
3690 detail to ease debugging.")
3691 (home-page "https://github.com/wwood/bioruby-commandeer")
3692 (license license:expat)))
3694 (define-public ruby-rubytest
3696 (name "ruby-rubytest")
3701 (uri (rubygems-uri "rubytest" version))
3704 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
3705 (build-system ruby-build-system)
3707 ;; Disable regular testing to break the cycle rubytest, qed, brass,
3708 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
3709 ;; simply test that the library can be require'd.
3711 (modify-phases %standard-phases
3714 (zero? (system* "ruby" "-Ilib" "-r" "rubytest")))))))
3716 `(("ruby-ansi" ,ruby-ansi)))
3717 (synopsis "Universal test harness for Ruby")
3719 "Rubytest is a testing meta-framework for Ruby. It can handle any
3720 compliant test framework and can run tests from multiple frameworks in a
3722 (home-page "http://rubyworks.github.io/rubytest")
3723 (license license:bsd-2)))
3725 (define-public ruby-brass
3732 (uri (rubygems-uri "brass" version))
3735 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
3736 (build-system ruby-build-system)
3738 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
3739 ;; Instead simply test that the library can be require'd.
3741 (modify-phases %standard-phases
3744 (zero? (system* "ruby" "-Ilib" "-r" "brass")))))))
3745 (synopsis "Basic foundational assertions framework")
3747 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
3748 foundational assertions framework for other assertion and test frameworks to
3750 (home-page "http://rubyworks.github.io/brass")
3751 (license license:bsd-2)))
3753 (define-public ruby-qed
3760 (uri (rubygems-uri "qed" version))
3763 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
3764 (build-system ruby-build-system)
3766 ;; Disable testing to break the cycle qed, ansi, qed, among others.
3767 ;; Instead simply test that the executable runs using --copyright.
3769 (modify-phases %standard-phases
3772 (zero? (system* "ruby" "-Ilib" "bin/qed" "--copyright")))))))
3774 `(("ruby-ansi" ,ruby-ansi)
3775 ("ruby-brass" ,ruby-brass)))
3776 (synopsis "Test framework utilizing literate programming techniques")
3778 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
3779 @dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
3780 Development} (BDD) utilizing Literate Programming techniques. QED sits
3781 somewhere between lower-level testing tools like @code{Test::Unit} and
3782 requirement specifications systems like Cucumber.")
3783 (home-page "http://rubyworks.github.io/qed")
3784 (license license:bsd-2)))
3786 (define-public ruby-ae
3793 ;; Fetch from github so tests are included.
3795 "https://github.com/rubyworks/ae/archive/"
3797 (file-name (string-append name "-" version ".tar.gz"))
3800 "147jmkx54x7asy2d8m4dyrhhf4hdx4galpnhwzai030y3cdsfrrl"))))
3801 (build-system ruby-build-system)
3804 (modify-phases %standard-phases
3806 (lambda _ (zero? (system* "qed"))))
3807 (add-before 'validate-runpath 'replace-broken-symlink
3808 (lambda* (#:key outputs #:allow-other-keys)
3809 (let* ((out (assoc-ref outputs "out"))
3810 (file (string-append out "/lib/ruby/gems/"
3811 ,(package-version ruby)
3812 "/gems/ae-" ,version
3814 ;; XXX: This symlink is broken since ruby 2.4.
3815 ;; https://lists.gnu.org/archive/html/guix-devel/2017-06/msg00034.html
3817 (symlink "../.index" file)
3820 `(("ruby-ansi" ,ruby-ansi)))
3822 `(("ruby-qed" ,ruby-qed)))
3823 (synopsis "Assertions library")
3825 "Assertive Expressive (AE) is an assertions library specifically designed
3826 for reuse by other test frameworks.")
3827 (home-page "http://rubyworks.github.io/ae")
3828 (license license:bsd-2)))
3830 (define-public ruby-lemon
3837 (uri (rubygems-uri "lemon" version))
3840 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
3841 (build-system ruby-build-system)
3844 (modify-phases %standard-phases
3845 (replace 'check (lambda _ (zero? (system* "qed")))))))
3847 `(("ruby-ae" ,ruby-ae)
3848 ("ruby-ansi" ,ruby-ansi)
3849 ("ruby-rubytest" ,ruby-rubytest)))
3851 `(("ruby-qed" ,ruby-qed)))
3852 (synopsis "Test framework correlating code structure and test unit")
3854 "Lemon is a unit testing framework that enforces highly formal
3855 case-to-class and unit-to-method test construction. This enforcement can help
3856 focus concern on individual units of behavior.")
3857 (home-page "http://rubyworks.github.io/lemon")
3858 (license license:bsd-2)))
3860 (define-public ruby-rubytest-cli
3862 (name "ruby-rubytest-cli")
3867 (uri (rubygems-uri "rubytest-cli" version))
3870 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
3871 (build-system ruby-build-system)
3873 `(#:tests? #f)) ; no tests
3875 `(("ruby-ansi" ,ruby-ansi)
3876 ("ruby-rubytest" ,ruby-rubytest)))
3877 (synopsis "Command-line interface for rubytest")
3879 "Rubytest CLI is a command-line interface for running tests for
3880 Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
3881 (home-page "http://rubyworks.github.io/rubytest-cli")
3882 (license license:bsd-2)))
3884 (define-public ruby-hashery
3886 (name "ruby-hashery")
3891 (uri (rubygems-uri "hashery" version))
3894 "0qj8815bf7q6q7llm5rzdz279gzmpqmqqicxnzv066a020iwqffj"))))
3895 (build-system ruby-build-system)
3898 (modify-phases %standard-phases
3901 (and (zero? (system* "qed"))
3902 (zero? (system* "rubytest" "-Ilib" "-Itest" "test/"))))))))
3904 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
3905 ("ruby-qed" ,ruby-qed)
3906 ("ruby-lemon" ,ruby-lemon)))
3907 (synopsis "Hash-like classes with extra features")
3909 "The Hashery is a tight collection of @code{Hash}-like classes.
3910 Included are the auto-sorting @code{Dictionary} class, the efficient
3911 @code{LRUHash}, the flexible @code{OpenHash} and the convenient
3912 @code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
3913 defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
3914 standard @code{Hash} making it possible to subclass and augment to fit any
3915 specific use case.")
3916 (home-page "http://rubyworks.github.io/hashery")
3917 (license license:bsd-2)))
3919 (define-public ruby-rc4
3926 (uri (rubygems-uri "ruby-rc4" version))
3929 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
3930 (build-system ruby-build-system)
3933 (modify-phases %standard-phases
3936 (zero? (system* "rspec" "spec/rc4_spec.rb")))))))
3938 `(("ruby-rspec" ,ruby-rspec-2)))
3939 (synopsis "Implementation of the RC4 algorithm")
3941 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
3942 (home-page "https://github.com/caiges/Ruby-RC4")
3943 (license license:expat)))
3945 (define-public ruby-afm
3952 (uri (rubygems-uri "afm" version))
3955 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
3956 (build-system ruby-build-system)
3958 `(("bundler" ,bundler)))
3959 (synopsis "Read Adobe Font Metrics (afm) files")
3961 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
3962 files and use the data therein.")
3963 (home-page "https://github.com/halfbyte/afm")
3964 (license license:expat)))
3966 (define-public ruby-ascii85
3968 (name "ruby-ascii85")
3973 (uri (rubygems-uri "Ascii85" version))
3976 "0j95sbxd18kc8rhcnvl1w37kflqpax1r12h1x47gh4xxn3mz4m7q"))))
3977 (build-system ruby-build-system)
3979 `(("bundler" ,bundler)))
3980 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
3982 "This library provides methods to encode and decode Ascii85
3983 binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
3984 @dfn{Portable Document Format} (PDF) file formats.")
3985 (home-page "https://github.com/datawraith/ascii85gem")
3986 (license license:expat)))
3988 (define-public ruby-ttfunk
3990 (name "ruby-ttfunk")
3995 ;; fetch from github as the gem does not contain testing code
3997 "https://github.com/prawnpdf/ttfunk/archive/"
3999 (file-name (string-append name "-" version ".tar.gz"))
4002 "1izq84pnm9niyvkzp8k0vl232q9zj41hwmp9na9fzycfh1pbnsl6"))))
4003 (build-system ruby-build-system)
4005 `(#:test-target "spec"
4007 (modify-phases %standard-phases
4008 (add-before 'check 'remove-rubocop
4010 ;; remove rubocop as a dependency as not needed for testing
4011 (substitute* "ttfunk.gemspec"
4012 (("spec.add_development_dependency\\('rubocop'.*") ""))
4013 (substitute* "Rakefile"
4014 (("require 'rubocop/rake_task'") "")
4015 (("Rubocop::RakeTask.new") ""))
4018 `(("ruby-rspec" ,ruby-rspec)
4019 ("bundler" ,bundler)))
4020 (synopsis "Font metrics parser for the Prawn PDF generator")
4022 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
4023 part of the Prawn PDF generator.")
4024 (home-page "https://github.com/prawnpdf/ttfunk")
4025 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
4027 (license (list license:gpl2 license:gpl3 license:ruby))))
4029 (define-public ruby-puma
4036 ;; Fetch from GitHub because distributed gem does not contain tests.
4037 (uri (string-append "https://github.com/puma/puma/archive/v"
4039 (file-name (string-append name "-" version ".tar.gz"))
4042 "03pifga841h17brh4vgia8i2ybh3cmsyg0dbybzdf6dq51wzcxdx"))))
4043 (build-system ruby-build-system)
4045 `(#:tests? #f ; Tests require an out-dated version of minitest.
4047 (modify-phases %standard-phases
4048 (add-before 'build 'fix-gemspec
4050 (substitute* "puma.gemspec"
4051 (("git ls-files") "find * |sort"))
4053 (synopsis "Simple, concurrent HTTP server for Ruby/Rack")
4055 "Puma is a simple, fast, threaded, and highly concurrent HTTP 1.1 server
4056 for Ruby/Rack applications. Puma is intended for use in both development and
4057 production environments. In order to get the best throughput, it is highly
4058 recommended that you use a Ruby implementation with real threads like Rubinius
4060 (home-page "http://puma.io")
4061 (license license:expat)))
4063 (define-public ruby-hoe-git
4065 (name "ruby-hoe-git")
4070 (uri (rubygems-uri "hoe-git" version))
4073 "10jmmbjm0lkglwxbn4rpqghgg1ipjxrswm117n50adhmy8yij650"))))
4074 (build-system ruby-build-system)
4076 `(("ruby-hoe" ,ruby-hoe)
4078 (synopsis "Hoe plugins for tighter Git integration")
4080 "This package provides a set of Hoe plugins for tighter Git integration.
4081 It provides tasks to automate release tagging and pushing and changelog
4083 (home-page "https://github.com/jbarnette/hoe-git")
4084 (license license:expat)))
4086 (define-public ruby-sequel
4088 (name "ruby-sequel")
4093 (uri (rubygems-uri "sequel" version))
4096 "010p4a60npppvgbyw7pq5xia8aydpgxdlhh3qjm2615kwjsw3fl8"))))
4097 (build-system ruby-build-system)
4099 '(#:tests? #f)) ; Avoid dependency loop with ruby-minitest-hooks.
4100 (synopsis "Database toolkit for Ruby")
4101 (description "Sequel provides thread safety, connection pooling and a
4102 concise DSL for constructing SQL queries and table schemas. It includes a
4103 comprehensive ORM layer for mapping records to Ruby objects and handling
4104 associated records.")
4105 (home-page "http://sequel.jeremyevans.net")
4106 (license license:expat)))
4108 (define-public ruby-timecop
4110 (name "ruby-timecop")
4115 (uri (rubygems-uri "timecop" version))
4118 "0d7mm786180v4kzvn1f77rhfppsg5n0sq2bdx63x9nv114zm8jrp"))))
4119 (build-system ruby-build-system)
4122 (modify-phases %standard-phases
4123 (add-before 'check 'set-check-rubylib
4125 ;; Set RUBYLIB so timecop tests finds its own lib.
4126 (setenv "RUBYLIB" "lib")
4129 `(("bundler" ,bundler)
4130 ("ruby-minitest-rg" ,ruby-minitest-rg)
4131 ("ruby-mocha" ,ruby-mocha)
4132 ("ruby-activesupport" ,ruby-activesupport)))
4133 (synopsis "Test mocks for time-dependent functions")
4135 "Timecop provides \"time travel\" and \"time freezing\" capabilities,
4136 making it easier to test time-dependent code. It provides a unified method to
4137 mock @code{Time.now}, @code{Date.today}, and @code{DateTime.now} in a single
4139 (home-page "https://github.com/travisjeffery/timecop")
4140 (license license:expat)))
4142 (define-public ruby-concurrent
4144 (name "ruby-concurrent")
4149 ;; Download from GitHub because the rubygems version does not contain
4152 "https://github.com/ruby-concurrency/concurrent-ruby/archive/v"
4155 (file-name (string-append name "-" version ".tar.gz"))
4158 "0qhv0qzsby4iijgwa4s9r88zj8123pmyz1dwaqzdk57xgqll9pny"))
4159 ;; Exclude failing test reported at
4160 ;; https://github.com/ruby-concurrency/concurrent-ruby/issues/534
4161 (patches (search-patches "ruby-concurrent-ignore-broken-test.patch"
4162 "ruby-concurrent-test-arm.patch"))))
4163 (build-system ruby-build-system)
4165 `(#:test-target "spec"
4167 (modify-phases %standard-phases
4168 (add-before 'replace-git-ls-files 'remove-extra-gemspecs
4170 ;; Delete extra gemspec files so 'first-gemspec' chooses the
4172 (delete-file "concurrent-ruby-edge.gemspec")
4173 (delete-file "concurrent-ruby-ext.gemspec")
4175 (add-before 'build 'replace-git-ls-files2
4177 (substitute* "support/file_map.rb"
4178 (("git ls-files") "find * |sort"))
4180 (add-before 'check 'rake-compile
4181 ;; Fix the test error described at
4182 ;; https://github.com/ruby-concurrency/concurrent-ruby/pull/408
4183 (lambda _ (zero? (system* "rake" "compile"))))
4184 (add-before 'check 'remove-timecop-dependency
4185 ;; Remove timecop-dependent tests as having timecop as a depedency
4186 ;; causes circular depedencies.
4188 (delete-file "spec/concurrent/executor/timer_set_spec.rb")
4189 (delete-file "spec/concurrent/scheduled_task_spec.rb")
4192 `(("ruby-rake-compiler" ,ruby-rake-compiler)
4193 ("ruby-rspec" ,ruby-rspec)))
4194 (synopsis "Concurrency tools for Ruby")
4196 "This library provides modern concurrency tools including agents,
4197 futures, promises, thread pools, actors, supervisors, and more. It is
4198 inspired by Erlang, Clojure, Go, JavaScript, actors and classic concurrency
4200 (home-page "http://www.concurrent-ruby.com")
4201 (license license:expat)))
4203 (define-public ruby-pkg-config
4205 (name "ruby-pkg-config")
4210 (uri (rubygems-uri "pkg-config" version))
4213 "0lljiqnm0b4z6iy87lzapwrdfa6ps63x2z5zbs038iig8dqx2g0z"))))
4214 (build-system ruby-build-system)
4216 ;; Tests require extra files not included in the gem.
4218 (synopsis "Detect libraries for compiling Ruby native extensions")
4220 "@code{pkg-config} can be used in your extconf.rb to properly detect need
4221 libraries for compiling Ruby native extensions.")
4222 (home-page "https://github.com/ruby-gnome2/pkg-config")
4223 (license license:lgpl2.0+)))
4225 (define-public ruby-net-http-digest-auth
4227 (name "ruby-net-http-digest-auth")
4232 (uri (rubygems-uri "net-http-digest_auth" version))
4235 "14801gr34g0rmqz9pv4rkfa3crfdbyfk6r48vpg5a5407v0sixqi"))))
4236 (build-system ruby-build-system)
4238 `(("ruby-hoe" ,ruby-hoe)))
4239 (synopsis "RFC 2617 HTTP digest authentication library")
4241 "This library implements HTTP's digest authentication scheme based on
4242 RFC 2617. This enables the use of the digest authentication scheme instead
4243 of the more insecure basic authentication scheme.")
4244 (home-page "https://github.com/drbrain/net-http-digest_auth")
4245 (license license:expat)))
4247 (define-public ruby-mail
4254 (uri (rubygems-uri "mail" version))
4257 "0c9vqfy0na9b5096i5i4qvrvhwamjnmajhgqi3kdsdfl8l6agmkp"))))
4258 (build-system ruby-build-system)
4260 `(("ruby-mime-types" ,ruby-mime-types)))
4262 ;; Tests require extra gems not included in the Gemfile.
4263 ;; XXX: Try enabling this for the next version with mini_mime.
4265 (synopsis "Mail library for Ruby")
4267 "Mail is an internet library for Ruby that is designed to handle email
4268 generation, parsing and sending. The purpose of this library is to provide
4269 a single point of access to handle all email functions, including sending
4270 and receiving emails. All network type actions are done through proxy
4271 methods to @code{Net::SMTP}, @code{Net::POP3} etc.
4273 Mail has been designed with a very simple object oriented system that
4274 really opens up the email messages you are parsing, if you know what you
4275 are doing, you can fiddle with every last bit of your email directly.")
4276 (home-page "https://github.com/mikel/mail")
4277 (license license:expat)))