gnu: Add emacs-slime.
[jackhill/guix/guix.git] / gnu / packages / ruby.scm
CommitLineData
6ef8c59a 1;;; GNU Guix --- Functional package management for GNU
37ab3aba 2;;; Copyright © 2014, 2015 Pjotr Prins <pjotr.guix@thebird.nl>
b416aadf 3;;; Copyright © 2014, 2015 Ludovic Courtès <ludo@gnu.org>
f586c877 4;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
37ab3aba 5;;; Copyright © 2014, 2015 David Thompson <davet@gnu.org>
cf36174f 6;;; Copyright © 2015 Ricardo Wurmus <rekado@elephly.net>
3918146b 7;;; Copyright © 2015, 2016 Ben Woodcroft <donttrustben@gmail.com>
6ef8c59a
PP
8;;;
9;;; This file is part of GNU Guix.
10;;;
11;;; GNU Guix is free software; you can redistribute it and/or modify it
12;;; under the terms of the GNU General Public License as published by
13;;; the Free Software Foundation; either version 3 of the License, or (at
14;;; your option) any later version.
15;;;
16;;; GNU Guix is distributed in the hope that it will be useful, but
17;;; WITHOUT ANY WARRANTY; without even the implied warranty of
18;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19;;; GNU General Public License for more details.
20;;;
21;;; You should have received a copy of the GNU General Public License
22;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
23
24(define-module (gnu packages ruby)
25 #:use-module ((guix licenses) #:prefix license:)
26 #:use-module (gnu packages)
27 #:use-module (gnu packages compression)
4a9e0585 28 #:use-module (gnu packages databases)
6ef8c59a 29 #:use-module (gnu packages readline)
6ef8c59a 30 #:use-module (gnu packages autotools)
ad79eb55 31 #:use-module (gnu packages java)
6ef8c59a 32 #:use-module (gnu packages libffi)
ac09beba 33 #:use-module (gnu packages python)
763624f5 34 #:use-module (gnu packages ragel)
cc2b77df 35 #:use-module (gnu packages tls)
66e20863 36 #:use-module (gnu packages version-control)
6ef8c59a
PP
37 #:use-module (guix packages)
38 #:use-module (guix download)
bda0c139 39 #:use-module (guix git-download)
6ef8c59a 40 #:use-module (guix utils)
acf735f2 41 #:use-module (guix build-system gnu)
e920bfca 42 #:use-module (gnu packages xml)
c2c4e5b2 43 #:use-module (gnu packages web)
acf735f2 44 #:use-module (guix build-system ruby))
6ef8c59a
PP
45
46(define-public ruby
47 (package
48 (name "ruby")
65e84e31 49 (version "2.3.0")
6ef8c59a
PP
50 (source
51 (origin
52 (method url-fetch)
6becfdff
MW
53 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
54 (version-major+minor version)
12d39eb5 55 "/ruby-" version ".tar.xz"))
6ef8c59a
PP
56 (sha256
57 (base32
65e84e31
BW
58 "15s0dsb5ynf3d2w5gzawnszq5594fqvapv2y7a0qw16przq5l4kh"))
59 (modules '((guix build utils)))
60 (snippet `(begin
61 ;; Remove bundled libffi
62 (delete-file-recursively
63 (string-append "ext/fiddle/libffi-3.2.1"))
64 #t))))
6ef8c59a
PP
65 (build-system gnu-build-system)
66 (arguments
67 `(#:test-target "test"
6ef8c59a 68 #:phases
9656b8be 69 (modify-phases %standard-phases
65e84e31 70 (add-before 'configure 'replace-bin-sh-and-remove-libffi
9656b8be
BW
71 (lambda _
72 (substitute* '("Makefile.in"
73 "ext/pty/pty.c"
74 "io.c"
75 "lib/mkmf.rb"
76 "process.c"
77 "test/rubygems/test_gem_ext_configure_builder.rb"
78 "test/rdoc/test_rdoc_parser.rb"
79 "test/ruby/test_rubyoptions.rb"
80 "test/ruby/test_process.rb"
81 "test/ruby/test_system.rb"
82 "tool/rbinstall.rb")
83 (("/bin/sh") (which "sh")))
84 #t)))))
6ef8c59a
PP
85 (inputs
86 `(("readline" ,readline)
6ef8c59a
PP
87 ("openssl" ,openssl)
88 ("libffi" ,libffi)
89 ("gdbm" ,gdbm)
90 ("zlib" ,zlib)))
91 (native-search-paths
92 (list (search-path-specification
93 (variable "GEM_PATH")
af070955
LC
94 (files (list (string-append "lib/ruby/gems/"
95 (version-major+minor version)
96 ".0"))))))
6becfdff 97 (synopsis "Programming language interpreter")
6ef8c59a
PP
98 (description "Ruby is a dynamic object-oriented programming language with
99a focus on simplicity and productivity.")
100 (home-page "https://ruby-lang.org")
101 (license license:ruby)))
102
65e84e31
BW
103(define-public ruby-2.2
104 (package (inherit ruby)
105 (version "2.2.4")
106 (source
107 (origin
108 (method url-fetch)
109 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
110 (version-major+minor version)
111 "/ruby-" version ".tar.xz"))
112 (sha256
113 (base32
114 "0g3ps4q3iz7wj9m45n8xyxzw8nh29ljdqb87b0f6i0p3853gz2yj"))
115 (modules '((guix build utils)))
116 (snippet `(begin
117 ;; Remove bundled libffi
118 (delete-file-recursively
119 (string-append "ext/fiddle/libffi-3.2.1"))
120 #t))))))
121
9942e803
PP
122(define-public ruby-2.1
123 (package (inherit ruby)
4c40fa02 124 (version "2.1.8")
9942e803
PP
125 (source
126 (origin
127 (method url-fetch)
128 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
129 (version-major+minor version)
130 "/ruby-" version ".tar.bz2"))
131 (sha256
132 (base32
4c40fa02 133 "11rkbfc90cg9p9mzg32475alf3ddcn9q8a3ar3fwm5xskic0n395"))))
9942e803
PP
134 (arguments
135 `(#:test-target "test"
136 #:parallel-tests? #f
137 #:phases
138 (alist-cons-before
139 'configure 'replace-bin-sh
140 (lambda _
141 (substitute* '("Makefile.in"
142 "ext/pty/pty.c"
143 "io.c"
144 "lib/mkmf.rb"
145 "process.c")
146 (("/bin/sh") (which "sh"))))
147 %standard-phases)))
148 (native-search-paths
149 (list (search-path-specification
150 (variable "GEM_PATH")
151 (files (list (string-append "lib/ruby/gems/"
152 (version-major+minor version)
153 ".0"))))))))
154
218ee89b
PP
155(define-public ruby-1.8
156 (package (inherit ruby)
218ee89b
PP
157 (version "1.8.7-p374")
158 (source
159 (origin
160 (method url-fetch)
6becfdff
MW
161 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
162 (version-major+minor version)
163 "/ruby-" version ".tar.bz2"))
218ee89b
PP
164 (sha256
165 (base32
166 "1qq7khilwkayrhwmzlxk83scrmiqfi7lgsn4c63znyvz2c1lgqxl"))))
167 (native-search-paths '())
168 (arguments
169 `(#:test-target "test"
170 #:parallel-tests? #f
171 #:phases
172 (alist-cons-before
173 'configure 'replace-bin-sh
174 (lambda _
175 (substitute* '("Makefile.in"
176 "ext/pty/pty.c"
177 "io.c"
178 "lib/mkmf.rb"
179 "process.c")
180 (("/bin/sh") (which "sh"))))
181 %standard-phases)))))
182
bda0c139
DT
183(define-public ruby-hoe
184 (package
185 (name "ruby-hoe")
186 (version "3.13.1")
187 (source (origin
e83c6d00
DT
188 (method url-fetch)
189 (uri (rubygems-uri "hoe" version))
bda0c139
DT
190 (sha256
191 (base32
e83c6d00 192 "1mac13krdrasn9819dd65xj27kklfy0xdbj3p6s2ij4vlcb46h8q"))) )
bda0c139 193 (build-system ruby-build-system)
bda0c139
DT
194 (synopsis "Ruby project management helper")
195 (description
196 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
197maintain, and release projects and includes a dynamic plug-in system allowing
198for easy extensibility. Hoe ships with plug-ins for all the usual project
199tasks including rdoc generation, testing, packaging, deployment, and
200announcement.")
201 (home-page "http://www.zenspider.com/projects/hoe.html")
202 (license license:expat)))
203
022170dc
PP
204(define-public ruby-rake-compiler
205 (package
206 (name "ruby-rake-compiler")
207 (version "0.9.5")
208 (source (origin
209 (method url-fetch)
e83c6d00 210 (uri (rubygems-uri "rake-compiler" version))
022170dc
PP
211 (sha256
212 (base32
e83c6d00 213 "1k8im2vzj849xdgjk6wafspkiwwapqwm738majchb4dnhnsk64cx"))))
022170dc
PP
214 (build-system ruby-build-system)
215 (arguments
e83c6d00 216 '(#:tests? #f)) ; needs cucumber
022170dc 217 (synopsis "Building and packaging helper for Ruby native extensions")
e881752c 218 (description "Rake-compiler provides a framework for building and
022170dc
PP
219packaging native C and Java extensions in Ruby.")
220 (home-page "https://github.com/rake-compiler/rake-compiler")
221 (license license:expat)))
222
acf735f2
DT
223(define-public ruby-i18n
224 (package
225 (name "ruby-i18n")
0bfdfd37 226 (version "0.7.0")
acf735f2
DT
227 (source (origin
228 (method url-fetch)
e83c6d00 229 (uri (rubygems-uri "i18n" version))
acf735f2
DT
230 (sha256
231 (base32
0bfdfd37 232 "1i5z1ykl8zhszsxcs8mzl8d0dxgs3ylz8qlzrw74jb0gplkx6758"))))
acf735f2
DT
233 (build-system ruby-build-system)
234 (arguments
0bfdfd37 235 '(#:tests? #f)) ; no tests
acf735f2
DT
236 (synopsis "Internationalization library for Ruby")
237 (description "Ruby i18n is an internationalization and localization
238solution for Ruby programs. It features translation and localization,
239interpolation of values to translations, pluralization, customizable
240transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
241translation data, custom key/scope separator, custom exception handlers, and
242an extensible architecture with a swappable backend.")
243 (home-page "http://github.com/svenfuchs/i18n")
244 (license license:expat)))
eb0c2dd6
DT
245
246;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
247;; dependencies use RSpec for their test suites! To avoid these circular
248;; dependencies, we disable tests for all of the RSpec-related packages.
249(define ruby-rspec-support
250 (package
251 (name "ruby-rspec-support")
252 (version "3.2.2")
253 (source (origin
254 (method url-fetch)
e83c6d00 255 (uri (rubygems-uri "rspec-support" version))
eb0c2dd6
DT
256 (sha256
257 (base32
e83c6d00 258 "194zry5195ls2hni7r9824vqb5d3qfg4jb15fgj8glfy0rvw3zxl"))))
eb0c2dd6
DT
259 (build-system ruby-build-system)
260 (arguments
261 '(#:tests? #f)) ; avoid dependency cycles
262 (synopsis "RSpec support library")
263 (description "Support utilities for RSpec gems.")
264 (home-page "https://github.com/rspec/rspec-support")
265 (license license:expat)))
266
267(define-public ruby-rspec-core
268 (package
269 (name "ruby-rspec-core")
270 (version "3.2.3")
271 (source (origin
272 (method url-fetch)
e83c6d00 273 (uri (rubygems-uri "rspec-core" version))
eb0c2dd6
DT
274 (sha256
275 (base32
e83c6d00 276 "0k2471iw30gc2cvv67damrx666pmsvx8l0ahk3hm20dhfnmcmpvv"))))
eb0c2dd6
DT
277 (build-system ruby-build-system)
278 (arguments
279 '(#:tests? #f)) ; avoid dependency cycles
280 (propagated-inputs
281 `(("ruby-rspec-support" ,ruby-rspec-support)))
282 (synopsis "RSpec core library")
283 (description "Rspec-core provides the RSpec test runner and example
284groups.")
285 (home-page "https://github.com/rspec/rspec-core")
286 (license license:expat)))
e6962009 287
64c318f2
BW
288(define-public ruby-rspec-core-2
289 (package (inherit ruby-rspec-core)
290 (version "2.14.8")
291 (source (origin
292 (method url-fetch)
293 (uri (rubygems-uri "rspec-core" version))
294 (sha256
295 (base32
296 "0psjy5kdlz3ph39br0m01w65i1ikagnqlg39f8p65jh5q7dz8hwc"))))
297 (propagated-inputs `())))
298
20c05ea9 299(define-public ruby-diff-lcs
e6962009
DT
300 (package
301 (name "ruby-diff-lcs")
302 (version "1.2.5")
303 (source (origin
304 (method url-fetch)
e83c6d00 305 (uri (rubygems-uri "diff-lcs" version))
e6962009
DT
306 (sha256
307 (base32
e83c6d00 308 "1vf9civd41bnqi6brr5d9jifdw73j9khc6fkhfl1f8r9cpkdvlx1"))))
e6962009
DT
309 (build-system ruby-build-system)
310 (arguments
311 '(#:tests? #f)) ; avoid dependency cycles
312 (synopsis "Compute the difference between two Enumerable sequences")
313 (description "Diff::LCS computes the difference between two Enumerable
314sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
315It includes utilities to create a simple HTML diff output format and a
316standard diff-like tool.")
317 (home-page "https://github.com/halostatue/diff-lcs")
318 (license license:expat)))
319
320(define-public ruby-rspec-expectations
321 (package
322 (name "ruby-rspec-expectations")
323 (version "3.2.1")
324 (source (origin
325 (method url-fetch)
e83c6d00 326 (uri (rubygems-uri "rspec-expectations" version))
e6962009
DT
327 (sha256
328 (base32
e83c6d00 329 "01kmchabgpdcaqdsqg8r0g5gy385xhp1k1jsds3w264ypin17n14"))))
e6962009
DT
330 (build-system ruby-build-system)
331 (arguments
332 '(#:tests? #f)) ; avoid dependency cycles
333 (propagated-inputs
334 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 335 ("ruby-diff-lcs" ,ruby-diff-lcs)))
e881752c 336 (synopsis "RSpec expectations library")
e6962009
DT
337 (description "Rspec-expectations provides a simple API to express expected
338outcomes of a code example.")
339 (home-page "https://github.com/rspec/rspec-expectations")
340 (license license:expat)))
4f2a0cac 341
fb157f25
BW
342(define-public ruby-rspec-expectations-2
343 (package (inherit ruby-rspec-expectations)
344 (version "2.14.5")
345 (source (origin
346 (method url-fetch)
347 (uri (rubygems-uri "rspec-expectations" version))
348 (sha256
349 (base32
350 "1ni8kw8kjv76jvwjzi4jba00k3qzj9f8wd94vm6inz0jz3gwjqf9"))))
351 (propagated-inputs
352 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
353
4f2a0cac
DT
354(define-public ruby-rspec-mocks
355 (package
356 (name "ruby-rspec-mocks")
357 (version "3.2.1")
358 (source (origin
359 (method url-fetch)
e83c6d00 360 (uri (rubygems-uri "rspec-mocks" version))
4f2a0cac
DT
361 (sha256
362 (base32
e83c6d00 363 "09yig1lwgxl8fsns71z3xhv7wkg7zvagydh37pvaqpw92dz55jv2"))))
4f2a0cac
DT
364 (build-system ruby-build-system)
365 (arguments
366 '(#:tests? #f)) ; avoid dependency cycles
367 (propagated-inputs
368 `(("ruby-rspec-support" ,ruby-rspec-support)
20c05ea9 369 ("ruby-diff-lcs" ,ruby-diff-lcs)))
4f2a0cac
DT
370 (synopsis "RSpec stubbing and mocking library")
371 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
372support for stubbing and mocking.")
373 (home-page "https://github.com/rspec/rspec-mocks")
374 (license license:expat)))
d4fde1f2 375
6da9adeb
BW
376(define-public ruby-rspec-mocks-2
377 (package (inherit ruby-rspec-mocks)
378 (version "2.14.6")
379 (source (origin
380 (method url-fetch)
381 (uri (rubygems-uri "rspec-mocks" version))
382 (sha256
383 (base32
384 "1fwsmijd6w6cmqyh4ky2nq89jrpzh56hzmndx9wgkmdgfhfakv30"))))
385 (propagated-inputs
386 `(("ruby-diff-lcs" ,ruby-diff-lcs)))))
387
d4fde1f2
DT
388(define-public ruby-rspec
389 (package
390 (name "ruby-rspec")
391 (version "3.2.0")
392 (source (origin
393 (method url-fetch)
e83c6d00 394 (uri (rubygems-uri "rspec" version))
d4fde1f2
DT
395 (sha256
396 (base32
e83c6d00 397 "0lkz01j4yxcwb3g5w6r1l9khnyw3sxib4rrh4npd2pxh390fcc4f"))))
d4fde1f2
DT
398 (build-system ruby-build-system)
399 (arguments
400 '(#:tests? #f)) ; avoid dependency cycles
401 (propagated-inputs
402 `(("ruby-rspec-core" ,ruby-rspec-core)
403 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
404 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
405 (synopsis "Behavior-driven development framework for Ruby")
406 (description "RSpec is a behavior-driven development (BDD) framework for
407Ruby. This meta-package includes the RSpec test runner, along with the
408expectations and mocks frameworks.")
409 (home-page "http://rspec.info/")
410 (license license:expat)))
2cbc105b 411
5ac984b3
BW
412(define-public ruby-rspec-2
413 (package (inherit ruby-rspec)
414 (version "2.14.1")
415 (source (origin
416 (method url-fetch)
417 (uri (rubygems-uri "rspec" version))
418 (sha256
419 (base32
420 "134y4wzk1prninb5a0bhxgm30kqfzl8dg06af4js5ylnhv2wd7sg"))))
421 (propagated-inputs
422 `(("ruby-rspec-core" ,ruby-rspec-core-2)
423 ("ruby-rspec-mocks" ,ruby-rspec-mocks-2)
424 ("ruby-rspec-expectations" ,ruby-rspec-expectations-2)))))
425
2cbc105b
DT
426;; Bundler is yet another source of circular dependencies, so we must disable
427;; its test suite as well.
428(define-public bundler
429 (package
430 (name "bundler")
38b327a9 431 (version "1.10.6")
2cbc105b
DT
432 (source (origin
433 (method url-fetch)
e83c6d00 434 (uri (rubygems-uri "bundler" version))
2cbc105b
DT
435 (sha256
436 (base32
38b327a9 437 "1vlzfq0bkkj4jyq6av0y55mh5nj5n0f3mfbmmifwgkh44g8k6agv"))))
2cbc105b
DT
438 (build-system ruby-build-system)
439 (arguments
440 '(#:tests? #f)) ; avoid dependency cycles
441 (synopsis "Ruby gem bundler")
442 (description "Bundler automatically downloads and installs a list of gems
443specified in a \"Gemfile\", as well as their dependencies.")
444 (home-page "http://bundler.io/")
445 (license license:expat)))
98b87b82 446
cf36174f
RW
447(define-public ruby-builder
448 (package
449 (name "ruby-builder")
450 (version "3.2.2")
451 (source (origin
452 (method url-fetch)
453 (uri (rubygems-uri "builder" version))
454 (sha256
455 (base32
456 "14fii7ab8qszrvsvhz6z2z3i4dw0h41a62fjr2h1j8m41vbrmyv2"))))
457 (build-system ruby-build-system)
458 (arguments
459 `(#:phases
460 (modify-phases %standard-phases
461 (add-after 'unpack 'do-not-use-rvm
462 (lambda _
463 (substitute* "rakelib/tags.rake"
464 (("RVM_GEMDIR = .*") "RVM_GEMDIR = 'no-rvm-please'\n"))
465 #t)))))
466 (synopsis "Ruby library to create structured data")
467 (description "Builder provides a number of builder objects that make it
468easy to create structured data. Currently the following builder objects are
469supported: XML Markup and XML Events.")
470 (home-page "https://github.com/jimweirich/builder")
471 (license license:expat)))
472
ad79eb55
RW
473(define-public ruby-rjb
474 (package
475 (name "ruby-rjb")
476 (version "1.5.3")
477 (source (origin
478 (method url-fetch)
479 (uri (rubygems-uri "rjb" version))
480 (sha256
481 (base32
482 "0gzs92dagk981s4vrymnqg0vll783b9k564j0cdgp167nc5a2zg4"))))
483 (build-system ruby-build-system)
484 (arguments
485 `(#:tests? #f ; no rakefile
486 #:phases
487 (modify-phases %standard-phases
488 (add-before 'build 'set-java-home
489 (lambda* (#:key inputs #:allow-other-keys)
490 (setenv "JAVA_HOME" (assoc-ref inputs "jdk"))
491 #t)))))
492 (native-inputs
d2540f80 493 `(("jdk" ,icedtea "jdk")))
ad79eb55
RW
494 (synopsis "Ruby-to-Java bridge using the Java Native Interface")
495 (description "RJB is a bridge program that connects Ruby and Java via the
496Java Native Interface.")
497 (home-page "http://www.artonx.org/collabo/backyard/?RubyJavaBridge")
498 (license license:lgpl2.1+)))
499
f9ae2c06
PP
500(define-public ruby-log4r
501 (package
502 (name "ruby-log4r")
503 (version "1.1.10")
504 (source
505 (origin
506 (method url-fetch)
507 (uri (rubygems-uri "log4r" version))
508 (sha256
509 (base32
510 "0ri90q0frfmigkirqv5ihyrj59xm8pq5zcmf156cbdv4r4l2jicv"))))
511 (build-system ruby-build-system)
512 (arguments
513 '(#:tests? #f)) ; no Rakefile in gem
514 (synopsis "Flexible logging library for Ruby")
515 (description "Comprehensive and flexible logging library written
516in Ruby for use in Ruby programs. It features a hierarchical logging
517system of any number of levels, custom level names, logger
518inheritance, multiple output destinations per log event, execution
519tracing, custom formatting, thread safteyness, XML and YAML
520configuration, and more.")
521 (home-page "http://log4r.rubyforge.org/")
522 (license license:bsd-3)))
523
71a03c29
RW
524(define-public ruby-atoulme-antwrap
525 (package
526 (name "ruby-atoulme-antwrap")
527 (version "0.7.5")
528 (source (origin
529 (method url-fetch)
530 (uri (rubygems-uri "atoulme-Antwrap" version))
531 (sha256
532 (base32
533 "05s3iw44lqa81f8nfy5f0xjj808600h82zb9bsh46b9kcq2w2kmz"))))
534 (build-system ruby-build-system)
535 ;; Test data required for most of the tests are not included.
536 (arguments `(#:tests? #f))
537 (native-inputs
538 `(("ruby-hoe" ,ruby-hoe)))
539 (inputs
540 `(("ruby-rjb" ,ruby-rjb)))
541 (synopsis "Ruby wrapper for the Ant build tool")
542 (description "Antwrap is a Ruby module that wraps the Apache Ant build
543tool. Antwrap can be used to invoke Ant tasks from a Ruby or a JRuby
544script.")
545 (home-page "http://rubyforge.org/projects/antwrap/")
546 (license license:expat)))
547
fe1ddad5
RW
548(define-public ruby-atoulme-saikuro
549 (package
550 (name "ruby-atoulme-saikuro")
551 (version "1.2.1")
552 (source (origin
553 (method url-fetch)
554 (uri (rubygems-uri "atoulme-Saikuro" version))
555 (sha256
556 (base32
557 "0kvd2nsxffbza61d3q4j94wrbnbv50r1zy3a7q26f6k706fw1f19"))))
558 (build-system ruby-build-system)
559 ;; FIXME: There are no unit tests. The tests are demonstrations of the
560 ;; "saikuro" tool.
561 (arguments `(#:tests? #f))
562 (synopsis "Cyclomatic complexity analyzer")
563 (description "Saikuro is a Ruby cyclomatic complexity analyzer. When
564given Ruby source code Saikuro will generate a report listing the cyclomatic
565complexity of each method found. In addition, Saikuro counts the number of
566lines per method and can generate a listing of the number of tokens on each
567line of code.")
568 (home-page "http://www.github.com/atoulme/Saikuro")
569 ;; File headers contain the BSD-3 license and the README.rdoc says that
570 ;; "Saikuro uses the BSD license", but the LICENSE file contains the text
571 ;; of the Expat license.
572 (license license:bsd-3)))
573
2f9e0b68
RW
574(define-public ruby-ci-reporter
575 (package
576 (name "ruby-ci-reporter")
577 (version "2.0.0")
578 (source (origin
579 (method url-fetch)
580 (uri (rubygems-uri "ci_reporter" version))
581 (sha256
582 (base32
583 "17fm20jmw3ajdryhkkxpjahcfx7bgswqzxrskivlkns2718ayyyg"))))
584 (build-system ruby-build-system)
585 (arguments
586 `(#:test-target "rspec"))
587 (propagated-inputs
588 `(("ruby-builder" ,ruby-builder)))
589 (native-inputs
590 `(("bundler" ,bundler)
591 ("ruby-rspec" ,ruby-rspec)))
592 (synopsis "Generate XML reports of runs test")
593 (description
594 "@code{CI::Reporter} is an add-on to Ruby testing frameworks that allows
595you to generate XML reports of your test runs. The resulting files can be
596read by a continuous integration system that understands Ant's JUnit report
597format.")
598 (home-page "https://github.com/nicksieger/ci_reporter")
599 (license license:expat)))
600
b004fb6a
RW
601(define-public ruby-saikuro-treemap
602 (package
603 (name "ruby-saikuro-treemap")
604 (version "0.2.0")
605 (source (origin
606 (method url-fetch)
607 (uri (rubygems-uri "saikuro_treemap" version))
608 (sha256
609 (base32
610 "0w70nmh43mwfbpq20iindl61siqqr8acmf7p3m7n5ipd61c24950"))))
611 (build-system ruby-build-system)
612 ;; Some of the tests fail because the generated JSON has keys in a
613 ;; different order. This is a problem with the test suite rather than any
614 ;; of the involved libraries.
615 (arguments `(#:tests? #f))
616 (propagated-inputs
617 `(("ruby-json-pure" ,ruby-json-pure)
618 ("ruby-atoulme-saikuro" ,ruby-atoulme-saikuro)))
619 (synopsis "Generate complexity treemap based on saikuro analysis")
620 (description
621 "This gem generates a treemap showing the complexity of Ruby code on
622which it is run. It uses Saikuro under the covers to analyze Ruby code
623complexity.")
624 (home-page "http://github.com/ThoughtWorksStudios/saikuro_treemap")
625 (license license:expat)))
626
cc53e630
RW
627(define-public ruby-orderedhash
628 (package
629 (name "ruby-orderedhash")
630 (version "0.0.6")
631 (source (origin
632 (method url-fetch)
633 (uri (rubygems-uri "orderedhash" version))
634 (sha256
635 (base32
636 "0fryy7f9jbpx33jq5m402yqj01zcg563k9fsxlqbhmq638p4bzd7"))))
637 (build-system ruby-build-system)
638 (arguments
639 '(#:tests? #f)) ; no test suite
640 (synopsis "Ruby library providing an order-preserving hash")
641 (description "Orderedhash is a Ruby library providing a hash
642implementation that preserves the order of items and features some array-like
643extensions.")
644 (home-page "http://codeforpeople.com/lib/ruby/orderedhash/")
645 (license license:public-domain)))
646
28c5d42d
PP
647(define-public ruby-libxml
648 (package
649 (name "ruby-libxml")
650 (version "2.8.0")
651 (source
652 (origin
653 (method url-fetch)
654 (uri (rubygems-uri "libxml-ruby" version))
655 (sha256
656 (base32
657 "1dhjqp4r9vkdp00l6h1cj8qfndzxlhlxk6b9g0w4v55gz857ilhb"))))
658 (build-system ruby-build-system)
659 (inputs
660 `(("zlib" ,zlib)
661 ("libxml2" ,libxml2)))
662 (arguments
663 '(#:tests? #f ; test suite hangs for unknown reason
664 #:gem-flags
665 (list "--"
666 (string-append "--with-xml2-include="
667 (assoc-ref %build-inputs "libxml2")
668 "/include/libxml2" ))))
669 (synopsis "Ruby bindings for GNOME Libxml2")
670 (description "The Libxml-Ruby project provides Ruby language bindings for
671the GNOME Libxml2 XML toolkit.")
672 (home-page "http://xml4r.github.com/libxml-ruby")
673 (license license:expat)))
674
8b9bde07
RW
675(define-public ruby-xml-simple
676 (package
677 (name "ruby-xml-simple")
678 (version "1.1.5")
679 (source (origin
680 (method url-fetch)
681 (uri (rubygems-uri "xml-simple" version))
682 (sha256
683 (base32
684 "0xlqplda3fix5pcykzsyzwgnbamb3qrqkgbrhhfz2a2fxhrkvhw8"))))
685 (build-system ruby-build-system)
686 (arguments
687 '(#:tests? #f)) ; no test suite
688 (synopsis "Simple Ruby library for XML processing")
689 (description "This library provides a simple API for XML processing in
690Ruby.")
691 (home-page "https://github.com/maik/xml-simple")
692 (license license:ruby)))
693
2cb3ab48
RW
694(define-public ruby-thor
695 (package
696 (name "ruby-thor")
697 (version "0.19.1")
698 (source (origin
699 (method url-fetch)
700 (uri (rubygems-uri "thor" version))
701 (sha256
702 (base32
703 "08p5gx18yrbnwc6xc0mxvsfaxzgy2y9i78xq7ds0qmdm67q39y4z"))))
704 (build-system ruby-build-system)
705 (arguments
706 '(#:tests? #f)) ; no test suite
707 (native-inputs
708 `(("bundler" ,bundler)))
709 (synopsis "Ruby toolkit for building command-line interfaces")
710 (description "Thor is a toolkit for building powerful command-line
711interfaces.")
712 (home-page "http://whatisthor.com/")
713 (license license:expat)))
714
ec79018e
RW
715(define-public ruby-lumberjack
716 (package
717 (name "ruby-lumberjack")
718 (version "1.0.9")
719 (source (origin
720 (method url-fetch)
721 (uri (rubygems-uri "lumberjack" version))
722 (sha256
723 (base32
724 "162frm2bwy58pj8ccsdqa4a6i0csrhb9h5l3inhkl1ivgfc8814l"))))
725 (build-system ruby-build-system)
726 (native-inputs
727 `(("ruby-rspec" ,ruby-rspec)))
728 (synopsis "Logging utility library for Ruby")
729 (description "Lumberjack is a simple logging utility that can be a drop in
730replacement for Logger or ActiveSupport::BufferedLogger. It provides support
731for automatically rolling log files even with multiple processes writing the
732same log file.")
733 (home-page "http://github.com/bdurand/lumberjack")
734 (license license:expat)))
735
70b4cf38
RW
736(define-public ruby-nenv
737 (package
738 (name "ruby-nenv")
739 (version "0.2.0")
740 (source (origin
741 (method url-fetch)
742 (uri (rubygems-uri "nenv" version))
743 (sha256
744 (base32
745 "152wxwri0afwgnxdf93gi6wjl9rr5z7vwp8ln0gpa3rddbfc27s6"))))
746 (build-system ruby-build-system)
747 (arguments
748 `(#:tests? #f)) ; no tests included
749 (native-inputs
750 `(("ruby-rspec" ,ruby-rspec)
751 ("bundler" ,bundler)))
752 (synopsis "Ruby interface for modifying the environment")
753 (description "Nenv provides a convenient wrapper for Ruby's ENV to modify
754and inspect the environment.")
755 (home-page "https://github.com/e2/nenv")
756 (license license:expat)))
757
8d9e9f28
RW
758(define-public ruby-permutation
759 (package
760 (name "ruby-permutation")
761 (version "0.1.8")
762 (source (origin
763 (method url-fetch)
764 (uri (rubygems-uri "permutation" version))
765 (sha256
766 (base32
767 "13crwk2vfbzv99czva7881027dbcnidihmvx2jc58z2vm3bp9sl8"))))
768 (build-system ruby-build-system)
769 (arguments
770 `(#:phases
771 (modify-phases %standard-phases
772 (add-after 'unpack 'fix-rakefile
773 (lambda _
774 (substitute* "Rakefile"
775 (("require 'rake/gempackagetask'")
776 "require 'rubygems/package_task'")
777 (("include Config") ""))
778 #t))
779 (replace 'check
780 (lambda _
781 (zero? (system* "ruby" "-Ilib" "test/test.rb")))))))
782 (synopsis "Library to perform operations with sequence permutations")
783 (description "This package provides a Ruby library to perform different
784operations with permutations of sequences, such as strings and arrays.")
785 (home-page "http://flori.github.io/permutation")
786 (license license:gpl2))) ; GPL 2 only
787
c5d14d42
RW
788(define-public ruby-shellany
789 (package
790 (name "ruby-shellany")
791 (version "0.0.1")
792 (source (origin
793 (method url-fetch)
794 (uri (rubygems-uri "shellany" version))
795 (sha256
796 (base32
797 "1ryyzrj1kxmnpdzhlv4ys3dnl2r5r3d2rs2jwzbnd1v96a8pl4hf"))))
798 (build-system ruby-build-system)
799 (arguments
800 `(#:test-target "default"
801 #:phases
802 (modify-phases %standard-phases
803 (add-after 'unpack 'fix-version-test
804 (lambda _
805 (substitute* "spec/shellany_spec.rb"
806 (("^RSpec") "require \"shellany\"\nRSpec"))
807 #t)))))
808 (native-inputs
809 `(("ruby-rspec" ,ruby-rspec)
810 ("ruby-nenv" ,ruby-nenv)
811 ("bundler" ,bundler)))
812 (synopsis "Capture command output")
813 (description "Shellany is a Ruby library providing functions to capture
814the output produced by running shell commands.")
815 (home-page "https://rubygems.org/gems/shellany")
816 (license license:expat)))
817
d152162f
RW
818(define-public ruby-notiffany
819 (package
820 (name "ruby-notiffany")
821 (version "0.0.7")
822 (source (origin
823 (method url-fetch)
824 (uri (rubygems-uri "notiffany" version))
825 (sha256
826 (base32
827 "1v5x1w59qq85r6dpv3y9ga34dfd7hka1qxyiykaw7gm0i6kggbhi"))))
828 (build-system ruby-build-system)
829 ;; Tests are not included in the gem.
830 (arguments `(#:tests? #f))
831 (propagated-inputs
832 `(("ruby-shellany" ,ruby-shellany)
833 ("ruby-nenv" ,ruby-nenv)))
834 (native-inputs
835 `(("bundler" ,bundler)))
836 (synopsis "Wrapper libray for notification libraries")
837 (description "Notiffany is a Ruby wrapper libray for notification
838libraries such as Libnotify.")
839 (home-page "https://github.com/guard/notiffany")
840 (license license:expat)))
841
8528365b
RW
842(define-public ruby-formatador
843 (package
844 (name "ruby-formatador")
845 (version "0.2.5")
846 (source (origin
847 (method url-fetch)
848 (uri (rubygems-uri "formatador" version))
849 (sha256
850 (base32
851 "1gc26phrwlmlqrmz4bagq1wd5b7g64avpx0ghxr9xdxcvmlii0l0"))))
852 (build-system ruby-build-system)
853 ;; Circular dependency: Tests require ruby-shindo, which requires
854 ;; ruby-formatador at runtime.
855 (arguments `(#:tests? #f))
856 (synopsis "Ruby library to format text on stdout")
857 (description "Formatador is a Ruby library to format text printed to the
858standard output stream.")
859 (home-page "http://github.com/geemus/formatador")
860 (license license:expat)))
861
7ac4610f
RW
862(define-public ruby-shindo
863 (package
864 (name "ruby-shindo")
865 (version "0.3.8")
866 (source (origin
867 (method url-fetch)
868 (uri (rubygems-uri "shindo" version))
869 (sha256
870 (base32
871 "0s8v1jbz8i0jh92f2fgxb3p51l1azrpkc8nv4mhrqy4vndpvd7wq"))))
872 (build-system ruby-build-system)
873 (arguments
874 `(#:test-target "shindo_tests"
875 #:phases
876 (modify-phases %standard-phases
877 (add-after 'unpack 'fix-tests
878 (lambda _
879 (substitute* "Rakefile"
880 (("system \"shindo") "system \"./bin/shindo")
881 ;; This test doesn't work, so we disable it.
882 (("fail \"The build_error test should fail") "#"))
883 #t)))))
884 (propagated-inputs
885 `(("ruby-formatador" ,ruby-formatador)))
886 (synopsis "Simple depth first Ruby testing")
887 (description "Shindo is a simple depth first testing library for Ruby.")
888 (home-page "https://github.com/geemus/shindo")
889 (license license:expat)))
890
f13636f2
RW
891(define-public ruby-rubygems-tasks
892 (package
893 (name "ruby-rubygems-tasks")
894 (version "0.2.4")
895 (source (origin
896 (method url-fetch)
897 (uri (rubygems-uri "rubygems-tasks" version))
898 (sha256
899 (base32
900 "16cp45qlbcglnqdm4f1vj3diywdz4v024saqpgrz6palf0wmgz2j"))))
901 (build-system ruby-build-system)
902 ;; Tests need Internet access.
903 (arguments `(#:tests? #f))
904 (native-inputs
905 `(("ruby-rspec" ,ruby-rspec)
906 ("ruby-yard" ,ruby-yard)))
907 (synopsis "Rake tasks for managing and releasing Ruby Gems")
908 (description "Rubygems-task provides Rake tasks for managing and releasing
909Ruby Gems.")
910 (home-page "https://github.com/postmodern/rubygems-tasks")
911 (license license:expat)))
912
2417fce3
RW
913(define-public ruby-ffi
914 (package
915 (name "ruby-ffi")
916 (version "1.9.10")
917 (source (origin
918 (method url-fetch)
919 (uri (rubygems-uri "ffi" version))
920 (sha256
921 (base32
922 "1m5mprppw0xcrv2mkim5zsk70v089ajzqiq5hpyb0xg96fcyzyxj"))))
923 (build-system ruby-build-system)
924 ;; FIXME: Before running tests the build system attempts to build libffi
925 ;; from sources.
926 (arguments `(#:tests? #f))
927 (native-inputs
928 `(("ruby-rake-compiler" ,ruby-rake-compiler)
929 ("ruby-rspec" ,ruby-rspec)
930 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
931 (inputs
932 `(("libffi" ,libffi)))
933 (synopsis "Ruby foreign function interface library")
934 (description "Ruby-FFI is a Ruby extension for programmatically loading
935dynamic libraries, binding functions within them, and calling those functions
936from Ruby code. Moreover, a Ruby-FFI extension works without changes on Ruby
937and JRuby.")
938 (home-page "http://wiki.github.com/ffi/ffi")
939 (license license:bsd-3)))
940
58b59742
RW
941(define-public ruby-simplecov-html
942 (package
943 (name "ruby-simplecov-html")
944 (version "0.10.0")
945 (source (origin
946 (method url-fetch)
947 (uri (rubygems-uri "simplecov-html" version))
948 (sha256
949 (base32
8b749cf3 950 "1qni8g0xxglkx25w54qcfbi4wjkpvmb28cb7rj5zk3iqynjcdrqf"))))
58b59742 951 (build-system ruby-build-system)
8b749cf3 952 (arguments `(#:tests? #f)) ; there are no tests
58b59742
RW
953 (native-inputs
954 `(("bundler" ,bundler)))
955 (synopsis "Default HTML formatter for SimpleCov code coverage tool")
956 (description "This package provides the default HTML formatter for
957the SimpleCov code coverage tool for Ruby version 1.9 and above.")
958 (home-page "https://github.com/colszowka/simplecov-html")
959 (license license:expat)))
960
a84fa2ad
RW
961(define-public ruby-simplecov
962 (package
963 (name "ruby-simplecov")
964 (version "0.10.0")
965 (source (origin
966 (method url-fetch)
967 (uri (rubygems-uri "simplecov" version))
968 (sha256
969 (base32
970 "1q2iq2vgrdvvla5y907gkmqx6ry2qvnvc7a90hlcbwgp1w0sv6z4"))))
971 (build-system ruby-build-system)
972 ;; Simplecov depends on rubocop for code style checking at build time.
973 ;; Rubocop needs simplecov at build time.
974 (arguments `(#:tests? #f))
975 (propagated-inputs
976 `(("ruby-json" ,ruby-json)
977 ("ruby-docile" ,ruby-docile)
978 ("ruby-simplecov-html" ,ruby-simplecov-html)))
979 (native-inputs
980 `(("bundler" ,bundler)))
981 (synopsis "Code coverage framework for Ruby")
982 (description "SimpleCov is a code coverage framework for Ruby with a
983powerful configuration library and automatic merging of coverage across test
984suites.")
985 (home-page "http://github.com/colszowka/simplecov")
986 (license license:expat)))
987
98b87b82
DT
988(define-public ruby-useragent
989 (package
990 (name "ruby-useragent")
991 (version "0.13.3")
992 (source (origin
993 (method url-fetch)
e83c6d00 994 (uri (rubygems-uri "useragent" version))
98b87b82
DT
995 (sha256
996 (base32
e83c6d00 997 "0kz7yyz7528bv4a2kfymvkcm8whqcddhmgaw1ksw1d90n30hhkpc"))))
98b87b82
DT
998 (build-system ruby-build-system)
999 (arguments
e83c6d00 1000 '(#:tests? #f)) ; no test suite
98b87b82
DT
1001 (synopsis "HTTP user agent parser for Ruby")
1002 (description "UserAgent is a Ruby library that parses and compares HTTP
1003User Agents.")
1004 (home-page "https://github.com/gshutler/useragent")
1005 (license license:expat)))
96086cc5
DT
1006
1007(define-public ruby-bacon
1008 (package
1009 (name "ruby-bacon")
e83c6d00 1010 (version "1.2.0")
96086cc5
DT
1011 (source (origin
1012 (method url-fetch)
e83c6d00 1013 (uri (rubygems-uri "bacon" version))
96086cc5
DT
1014 (sha256
1015 (base32
e83c6d00 1016 "1f06gdj77bmwzc1k5iragl1595hbn67yc7sqvs56ca8plrr2vmai"))))
96086cc5 1017 (build-system ruby-build-system)
96086cc5
DT
1018 (synopsis "Small RSpec clone")
1019 (description "Bacon is a small RSpec clone providing all essential
1020features.")
1021 (home-page "https://github.com/chneukirchen/bacon")
1022 (license license:expat)))
de59d316
DT
1023
1024(define-public ruby-arel
1025 (package
1026 (name "ruby-arel")
1027 (version "6.0.0")
1028 (source (origin
1029 (method url-fetch)
e83c6d00 1030 (uri (rubygems-uri "arel" version))
de59d316
DT
1031 (sha256
1032 (base32
e83c6d00 1033 "18wnfnzr2i5p3fygsddjbi1cimws6823nbk8drxidmnj8jz7h0ar"))))
de59d316 1034 (build-system ruby-build-system)
e83c6d00
DT
1035 (arguments
1036 '(#:tests? #f)) ; no test suite
de59d316
DT
1037 (synopsis "SQL AST manager for Ruby")
1038 (description "Arel is a SQL AST manager for Ruby. It simplifies the
1039generation of complex SQL queries and adapts to various relational database
1040implementations.")
1041 (home-page "https://github.com/rails/arel")
1042 (license license:expat)))
e259bdf0
DT
1043
1044(define-public ruby-connection-pool
1045 (package
1046 (name "ruby-connection-pool")
1047 (version "2.2.0")
1048 (source (origin
1049 (method url-fetch)
e83c6d00 1050 (uri (rubygems-uri "connection_pool" version))
e259bdf0
DT
1051 (sha256
1052 (base32
e83c6d00 1053 "1b2bb3k39ni5mzcnqlv9y4yjkbin20s7dkwzp0jw2jf1rmzcgrmy"))))
e259bdf0
DT
1054 (build-system ruby-build-system)
1055 (native-inputs
1056 `(("bundler" ,bundler)))
1057 (synopsis "Generic connection pool for Ruby")
1058 (description "Connection_pool provides a generic connection pooling
1059interface for Ruby programs.")
1060 (home-page "https://github.com/mperham/connection_pool")
1061 (license license:expat)))
4c0aeb44
DT
1062
1063(define-public ruby-net-http-persistent
1064 (package
1065 (name "ruby-net-http-persistent")
1066 (version "2.9.4")
1067 (source (origin
1068 (method url-fetch)
e83c6d00 1069 (uri (rubygems-uri "net-http-persistent" version))
4c0aeb44
DT
1070 (sha256
1071 (base32
e83c6d00 1072 "1y9fhaax0d9kkslyiqi1zys6cvpaqx9a0y0cywp24rpygwh4s9r4"))))
4c0aeb44 1073 (build-system ruby-build-system)
4c0aeb44
DT
1074 (native-inputs
1075 `(("ruby-connection-pool" ,ruby-connection-pool)
1076 ("ruby-hoe" ,ruby-hoe)))
1077 (synopsis "Persistent HTTP connection manager")
1078 (description "Net::HTTP::Persistent manages persistent HTTP connections
1079using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
1080 (home-page "https://github.com/drbrain/net-http-persistent")
1081 (license license:expat)))
afbbdf77 1082
f88bacaf
RW
1083(define-public ruby-power-assert
1084 (package
1085 (name "ruby-power-assert")
3918146b 1086 (version "0.2.7")
f88bacaf
RW
1087 (source (origin
1088 (method url-fetch)
1089 (uri (rubygems-uri "power_assert" version))
1090 (sha256
1091 (base32
3918146b 1092 "0ka6w71lcan4wgf111xi3pcn9ma9lhakv31jg8w007nwzi0xfjbi"))))
f88bacaf
RW
1093 (build-system ruby-build-system)
1094 (native-inputs
1095 `(("bundler" ,bundler)))
1096 (synopsis "Assert library with descriptive assertion messages")
1097 (description "Power-assert is an assertion library providing descriptive
1098assertion messages for tests.")
1099 (home-page "https://github.com/k-tsj/power_assert")
1100 (license (list license:bsd-2 license:ruby))))
1101
347eb21e
RW
1102(define-public ruby-locale
1103 (package
1104 (name "ruby-locale")
1105 (version "2.1.2")
1106 (source (origin
1107 (method url-fetch)
1108 (uri (rubygems-uri "locale" version))
1109 (sha256
1110 (base32
1111 "1sls9bq4krx0fmnzmlbn64dw23c4d6pz46ynjzrn9k8zyassdd0x"))))
1112 (build-system ruby-build-system)
1113 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
1114 ;; which needs ruby-gettext, which needs ruby-locale. To break the
1115 ;; dependency cycle we disable tests.
1116 (arguments `(#:tests? #f))
1117 (native-inputs
1118 `(("bundler" ,bundler)
1119 ("ruby-yard" ,ruby-yard)))
1120 (synopsis "Ruby library providing basic localization APIs")
1121 (description
1122 "Ruby-Locale is the pure ruby library which provides basic APIs for
1123localization.")
1124 (home-page "https://github.com/ruby-gettext/locale")
1125 (license (list license:lgpl3+ license:ruby))))
1126
e2333ea3
RW
1127(define-public ruby-text
1128 (package
1129 (name "ruby-text")
1130 (version "1.3.1")
1131 (source (origin
1132 (method url-fetch)
1133 (uri (rubygems-uri "text" version))
1134 (sha256
1135 (base32
1136 "1x6kkmsr49y3rnrin91rv8mpc3dhrf3ql08kbccw8yffq61brfrg"))))
1137 (build-system ruby-build-system)
1138 (synopsis "Collection of text algorithms for Ruby")
1139 (description
1140 "This package provides a collection of text algorithms: Levenshtein,
1141Soundex, Metaphone, Double Metaphone, Porter Stemming.")
1142 (home-page "http://github.com/threedaymonk/text")
1143 (license license:expat)))
1144
c1f52261
RW
1145(define-public ruby-gettext
1146 (package
1147 (name "ruby-gettext")
1148 (version "3.1.7")
1149 (source (origin
1150 (method url-fetch)
1151 (uri (rubygems-uri "gettext" version))
1152 (sha256
1153 (base32
1154 "1hg9islkm324mb4sd4za1fgafj1hqnm3bdvzj3k4fqpnzqnbcfiq"))))
1155 (build-system ruby-build-system)
1156 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga,
1157 ;; which needs ruby-gettext. To break the dependency cycle we disable
1158 ;; tests.
1159 (arguments `(#:tests? #f))
1160 (propagated-inputs
1161 `(("ruby-locale" ,ruby-locale)
1162 ("ruby-text" ,ruby-text)))
1163 (native-inputs
1164 `(("bundler" ,bundler)
1165 ("ruby-yard" ,ruby-yard)))
1166 (synopsis "GNU gettext-like program for Ruby")
1167 (description
1168 "Gettext is a GNU gettext-like program for Ruby. The catalog
1169file (po-file) used is the same as that used by GNU gettext, allowing you to
1170use GNU gettext tools for maintenance.")
1171 (home-page "http://ruby-gettext.github.com/")
1172 (license (list license:lgpl3+ license:ruby))))
1173
cc5aeb8c
RW
1174(define-public ruby-packnga
1175 (package
1176 (name "ruby-packnga")
1177 (version "1.0.1")
1178 (source (origin
1179 (method url-fetch)
1180 (uri (rubygems-uri "packnga" version))
1181 (sha256
1182 (base32
1183 "1i71yhvlkvi5fp3m8jl9317cnddkbnrcy0syrmiw4y1lrq0cbncj"))))
1184 (build-system ruby-build-system)
1185 ;; ruby-test-unit is required to run tests, but that needs ruby-packnga.
1186 ;; To break the dependency cycle we disable tests.
1187 (arguments `(#:tests? #f))
1188 (propagated-inputs
1189 `(("ruby-gettext" ,ruby-gettext)
1190 ("ruby-yard" ,ruby-yard)))
1191 (native-inputs
1192 `(("bundler" ,bundler)))
1193 (synopsis "Utility library to package internationalized libraries")
1194 (description
1195 "Packnga is a library to translate to many languages using YARD.")
1196 (home-page "http://ranguba.org/packnga/")
1197 (license license:lgpl2.0+)))
1198
3383f5bd
RW
1199(define-public ruby-test-unit
1200 (package
1201 (name "ruby-test-unit")
1202 (version "3.1.5")
1203 (source (origin
1204 (method url-fetch)
1205 (uri (rubygems-uri "test-unit" version))
1206 (sha256
1207 (base32
1208 "0jxznjzwmrlp8wqjxsd06qbiddffn68pdhz6nrqpjbiln1z3af4w"))))
1209 (build-system ruby-build-system)
1210 (propagated-inputs
1211 `(("ruby-power-assert" ,ruby-power-assert)))
1212 (native-inputs
1213 `(("bundler" ,bundler)
1214 ("ruby-packnga" ,ruby-packnga)
1215 ("ruby-yard" ,ruby-yard)))
1216 (synopsis "Unit testing framework for Ruby")
1217 (description "@code{Test::Unit} is unit testing framework for Ruby, based
1218on xUnit principles. These were originally designed by Kent Beck, creator of
1219extreme programming software development methodology, for Smalltalk's SUnit.
1220It allows writing tests, checking results and automated testing in Ruby.")
1221 (home-page "http://test-unit.github.io/")
1222 (license (list license:psfl license:ruby))))
1223
25d6d49b
RW
1224(define-public ruby-metaclass
1225 (package
1226 (name "ruby-metaclass")
1227 (version "0.0.4")
1228 (source (origin
1229 (method url-fetch)
1230 (uri (rubygems-uri "metaclass" version))
1231 (sha256
1232 (base32
1233 "0hp99y2b1nh0nr8pc398n3f8lakgci6pkrg4bf2b2211j1f6hsc5"))))
1234 (build-system ruby-build-system)
1235 (arguments
1236 `(#:phases
1237 (modify-phases %standard-phases
1238 (add-after 'unpack 'add-test-unit-to-search-path
761e7042
BW
1239 (lambda* (#:key inputs #:allow-other-keys)
1240 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1241 (test-unit-home (gem-home test-unit
1242 ,(package-version ruby))))
1243 (substitute* "Rakefile"
1244 (("t\\.libs << \"test\"" line)
1245 (string-append line "; t.libs << \""
1246 test-unit-home
1247 "/gems/test-unit-"
1248 ,(package-version ruby-test-unit)
1249 "/lib\""))))
1250 #t)))))
25d6d49b
RW
1251 (native-inputs
1252 `(("bundler" ,bundler)
1253 ("ruby-test-unit" ,ruby-test-unit)))
1254 (synopsis "Ruby library adding metaclass method to all objects")
1255 (description
1256 "Metaclass is a Ruby library adding a @code{metaclass} method to all Ruby
1257objects.")
1258 (home-page "http://github.com/floehopper/metaclass")
1259 (license license:expat)))
1260
21f7b7bd
RW
1261(define-public ruby-blankslate
1262 (package
1263 (name "ruby-blankslate")
1264 (version "3.1.3")
1265 (source (origin
1266 (method url-fetch)
1267 (uri (rubygems-uri "blankslate" version))
1268 (sha256
1269 (base32
1270 "0fwkb4d1j9gc7vdwn2nxvwgy2g5wlag4c4bp7bl85jvq0kgp6cyx"))))
1271 (build-system ruby-build-system)
1272 (arguments
1273 `(#:phases
1274 (modify-phases %standard-phases
1275 (replace 'check
1276 (lambda _ (zero? (system* "rspec" "spec/")))))))
1277 (native-inputs
1278 `(("bundler" ,bundler)
1279 ("ruby-rspec" ,ruby-rspec)))
1280 (synopsis "Abstract base class with no predefined methods")
1281 (description
1282 "BlankSlate provides an abstract base class with no predefined
1283methods (except for @code{__send__} and @code{__id__}). BlankSlate is useful
1284as a base class when writing classes that depend upon
1285@code{method_missing} (e.g. dynamic proxies).")
1286 (home-page "http://github.com/masover/blankslate")
1287 (license license:expat)))
1288
4016ba3f
RW
1289(define-public ruby-instantiator
1290 (package
1291 (name "ruby-instantiator")
1292 (version "0.0.6")
1293 (source (origin
1294 (method url-fetch)
1295 (uri (rubygems-uri "instantiator" version))
1296 (sha256
1297 (base32
1298 "0mfmqhg9xrv9i8i1kmphf15ywddhivyh2z3ccl0xjw8qy54zr21i"))))
1299 (build-system ruby-build-system)
1300 (arguments
1301 `(#:phases
1302 (modify-phases %standard-phases
1303 (add-after 'unpack 'add-test-unit-to-search-path
761e7042
BW
1304 (lambda* (#:key inputs #:allow-other-keys)
1305 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1306 (test-unit-home (gem-home test-unit ,(package-version
1307 ruby))))
1308 (substitute* "Rakefile"
1309 (("t\\.libs << \"test\"" line)
1310 (string-append line "; t.libs << \""
1311 test-unit-home
1312 "/gems/test-unit-"
1313 ,(package-version ruby-test-unit)
1314 "/lib\""))))
1315 #t)))))
4016ba3f
RW
1316 (propagated-inputs
1317 `(("ruby-blankslate" ,ruby-blankslate)))
1318 (native-inputs
1319 `(("bundler" ,bundler)
1320 ("ruby-test-unit" ,ruby-test-unit)))
1321 (synopsis "Instantiate an arbitrary Ruby class")
1322 (description
1323 "Instantiator lets you instantiate an arbitrary Ruby class without
1324knowing anything about the constructor.")
1325 (home-page "https://github.com/floehopper/instantiator")
1326 (license license:expat)))
1327
97aee8d3
RW
1328(define-public ruby-introspection
1329 (package
1330 (name "ruby-introspection")
1331 (version "0.0.3")
1332 (source (origin
1333 (method url-fetch)
1334 (uri (rubygems-uri "introspection" version))
1335 (sha256
1336 (base32
1337 "0g1j71sqfxbqk32wj7d0bkd3dlayfqzprfq3dbr0rq107xbxjcrr"))))
1338 (build-system ruby-build-system)
1339 (arguments
1340 `(#:phases
1341 (modify-phases %standard-phases
1342 (add-after 'unpack 'add-test-unit-to-search-path
1343 (lambda* (#:key inputs #:allow-other-keys)
761e7042
BW
1344 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1345 (test-unit-home (gem-home test-unit ,(package-version
1346 ruby))))
1347 (substitute* "Rakefile"
1348 (("t\\.libs << \"test\"" line)
1349 (string-append line "; t.libs << \""
1350 test-unit-home
1351 "/gems/test-unit-"
1352 ,(package-version ruby-test-unit)
1353 "/lib\""))))
97aee8d3
RW
1354 #t)))))
1355 (propagated-inputs
1356 `(("ruby-instantiator" ,ruby-instantiator)
1357 ("ruby-metaclass" ,ruby-metaclass)))
1358 (native-inputs
1359 `(("bundler" ,bundler)
1360 ("ruby-blankslate" ,ruby-blankslate)
1361 ("ruby-test-unit" ,ruby-test-unit)))
1362 (synopsis "Dynamic inspection of the method hierarchy on a Ruby object")
1363 (description
1364 "Introspection provides tools to inspect the hierarchy of method
1365definitions on a Ruby object.")
1366 (home-page "https://github.com/floehopper/introspection")
1367 (license license:expat)))
1368
d93062fd
RW
1369(define-public ruby-redcarpet
1370 (package
1371 (name "ruby-redcarpet")
1372 (version "3.3.3")
1373 (source (origin
1374 (method url-fetch)
1375 (uri (rubygems-uri "redcarpet" version))
1376 (sha256
1377 (base32
1378 "14i3wypp97bpk20679d1csy88q4hsgfqbnqw6mryl77m2g0d09pk"))))
1379 (build-system ruby-build-system)
1380 (arguments
1381 `(#:phases
1382 (modify-phases %standard-phases
1383 ;; The gem archive does not include the conformance tests.
1384 (add-after 'unpack 'disable-conformance-tests
1385 (lambda _
1386 (substitute* "Rakefile"
1387 (("task :test => %w\\[test:unit test:conformance\\]")
1388 "task :test => %w[test:unit]"))
1389 #t)))))
1390 (native-inputs
1391 `(("bundler" ,bundler)
1392 ("ruby-test-unit" ,ruby-test-unit)
1393 ("ruby-rake-compiler" ,ruby-rake-compiler)))
1394 (synopsis "Extensible Markdown to (X)HTML converter")
1395 (description
1396 "Redcarpet is an extensible Ruby library for Markdown processing and
1397conversion to (X)HTML.")
1398 (home-page "http://github.com/vmg/redcarpet")
1399 (license license:expat)))
1400
4f2a52ae
RW
1401(define-public ruby-mocha
1402 (package
1403 (name "ruby-mocha")
1404 (version "1.1.0")
1405 (source (origin
1406 (method url-fetch)
1407 (uri (rubygems-uri "mocha" version))
1408 (sha256
1409 (base32
1410 "107nmnngbv8lq2g7hbjpn5kplb4v2c8gs9lxrg6vs8gdbddkilzi"))))
1411 (build-system ruby-build-system)
1412 (arguments
1413 `(#:phases
1414 (modify-phases %standard-phases
1415 (add-after 'unpack 'add-test-unit-to-search-path
1416 (lambda* (#:key inputs #:allow-other-keys)
761e7042
BW
1417 (let* ((test-unit (assoc-ref inputs "ruby-test-unit"))
1418 (test-unit-home (gem-home test-unit
1419 ,(package-version ruby))))
1420 (substitute* "Rakefile"
1421 (("t\\.libs << 'test'" line)
1422 (string-append line "; t.libs << \""
1423 test-unit-home
1424 "/gems/test-unit-"
1425 ,(package-version ruby-test-unit)
1426 "/lib\""))))
4f2a52ae
RW
1427 #t))
1428 (add-before 'check 'use-latest-redcarpet
1429 (lambda _
1430 (substitute* "mocha.gemspec"
1431 (("<redcarpet>, \\[\"~> 1\"\\]")
1432 "<redcarpet>, [\">= 3\"]"))
1433 #t))
1434 (add-before 'check 'hardcode-version
1435 (lambda _
1436 ;; Mocha is undefined at build time
1437 (substitute* "Rakefile"
1438 (("#\\{Mocha::VERSION\\}") ,version))
1439 #t))
1440 (add-before 'check 'remove-failing-test
1441 ;; FIXME: This test fails for reasons unrelated to Guix packaging.
1442 (lambda _
1443 (delete-file "test/acceptance/stubbing_nil_test.rb")
1444 #t)))))
1445 (propagated-inputs
1446 `(("ruby-metaclass" ,ruby-metaclass)))
1447 (native-inputs
1448 `(("bundler" ,bundler)
1449 ("ruby-yard" ,ruby-yard)
1450 ("ruby-introspection" ,ruby-introspection)
1451 ("ruby-test-unit" ,ruby-test-unit)
1452 ("ruby-redcarpet" ,ruby-redcarpet)))
1453 (synopsis "Mocking and stubbing library for Ruby")
1454 (description
1455 "Mocha is a mocking and stubbing library with JMock/SchMock syntax, which
1456allows mocking and stubbing of methods on real (non-mock) classes.")
1457 (home-page "http://gofreerange.com/mocha/docs")
1458 (license license:expat)))
1459
2c84ba7e
RW
1460(define-public ruby-net-ssh
1461 (package
1462 (name "ruby-net-ssh")
1463 (version "3.0.1")
1464 (source (origin
1465 (method url-fetch)
1466 (uri (rubygems-uri "net-ssh" version))
1467 (sha256
1468 (base32
1469 "1dzqkgwi9xm6mbfk1rkk17rzmz8m5xakqi21w1b97ybng6kkw0hf"))))
1470 (build-system ruby-build-system)
1471 (native-inputs
1472 `(("ruby-mocha" ,ruby-mocha)
1473 ("ruby-test-unit" ,ruby-test-unit)))
1474 (synopsis "Ruby implementation of the SSH2 client protocol")
1475 (description "@code{Net::SSH} is a pure-Ruby implementation of the SSH2
1476client protocol. It allows you to write programs that invoke and interact
1477with processes on remote servers, via SSH2.")
1478 (home-page "https://github.com/net-ssh/net-ssh")
1479 (license license:expat)))
1480
2206e948
DT
1481(define-public ruby-minitest
1482 (package
1483 (name "ruby-minitest")
1484 (version "5.7.0")
1485 (source (origin
e83c6d00
DT
1486 (method url-fetch)
1487 (uri (rubygems-uri "minitest" version))
2206e948
DT
1488 (sha256
1489 (base32
e83c6d00 1490 "0rxqfakp629mp3vwda7zpgb57lcns5znkskikbfd0kriwv8i1vq8"))))
2206e948 1491 (build-system ruby-build-system)
2206e948
DT
1492 (native-inputs
1493 `(("ruby-hoe" ,ruby-hoe)))
1494 (synopsis "Small test suite library for Ruby")
1495 (description "Minitest provides a complete suite of Ruby testing
1496facilities supporting TDD, BDD, mocking, and benchmarking.")
1497 (home-page "https://github.com/seattlerb/minitest")
1498 (license license:expat)))
1499
1db6e09f
RW
1500;; This is the last release of Minitest 4, which is used by some packages.
1501(define-public ruby-minitest-4
1502 (package (inherit ruby-minitest)
1503 (version "4.7.5")
1504 (source (origin
1505 (method url-fetch)
1506 (uri (rubygems-uri "minitest" version))
1507 (sha256
1508 (base32
1509 "03p6iban9gcpcflzp4z901s1hgj9369p6515h967ny6hlqhcf2iy"))))
1510 (arguments
1511 `(#:phases
1512 (modify-phases %standard-phases
1513 (add-after 'unpack 'remove-unsupported-method
1514 (lambda _
1515 (substitute* "Rakefile"
1516 (("self\\.rubyforge_name = .*") ""))
1517 #t)))))))
1518
35130835
DT
1519(define-public ruby-minitest-sprint
1520 (package
1521 (name "ruby-minitest-sprint")
1522 (version "1.1.0")
1523 (source (origin
e83c6d00
DT
1524 (method url-fetch)
1525 (uri (rubygems-uri "minitest-sprint" version))
35130835
DT
1526 (sha256
1527 (base32
e83c6d00 1528 "179d6pj56l9xzm46fqsqj10mzjkr1f9fv4cxa8wvchs97hqz33w1"))))
35130835 1529 (build-system ruby-build-system)
35130835
DT
1530 (native-inputs
1531 `(("ruby-hoe" ,ruby-hoe)
1532 ("ruby-minitest" ,ruby-minitest)))
1533 (synopsis "Fast test suite runner for minitest")
1534 (description "Minitest-sprint is a test runner for minitest that makes it
1535easier to re-run individual failing tests.")
1536 (home-page "https://github.com/seattlerb/minitest-sprint")
1537 (license license:expat)))
1538
0808e361
DT
1539(define-public ruby-minitest-bacon
1540 (package
1541 (name "ruby-minitest-bacon")
1542 (version "1.0.2")
1543 (source (origin
e83c6d00
DT
1544 (method url-fetch)
1545 (uri (rubygems-uri "minitest-bacon" version))
0808e361
DT
1546 (sha256
1547 (base32
e83c6d00 1548 "0cm7r68422743i3b6fm4rrm0r6cnnjmglq5gcmmgl1f0rk5hnf6r"))))
0808e361 1549 (build-system ruby-build-system)
0808e361
DT
1550 (native-inputs
1551 `(("ruby-hoe" ,ruby-hoe)))
1552 (inputs
1553 `(("ruby-minitest" ,ruby-minitest)))
1554 (synopsis "Bacon compatibility library for minitest")
1555 (description "Minitest-bacon extends minitest with bacon-like
1556functionality, making it easier to migrate test suites from bacon to minitest.")
1557 (home-page "https://github.com/seattlerb/minitest-bacon")
1558 (license license:expat)))
1559
39dc0eb5
BW
1560(define-public ruby-minitest-focus
1561 (package
1562 (name "ruby-minitest-focus")
1563 (version "1.1.2")
1564 (source
1565 (origin
1566 (method url-fetch)
1567 (uri (rubygems-uri "minitest-focus" version))
1568 (sha256
1569 (base32
1570 "1zgjslp6d7dzcn8smj595idymgd5j603p9g2jqkfgi28sqbhz6m0"))))
1571 (build-system ruby-build-system)
1572 (propagated-inputs
1573 `(("ruby-minitest" ,ruby-minitest)))
1574 (native-inputs
1575 `(("ruby-hoe" ,ruby-hoe)))
1576 (synopsis "Allows a few specific tests to be focused on")
1577 (description
1578 "@code{minitest-focus} gives the ability focus on a few tests with ease
1579without having to use command-line arguments. It introduces a @code{focus}
1580class method for use in testing classes, specifying that the next defined test
1581is to be run.")
1582 (home-page "https://github.com/seattlerb/minitest-focus")
1583 (license license:expat)))
1584
99fc5cd5
BW
1585(define-public ruby-minitest-pretty-diff
1586 ;; Use git reference because gem is out of date and does not contain testing
1587 ;; script. There are no releases on GitHub.
1588 (let ((commit "11f32e930f574225432f42e5e1ef6e7471efe572"))
1589 (package
1590 (name "ruby-minitest-pretty-diff")
1591 (version (string-append "0.1-1." (string-take commit 8)))
1592 (source (origin
1593 (method git-fetch)
1594 (uri (git-reference
1595 (url "https://github.com/adammck/minitest-pretty_diff.git")
1596 (commit commit)))
1597 (file-name (string-append name "-" version "-checkout"))
1598 (sha256
1599 (base32
1600 "13y5dhmcckhzd83gj1nfwh41iykbjcm2w7y4pr6j6rpqa5as122r"))))
1601 (build-system ruby-build-system)
1602 (arguments
1603 `(#:phases
1604 (modify-phases %standard-phases
1605 (replace 'check
1606 (lambda _
1607 (zero? (system* "script/test")))))))
1608 (native-inputs
1609 `(("bundler" ,bundler)
1610 ("ruby-turn" ,ruby-turn)))
1611 (synopsis "Pretty-print hashes and arrays in MiniTest")
1612 (description
1613 "@code{minitest-pretty_diff} monkey-patches
1614@code{MiniTest::Assertions#mu_pp} to pretty-print hashes and arrays before
1615diffing them. This makes it easier to spot differences between nested
1616structures when tests fail.")
1617 (home-page "https://github.com/adammck/minitest-pretty_diff")
1618 (license license:expat))))
1619
685d0d2f
BW
1620(define-public ruby-minitest-moar
1621 (package
1622 (name "ruby-minitest-moar")
1623 (version "0.0.4")
1624 (source
1625 (origin
1626 (method url-fetch)
1627 (uri (rubygems-uri "minitest-moar" version))
1628 (sha256
1629 (base32
1630 "0nb83blrsab92gcy6nfpw39njys7zisia8pw4igzzfzfl51cis0x"))))
1631 (build-system ruby-build-system)
1632 (arguments
1633 `(#:phases
1634 (modify-phases %standard-phases
1635 (add-before 'check 'clean-dependencies
1636 (lambda _
1637 ;; Remove all gems defined in the Gemfile because these are not
1638 ;; truly needed.
1639 (substitute* "Gemfile"
1640 (("gem .*") ""))
1641 ;; Remove byebug as not needed to run tests.
1642 (substitute* "test/test_helper.rb"
1643 (("require 'byebug'") ""))
1644 #t)))))
1645 (native-inputs
1646 `(("bundler" ,bundler)
1647 ("ruby-minitest" ,ruby-minitest)))
1648 (synopsis "Extra features and changes to MiniTest")
1649 (description "@code{MiniTest Moar} add some additional features and
1650changes some default behaviours in MiniTest. For instance, Moar replaces the
1651MiniTest @code{Object#stub} with a global @code{stub} method.")
1652 (home-page "https://github.com/dockyard/minitest-moar")
1653 (license license:expat)))
1654
e07ef1d6
BW
1655(define-public ruby-minitest-bonus-assertions
1656 (package
1657 (name "ruby-minitest-bonus-assertions")
1658 (version "2.0")
1659 (source
1660 (origin
1661 (method url-fetch)
1662 (uri (rubygems-uri "minitest-bonus-assertions" version))
1663 (sha256
1664 (base32
1665 "11nrd32kwy61ndg9csk7l1ifya79ghrrv3vsrxj57k50m7na6jkm"))))
1666 (build-system ruby-build-system)
1667 (arguments
1668 `(#:phases
1669 (modify-phases %standard-phases
1670 (add-before 'check 'clean-dependencies
1671 (lambda _
1672 ;; Remove unneeded require statement that would entail another
1673 ;; dependency.
1674 (substitute* "test/minitest_config.rb"
1675 (("require 'minitest/bisect'") ""))
1676 #t)))))
1677 (native-inputs
1678 `(("ruby-hoe" ,ruby-hoe)
1679 ("ruby-minitest-pretty-diff" ,ruby-minitest-pretty-diff)
1680 ("ruby-minitest-focus" ,ruby-minitest-focus)
1681 ("ruby-minitest-moar" ,ruby-minitest-moar)))
1682 (synopsis "Bonus assertions for @code{Minitest}")
1683 (description
1684 "Minitest bonus assertions provides extra MiniTest assertions. For
1685instance, it provides @code{assert_true}, @code{assert_false} and
1686@code{assert_set_equal}.")
1687 (home-page "https://github.com/halostatue/minitest-bonus-assertions")
1688 (license license:expat)))
1689
e582fa93
BW
1690(define-public ruby-minitest-rg
1691 (package
1692 (name "ruby-minitest-rg")
1693 (version "5.2.0")
1694 (source
1695 (origin
1696 (method url-fetch)
1697 (uri (rubygems-uri "minitest-rg" version))
1698 (sha256
1699 (base32
1700 "0sq509ax1x62rd0w10b0hcydcxyk5bxxr3fwrgxv02r8drq2r354"))))
1701 (build-system ruby-build-system)
1702 (arguments
1703 ;; Some tests fail even outside Guix, so disable tests.
1704 ;; https://github.com/blowmage/minitest-rg/issues/12
1705 ;; https://github.com/blowmage/minitest-rg/pull/13
1706 `(#:tests? #f))
1707 (propagated-inputs
1708 `(("ruby-minitest" ,ruby-minitest)))
1709 (synopsis "Coloured output for Minitest")
1710 (description
1711 "@code{minitest-rg} changes the colour of the output from Minitest.")
1712 (home-page "http://blowmage.com/minitest-rg")
1713 (license license:expat)))
1714
afbbdf77
DT
1715(define-public ruby-daemons
1716 (package
1717 (name "ruby-daemons")
1718 (version "1.2.2")
1719 (source (origin
1720 (method url-fetch)
e83c6d00 1721 (uri (rubygems-uri "daemons" version))
afbbdf77
DT
1722 (sha256
1723 (base32
e83c6d00 1724 "121c7vkimg3baxga69xvdkwxiq8wkmxqvdbyqi5i82vhih5d3cn3"))))
afbbdf77
DT
1725 (build-system ruby-build-system)
1726 (arguments
1727 `(#:tests? #f)) ; no test suite
1728 (synopsis "Daemonize Ruby programs")
1729 (description "Daemons provides a way to wrap existing Ruby scripts to be
1730run as a daemon and to be controlled by simple start/stop/restart commands.")
1731 (home-page "https://github.com/thuehlinger/daemons")
1732 (license license:expat)))
66e20863
DT
1733
1734(define-public ruby-git
1735 (package
1736 (name "ruby-git")
1737 (version "1.2.9.1")
1738 (source (origin
1739 (method url-fetch)
e83c6d00 1740 (uri (rubygems-uri "git" version))
66e20863
DT
1741 (sha256
1742 (base32
e83c6d00 1743 "1sqfj8lmhl7c5zamcckkpik4izfph2zkv6krw0i8mzj5pdws5acs"))))
66e20863
DT
1744 (build-system ruby-build-system)
1745 (arguments
e83c6d00
DT
1746 `(#:tests? #f ; no tests
1747 #:phases (modify-phases %standard-phases
1748 (add-after 'install 'patch-git-binary
1749 (lambda* (#:key inputs outputs #:allow-other-keys)
66e20863
DT
1750 ;; Make the default git binary an absolute path to the
1751 ;; store.
e83c6d00
DT
1752 (let ((git (string-append (assoc-ref inputs "git")
1753 "/bin/git"))
1754 (config (string-append (getenv "GEM_HOME")
1755 "/gems/git-" ,version
1756 "/lib/git/config.rb")))
1757 (substitute* (list config)
66e20863
DT
1758 (("'git'")
1759 (string-append "'" git "'")))
e83c6d00 1760 #t))))))
66e20863
DT
1761 (inputs
1762 `(("git" ,git)))
1763 (synopsis "Ruby wrappers for Git")
1764 (description "Ruby/Git is a Ruby library that can be used to create, read
1765and manipulate Git repositories by wrapping system calls to the git binary.")
1766 (home-page "https://github.com/schacon/ruby-git")
1767 (license license:expat)))
71d3e2c2
DT
1768
1769(define-public ruby-slop
1770 (package
1771 (name "ruby-slop")
1772 (version "4.1.0")
1773 (source (origin
1774 (method url-fetch)
e83c6d00 1775 (uri (rubygems-uri "slop" version))
71d3e2c2
DT
1776 (sha256
1777 (base32
e83c6d00 1778 "0dj0ps6v1mqd02k84mgwd7hp578n2bzl7c51h3grdhxfl3jkfsj5"))))
71d3e2c2
DT
1779 (build-system ruby-build-system)
1780 (native-inputs
1781 `(("ruby-minitest" ,ruby-minitest)))
1782 (synopsis "Ruby command line option parser")
1783 (description "Slop provides a Ruby domain specific language for gathering
1784options and parsing command line flags.")
1785 (home-page "https://github.com/leejarvis/slop")
1786 (license license:expat)))
e778a549 1787
5337f8b9
DT
1788(define-public ruby-slop-3
1789 (package (inherit ruby-slop)
1790 (version "3.6.0")
1791 (source (origin
1792 (method url-fetch)
1793 (uri (rubygems-uri "slop" version))
1794 (sha256
1795 (base32
1796 "00w8g3j7k7kl8ri2cf1m58ckxk8rn350gp4chfscmgv6pq1spk3n"))))))
1797
e778a549
DT
1798(define-public ruby-multipart-post
1799 (package
1800 (name "ruby-multipart-post")
1801 (version "2.0.0")
1802 (source (origin
1803 (method url-fetch)
e83c6d00 1804 (uri (rubygems-uri "multipart-post" version))
e778a549
DT
1805 (sha256
1806 (base32
e83c6d00 1807 "09k0b3cybqilk1gwrwwain95rdypixb2q9w65gd44gfzsd84xi1x"))))
e778a549
DT
1808 (build-system ruby-build-system)
1809 (native-inputs
1810 `(("bundler" ,bundler)))
1811 (synopsis "Multipart POST library for Ruby")
1812 (description "Multipart-Post Adds multipart POST capability to Ruby's
1813net/http library.")
1814 (home-page "https://github.com/nicksieger/multipart-post")
1815 (license license:expat)))
f8da3af0
DT
1816
1817(define-public ruby-arel
1818 (package
1819 (name "ruby-arel")
1820 (version "6.0.3")
1821 (source (origin
1822 (method url-fetch)
1823 (uri (rubygems-uri "arel" version))
1824 (sha256
1825 (base32
1826 "1a270mlajhrmpqbhxcqjqypnvgrq4pgixpv3w9gwp1wrrapnwrzk"))))
1827 (build-system ruby-build-system)
1828 (arguments '(#:tests? #f)) ; no tests
1829 (home-page "https://github.com/rails/arel")
1830 (synopsis "SQL AST manager for Ruby")
1831 (description "Arel is a SQL AST manager for Ruby. It simplifies the
1832generation of complex SQL queries and is compatible with various RDBMSes.")
1833 (license license:expat)))
616eaead
DT
1834
1835(define-public ruby-minitar
1836 (package
1837 (name "ruby-minitar")
1838 (version "0.5.4")
1839 (source
1840 (origin
1841 (method url-fetch)
1842 (uri (rubygems-uri "minitar" version))
1843 (sha256
1844 (base32
1845 "1vpdjfmdq1yc4i620frfp9af02ia435dnpj8ybsd7dc3rypkvbka"))))
1846 (build-system ruby-build-system)
1847 (arguments
1848 '(#:tests? #f)) ; missing a gemspec
1849 (synopsis "Ruby library and utility for handling tar archives")
1850 (description
1851 "Archive::Tar::Minitar is a pure-Ruby library and command-line utility
1852that provides the ability to deal with POSIX tar archive files.")
1853 (home-page "http://www.github.com/atoulme/minitar")
1854 (license (list license:gpl2+ license:ruby))))
bea1c0e2
DT
1855
1856(define-public ruby-mini-portile
1857 (package
1858 (name "ruby-mini-portile")
1859 (version "0.6.2")
1860 (source
1861 (origin
1862 (method url-fetch)
1863 (uri (rubygems-uri "mini_portile" version))
1864 (sha256
1865 (base32
1866 "0h3xinmacscrnkczq44s6pnhrp4nqma7k056x5wv5xixvf2wsq2w"))))
1867 (build-system ruby-build-system)
1868 (arguments
1869 '(#:tests? #f)) ; tests require network access
1870 (synopsis "Ports system for Ruby developers")
1871 (description "Mini-portile is a port/recipe system for Ruby developers.
1872It provides a standard way to compile against specific versions of libraries
1873to reproduce user environments.")
1874 (home-page "http://github.com/flavorjones/mini_portile")
1875 (license license:expat)))
e920bfca 1876
d000fc92
BW
1877(define-public ruby-mini-portile-2
1878 (package (inherit ruby-mini-portile)
1879 (version "2.0.0")
1880 (source (origin
1881 (method url-fetch)
1882 (uri (rubygems-uri "mini_portile2" version))
1883 (sha256
1884 (base32
1885 "056drbn5m4khdxly1asmiik14nyllswr6sh3wallvsywwdiryz8l"))))))
1886
e920bfca
DT
1887(define-public ruby-nokogiri
1888 (package
1889 (name "ruby-nokogiri")
1b9d4e2e 1890 (version "1.6.7.1")
e920bfca
DT
1891 (source (origin
1892 (method url-fetch)
1893 (uri (rubygems-uri "nokogiri" version))
1894 (sha256
1895 (base32
1b9d4e2e 1896 "12nwv3lad5k2k73aa1d1xy4x577c143ixks6rs70yp78sinbglk2"))))
e920bfca
DT
1897 (build-system ruby-build-system)
1898 (arguments
1899 ;; Tests fail because Nokogiri can only test with an installed extension,
1900 ;; and also because many test framework dependencies are missing.
1901 '(#:tests? #f
1902 #:gem-flags (list "--" "--use-system-libraries"
1903 (string-append "--with-xml2-include="
1904 (assoc-ref %build-inputs "libxml2")
1905 "/include/libxml2" ))))
1906 (native-inputs
1907 `(("ruby-hoe" ,ruby-hoe)
1908 ("ruby-rake-compiler", ruby-rake-compiler)))
1909 (inputs
1910 `(("zlib" ,zlib)
1911 ("libxml2" ,libxml2)
1912 ("libxslt" ,libxslt)))
1913 (propagated-inputs
1b9d4e2e 1914 `(("ruby-mini-portile" ,ruby-mini-portile-2)))
e920bfca
DT
1915 (synopsis "HTML, XML, SAX, and Reader parser for Ruby")
1916 (description "Nokogiri (鋸) parses and searches XML/HTML, and features
1917both CSS3 selector and XPath 1.0 support.")
1918 (home-page "http://www.nokogiri.org/")
1919 (license license:expat)))
30b0b725
DT
1920
1921(define-public ruby-method-source
1922 (package
1923 (name "ruby-method-source")
1924 (version "0.8.2")
1925 (source
1926 (origin
1927 (method url-fetch)
1928 (uri (rubygems-uri "method_source" version))
1929 (sha256
1930 (base32
1931 "1g5i4w0dmlhzd18dijlqw5gk27bv6dj2kziqzrzb7mpgxgsd1sf2"))))
1932 (build-system ruby-build-system)
1933 (native-inputs
1934 `(("ruby-bacon" ,ruby-bacon)
1935 ("git" ,git)))
1936 (synopsis "Retrieve the source code for Ruby methods")
1937 (description "Method_source retrieves the source code for Ruby methods.
1938Additionally, it can extract source code from Proc and Lambda objects or just
1939extract comments.")
1940 (home-page "https://github.com/banister/method_source")
1941 (license license:expat)))
2e3fdea4
DT
1942
1943(define-public ruby-coderay
1944 (package
1945 (name "ruby-coderay")
1946 (version "1.1.0")
1947 (source
1948 (origin
1949 (method url-fetch)
1950 (uri (rubygems-uri "coderay" version))
1951 (sha256
1952 (base32
1953 "059wkzlap2jlkhg460pkwc1ay4v4clsmg1bp4vfzjzkgwdckr52s"))))
1954 (build-system ruby-build-system)
1955 (arguments
1956 '(#:tests? #f)) ; missing test files
1957 (synopsis "Ruby syntax highlighting library")
1958 (description "Coderay is a Ruby library that provides syntax highlighting
1959for select languages.")
1960 (home-page "http://coderay.rubychan.de")
1961 (license license:expat)))
96e76083
DT
1962
1963(define-public ruby-pry
1964 (package
1965 (name "ruby-pry")
1966 (version "0.10.1")
1967 (source
1968 (origin
1969 (method url-fetch)
1970 (uri (rubygems-uri "pry" version))
1971 (sha256
1972 (base32
1973 "1j0r5fm0wvdwzbh6d6apnp7c0n150hpm9zxpm5xvcgfqr36jaj8z"))))
1974 (build-system ruby-build-system)
1975 (arguments
1976 '(#:tests? #f)) ; no tests
1977 (propagated-inputs
1978 `(("ruby-coderay" ,ruby-coderay)
1979 ("ruby-method-source" ,ruby-method-source)
1980 ("ruby-slop" ,ruby-slop-3)))
1981 (synopsis "Ruby REPL")
1982 (description "Pry is an IRB alternative and runtime developer console for
1983Ruby. It features syntax highlighting, a plugin architecture, runtime
1984invocation, and source and documentation browsing.")
1985 (home-page "http://pryrepl.org")
1986 (license license:expat)))
1415792a 1987
051deeb7
RW
1988(define-public ruby-guard
1989 (package
1990 (name "ruby-guard")
1991 (version "2.13.0")
1992 (source (origin
1993 (method url-fetch)
1994 ;; The gem does not include a Rakefile, nor does it contain a
1995 ;; gemspec file, nor does it come with the tests. This is why
1996 ;; we fetch the tarball from Github.
1997 (uri (string-append "https://github.com/guard/guard/archive/v"
1998 version ".tar.gz"))
1999 (file-name (string-append name "-" version ".tar.gz"))
2000 (sha256
2001 (base32
2002 "1hwj0yi17k6f5axrm0k2bb7fq71dlp0zfywmd7pij9iimbppcca0"))))
2003 (build-system ruby-build-system)
2004 (arguments
2005 `(#:tests? #f ; tests require cucumber
2006 #:phases
2007 (modify-phases %standard-phases
2008 (add-after 'unpack 'remove-git-ls-files
2009 (lambda* (#:key outputs #:allow-other-keys)
2010 (substitute* "guard.gemspec"
2011 (("git ls-files -z") "find . -type f -print0"))
2012 #t))
2013 (replace 'build
2014 (lambda _
2015 (zero? (system* "gem" "build" "guard.gemspec")))))))
2016 (propagated-inputs
2017 `(("ruby-formatador" ,ruby-formatador)
2018 ("ruby-listen" ,ruby-listen)
2019 ("ruby-lumberjack" ,ruby-lumberjack)
2020 ("ruby-nenv" ,ruby-nenv)
2021 ("ruby-notiffany" ,ruby-notiffany)
2022 ("ruby-pry" ,ruby-pry)
2023 ("ruby-shellany" ,ruby-shellany)
2024 ("ruby-thor" ,ruby-thor)))
2025 (native-inputs
2026 `(("bundler" ,bundler)
2027 ("ruby-rspec" ,ruby-rspec)))
2028 (synopsis "Tool to handle events on file system modifications")
2029 (description
2030 "Guard is a command line tool to easily handle events on file system
2031modifications. Guard automates various tasks by running custom rules whenever
2032file or directories are modified.")
2033 (home-page "http://guardgem.org/")
2034 (license license:expat)))
2035
1415792a
DT
2036(define-public ruby-thread-safe
2037 (package
2038 (name "ruby-thread-safe")
2039 (version "0.3.5")
2040 (source
2041 (origin
2042 (method url-fetch)
2043 (uri (rubygems-uri "thread_safe" version))
2044 (sha256
2045 (base32
2046 "1hq46wqsyylx5afkp6jmcihdpv4ynzzq9ygb6z2pb1cbz5js0gcr"))))
2047 (build-system ruby-build-system)
2048 (arguments
2049 '(#:tests? #f)) ; needs simplecov, among others
2050 (synopsis "Thread-safe utilities for Ruby")
2051 (description "The thread_safe library provides thread-safe collections and
2052utilities for Ruby.")
2053 (home-page "https://github.com/ruby-concurrency/thread_safe")
2054 (license license:asl2.0)))
08a1b701
DT
2055
2056(define-public ruby-tzinfo
2057 (package
2058 (name "ruby-tzinfo")
2059 (version "1.2.2")
2060 (source
2061 (origin
2062 (method url-fetch)
2063 (uri (rubygems-uri "tzinfo" version))
2064 (sha256
2065 (base32
2066 "1c01p3kg6xvy1cgjnzdfq45fggbwish8krd0h864jvbpybyx7cgx"))))
2067 (build-system ruby-build-system)
2068 (propagated-inputs
2069 `(("ruby-thread-safe" ,ruby-thread-safe)))
2070 (synopsis "Time zone library for Ruby")
2071 (description "TZInfo is a Ruby library that provides daylight savings
2072aware transformations between times in different time zones.")
2073 (home-page "http://tzinfo.github.io")
2074 (license license:expat)))
c99e2247 2075
48e6851f
RW
2076(define-public ruby-rb-inotify
2077 (package
2078 (name "ruby-rb-inotify")
2079 (version "0.9.5")
2080 (source
2081 (origin
2082 (method url-fetch)
2083 (uri (rubygems-uri "rb-inotify" version))
2084 (sha256
2085 (base32
2086 "0kddx2ia0qylw3r52nhg83irkaclvrncgy2m1ywpbhlhsz1rymb9"))))
2087 (build-system ruby-build-system)
2088 (arguments
2089 '(#:tests? #f ; there are no tests
2090 #:phases
2091 (modify-phases %standard-phases
2092 ;; Building the gemspec with rake is not working here since it is
2093 ;; generated with Jeweler. It is also unnecessary because the
2094 ;; existing gemspec does not use any development tools to generate a
2095 ;; list of files.
2096 (replace 'build
2097 (lambda _
2098 (zero? (system* "gem" "build" "rb-inotify.gemspec")))))))
2099 (propagated-inputs
2100 `(("ruby-ffi" ,ruby-ffi)))
2101 (native-inputs
2102 `(("ruby-yard" ,ruby-yard)))
2103 (synopsis "Ruby wrapper for Linux's inotify")
2104 (description "rb-inotify is a simple wrapper over the @code{inotify} Linux
2105kernel subsystem for monitoring changes to files and directories.")
2106 (home-page "https://github.com/nex3/rb-inotify")
2107 (license license:expat)))
2108
a75bdfce
RW
2109(define-public ruby-pry-editline
2110 (package
2111 (name "ruby-pry-editline")
2112 (version "1.1.2")
2113 (source (origin
2114 (method url-fetch)
2115 (uri (rubygems-uri "pry-editline" version))
2116 (sha256
2117 (base32
2118 "1pjxyvdxvw41xw3yyl18pwzix8hbvn6lgics7qcfhjfsf1zs8x1z"))))
2119 (build-system ruby-build-system)
2120 (arguments `(#:tests? #f)) ; no tests included
2121 (native-inputs
2122 `(("bundler" ,bundler)))
2123 (synopsis "Open the current REPL line in an editor")
2124 (description
2125 "This gem provides a plugin for the Ruby REPL to enable opening the
2126current line in an external editor.")
2127 (home-page "https://github.com/tpope/pry-editline")
2128 (license license:expat)))
2129
d3b20a02
RW
2130(define-public ruby-sdoc
2131 (package
2132 (name "ruby-sdoc")
2133 (version "0.4.1")
2134 (source (origin
2135 (method url-fetch)
2136 (uri (rubygems-uri "sdoc" version))
2137 (sha256
2138 (base32
2139 "16xyfair1j4irfkd6sxvmdcak957z71lwkvhglrznfpkalfnqyqp"))))
2140 (build-system ruby-build-system)
2141 (arguments
2142 `(#:phases
2143 (modify-phases %standard-phases
2144 (add-after 'build 'relax-minitest-requirement
2145 (lambda _
2146 (substitute* "sdoc.gemspec"
2147 (("<minitest>, \\[\"~> 4\\.0\"\\]")
2148 "<minitest>, [\">= 4.0\"]"))
2149 #t)))))
2150 (propagated-inputs
2151 `(("ruby-json" ,ruby-json)))
2152 (native-inputs
2153 `(("bundler" ,bundler)
2154 ("ruby-minitest" ,ruby-minitest)))
2155 (synopsis "Generate searchable RDoc documentation")
2156 (description
2157 "SDoc is an RDoc documentation generator to build searchable HTML
2158documentation for Ruby code.")
2159 (home-page "http://github.com/voloko/sdoc")
2160 (license license:expat)))
2161
70b002aa
RW
2162(define-public ruby-tins
2163 (package
2164 (name "ruby-tins")
2165 (version "1.7.0")
2166 (source (origin
2167 (method url-fetch)
2168 (uri (rubygems-uri "tins" version))
2169 (sha256
2170 (base32
2171 "1060h8dgnjl9az0sv1b74yrni8d4mh3x858wq6yfbfdf5dxrfl0a"))))
2172 (build-system ruby-build-system)
2173 ;; This gem needs gem-hadar at development time, but gem-hadar needs tins
2174 ;; at runtime. To avoid the dependency on gem-hadar we disable rebuilding
2175 ;; the gemspec.
2176 (arguments
2177 `(#:tests? #f ; there are no tests
2178 #:phases
2179 (modify-phases %standard-phases
2180 (replace 'build
2181 (lambda _
2182 ;; "lib/spruz" is a symlink. Leaving it in the gemspec file
2183 ;; causes an error.
2184 (substitute* "tins.gemspec"
2185 (("\"lib/spruz\", ") ""))
2186 (zero? (system* "gem" "build" "tins.gemspec")))))))
2187 (synopsis "Assorted tools for Ruby")
2188 (description "Tins is a Ruby library providing assorted tools.")
2189 (home-page "https://github.com/flori/tins")
2190 (license license:expat)))
2191
bc8277e4
RW
2192(define-public ruby-gem-hadar
2193 (package
2194 (name "ruby-gem-hadar")
2195 (version "1.3.1")
2196 (source (origin
2197 (method url-fetch)
2198 (uri (rubygems-uri "gem_hadar" version))
2199 (sha256
2200 (base32
2201 "1j8qri4m9wf8nbfv0kakrgsv2x8vg10914xgm6f69nw8zi3i39ws"))))
2202 (build-system ruby-build-system)
2203 ;; This gem needs itself at development time. We disable rebuilding of the
2204 ;; gemspec to avoid this loop.
2205 (arguments
2206 `(#:tests? #f ; there are no tests
2207 #:phases
2208 (modify-phases %standard-phases
2209 (replace 'build
2210 (lambda _
2211 (zero? (system* "gem" "build" "gem_hadar.gemspec")))))))
2212 (propagated-inputs
2213 `(("git" ,git)
2214 ("ruby-tins" ,ruby-tins)
2215 ("ruby-sdoc" ,ruby-sdoc)))
2216 (native-inputs
2217 `(("bundler" ,bundler)))
2218 (synopsis "Library for the development of Ruby gems")
2219 (description
2220 "This library contains some useful functionality to support the
2221development of Ruby gems.")
2222 (home-page "https://github.com/flori/gem_hadar")
2223 (license license:expat)))
2224
d8cafe29
RW
2225(define-public ruby-minitest-tu-shim
2226 (package
2227 (name "ruby-minitest-tu-shim")
2228 (version "1.3.3")
2229 (source (origin
2230 (method url-fetch)
2231 (uri (rubygems-uri "minitest_tu_shim" version))
2232 (sha256
2233 (base32
2234 "0xlyh94iirvssix157ng2akr9nqhdygdd0c6094hhv7dqcfrn9fn"))))
2235 (build-system ruby-build-system)
2236 (arguments
2237 `(#:phases
2238 (modify-phases %standard-phases
2239 (add-after 'unpack 'fix-test-include-path
2240 (lambda* (#:key inputs #:allow-other-keys)
761e7042
BW
2241 (let* ((minitest (assoc-ref inputs "ruby-minitest-4"))
2242 (minitest-home (gem-home minitest
2243 ,(package-version ruby))))
2244 (substitute* "Rakefile"
2245 (("Hoe\\.add_include_dirs .*")
2246 (string-append "Hoe.add_include_dirs \""
2247 minitest-home
2248 "/gems/minitest-"
2249 ,(package-version ruby-minitest-4)
2250 "/lib" "\""))))
2251 #t))
d8cafe29
RW
2252 (add-before 'check 'fix-test-assumptions
2253 (lambda _
2254 ;; The test output includes the file name, so a couple of tests
2255 ;; fail. Changing the regular expressions slightly fixes this
2256 ;; problem.
2257 (substitute* "test/test_mini_test.rb"
2258 (("output.sub!\\(.*, 'FILE:LINE'\\)")
2259 "output.sub!(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')")
2260 (("gsub\\(/.*, 'FILE:LINE'\\)")
2261 "gsub(/\\/.+-[\\w\\/\\.]+:\\d+/, 'FILE:LINE')"))
2262 #t)))))
2263 (propagated-inputs
2264 `(("ruby-minitest-4" ,ruby-minitest-4)))
2265 (native-inputs
2266 `(("ruby-hoe" ,ruby-hoe)))
2267 (synopsis "Adapter library between minitest and test/unit")
2268 (description
2269 "This library bridges the gap between the small and fast minitest and
2270Ruby's large and slower test/unit.")
2271 (home-page "https://rubygems.org/gems/minitest_tu_shim")
2272 (license license:expat)))
2273
fd83a212
RW
2274(define-public ruby-term-ansicolor
2275 (package
2276 (name "ruby-term-ansicolor")
2277 (version "1.3.2")
2278 (source (origin
2279 (method url-fetch)
2280 (uri (rubygems-uri "term-ansicolor" version))
2281 (sha256
2282 (base32
2283 "0ydbbyjmk5p7fsi55ffnkq79jnfqx65c3nj8d9rpgl6sw85ahyys"))))
2284 (build-system ruby-build-system)
2285 ;; Rebuilding the gemspec seems to require git, even though this is not a
2286 ;; git repository, so we just build the gem from the existing gemspec.
2287 (arguments
2288 `(#:phases
2289 (modify-phases %standard-phases
2290 (replace 'build
2291 (lambda _
2292 (zero? (system* "gem" "build" "term-ansicolor.gemspec")))))))
2293 (propagated-inputs
2294 `(("ruby-tins" ,ruby-tins)))
2295 (native-inputs
2296 `(("ruby-gem-hadar" ,ruby-gem-hadar)
2297 ("ruby-minitest-tu-shim" ,ruby-minitest-tu-shim)))
2298 (synopsis "Ruby library to control the attributes of terminal output")
2299 (description
2300 "This Ruby library uses ANSI escape sequences to control the attributes
2301of terminal output.")
2302 (home-page "http://flori.github.io/term-ansicolor/")
2303 ;; There is no mention of the "or later" clause.
2304 (license license:gpl2)))
2305
6e376ca4
RW
2306(define-public ruby-pstree
2307 (package
2308 (name "ruby-pstree")
2309 (version "0.1.0")
2310 (source (origin
2311 (method url-fetch)
2312 (uri (rubygems-uri "pstree" version))
2313 (sha256
2314 (base32
2315 "1mig1sv5qx1cdyhjaipy8jlh9j8pnja04vprrzihyfr54x0215p1"))))
2316 (build-system ruby-build-system)
2317 (native-inputs
2318 `(("ruby-gem-hadar" ,ruby-gem-hadar)
2319 ("bundler" ,bundler)))
2320 (synopsis "Create a process tree data structure")
2321 (description
2322 "This library uses the output of the @code{ps} command to create a
2323process tree data structure for the current host.")
2324 (home-page "http://flori.github.com/pstree")
2325 ;; There is no mention of the "or later" clause.
2326 (license license:gpl2)))
2327
53239b5f
RW
2328(define-public ruby-utils
2329 (package
2330 (name "ruby-utils")
2331 (version "0.2.4")
2332 (source (origin
2333 (method url-fetch)
2334 (uri (rubygems-uri "utils" version))
2335 (sha256
2336 (base32
2337 "0vycgscxf3s1xn4yyfsq54zlh082581ga8azybmqgc4pij6iz2cd"))))
2338 (build-system ruby-build-system)
2339 (propagated-inputs
2340 `(("ruby-tins" ,ruby-tins)
2341 ("ruby-term-ansicolor" ,ruby-term-ansicolor)
2342 ("ruby-pstree" ,ruby-pstree)
2343 ("ruby-pry-editline" ,ruby-pry-editline)))
2344 (native-inputs
2345 `(("ruby-gem-hadar" ,ruby-gem-hadar)
2346 ("bundler" ,bundler)))
2347 (synopsis "Command line tools for working with Ruby")
2348 (description
2349 "This package provides assorted command line tools that may be useful
2350when working with Ruby code.")
2351 (home-page "https://github.com/flori/utils")
2352 ;; There is no mention of the "or later" clause.
2353 (license license:gpl2)))
2354
c99e2247
DT
2355(define-public ruby-json
2356 (package
2357 (name "ruby-json")
2358 (version "1.8.3")
2359 (source
2360 (origin
2361 (method url-fetch)
2362 (uri (rubygems-uri "json" version))
2363 (sha256
2364 (base32
2365 "1nsby6ry8l9xg3yw4adlhk2pnc7i0h0rznvcss4vk3v74qg0k8lc"))))
2366 (build-system ruby-build-system)
2367 (arguments '(#:tests? #f)) ; dependency cycle with sdoc
2368 (synopsis "JSON library for Ruby")
2369 (description "This Ruby library provides a JSON implementation written as
2370a native C extension.")
2371 (home-page "http://json-jruby.rubyforge.org/")
2372 (license (list license:ruby license:gpl2)))) ; GPL2 only
5ff89a1b 2373
763624f5
RW
2374(define-public ruby-json-pure
2375 (package
2376 (name "ruby-json-pure")
2377 (version "1.8.3")
2378 (source (origin
2379 (method url-fetch)
2380 (uri (rubygems-uri "json_pure" version))
2381 (sha256
2382 (base32
2383 "025aykr360x6dr1jmg8pmsrx7gr30pws4p1q686vnb48zyw1sc94"))))
2384 (build-system ruby-build-system)
2385 (arguments
2386 `(#:modules ((srfi srfi-1)
2387 (ice-9 regex)
2388 (rnrs io ports)
2389 (guix build ruby-build-system)
2390 (guix build utils))
2391 #:phases
2392 (modify-phases %standard-phases
2393 (add-after 'unpack 'replace-git-ls-files
2394 (lambda _
2395 ;; The existing gemspec file already contains a nice list of
2396 ;; files that belong to the gem. We extract the list from the
2397 ;; gemspec file and then replace the file list in the Rakefile to
2398 ;; get rid of the call to "git ls-files".
2399 (let* ((contents (call-with-input-file "json.gemspec" get-string-all))
2400 ;; Guile is unhappy about the #\nul characters in comments.
2401 (filtered (string-filter (lambda (char)
2402 (not (equal? #\nul char)))
2403 contents))
2404 (files (match:substring
2405 (string-match " s\\.files = ([^]]+\\])" filtered) 1)))
2406 (substitute* "Rakefile"
2407 (("FileList\\[`git ls-files`\\.split\\(/\\\\n/\\)\\]")
2408 (string-append "FileList" files))))
2409 #t)))))
2410 (native-inputs
2411 `(("ruby-permutation" ,ruby-permutation)
2412 ("ruby-utils" ,ruby-utils)
2413 ("ragel" ,ragel)
2414 ("bundler" ,bundler)))
2415 (synopsis "JSON implementation in pure Ruby")
2416 (description
2417 "This package provides a JSON implementation written in pure Ruby.")
2418 (home-page "http://flori.github.com/json")
2419 (license license:ruby)))
2420
16b324cd
RW
2421;; Even though this package only provides bindings for a Mac OSX API it is
2422;; required by "ruby-listen" at runtime.
2423(define-public ruby-rb-fsevent
2424 (package
2425 (name "ruby-rb-fsevent")
2426 (version "0.9.6")
2427 (source (origin
2428 (method url-fetch)
2429 (uri (rubygems-uri "rb-fsevent" version))
2430 (sha256
2431 (base32
2432 "1hq57by28iv0ijz8pk9ynih0xdg7vnl1010xjcijfklrcv89a1j2"))))
2433 (build-system ruby-build-system)
2434 ;; Tests need "guard-rspec", which needs "guard". However, "guard" needs
2435 ;; "listen", which needs "rb-fsevent" at runtime.
2436 (arguments `(#:tests? #f))
2437 (synopsis "FSEvents API with signals catching")
2438 (description
2439 "This library provides Ruby bindings for the Mac OSX FSEvents API.")
2440 (home-page "https://rubygems.org/gems/rb-fsevent")
2441 (license license:expat)))
2442
b86be2ad
RW
2443(define-public ruby-listen
2444 (package
2445 (name "ruby-listen")
2446 (version "3.0.3")
2447 (source
2448 (origin
2449 (method url-fetch)
2450 (uri (rubygems-uri "listen" version))
2451 (sha256
2452 (base32
2453 "10lhshjklxlrkw7999j0xl6sdxd4x32kiy8rp88jwr68kis5vq2b"))))
2454 (build-system ruby-build-system)
2455 (arguments '(#:tests? #f)) ; no tests
2456 (propagated-inputs
cf1a01f4
RW
2457 `(("ruby-rb-inotify" ,ruby-rb-inotify)
2458 ("ruby-rb-fsevent" ,ruby-rb-fsevent)))
b86be2ad
RW
2459 (synopsis "Listen to file modifications")
2460 (description "The Listen gem listens to file modifications and notifies
2461you about the changes.")
2462 (home-page "https://github.com/guard/listen")
2463 (license license:expat)))
2464
5ff89a1b
DT
2465(define-public ruby-activesupport
2466 (package
2467 (name "ruby-activesupport")
2468 (version "4.2.4")
2469 (source
2470 (origin
2471 (method url-fetch)
2472 (uri (rubygems-uri "activesupport" version))
2473 (sha256
2474 (base32
2475 "19n38rj6r1gyxgka18qvcxyla0fwan8a5p3ghq0pp8aj93sbmr6f"))))
2476 (build-system ruby-build-system)
2477 (arguments
2478 '(#:tests? #f)) ; no tests
2479 (propagated-inputs
2480 `(("ruby-i18n" ,ruby-i18n)
2481 ("ruby-json" ,ruby-json)
2482 ("ruby-minitest" ,ruby-minitest)
2483 ("ruby-thread-safe" ,ruby-thread-safe)
2484 ("ruby-tzinfo" ,ruby-tzinfo)))
2485 (synopsis "Ruby on Rails utility library")
2486 (description "ActiveSupport is a toolkit of support libraries and Ruby
2487core extensions extracted from the Rails framework. It includes support for
2488multibyte strings, internationalization, time zones, and testing.")
2489 (home-page "http://www.rubyonrails.org")
2490 (license license:expat)))
f847ad7b 2491
3996f0aa
RW
2492(define-public ruby-crass
2493 (package
2494 (name "ruby-crass")
2495 (version "1.0.2")
2496 (source (origin
2497 (method url-fetch)
2498 (uri (rubygems-uri "crass" version))
2499 (sha256
2500 (base32
2501 "1c377r8g7m58y22803iyjgqkkvnnii0pymskda1pardxrzaighj9"))))
2502 (build-system ruby-build-system)
2503 (native-inputs
2504 `(("bundler" ,bundler)
2505 ("ruby-minitest" ,ruby-minitest)))
2506 (synopsis "Pure Ruby CSS parser")
2507 (description
2508 "Crass is a pure Ruby CSS parser based on the CSS Syntax Level 3 spec.")
2509 (home-page "https://github.com/rgrove/crass/")
2510 (license license:expat)))
2511
c2c4e5b2
RW
2512(define-public ruby-nokogumbo
2513 (package
2514 (name "ruby-nokogumbo")
2515 (version "1.4.6")
2516 (source (origin
2517 ;; We use the git reference, because there's no Rakefile in the
2518 ;; published gem and the tarball on Github is outdated.
2519 (method git-fetch)
2520 (uri (git-reference
2521 (url "https://github.com/rubys/nokogumbo.git")
2522 (commit "d56f954d20a")))
2523 (file-name (string-append name "-" version "-checkout"))
2524 (sha256
2525 (base32
2526 "0bnppjy96xiadrsrc9dp8y6wvdwnkfa930n7acrp0mqm4qywl2wl"))))
2527 (build-system ruby-build-system)
2528 (arguments
2529 `(#:modules ((guix build ruby-build-system)
2530 (guix build utils)
2531 (ice-9 rdelim))
2532 #:phases
2533 (modify-phases %standard-phases
2534 (add-before 'build 'build-gemspec
2535 (lambda _
2536 (substitute* "Rakefile"
2537 ;; Build Makefile even without a copy of gumbo-parser sources
2538 (("'gumbo-parser/src',") "")
2539 ;; We don't bundle gumbo-parser sources
2540 (("'gumbo-parser/src/\\*',") "")
2541 (("'gumbo-parser/visualc/include/\\*',") "")
2542 ;; The definition of SOURCES will be cut in gemspec, and
2543 ;; "FileList" will be undefined.
2544 (("SOURCES \\+ FileList\\[")
2545 "['ext/nokogumboc/extconf.rb', 'ext/nokogumboc/nokogumbo.c', "))
2546
2547 ;; Copy the Rakefile and cut out the gemspec.
2548 (copy-file "Rakefile" ".gemspec")
2549 (with-atomic-file-replacement ".gemspec"
2550 (lambda (in out)
2551 (let loop ((line (read-line in 'concat))
2552 (skipping? #t))
2553 (if (eof-object? line)
2554 #t
2555 (let ((skip-next? (if skipping?
2556 (not (string-prefix? "SPEC =" line))
2557 (string-prefix? "end" line))))
2558 (when (or (not skipping?)
2559 (and skipping? (not skip-next?)))
2560 (format #t "~a" line)
2561 (display line out))
2562 (loop (read-line in 'concat) skip-next?))))))
2563 #t)))))
2564 (inputs
2565 `(("gumbo-parser" ,gumbo-parser)))
2566 (propagated-inputs
2567 `(("ruby-nokogiri" ,ruby-nokogiri)))
2568 (synopsis "Ruby bindings to the Gumbo HTML5 parser")
2569 (description
2570 "Nokogumbo allows a Ruby program to invoke the Gumbo HTML5 parser and
2571access the result as a Nokogiri parsed document.")
2572 (home-page "https://github.com/rubys/nokogumbo/")
2573 (license license:asl2.0)))
2574
d56ff88b
RW
2575(define-public ruby-sanitize
2576 (package
2577 (name "ruby-sanitize")
2578 (version "4.0.0")
2579 (source (origin
2580 (method url-fetch)
2581 ;; The gem does not include the Rakefile, so we download the
2582 ;; release tarball from Github.
2583 (uri (string-append "https://github.com/rgrove/"
2584 "sanitize/archive/v" version ".tar.gz"))
2585 (file-name (string-append name "-" version ".tar.gz"))
2586 (sha256
2587 (base32
2588 "055xnj38l60gxnnng76kpy2l2jbrp0byjdyq17jw79w7l4b40znr"))))
2589 (build-system ruby-build-system)
2590 (propagated-inputs
2591 `(("ruby-crass" ,ruby-crass)
2592 ("ruby-nokogiri" ,ruby-nokogiri)
2593 ("ruby-nokogumbo" ,ruby-nokogumbo)))
2594 (native-inputs
2595 `(("bundler" ,bundler)
2596 ("ruby-minitest" ,ruby-minitest)
2597 ("ruby-redcarpet" ,ruby-redcarpet)
2598 ("ruby-yard" ,ruby-yard)))
2599 (synopsis "Whitelist-based HTML and CSS sanitizer")
2600 (description
2601 "Sanitize is a whitelist-based HTML and CSS sanitizer. Given a list of
2602acceptable elements, attributes, and CSS properties, Sanitize will remove all
2603unacceptable HTML and/or CSS from a string.")
2604 (home-page "https://github.com/rgrove/sanitize/")
2605 (license license:expat)))
2606
f847ad7b
DT
2607(define-public ruby-ox
2608 (package
2609 (name "ruby-ox")
2610 (version "2.2.1")
2611 (source
2612 (origin
2613 (method url-fetch)
2614 (uri (rubygems-uri "ox" version))
2615 (sha256
2616 (base32
2617 "00i11xd4ayh7349rhgskajfxn0qzkb74ab01217zix9qcapssxax"))))
2618 (build-system ruby-build-system)
2619 (arguments
2620 '(#:tests? #f)) ; no tests
2621 (synopsis "Optimized XML library for Ruby")
2622 (description
2623 "Optimized XML (Ox) is a fast XML parser and object serializer for Ruby
2624written as a native C extension. It was designed to be an alternative to
2625Nokogiri and other Ruby XML parsers for generic XML parsing and as an
2626alternative to Marshal for Object serialization. ")
2627 (home-page "http://www.ohler.com/ox")
2628 (license license:expat)))
4a9e0585 2629
0c4e7625
RW
2630(define-public ruby-redcloth
2631 (package
2632 (name "ruby-redcloth")
2633 (version "4.2.9")
2634 (source (origin
2635 (method url-fetch)
2636 (uri (rubygems-uri "RedCloth" version))
2637 (sha256
2638 (base32
2639 "06pahxyrckhgb7alsxwhhlx1ib2xsx33793finj01jk8i054bkxl"))))
2640 (build-system ruby-build-system)
2641 (arguments
2642 `(#:tests? #f ; no tests
2643 #:phases
2644 (modify-phases %standard-phases
2645 ;; Redcloth has complicated rake tasks to build various versions for
2646 ;; multiple targets using RVM. We don't want this so we just use the
2647 ;; existing gemspec.
2648 (replace 'build
2649 (lambda _
2650 (zero? (system* "gem" "build" "redcloth.gemspec"))))
2651 ;; Make sure that the "redcloth" executable finds required Ruby
2652 ;; libraries.
2653 (add-after 'install 'wrap-bin-redcloth
2654 (lambda* (#:key outputs #:allow-other-keys)
2655 (wrap-program (string-append (assoc-ref outputs "out")
2656 "/bin/redcloth")
2657 `("GEM_HOME" ":" prefix (,(getenv "GEM_HOME"))))
2658 #t)))))
2659 (native-inputs
2660 `(("bundler" ,bundler)
2661 ("ruby-diff-lcs" ,ruby-diff-lcs)
2662 ("ruby-rspec-2" ,ruby-rspec-2)))
2663 (synopsis "Textile markup language parser for Ruby")
2664 (description
2665 "RedCloth is a Ruby parser for the Textile markup language.")
2666 (home-page "http://redcloth.org")
2667 (license license:expat)))
2668
4a9e0585
DT
2669(define-public ruby-pg
2670 (package
2671 (name "ruby-pg")
2672 (version "0.18.2")
2673 (source
2674 (origin
2675 (method url-fetch)
2676 (uri (rubygems-uri "pg" version))
2677 (sha256
2678 (base32
2679 "1axxbf6ij1iqi3i1r3asvjc80b0py5bz0m2wy5kdi5xkrpr82kpf"))))
2680 (build-system ruby-build-system)
2681 (arguments
2682 '(#:test-target "spec"))
2683 (native-inputs
2684 `(("ruby-rake-compiler" ,ruby-rake-compiler)
2685 ("ruby-hoe" ,ruby-hoe)
2686 ("ruby-rspec" ,ruby-rspec)))
2687 (inputs
2688 `(("postgresql" ,postgresql)))
2689 (synopsis "Ruby interface to PostgreSQL")
2690 (description "Pg is the Ruby interface to the PostgreSQL RDBMS. It works
2691with PostgreSQL 8.4 and later.")
2692 (home-page "https://bitbucket.org/ged/ruby-pg")
2693 (license license:ruby)))
468e5657
DT
2694
2695(define-public ruby-byebug
2696 (package
2697 (name "ruby-byebug")
2698 (version "6.0.2")
2699 (source
2700 (origin
2701 (method url-fetch)
2702 (uri (rubygems-uri "byebug" version))
2703 (sha256
2704 (base32
2705 "0537h9qbhr6csahmzyn4lk1g5b2lcligbzd21gfy93nx9lbfdnzc"))))
2706 (build-system ruby-build-system)
2707 (arguments
2708 '(#:tests? #f)) ; no tests
2709 (synopsis "Debugger for Ruby 2")
2710 (description "Byebug is a Ruby 2 debugger implemented using the Ruby 2
2711TracePoint C API for execution control and the Debug Inspector C API for call
2712stack navigation. The core component provides support that front-ends can
2713build on. It provides breakpoint handling and bindings for stack frames among
2714other things and it comes with a command line interface.")
2715 (home-page "http://github.com/deivid-rodriguez/byebug")
2716 (license license:bsd-2)))
64b6ccc3 2717
5799bc2b
RW
2718(define-public ruby-netrc
2719 (package
2720 (name "ruby-netrc")
2721 (version "0.11.0")
2722 (source (origin
2723 (method url-fetch)
2724 (uri (rubygems-uri "netrc" version))
2725 (sha256
2726 (base32
2727 "0gzfmcywp1da8nzfqsql2zqi648mfnx6qwkig3cv36n9m0yy676y"))))
2728 (build-system ruby-build-system)
2729 (arguments
2730 `(#:phases
2731 (modify-phases %standard-phases
2732 (replace 'check
2733 ;; There is no Rakefile and minitest can only run one file at once,
2734 ;; so we have to iterate over all test files.
2735 (lambda _
2736 (and (map (lambda (file)
2737 (zero? (system* "ruby" "-Itest" file)))
2738 (find-files "./test" "test_.*\\.rb"))))))))
2739 (native-inputs
2740 `(("ruby-minitest" ,ruby-minitest)))
2741 (synopsis "Library to read and update netrc files")
2742 (description
2743 "This library can read and update netrc files, preserving formatting
2744including comments and whitespace.")
2745 (home-page "https://github.com/geemus/netrc")
2746 (license license:expat)))
2747
3a6989ce
RW
2748(define-public ruby-unf-ext
2749 (package
2750 (name "ruby-unf-ext")
2751 (version "0.0.7.1")
2752 (source (origin
2753 (method url-fetch)
2754 (uri (rubygems-uri "unf_ext" version))
2755 (sha256
2756 (base32
2757 "0ly2ms6c3irmbr1575ldyh52bz2v0lzzr2gagf0p526k12ld2n5b"))))
2758 (build-system ruby-build-system)
b809cc9a
RW
2759 (arguments
2760 `(#:phases
2761 (modify-phases %standard-phases
2762 (add-after 'build 'build-ext
2763 (lambda _ (zero? (system* "rake" "compile:unf_ext")))))))
3a6989ce
RW
2764 (native-inputs
2765 `(("bundler" ,bundler)
2766 ("ruby-rake-compiler" ,ruby-rake-compiler)
2767 ("ruby-test-unit" ,ruby-test-unit)))
2768 (synopsis "Unicode normalization form support library")
2769 (description
2770 "This package provides unicode normalization form support for Ruby.")
2771 (home-page "https://github.com/knu/ruby-unf_ext")
2772 (license license:expat)))
2773
2632a067
RW
2774(define-public ruby-tdiff
2775 (package
2776 (name "ruby-tdiff")
2777 (version "0.3.3")
2778 (source (origin
2779 (method url-fetch)
2780 (uri (rubygems-uri "tdiff" version))
2781 (sha256
2782 (base32
2783 "0k41jbvn8qq4mgrixnhlk742b971d136i8wpbcv2cczvi22xpc86"))))
2784 (build-system ruby-build-system)
2785 (native-inputs
2786 `(("ruby-rspec-2" ,ruby-rspec-2)
2787 ("ruby-yard" ,ruby-yard)
2788 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
2789 (synopsis "Calculate the differences between two tree-like structures")
2790 (description
2791 "This library provides functions to calculate the differences between two
2792tree-like structures. It is similar to Ruby's built-in @code{TSort} module.")
2793 (home-page "https://github.com/postmodern/tdiff")
2794 (license license:expat)))
2795
f60f5002
RW
2796(define-public ruby-nokogiri-diff
2797 (package
2798 (name "ruby-nokogiri-diff")
2799 (version "0.2.0")
2800 (source (origin
2801 (method url-fetch)
2802 (uri (rubygems-uri "nokogiri-diff" version))
2803 (sha256
2804 (base32
2805 "0njr1s42war0bj1axb2psjvk49l74a8wzr799wckqqdcb6n51lc1"))))
2806 (build-system ruby-build-system)
2807 (propagated-inputs
2808 `(("ruby-tdiff" ,ruby-tdiff)
2809 ("ruby-nokogiri" ,ruby-nokogiri)))
2810 (native-inputs
2811 `(("ruby-rspec-2" ,ruby-rspec-2)
2812 ("ruby-yard" ,ruby-yard)
2813 ("ruby-rubygems-tasks" ,ruby-rubygems-tasks)))
2814 (synopsis "Calculate the differences between two XML/HTML documents")
2815 (description
2816 "@code{Nokogiri::Diff} adds the ability to calculate the
2817differences (added or removed nodes) between two XML/HTML documents.")
2818 (home-page "https://github.com/postmodern/nokogiri-diff")
2819 (license license:expat)))
2820
64b6ccc3
DT
2821(define-public ruby-rack
2822 (package
2823 (name "ruby-rack")
2824 (version "1.6.4")
2825 (source
2826 (origin
2827 (method url-fetch)
2828 (uri (rubygems-uri "rack" version))
2829 (sha256
2830 (base32
2831 "09bs295yq6csjnkzj7ncj50i6chfxrhmzg1pk6p0vd2lb9ac8pj5"))))
2832 (build-system ruby-build-system)
2833 (arguments
2834 '(#:phases
2835 (modify-phases %standard-phases
2836 (add-before 'check 'fix-tests
2837 (lambda _
2838 ;; A few of the tests use the length of a file on disk for
2839 ;; Content-Length and Content-Range headers. However, this file
2840 ;; has a shebang in it which an earlier phase patches, growing
2841 ;; the file size from 193 to 239 bytes when the store prefix is
2842 ;; "/gnu/store".
2843 (let ((size-diff (- (string-length (which "ruby"))
2844 (string-length "/usr/bin/env ruby"))))
2845 (substitute* '("test/spec_file.rb")
2846 (("193")
2847 (number->string (+ 193 size-diff)))
2848 (("bytes(.)22-33" all delimiter)
2849 (string-append "bytes"
2850 delimiter
2851 (number->string (+ 22 size-diff))
2852 "-"
2853 (number->string (+ 33 size-diff))))))
2854 #t)))))
2855 (native-inputs
2856 `(("ruby-bacon" ,ruby-bacon)))
2857 (synopsis "Unified web application interface for Ruby")
2858 (description "Rack provides a minimal, modular and adaptable interface for
2859developing web applications in Ruby. By wrapping HTTP requests and responses,
2860it unifies the API for web servers, web frameworks, and software in between
2861into a single method call.")
2862 (home-page "http://rack.github.io/")
2863 (license license:expat)))
62e4cc5a 2864
6aaa815e
PP
2865(define-public ruby-docile
2866 (package
2867 (name "ruby-docile")
2868 (version "1.1.5")
2869 (source
2870 (origin
2871 (method url-fetch)
2872 (uri (rubygems-uri "docile" version))
2873 (sha256
2874 (base32
2875 "0m8j31whq7bm5ljgmsrlfkiqvacrw6iz9wq10r3gwrv5785y8gjx"))))
2876 (build-system ruby-build-system)
2877 (arguments
2878 '(#:tests? #f)) ; needs github-markup, among others
2879 (synopsis "Ruby EDSL helper library")
2880 (description "Docile is a Ruby library that provides an interface for
2881creating embedded domain specific languages (EDSLs) that manipulate existing
2882Ruby classes.")
2883 (home-page "https://ms-ati.github.io/docile/")
2884 (license license:expat)))
2885
62e4cc5a
PP
2886(define-public ruby-gherkin3
2887 (package
2888 (name "ruby-gherkin3")
2889 (version "3.1.1")
2890 (source
2891 (origin
2892 (method url-fetch)
2893 (uri (rubygems-uri "gherkin3" version))
2894 (sha256
2895 (base32
2896 "0xsyxhqa1gwcxzvsdy4didaiq5vam8ma3fbwbw2w60via4k6r1z9"))))
2897 (build-system ruby-build-system)
2898 (native-inputs
2899 `(("bundler" ,bundler)))
2900 (arguments
2901 '(#:tests? #f)) ; needs simplecov, among others
2902 (synopsis "Gherkin parser for Ruby")
2903 (description "Gherkin 3 is a parser and compiler for the Gherkin language.
2904It is intended to replace Gherkin 2 and be used by all Cucumber
2905implementations to parse '.feature' files.")
2906 (home-page "https://github.com/cucumber/gherkin3")
2907 (license license:expat)))
cd89fecb
PP
2908
2909(define-public ruby-cucumber-core
2910 (package
2911 (name "ruby-cucumber-core")
2912 (version "1.3.0")
2913 (source
2914 (origin
2915 (method url-fetch)
2916 (uri (rubygems-uri "cucumber-core" version))
2917 (sha256
2918 (base32
2919 "12mrzf0s96izpq0k10lahlkgwc4fjs0zfs344rh8r8h3w3jyppr8"))))
2920 (build-system ruby-build-system)
2921 (propagated-inputs
2922 `(("ruby-gherkin3" ,ruby-gherkin3)))
2923 (native-inputs
2924 `(("bundler" ,bundler)))
2925 (arguments
2926 '(#:tests? #f)) ; needs simplecov, among others
2927 (synopsis "Core library for the Cucumber BDD app")
2928 (description "Cucumber is a tool for running automated tests
2929written in plain language. Because they're written in plain language,
2930they can be read by anyone on your team. Because they can be read by
2931anyone, you can use them to help improve communication, collaboration
2932and trust on your team.")
2933 (home-page "https://cucumber.io/")
2934 (license license:expat)))
212d563d
PP
2935
2936(define-public ruby-bio-logger
2937 (package
2938 (name "ruby-bio-logger")
2939 (version "1.0.1")
2940 (source
2941 (origin
2942 (method url-fetch)
2943 (uri (rubygems-uri "bio-logger" version))
2944 (sha256
2945 (base32
2946 "02pylfy8nkdqzyzplvnhn1crzmfkj1zmi3qjhrj2f2imlxvycd28"))))
2947 (build-system ruby-build-system)
2948 (arguments
2949 `(#:tests? #f)) ; rake errors, missing shoulda
2950 (propagated-inputs
2951 `(("ruby-log4r" ,ruby-log4r)))
2952 (synopsis "Log4r wrapper for Ruby")
2953 (description "Bio-logger is a wrapper around Log4r adding extra logging
2954features such as filtering and fine grained logging.")
2955 (home-page "https://github.com/pjotrp/bioruby-logger-plugin")
2956 (license license:expat)))
07f61cb2
BW
2957
2958(define-public ruby-yard
2959 (package
2960 (name "ruby-yard")
2961 (version "0.8.7.6")
2962 (source
2963 (origin
2964 (method url-fetch)
2965 (uri (rubygems-uri "yard" version))
2966 (sha256
2967 (base32
2968 "1dj6ibc0qqvmb5a5r5kk0vhr04mnrz9b26gnfrs5p8jgp620i89x"))))
2969 (build-system ruby-build-system)
2970 (arguments
2971 `(#:test-target "specs"
2972 #:phases
2973 (modify-phases %standard-phases
048036ae
BW
2974 (add-before 'check 'set-HOME-and-disable-failing-test
2975 (lambda _
2976 ;; $HOME needs to be set to somewhere writeable for tests to run
2977 (setenv "HOME" "/tmp")
2978 ;; Disable tests which fails on Ruby 2.3. See
2979 ;; https://github.com/lsegal/yard/issues/927
2980 (substitute* "spec/parser/ruby/ruby_parser_spec.rb"
2981 (("comment.type.should == :comment") "")
2982 (("comment.docstring_hash_flag.should be_true") "")
2983 (("comment.docstring.strip.should == .*") ""))
2984 #t)))))
07f61cb2
BW
2985 (native-inputs
2986 `(("ruby-rspec" ,ruby-rspec-2)
2987 ("ruby-rack" ,ruby-rack)))
2988 (synopsis "Documentation generation tool for Ruby")
2989 (description
2990 "YARD is a documentation generation tool for the Ruby programming
2991language. It enables the user to generate consistent, usable documentation
2992that can be exported to a number of formats very easily, and also supports
2993extending for custom Ruby constructs such as custom class level definitions.")
2994 (home-page "http://yardoc.org")
2995 (license license:expat)))
2cbcd23a 2996
ad686ef3
RW
2997(define-public ruby-clap
2998 (package
2999 (name "ruby-clap")
3000 (version "1.0.0")
3001 (source (origin
3002 (method url-fetch)
3003 (uri (rubygems-uri "clap" version))
3004 (sha256
3005 (base32
3006 "190m05k3pca72c1h8k0fnvby15m303zi0lpb9c478ad19wqawa5q"))))
3007 (build-system ruby-build-system)
3008 ;; Clap needs cutest for running tests, but cutest needs clap.
3009 (arguments `(#:tests? #f))
3010 (synopsis "Command line argument parsing for simple applications")
3011 (description
3012 "Clap provides command line argument parsing features. It covers the
3013simple case of executing code based on the flags or parameters passed.")
3014 (home-page "https://github.com/djanowski/cutest")
0c80451e
RW
3015 (license license:expat)))
3016
3017(define-public ruby-cutest
3018 (package
3019 (name "ruby-cutest")
3020 (version "1.2.2")
3021 (source (origin
3022 (method url-fetch)
3023 (uri (rubygems-uri "cutest" version))
3024 (sha256
3025 (base32
3026 "1mldhjn62g53vx4gq2qdqg2lgjvyrqxa8d0khf8347bbfgi16d32"))))
3027 (build-system ruby-build-system)
3028 (propagated-inputs
3029 `(("ruby-clap" ,ruby-clap)))
3030 (synopsis "Run tests in separate processes")
3031 (description
3032 "Cutest runs tests in separate processes to avoid shared state.")
3033 (home-page "https://github.com/djanowski/cutest")
ad686ef3
RW
3034 (license license:expat)))
3035
ac09beba
RW
3036(define-public ruby-pygmentize
3037 (package
3038 (name "ruby-pygmentize")
3039 (version "0.0.3")
3040 (source (origin
3041 (method url-fetch)
3042 (uri (rubygems-uri "pygmentize" version))
3043 (sha256
3044 (base32
3045 "1pxryhkiwvsz6xzda3bvqwz5z8ggzl1cdglf8qbcf4bb7akirdpb"))))
3046 (build-system ruby-build-system)
3047 (arguments
3048 `(#:phases
3049 (modify-phases %standard-phases
3050 (add-after 'unpack 'fix-pygmentize-path
3051 (lambda _
3052 (substitute* "lib/pygmentize.rb"
3053 (("\"/usr/bin/env python.*")
3054 (string-append "\"" (which "pygmentize") "\"\n")))
3055 #t))
3056 (add-after 'build 'do-not-use-vendor-directory
3057 (lambda _
3058 ;; Remove bundled pygments sources
3059 ;; FIXME: ruby-build-system does not support snippets.
3060 (delete-file-recursively "vendor")
3061 (substitute* "pygmentize.gemspec"
3062 (("\"vendor/\\*\\*/\\*\",") ""))
3063 #t)))))
3064 (inputs
3065 `(("pygments" ,python-pygments)))
3066 (native-inputs
3067 `(("ruby-cutest" ,ruby-cutest)
3068 ("ruby-nokogiri" ,ruby-nokogiri)))
3069 (synopsis "Thin Ruby wrapper around pygmentize")
3070 (description
3071 "Pygmentize provides a simple way to call pygmentize from within a Ruby
3072application.")
3073 (home-page "https://github.com/djanowski/pygmentize")
3074 (license license:expat)))
3075
2cbcd23a
DT
3076(define-public ruby-eventmachine
3077 (package
3078 (name "ruby-eventmachine")
3079 (version "1.0.8")
3080 (source
3081 (origin
3082 (method url-fetch)
3083 (uri (rubygems-uri "eventmachine" version))
3084 (sha256
3085 (base32
3086 "1frvpk3p73xc64qkn0ymll3flvn4xcycq5yx8a43zd3gyzc1ifjp"))))
3087 (build-system ruby-build-system)
3088 (arguments
3089 '(#:tests? #f)) ; test suite tries to connect to google.com
3090 (native-inputs
3091 `(("ruby-rake-compiler" ,ruby-rake-compiler)))
3092 (synopsis "Single-threaded network event framework for Ruby")
3093 (description
3094 "EventMachine implements a single-threaded engine for arbitrary network
3095communications. EventMachine wraps all interactions with sockets, allowing
3096programs to concentrate on the implementation of network protocols. It can be
3097used to create both network servers and clients.")
3098 (home-page "http://rubyeventmachine.com")
3099 (license (list license:ruby license:gpl3)))) ; GPLv3 only AFAICT
7d3a1a2d 3100
8092e333
BW
3101(define-public ruby-turn
3102 (package
3103 (name "ruby-turn")
3104 (version "0.9.7")
3105 (source
3106 (origin
3107 (method url-fetch)
3108 (uri (rubygems-uri "turn" version))
3109 (sha256
3110 (base32
3111 "1691rc2sq04cw8mxxh340k2j04ll90kwgcy8ddrp6rligmfrf8fw"))))
3112 (build-system ruby-build-system)
3113 (arguments
3114 `(#:phases
3115 (modify-phases %standard-phases
3116 ;; Tests fail because turn changes its environment so can no longer
3117 ;; find test/unit. Instead simply test if the executable runs
3118 ;; without issue.
3119 (replace 'check
3120 (lambda _
3121 (zero? (system* "ruby" "-Ilib" "bin/turn" "-h")))))))
3122 (propagated-inputs
3123 `(("ruby-ansi" ,ruby-ansi)
3124 ("ruby-minitest" ,ruby-minitest-4)))
3125 (synopsis "Alternate set of alternative runners for MiniTest")
3126 (description
3127 "TURN provides a set of alternative runners for MiniTest which are both
3128colorful and informative. TURN displays each test on a separate line with
3129failures being displayed immediately instead of at the end of the tests. Note
3130that TURN is no longer being maintained.")
3131 (home-page "http://rubygems.org/gems/turn")
3132 (license license:expat)))
3133
32d1c06f
BW
3134(define-public ruby-mime-types-data
3135 (package
3136 (name "ruby-mime-types-data")
3137 (version "3.2015.1120")
3138 (source
3139 (origin
3140 (method url-fetch)
3141 (uri (rubygems-uri "mime-types-data" version))
3142 (sha256
3143 (base32
3144 "04fzvy02w8d0rrsg8avncn7h58pvwdxj82aps54srb3sam2dkhic"))))
3145 (build-system ruby-build-system)
3146 (native-inputs
3147 `(("ruby-hoe" ,ruby-hoe)))
3148 (synopsis "Registry for information about MIME media type definitions")
3149 (description
3150 "@code{mime-types-data} provides a registry for information about
3151Multipurpose Internet Mail Extensions (MIME) media type definitions. It can
3152be used with the Ruby mime-types library or other software to determine
3153defined filename extensions for MIME types, or to use filename extensions to
3154look up the likely MIME type definitions.")
3155 (home-page "https://github.com/mime-types/mime-types-data/")
3156 (license license:expat)))
3157
d39b606c
BW
3158(define-public ruby-mime-types
3159 (package
3160 (name "ruby-mime-types")
3161 (version "3.0")
3162 (source
3163 (origin
3164 (method url-fetch)
3165 (uri (rubygems-uri "mime-types" version))
3166 (sha256
3167 (base32
3168 "1snjc38a9vqvy8j41xld1i1byq9prbl955pbjw7dxqcfcirqlzra"))))
3169 (build-system ruby-build-system)
3170 (propagated-inputs
3171 `(("ruby-mime-types-data" ,ruby-mime-types-data)))
3172 (native-inputs
3173 `(("ruby-hoe" ,ruby-hoe)
3174 ("ruby-fivemat" ,ruby-fivemat)
3175 ("ruby-minitest-focus" ,ruby-minitest-focus)
3176 ("ruby-minitest-rg" ,ruby-minitest-rg)
3177 ("ruby-minitest-bonus-assertions" ,ruby-minitest-bonus-assertions)))
3178 (synopsis "Library and registry for MIME content type definitions")
3179 (description "The mime-types library provides a library and registry for
3180information about Multipurpose Internet Mail Extensions (MIME) content type
3181definitions. It can be used to determine defined filename extensions for MIME
3182types, or to use filename extensions to look up the likely MIME type
3183definitions.")
3184 (home-page "https://github.com/mime-types/ruby-mime-types")
3185 (license license:expat)))
3186
eb5e0bd9
BW
3187(define-public ruby-fivemat
3188 (package
3189 (name "ruby-fivemat")
3190 (version "1.3.2")
3191 (source
3192 (origin
3193 (method url-fetch)
3194 (uri (rubygems-uri "fivemat" version))
3195 (sha256
3196 (base32
3197 "1gvw6g4yc96l2pcyvigahyfsjxpdjx21iiwzvf965zippchdh6gk"))))
3198 (build-system ruby-build-system)
3199 (arguments
3200 `(#:tests? #f)) ; no tests
3201 (synopsis "Each test file given its own line of dots")
3202 (description
3203 "Fivemat is a MiniTest/RSpec/Cucumber formatter that gives each test file
3204its own line of dots during testing. It aims to provide test output that is
3205neither too verbose nor too minimal.")
3206 (home-page "https://github.com/tpope/fivemat")
3207 (license license:expat)))
3208
4fea500b
BW
3209(define-public ruby-sqlite3
3210 (package
3211 (name "ruby-sqlite3")
3212 (version "1.3.11")
3213 (source
3214 (origin
3215 (method url-fetch)
3216 (uri (rubygems-uri "sqlite3" version))
3217 (sha256
3218 (base32
3219 "19r06wglnm6479ffj9dl0fa4p5j2wi6dj7k6k3d0rbx7036cv3ny"))))
3220 (build-system ruby-build-system)
3221 (arguments
3222 `(#:phases
3223 (modify-phases %standard-phases
3224 (add-before 'check 'add-gemtest-file
3225 ;; This file exists in the repository but is not distributed.
3226 (lambda _ (zero? (system* "touch" ".gemtest")))))))
3227 (inputs
3228 `(("sqlite" ,sqlite)))
3229 (native-inputs
3230 `(("ruby-hoe" ,ruby-hoe)
3231 ("ruby-rake-compiler" ,ruby-rake-compiler)
3232 ("ruby-mini-portile" ,ruby-mini-portile)))
3233 (synopsis "Interface with SQLite3 databases")
3234 (description
3235 "This module allows Ruby programs to interface with the SQLite3 database
3236engine.")
3237 (home-page
3238 "https://github.com/sparklemotion/sqlite3-ruby")
3239 (license license:bsd-3)))
3240
4dfa39cc
BW
3241(define-public ruby-shoulda-context
3242 (package
3243 (name "ruby-shoulda-context")
3244 (version "1.2.1")
3245 (source
3246 (origin
3247 (method url-fetch)
3248 (uri (rubygems-uri "shoulda-context" version))
3249 (sha256
3250 (base32
3251 "06wv2ika5zrbxn0m3qxwk0zkbspxids3zmlq3xxays5qmvl1qb55"))))
3252 (build-system ruby-build-system)
3253 (arguments
3254 `(#:phases
3255 (modify-phases %standard-phases
3256 (replace 'check
3257 (lambda _
3258 ;; Do not run tests to avoid circular dependence with rails.
3259 ;; Instead just import the library to test.
3260 (zero? (system* "ruby" "-Ilib" "-r" "shoulda-context")))))))
3261 (synopsis "Test::Unit context framework extracted from Shoulda")
3262 (description
3263 "@code{shoulda-context} is the context framework extracted from Shoulda.
3264Instead of writing Ruby methods with lots_of_underscores, shoulda-context adds
3265context, setup, and should blocks combine to produce natural test method
3266names.")
3267 (home-page "https://github.com/thoughtbot/shoulda-context")
3268 (license license:expat)))
3269
e4fea008
BW
3270(define-public ruby-shoulda-matchers
3271 (package
3272 (name "ruby-shoulda-matchers")
3273 (version "3.0.1")
3274 (source
3275 (origin
3276 (method url-fetch)
3277 (uri (rubygems-uri "shoulda-matchers" version))
3278 (sha256
3279 (base32
3280 "1agabvb8i39mjrp3kb78nvhl41xk1i258hdwdlj0fm8nj9yzn1jb"))))
3281 (build-system ruby-build-system)
3282 (arguments
3283 `(#:phases
3284 (modify-phases %standard-phases
3285 (add-before 'build 'fix-import
3286 (lambda _
3287 ;; A presumed bug reported upstream at
3288 ;; https://github.com/thoughtbot/shoulda-matchers/pull/871
3289 (substitute* (string-append "lib/shoulda/matchers/active_model/"
3290 "validate_inclusion_of_matcher.rb")
3291 (("^require 'bigdecimal'")
3292 "require 'bigdecimal'; require 'date'"))))
3293 (replace 'check
3294 (lambda _
3295 ;; Do not run tests to avoid circular dependence with rails. Instead
3296 ;; just import the library to test.
3297 (zero? (system* "ruby" "-Ilib" "-r" "shoulda-matchers")))))))
3298 (propagated-inputs
3299 `(("ruby-activesupport" ,ruby-activesupport)))
3300 (synopsis "Collection of testing matchers extracted from Shoulda")
3301 (description
3302 "Shoulda Matchers provides RSpec- and Minitest-compatible one-liners that
3303test common Rails functionality. These tests would otherwise be much longer,
3304more complex, and error-prone.")
3305 (home-page "https://github.com/thoughtbot/shoulda-matchers")
3306 (license license:expat)))
3307
3885c58b
BW
3308(define-public ruby-shoulda-matchers-2
3309 (package
3310 (inherit ruby-shoulda-matchers)
3311 (version "2.8.0")
3312 (source (origin
3313 (method url-fetch)
3314 (uri (rubygems-uri "shoulda-matchers" version))
3315 (sha256
3316 (base32
3317 "0d3ryqcsk1n9y35bx5wxnqbgw4m8b3c79isazdjnnbg8crdp72d0"))))))
3318
6f390716
BW
3319(define-public ruby-shoulda
3320 (package
3321 (name "ruby-shoulda")
3322 (version "3.5.0")
3323 (source
3324 (origin
3325 (method url-fetch)
3326 (uri (rubygems-uri "shoulda" version))
3327 (sha256
3328 (base32
3329 "0csmf15a7mcinfq54lfa4arp0f4b2jmwva55m0p94hdf3pxnjymy"))))
3330 (build-system ruby-build-system)
3331 (arguments
3332 `(#:phases
3333 (modify-phases %standard-phases
3334 (replace 'check
3335 ;; Don't run tests to avoid circular dependence with rails. Instead
3336 ;; just import the library to test.
3337 (lambda _ (zero? (system* "ruby" "-Ilib" "-r" "shoulda")))))))
3338 (propagated-inputs
3339 `(("ruby-shoulda-context" ,ruby-shoulda-context)
3340 ("ruby-shoulda-matchers" ,ruby-shoulda-matchers-2)))
3341 (synopsis "Context framework and matchers for testing")
3342 (description
3343 "@code{shoulda} is a meta-package combining @code{shoulda-context} and
3344@code{shoulda-matchers} providing tools for writing tests.")
3345 (home-page "https://github.com/thoughtbot/shoulda")
3346 (license license:expat)))
3347
3b44bcdf
BW
3348(define-public ruby-unf
3349 (package
3350 (name "ruby-unf")
3351 (version "0.1.4")
3352 (source
3353 (origin
3354 (method url-fetch)
3355 (uri (rubygems-uri "unf" version))
3356 (sha256
3357 (base32
3358 "0bh2cf73i2ffh4fcpdn9ir4mhq8zi50ik0zqa1braahzadx536a9"))))
3359 (build-system ruby-build-system)
3360 (arguments
3361 `(#:phases
3362 (modify-phases %standard-phases
3363 (add-before 'check 'add-dependency-to-bundler
3364 (lambda _
3365 ;; test-unit is required but not provided by the bundler
3366 ;; environment. This is fixed in the upstream repository but fix
3367 ;; has not been released.
3368 (substitute* "Gemfile"
3369 (("^gemspec") "gem 'test-unit'\ngemspec"))
3370 #t)))))
3371 (propagated-inputs
3372 `(("ruby-unf-ext" ,ruby-unf-ext)))
3373 (native-inputs
3374 `(("ruby-shoulda" ,ruby-shoulda)
3375 ("bundler" ,bundler)
3376 ("ruby-test-unit" ,ruby-test-unit)))
3377 (synopsis "Unicode Normalization Form support to Ruby and JRuby")
3378 (description
3379 "@code{ruby-unf} is a wrapper library to bring Unicode Normalization Form
3380support to both Ruby and JRuby. It uses @code{unf_ext} on CRuby and
3381@code{java.text.Normalizer} on JRuby.")
3382 (home-page "https://github.com/knu/ruby-unf")
3383 (license license:bsd-2)))
3384
5799aadd
BW
3385(define-public ruby-domain-name
3386 (package
3387 (name "ruby-domain-name")
3388 (version "0.5.25")
3389 (source
3390 (origin
3391 (method url-fetch)
3392 (uri (rubygems-uri "domain_name" version))
3393 (sha256
3394 (base32
3395 "16qvfrmcwlzz073aas55mpw2nhyhjcn96s524w0g1wlml242hjav"))))
3396 (build-system ruby-build-system)
3397 (arguments
3398 `(#:phases
3399 (modify-phases %standard-phases
3400 (add-before 'check 'fix-versions
3401 (lambda _
3402 ;; Fix NameError that appears to already be fixed upstream.
3403 (substitute* "Rakefile"
3404 (("DomainName::VERSION")
3405 "Bundler::GemHelper.gemspec.version"))
3406 ;; Loosen unnecessarily strict test-unit version specification.
3407 (substitute* "domain_name.gemspec"
3408 (("<test-unit>, \\[\\\"~> 2.5.5") "<test-unit>, [\">0"))
3409 #t)))))
3410 (propagated-inputs
3411 `(("ruby-unf" ,ruby-unf)))
3412 (native-inputs
3413 `(("ruby-shoulda" ,ruby-shoulda)
3414 ("bundler" ,bundler)
3415 ("ruby-test-unit" ,ruby-test-unit)))
3416 (synopsis "Domain name manipulation library")
3417 (description
3418 "@code{domain_name} is a Domain name manipulation library. It parses a
3419domain name ready for extracting the registered domain and TLD (Top Level
3420Domain). It can also be used for cookie domain validation based on the Public
3421Suffix List.")
3422 (home-page "https://github.com/knu/ruby-domain_name")
3423 (license license:bsd-2)))
3424
d114ceeb
BW
3425(define-public ruby-http-cookie
3426 (package
3427 (name "ruby-http-cookie")
3428 (version "1.0.2")
3429 (source
3430 (origin
3431 (method url-fetch)
3432 (uri (rubygems-uri "http-cookie" version))
3433 (sha256
3434 (base32
3435 "0cz2fdkngs3jc5w32a6xcl511hy03a7zdiy988jk1sf3bf5v3hdw"))))
3436 (build-system ruby-build-system)
3437 (arguments
3438 `(#:phases
3439 (modify-phases %standard-phases
3440 (add-before 'check 'add-dependency-to-bundler
3441 (lambda _
3442 ;; Fix NameError
3443 (substitute* "Rakefile"
3444 (("HTTP::Cookie::VERSION")
3445 "Bundler::GemHelper.gemspec.version"))
3446 #t)))))
3447 (propagated-inputs
3448 `(("ruby-domain-name" ,ruby-domain-name)))
3449 (native-inputs
3450 `(("rubysimplecov" ,ruby-simplecov)
3451 ("bundler" ,bundler)
3452 ("ruby-sqlite3" ,ruby-sqlite3)
3453 ("ruby-test-unit" ,ruby-test-unit)))
3454 (synopsis "Handle HTTP Cookies based on RFC 6265")
3455 (description
3456 "@code{HTTP::Cookie} is a Ruby library to handle HTTP Cookies based on
3457RFC 6265. It has been designed with security, standards compliance and
3458compatibility in mind, to behave just the same as today's major web browsers.
3459It has built-in support for the legacy @code{cookies.txt} and
3460@code{cookies.sqlite} formats of Mozilla Firefox.")
3461 (home-page "https://github.com/sparklemotion/http-cookie")
3462 (license license:expat)))
3463
7d3a1a2d
BW
3464(define-public ruby-ansi
3465 (package
3466 (name "ruby-ansi")
3467 (version "1.5.0")
3468 (source
3469 (origin
3470 (method url-fetch)
3471 ;; Fetch from GitHub as the gem does not contain testing code.
3472 (uri (string-append "https://github.com/rubyworks/ansi/archive/"
3473 version ".tar.gz"))
3474 (file-name (string-append name "-" version ".tar.gz"))
3475 (sha256
3476 (base32
3477 "1zdip30hivyipi8hndhb457bhiz033awd00bgrsk5axjrwp6zhly"))))
3478 (build-system ruby-build-system)
3479 (arguments
3480 `(#:phases
3481 (modify-phases %standard-phases
3482 ;; Disable testing to break the cycle ansi, ae, ansi, as well as the
3483 ;; cycle ansi, qed, ansi. Instead simply test that the library can
3484 ;; be require'd.
3485 (replace 'check
3486 (lambda _
3487 (zero? (system* "ruby" "-Ilib" "-r" "ansi")))))))
3488 (synopsis "ANSI escape code related libraries")
3489 (description
3490 "This package is a collection of ANSI escape code related libraries
3491enabling ANSI colorization and stylization of console output. Included in the
3492library are the @code{Code} module, which defines ANSI codes as constants and
3493methods, a @code{Mixin} module for including color methods, a @code{Logger}, a
3494@code{ProgressBar}, and a @code{String} subclass. The library also includes a
3495@code{Terminal} module which provides information about the current output
3496device.")
3497 (home-page "http://rubyworks.github.io/ansi")
3498 (license license:bsd-2)))
7c033c46
BW
3499
3500(define-public ruby-systemu
3501 (package
3502 (name "ruby-systemu")
3503 (version "2.6.5")
3504 (source
3505 (origin
3506 (method url-fetch)
3507 (uri (rubygems-uri "systemu" version))
3508 (sha256
3509 (base32
3510 "0gmkbakhfci5wnmbfx5i54f25j9zsvbw858yg3jjhfs5n4ad1xq1"))))
3511 (build-system ruby-build-system)
3512 (arguments
3513 `(#:phases
3514 (modify-phases %standard-phases
3515 (add-before 'check 'set-version
3516 (lambda _
3517 (setenv "VERSION" ,version)
3518 #t)))))
3519 (synopsis "Capture of stdout/stderr and handling of child processes")
3520 (description
3521 "Systemu can be used on any platform to return status, stdout, and stderr
3522of any command. Unlike other methods like @code{open3} and @code{popen4}
3523there is no danger of full pipes or threading issues hanging your process or
3524subprocess.")
3525 (home-page "https://github.com/ahoward/systemu")
3526 (license license:ruby)))
3d84a99e
BW
3527
3528(define-public ruby-bio-commandeer
3529 (package
3530 (name "ruby-bio-commandeer")
3531 (version "0.1.2")
3532 (source
3533 (origin
3534 (method url-fetch)
3535 (uri (rubygems-uri "bio-commandeer" version))
3536 (sha256
3537 (base32
3538 "061jxa6km92qfwzl058r2gp8gfcsbyr7m643nw1pxvmjdswaf6ly"))))
3539 (build-system ruby-build-system)
3540 (arguments
3541 `(#:phases
3542 (modify-phases %standard-phases
3543 (replace 'check
3544 ;; Run test without calling 'rake' so that jeweler is
3545 ;; not required as an input.
3546 (lambda _
3547 (zero? (system* "rspec" "spec/bio-commandeer_spec.rb")))))))
3548 (propagated-inputs
3549 `(("ruby-bio-logger" ,ruby-bio-logger)
3550 ("ruby-systemu" ,ruby-systemu)))
3551 (native-inputs
3552 `(("bundler" ,bundler)
3553 ("ruby-rspec" ,ruby-rspec)))
3554 (synopsis "Simplified running of shell commands from within Ruby")
3555 (description
3556 "Bio-commandeer provides an opinionated method of running shell commands
3557from within Ruby. The advantage of bio-commandeer over other methods of
3558running external commands is that when something goes wrong, messages printed
3559to the @code{STDOUT} and @code{STDERR} streams are reported, giving extra
3560detail to ease debugging.")
3561 (home-page "http://github.com/wwood/bioruby-commandeer")
3562 (license license:expat)))
7c8131c7
BW
3563
3564(define-public ruby-rubytest
3565 (package
3566 (name "ruby-rubytest")
3567 (version "0.8.1")
3568 (source
3569 (origin
3570 (method url-fetch)
3571 (uri (rubygems-uri "rubytest" version))
3572 (sha256
3573 (base32
3574 "19jydsdnkl81i9dhdcr4dc34j0ilm68ff2ngnka1hi38xiw4p5qz"))))
3575 (build-system ruby-build-system)
3576 (arguments
3577 ;; Disable regular testing to break the cycle rubytest, qed, brass,
3578 ;; rubytest, as well as the cycle rubytest, qed, ansi, rubytest. Instead
3579 ;; simply test that the library can be require'd.
3580 `(#:phases
3581 (modify-phases %standard-phases
3582 (replace 'check
3583 (lambda _
3584 (zero? (system* "ruby" "-Ilib" "-r" "rubytest")))))))
3585 (propagated-inputs
3586 `(("ruby-ansi" ,ruby-ansi)))
3587 (synopsis "Universal test harness for Ruby")
3588 (description
3589 "Rubytest is a testing meta-framework for Ruby. It can handle any
3590compliant test framework and can run tests from multiple frameworks in a
3591single pass.")
3592 (home-page "http://rubyworks.github.io/rubytest")
3593 (license license:bsd-2)))
90fcedf2
BW
3594
3595(define-public ruby-brass
3596 (package
3597 (name "ruby-brass")
3598 (version "1.2.1")
3599 (source
3600 (origin
3601 (method url-fetch)
3602 (uri (rubygems-uri "brass" version))
3603 (sha256
3604 (base32
3605 "154lp8rp1vmg60ri1j4cb8hqlw37z7bn575h899v8hzxwi11sxka"))))
3606 (build-system ruby-build-system)
3607 (arguments
3608 ;; Disable tests to break the cycle brass, lemon, ae, qed, brass.
3609 ;; Instead simply test that the library can be require'd.
3610 `(#:phases
3611 (modify-phases %standard-phases
3612 (replace 'check
3613 (lambda _
3614 (zero? (system* "ruby" "-Ilib" "-r" "brass")))))))
3615 (synopsis "Basic foundational assertions framework")
3616 (description
3617 "BRASS (Bare-Metal Ruby Assertion System Standard) is a basic
3618foundational assertions framework for other assertion and test frameworks to
3619make use of.")
3620 (home-page "http://rubyworks.github.io/brass")
3621 (license license:bsd-2)))
120fc74b
BW
3622
3623(define-public ruby-qed
3624 (package
3625 (name "ruby-qed")
3626 (version "2.9.2")
3627 (source
3628 (origin
3629 (method url-fetch)
3630 (uri (rubygems-uri "qed" version))
3631 (sha256
3632 (base32
3633 "03h4lmlxpcya8j7s2cnyscqlx8v3xl1xgsw5y1wk1scxcgz2vbmr"))))
3634 (build-system ruby-build-system)
3635 (arguments
3636 ;; Disable testing to break the cycle qed, ansi, qed, among others.
3637 ;; Instead simply test that the executable runs using --copyright.
3638 `(#:phases
3639 (modify-phases %standard-phases
3640 (replace 'check
3641 (lambda _
3642 (zero? (system* "ruby" "-Ilib" "bin/qed" "--copyright")))))))
3643 (propagated-inputs
3644 `(("ruby-ansi" ,ruby-ansi)
3645 ("ruby-brass" ,ruby-brass)))
3646 (synopsis "Test framework utilizing literate programming techniques")
3647 (description
3648 "@dfn{Quality Ensured Demonstrations} (QED) is a test framework for
3649@dfn{Test Driven Development} (TDD) and @dfn{Behaviour Driven
3650Development} (BDD) utilizing Literate Programming techniques. QED sits
3651somewhere between lower-level testing tools like @code{Test::Unit} and
3652requirement specifications systems like Cucumber.")
3653 (home-page "http://rubyworks.github.io/qed")
3654 (license license:bsd-2)))
9273ee8f
BW
3655
3656(define-public ruby-ae
3657 (package
3658 (name "ruby-ae")
3659 (version "1.8.2")
3660 (source
3661 (origin
3662 (method url-fetch)
3663 ;; Fetch from github so tests are included.
3664 (uri (string-append
3665 "https://github.com/rubyworks/ae/archive/"
3666 version ".tar.gz"))
3667 (file-name (string-append name "-" version ".tar.gz"))
3668 (sha256
3669 (base32
3670 "147jmkx54x7asy2d8m4dyrhhf4hdx4galpnhwzai030y3cdsfrrl"))))
3671 (build-system ruby-build-system)
3672 (arguments
3673 `(#:phases
3674 (modify-phases %standard-phases
3675 (replace 'check
3676 (lambda _ (zero? (system* "qed")))))))
3677 (propagated-inputs
3678 `(("ruby-ansi" ,ruby-ansi)))
3679 (native-inputs
3680 `(("ruby-qed" ,ruby-qed)))
3681 (synopsis "Assertions library")
3682 (description
3683 "Assertive Expressive (AE) is an assertions library specifically designed
3684for reuse by other test frameworks.")
3685 (home-page "http://rubyworks.github.io/ae")
3686 (license license:bsd-2)))
78bb471f
BW
3687
3688(define-public ruby-lemon
3689 (package
3690 (name "ruby-lemon")
3691 (version "0.9.1")
3692 (source
3693 (origin
3694 (method url-fetch)
3695 (uri (rubygems-uri "lemon" version))
3696 (sha256
3697 (base32
3698 "0gqhpgjavgpvx23rqpfqcv3d5bs8gc7lr9yvj8kxgp7mfbdc2jcm"))))
3699 (build-system ruby-build-system)
3700 (arguments
3701 `(#:phases
3702 (modify-phases %standard-phases
3703 (replace 'check (lambda _ (zero? (system* "qed")))))))
3704 (propagated-inputs
3705 `(("ruby-ae" ,ruby-ae)
3706 ("ruby-ansi" ,ruby-ansi)
3707 ("ruby-rubytest" ,ruby-rubytest)))
3708 (native-inputs
3709 `(("ruby-qed" ,ruby-qed)))
3710 (synopsis "Test framework correlating code structure and test unit")
3711 (description
3712 "Lemon is a unit testing framework that enforces highly formal
3713case-to-class and unit-to-method test construction. This enforcement can help
3714focus concern on individual units of behavior.")
3715 (home-page "http://rubyworks.github.io/lemon")
3716 (license license:bsd-2)))
0832804e
BW
3717
3718(define-public ruby-rubytest-cli
3719 (package
3720 (name "ruby-rubytest-cli")
3721 (version "0.2.0")
3722 (source
3723 (origin
3724 (method url-fetch)
3725 (uri (rubygems-uri "rubytest-cli" version))
3726 (sha256
3727 (base32
3728 "0n7hv4k1ba4fm3i98c6ydbsqhkxgbp52mhi70ba1x3mqzfvk438p"))))
3729 (build-system ruby-build-system)
3730 (arguments
3731 `(#:tests? #f)) ; no tests
3732 (propagated-inputs
3733 `(("ruby-ansi" ,ruby-ansi)
3734 ("ruby-rubytest" ,ruby-rubytest)))
3735 (synopsis "Command-line interface for rubytest")
3736 (description
3737 "Rubytest CLI is a command-line interface for running tests for
3738Rubytest-based test frameworks. It provides the @code{rubytest} executable.")
3739 (home-page "http://rubyworks.github.io/rubytest-cli")
3740 (license license:bsd-2)))
72ccbfe3
BW
3741
3742(define-public ruby-hashery
3743 (package
3744 (name "ruby-hashery")
3745 (version "2.1.1")
3746 (source
3747 (origin
3748 (method url-fetch)
3749 (uri (rubygems-uri "hashery" version))
3750 (sha256
3751 (base32
3752 "0xawbljsjarl9l7700bka672ixwznzwih4s9i38p1y9mp8hyx54g"))))
3753 (build-system ruby-build-system)
3754 (arguments
3755 `(#:phases
3756 (modify-phases %standard-phases
3757 (replace 'check
3758 (lambda _
3759 (and (zero? (system* "qed"))
3760 (zero? (system* "rubytest" "-Ilib" "-Itest" "test/"))))))))
3761 (native-inputs
3762 `(("ruby-rubytest-cli" ,ruby-rubytest-cli)
3763 ("ruby-qed" ,ruby-qed)
3764 ("ruby-lemon" ,ruby-lemon)))
3765 (synopsis "Hash-like classes with extra features")
3766 (description
3767 "The Hashery is a tight collection of @code{Hash}-like classes.
3768Included are the auto-sorting @code{Dictionary} class, the efficient
3769@code{LRUHash}, the flexible @code{OpenHash} and the convenient
3770@code{KeyHash}. Nearly every class is a subclass of the @code{CRUDHash} which
3771defines a CRUD (Create, Read, Update and Delete) model on top of Ruby's
3772standard @code{Hash} making it possible to subclass and augment to fit any
3773specific use case.")
3774 (home-page "http://rubyworks.github.io/hashery")
3775 (license license:bsd-2)))
1f1d71e0
BW
3776
3777(define-public ruby-rc4
3778 (package
3779 (name "ruby-rc4")
3780 (version "0.1.5")
3781 (source
3782 (origin
3783 (method url-fetch)
3784 (uri (rubygems-uri "ruby-rc4" version))
3785 (sha256
3786 (base32
3787 "00vci475258mmbvsdqkmqadlwn6gj9m01sp7b5a3zd90knil1k00"))))
3788 (build-system ruby-build-system)
3789 (arguments
3790 `(#:phases
3791 (modify-phases %standard-phases
3792 (replace 'check
3793 (lambda _
3794 (zero? (system* "rspec" "spec/rc4_spec.rb")))))))
3795 (native-inputs
3796 `(("ruby-rspec" ,ruby-rspec-2)))
3797 (synopsis "Implementation of the RC4 algorithm")
3798 (description
3799 "RubyRC4 is a pure Ruby implementation of the RC4 algorithm.")
3800 (home-page "https://github.com/caiges/Ruby-RC4")
3801 (license license:expat)))
f3e085a8
BW
3802
3803(define-public ruby-afm
3804 (package
3805 (name "ruby-afm")
3806 (version "0.2.2")
3807 (source
3808 (origin
3809 (method url-fetch)
3810 (uri (rubygems-uri "afm" version))
3811 (sha256
3812 (base32
3813 "06kj9hgd0z8pj27bxp2diwqh6fv7qhwwm17z64rhdc4sfn76jgn8"))))
3814 (build-system ruby-build-system)
3815 (native-inputs
3816 `(("bundler" ,bundler)))
3817 (synopsis "Read Adobe Font Metrics (afm) files")
3818 (description
3819 "This library provides methods to read @dfn{Adobe Font Metrics} (afm)
3820files and use the data therein.")
3821 (home-page "http://github.com/halfbyte/afm")
3822 (license license:expat)))
acb6be42
BW
3823
3824(define-public ruby-ascii85
3825 (package
3826 (name "ruby-ascii85")
3827 (version "1.0.2")
3828 (source
3829 (origin
3830 (method url-fetch)
3831 (uri (rubygems-uri "Ascii85" version))
3832 (sha256
3833 (base32
3834 "0j95sbxd18kc8rhcnvl1w37kflqpax1r12h1x47gh4xxn3mz4m7q"))))
3835 (build-system ruby-build-system)
3836 (native-inputs
3837 `(("bundler" ,bundler)))
3838 (synopsis "Encode and decode Ascii85 binary-to-text encoding")
3839 (description
3840 "This library provides methods to encode and decode Ascii85
3841binary-to-text encoding. The main modern use of Ascii85 is in PostScript and
3842@dfn{Portable Document Format} (PDF) file formats.")
3843 (home-page "https://github.com/datawraith/ascii85gem")
3844 (license license:expat)))
edf8caae
BW
3845
3846(define-public ruby-ttfunk
3847 (package
3848 (name "ruby-ttfunk")
3849 (version "1.4.0")
3850 (source
3851 (origin
3852 (method url-fetch)
3853 ;; fetch from github as the gem does not contain testing code
3854 (uri (string-append
3855 "https://github.com/prawnpdf/ttfunk/archive/"
3856 version ".tar.gz"))
3857 (file-name (string-append name "-" version ".tar.gz"))
3858 (sha256
3859 (base32
3860 "1izq84pnm9niyvkzp8k0vl232q9zj41hwmp9na9fzycfh1pbnsl6"))))
3861 (build-system ruby-build-system)
3862 (arguments
3863 `(#:test-target "spec"
3864 #:phases
3865 (modify-phases %standard-phases
3866 (add-before 'check 'remove-rubocop
3867 (lambda _
3868 ;; remove rubocop as a dependency as not needed for testing
3869 (substitute* "ttfunk.gemspec"
3870 (("spec.add_development_dependency\\('rubocop'.*") ""))
3871 (substitute* "Rakefile"
3872 (("require 'rubocop/rake_task'") "")
3873 (("Rubocop::RakeTask.new") ""))
3874 #t)))))
3875 (native-inputs
3876 `(("ruby-rspec" ,ruby-rspec)
3877 ("bundler" ,bundler)))
3878 (synopsis "Font metrics parser for the Prawn PDF generator")
3879 (description
3880 "TTFunk is a TrueType font parser written in pure Ruby. It is used as
3881part of the Prawn PDF generator.")
3882 (home-page "https://github.com/prawnpdf/ttfunk")
3883 ;; From the README: "Matz's terms for Ruby, GPLv2, or GPLv3. See LICENSE
3884 ;; for details."
3885 (license (list license:gpl2 license:gpl3 license:ruby))))