gnu packages: Avoid description lines with leading "(".
[jackhill/guix/guix.git] / gnu / packages / ruby.scm
CommitLineData
6ef8c59a
PP
1;;; GNU Guix --- Functional package management for GNU
2;;; Copyright © 2014 Pjotr Prins <pjotr.guix@thebird.nl>
3;;; Copyright © 2014 Ludovic Courtès <ludo@gnu.org>
f586c877 4;;; Copyright © 2014, 2015 Mark H Weaver <mhw@netris.org>
ecde6191 5;;; Copyright © 2014 David Thompson <davet@gnu.org>
6ef8c59a
PP
6;;;
7;;; This file is part of GNU Guix.
8;;;
9;;; GNU Guix is free software; you can redistribute it and/or modify it
10;;; under the terms of the GNU General Public License as published by
11;;; the Free Software Foundation; either version 3 of the License, or (at
12;;; your option) any later version.
13;;;
14;;; GNU Guix is distributed in the hope that it will be useful, but
15;;; WITHOUT ANY WARRANTY; without even the implied warranty of
16;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17;;; GNU General Public License for more details.
18;;;
19;;; You should have received a copy of the GNU General Public License
20;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
21
22(define-module (gnu packages ruby)
23 #:use-module ((guix licenses) #:prefix license:)
24 #:use-module (gnu packages)
25 #:use-module (gnu packages compression)
26 #:use-module (gnu packages readline)
6ef8c59a
PP
27 #:use-module (gnu packages autotools)
28 #:use-module (gnu packages libffi)
29 #:use-module (gnu packages gdbm)
cc2b77df 30 #:use-module (gnu packages tls)
66e20863 31 #:use-module (gnu packages version-control)
6ef8c59a
PP
32 #:use-module (guix packages)
33 #:use-module (guix download)
bda0c139 34 #:use-module (guix git-download)
6ef8c59a 35 #:use-module (guix utils)
acf735f2
DT
36 #:use-module (guix build-system gnu)
37 #:use-module (guix build-system ruby))
6ef8c59a
PP
38
39(define-public ruby
40 (package
41 (name "ruby")
463acb4a 42 (version "2.2.2")
6ef8c59a
PP
43 (source
44 (origin
45 (method url-fetch)
6becfdff
MW
46 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
47 (version-major+minor version)
12d39eb5 48 "/ruby-" version ".tar.xz"))
6ef8c59a
PP
49 (sha256
50 (base32
463acb4a 51 "0qj48a8ji8qj1sllsrhb6y65frwr77bvr08xikj86w5mib8baczh"))))
6ef8c59a
PP
52 (build-system gnu-build-system)
53 (arguments
54 `(#:test-target "test"
55 #:parallel-tests? #f
56 #:phases
12d39eb5
DT
57 (alist-cons-before
58 'configure 'replace-bin-sh
6ef8c59a 59 (lambda _
12d39eb5
DT
60 (substitute* '("Makefile.in"
61 "ext/pty/pty.c"
62 "io.c"
63 "lib/mkmf.rb"
64 "process.c"
65 "test/rubygems/test_gem_ext_configure_builder.rb"
66 "test/rdoc/test_rdoc_parser.rb"
67 "test/ruby/test_rubyoptions.rb"
68 "test/ruby/test_process.rb"
69 "test/ruby/test_system.rb"
70 "tool/rbinstall.rb")
71 (("/bin/sh") (which "sh"))))
72 %standard-phases)))
6ef8c59a
PP
73 (inputs
74 `(("readline" ,readline)
6ef8c59a
PP
75 ("openssl" ,openssl)
76 ("libffi" ,libffi)
77 ("gdbm" ,gdbm)
78 ("zlib" ,zlib)))
79 (native-search-paths
80 (list (search-path-specification
81 (variable "GEM_PATH")
af070955
LC
82 (files (list (string-append "lib/ruby/gems/"
83 (version-major+minor version)
84 ".0"))))))
6becfdff 85 (synopsis "Programming language interpreter")
6ef8c59a
PP
86 (description "Ruby is a dynamic object-oriented programming language with
87a focus on simplicity and productivity.")
88 (home-page "https://ruby-lang.org")
89 (license license:ruby)))
90
9942e803
PP
91(define-public ruby-2.1
92 (package (inherit ruby)
93 (version "2.1.6")
94 (source
95 (origin
96 (method url-fetch)
97 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
98 (version-major+minor version)
99 "/ruby-" version ".tar.bz2"))
100 (sha256
101 (base32
102 "1sbcmbhadcxk0509svwxbm2vvgmpf3xjxr1397bgp9x46nz36lkv"))))
103 (arguments
104 `(#:test-target "test"
105 #:parallel-tests? #f
106 #:phases
107 (alist-cons-before
108 'configure 'replace-bin-sh
109 (lambda _
110 (substitute* '("Makefile.in"
111 "ext/pty/pty.c"
112 "io.c"
113 "lib/mkmf.rb"
114 "process.c")
115 (("/bin/sh") (which "sh"))))
116 %standard-phases)))
117 (native-search-paths
118 (list (search-path-specification
119 (variable "GEM_PATH")
120 (files (list (string-append "lib/ruby/gems/"
121 (version-major+minor version)
122 ".0"))))))))
123
218ee89b
PP
124(define-public ruby-1.8
125 (package (inherit ruby)
218ee89b
PP
126 (version "1.8.7-p374")
127 (source
128 (origin
129 (method url-fetch)
6becfdff
MW
130 (uri (string-append "http://cache.ruby-lang.org/pub/ruby/"
131 (version-major+minor version)
132 "/ruby-" version ".tar.bz2"))
218ee89b
PP
133 (sha256
134 (base32
135 "1qq7khilwkayrhwmzlxk83scrmiqfi7lgsn4c63znyvz2c1lgqxl"))))
136 (native-search-paths '())
137 (arguments
138 `(#:test-target "test"
139 #:parallel-tests? #f
140 #:phases
141 (alist-cons-before
142 'configure 'replace-bin-sh
143 (lambda _
144 (substitute* '("Makefile.in"
145 "ext/pty/pty.c"
146 "io.c"
147 "lib/mkmf.rb"
148 "process.c")
149 (("/bin/sh") (which "sh"))))
150 %standard-phases)))))
151
bda0c139
DT
152(define-public ruby-hoe
153 (package
154 (name "ruby-hoe")
155 (version "3.13.1")
156 (source (origin
157 (method git-fetch)
158 (uri (git-reference
159 (url "https://github.com/seattlerb/hoe.git")
160 (commit "0c11836"))) ; no release tags :(
161 (sha256
162 (base32
163 "0i8dimf8kxcjgqj9x65bbi3l6hc9p9gbfbb1vmrz42764a4jjbz9"))) )
164 (build-system ruby-build-system)
bda0c139
DT
165 (synopsis "Ruby project management helper")
166 (description
167 "Hoe is a rake/rubygems helper for project Rakefiles. It helps manage,
168maintain, and release projects and includes a dynamic plug-in system allowing
169for easy extensibility. Hoe ships with plug-ins for all the usual project
170tasks including rdoc generation, testing, packaging, deployment, and
171announcement.")
172 (home-page "http://www.zenspider.com/projects/hoe.html")
173 (license license:expat)))
174
022170dc
PP
175(define-public ruby-rake-compiler
176 (package
177 (name "ruby-rake-compiler")
178 (version "0.9.5")
179 (source (origin
180 (method url-fetch)
181 (uri (string-append
182 "https://github.com/rake-compiler/rake-compiler/archive/v"
183 version ".tar.gz"))
184 (file-name (string-append name "-" version ".tar.gz"))
185 (sha256
186 (base32
187 "07lk1vl0jqcaqwjjhmg0qshqwcxdyr5kscc9xxm13m03835xgpf3"))))
188 (build-system ruby-build-system)
189 (arguments
190 '(#:tests? #f ; needs cucumber
191 #:phases (modify-phases %standard-phases
192 (add-before 'build 'remove-cucumber-rake-task
193 (lambda _
194 ;; Remove cucumber test file because the
195 ;; dependencies are not available right now.
4ca5c91f 196 (delete-file "tasks/cucumber.rake"))))))
022170dc
PP
197 (synopsis "Building and packaging helper for Ruby native extensions")
198 (description "Rake-compiler proivides a framework for building and
199packaging native C and Java extensions in Ruby.")
200 (home-page "https://github.com/rake-compiler/rake-compiler")
201 (license license:expat)))
202
acf735f2
DT
203(define-public ruby-i18n
204 (package
205 (name "ruby-i18n")
206 (version "0.6.11")
207 (source (origin
208 (method url-fetch)
209 (uri (string-append "https://github.com/svenfuchs/i18n/archive/v"
210 version ".tar.gz"))
f586c877 211 (file-name (string-append name "-" version ".tar.gz"))
acf735f2
DT
212 (sha256
213 (base32
214 "1fdhnhh1p5g8vibv44d770z8nq208zrms3m2nswdvr54072y1m6k"))))
215 (build-system ruby-build-system)
216 (arguments
217 '(#:tests? #f)) ; requires bundler
218 (synopsis "Internationalization library for Ruby")
219 (description "Ruby i18n is an internationalization and localization
220solution for Ruby programs. It features translation and localization,
221interpolation of values to translations, pluralization, customizable
222transliteration to ASCII, flexible defaults, bulk lookup, lambdas as
223translation data, custom key/scope separator, custom exception handlers, and
224an extensible architecture with a swappable backend.")
225 (home-page "http://github.com/svenfuchs/i18n")
226 (license license:expat)))
eb0c2dd6
DT
227
228;; RSpec is the dominant testing library for Ruby projects. Even RSpec's
229;; dependencies use RSpec for their test suites! To avoid these circular
230;; dependencies, we disable tests for all of the RSpec-related packages.
231(define ruby-rspec-support
232 (package
233 (name "ruby-rspec-support")
234 (version "3.2.2")
235 (source (origin
236 (method url-fetch)
237 (uri (string-append
238 "https://github.com/rspec/rspec-support/archive/v"
239 version ".tar.gz"))
240 (file-name (string-append name "-" version ".tar.gz"))
241 (sha256
242 (base32
243 "1pvzfrqgy0z0gwmdgjp9f2vz1d9c0cajyzfqj9z8i2ssxnzmj4bv"))))
244 (build-system ruby-build-system)
245 (arguments
246 '(#:tests? #f)) ; avoid dependency cycles
247 (synopsis "RSpec support library")
248 (description "Support utilities for RSpec gems.")
249 (home-page "https://github.com/rspec/rspec-support")
250 (license license:expat)))
251
252(define-public ruby-rspec-core
253 (package
254 (name "ruby-rspec-core")
255 (version "3.2.3")
256 (source (origin
257 (method url-fetch)
258 (uri (string-append
259 "https://github.com/rspec/rspec-core/archive/v"
260 version ".tar.gz"))
261 (file-name (string-append name "-" version ".tar.gz"))
262 (sha256
263 (base32
264 "1clsa4lkh5c9c7xc3xa336ym00ycr67pchpg1bv4y3fz5hvzw8ki"))))
265 (build-system ruby-build-system)
266 (arguments
267 '(#:tests? #f)) ; avoid dependency cycles
268 (propagated-inputs
269 `(("ruby-rspec-support" ,ruby-rspec-support)))
270 (synopsis "RSpec core library")
271 (description "Rspec-core provides the RSpec test runner and example
272groups.")
273 (home-page "https://github.com/rspec/rspec-core")
274 (license license:expat)))
e6962009
DT
275
276(define ruby-diff-lcs-for-rspec
277 (package
278 (name "ruby-diff-lcs")
279 (version "1.2.5")
280 (source (origin
281 (method url-fetch)
282 (uri (string-append
283 "https://github.com/halostatue/diff-lcs/archive/v"
284 version ".tar.gz"))
285 (file-name (string-append name "-" version ".tar.gz"))
286 (sha256
287 (base32
288 "0kmfz2qdwbfjf97rx27hh9fm39mv3z9avjmvsajqnb5wxj2l5l4s"))))
289 (build-system ruby-build-system)
290 (arguments
291 '(#:tests? #f)) ; avoid dependency cycles
292 (synopsis "Compute the difference between two Enumerable sequences")
293 (description "Diff::LCS computes the difference between two Enumerable
294sequences using the McIlroy-Hunt longest common subsequence (LCS) algorithm.
295It includes utilities to create a simple HTML diff output format and a
296standard diff-like tool.")
297 (home-page "https://github.com/halostatue/diff-lcs")
298 (license license:expat)))
299
300(define-public ruby-rspec-expectations
301 (package
302 (name "ruby-rspec-expectations")
303 (version "3.2.1")
304 (source (origin
305 (method url-fetch)
306 (uri (string-append
307 "https://github.com/rspec/rspec-expectations/archive/v"
308 version ".tar.gz"))
309 (file-name (string-append name "-" version ".tar.gz"))
310 (sha256
311 (base32
312 "0h0rpprbh6h59gmksiyi1b8w6cvcai4wdbkikajwx3w1asxi6f7x"))))
313 (build-system ruby-build-system)
314 (arguments
315 '(#:tests? #f)) ; avoid dependency cycles
316 (propagated-inputs
317 `(("ruby-rspec-support" ,ruby-rspec-support)
318 ("ruby-diff-lcs" ,ruby-diff-lcs-for-rspec)))
319 (synopsis "RSpec expecations library")
320 (description "Rspec-expectations provides a simple API to express expected
321outcomes of a code example.")
322 (home-page "https://github.com/rspec/rspec-expectations")
323 (license license:expat)))
4f2a0cac
DT
324
325(define-public ruby-rspec-mocks
326 (package
327 (name "ruby-rspec-mocks")
328 (version "3.2.1")
329 (source (origin
330 (method url-fetch)
331 (uri (string-append
332 "https://github.com/rspec/rspec-mocks/archive/v"
333 version ".tar.gz"))
334 (file-name (string-append name "-" version ".tar.gz"))
335 (sha256
336 (base32
337 "1xzxsg0idxkg7czmjgqq10lcd821ibw1hjzn404sk9j6rw0fbx2g"))))
338 (build-system ruby-build-system)
339 (arguments
340 '(#:tests? #f)) ; avoid dependency cycles
341 (propagated-inputs
342 `(("ruby-rspec-support" ,ruby-rspec-support)
343 ("ruby-diff-lcs" ,ruby-diff-lcs-for-rspec)))
344 (synopsis "RSpec stubbing and mocking library")
345 (description "Rspec-mocks provides RSpec's \"test double\" framework, with
346support for stubbing and mocking.")
347 (home-page "https://github.com/rspec/rspec-mocks")
348 (license license:expat)))
d4fde1f2
DT
349
350(define-public ruby-rspec
351 (package
352 (name "ruby-rspec")
353 (version "3.2.0")
354 (source (origin
355 (method url-fetch)
356 (uri (string-append
357 "https://github.com/rspec/rspec/archive/v"
358 version ".tar.gz"))
359 (file-name (string-append name "-" version ".tar.gz"))
360 (sha256
361 (base32
362 "1jg38dbaknsdhiav5vnrwfccg524fwcg6sq1715441vx1xl6p54q"))))
363 (build-system ruby-build-system)
364 (arguments
365 '(#:tests? #f)) ; avoid dependency cycles
366 (propagated-inputs
367 `(("ruby-rspec-core" ,ruby-rspec-core)
368 ("ruby-rspec-mocks" ,ruby-rspec-mocks)
369 ("ruby-rspec-expectations" ,ruby-rspec-expectations)))
370 (synopsis "Behavior-driven development framework for Ruby")
371 (description "RSpec is a behavior-driven development (BDD) framework for
372Ruby. This meta-package includes the RSpec test runner, along with the
373expectations and mocks frameworks.")
374 (home-page "http://rspec.info/")
375 (license license:expat)))
2cbc105b
DT
376
377;; Bundler is yet another source of circular dependencies, so we must disable
378;; its test suite as well.
379(define-public bundler
380 (package
381 (name "bundler")
382 (version "1.9.9")
383 (source (origin
384 (method url-fetch)
385 (uri (string-append "https://github.com/bundler/bundler/archive/v"
386 version ".tar.gz"))
387 (file-name (string-append name "-" version ".tar.gz"))
388 (sha256
389 (base32
390 "08flx3n9hb3yz8mm5k16cdz0sb7g774f6vxn6gc3wfh5la83vfyx"))))
391 (build-system ruby-build-system)
392 (arguments
393 '(#:tests? #f)) ; avoid dependency cycles
394 (synopsis "Ruby gem bundler")
395 (description "Bundler automatically downloads and installs a list of gems
396specified in a \"Gemfile\", as well as their dependencies.")
397 (home-page "http://bundler.io/")
398 (license license:expat)))
98b87b82
DT
399
400(define-public ruby-useragent
401 (package
402 (name "ruby-useragent")
403 (version "0.13.3")
404 (source (origin
405 (method url-fetch)
406 (uri (string-append
407 "https://github.com/gshutler/useragent/archive/v"
408 version ".tar.gz"))
409 (file-name (string-append name "-" version ".tar.gz"))
410 (sha256
411 (base32
412 "1hj00fw06i0y3rwxxhxmnrqxhpnffv4zfqx2sqqpc5qc4fdvd2x9"))))
413 (build-system ruby-build-system)
414 (arguments
415 '(#:test-target "spec"))
416 (native-inputs
417 `(("ruby-rspec" ,ruby-rspec)
418 ("bundler" ,bundler)))
419 (synopsis "HTTP user agent parser for Ruby")
420 (description "UserAgent is a Ruby library that parses and compares HTTP
421User Agents.")
422 (home-page "https://github.com/gshutler/useragent")
423 (license license:expat)))
96086cc5
DT
424
425(define-public ruby-bacon
426 (package
427 (name "ruby-bacon")
428 (version "1.2")
429 (source (origin
430 (method url-fetch)
431 (uri (string-append
432 "https://github.com/chneukirchen/bacon/archive/"
433 version ".tar.gz"))
434 (file-name (string-append name "-" version ".tar.gz"))
435 (sha256
436 (base32
437 "0g03fxilrrx17dijww68n1lq5d8s69hrxgpga8c1i2k35bzcw5jc"))))
438 (build-system ruby-build-system)
439 (arguments
440 `(#:phases (modify-phases %standard-phases
441 (add-before 'build 'generate-docs
442 (lambda _
443 ;; This rake task also tries to generate a ChangeLog
444 ;; file from the Git log, which we don't have. It fails
445 ;; but creates an empty file, allowing the rest of the
446 ;; build to succeed.
447 (zero? (system* "rake" "predist")))))))
448 (synopsis "Small RSpec clone")
449 (description "Bacon is a small RSpec clone providing all essential
450features.")
451 (home-page "https://github.com/chneukirchen/bacon")
452 (license license:expat)))
de59d316
DT
453
454(define-public ruby-arel
455 (package
456 (name "ruby-arel")
457 (version "6.0.0")
458 (source (origin
459 (method url-fetch)
460 (uri (string-append
461 "https://github.com/rails/arel/archive/v"
462 version ".tar.gz"))
463 (file-name (string-append name "-" version ".tar.gz"))
464 (sha256
465 (base32
466 "0fldwp2hmrmddx22xf7hdmybngzv97qnv5rvz3qw61m94ddd6w4n"))))
467 (build-system ruby-build-system)
468 (native-inputs
469 `(("bundler" ,bundler)))
470 (synopsis "SQL AST manager for Ruby")
471 (description "Arel is a SQL AST manager for Ruby. It simplifies the
472generation of complex SQL queries and adapts to various relational database
473implementations.")
474 (home-page "https://github.com/rails/arel")
475 (license license:expat)))
e259bdf0
DT
476
477(define-public ruby-connection-pool
478 (package
479 (name "ruby-connection-pool")
480 (version "2.2.0")
481 (source (origin
482 (method url-fetch)
483 (uri (string-append
484 "https://github.com/mperham/connection_pool/archive/v"
485 version ".tar.gz"))
486 (file-name (string-append name "-" version ".tar.gz"))
487 (sha256
488 (base32
489 "02s5rwhmgy8qqns7a5y1daa0yaw38x6lzpwyvmy46h1yrj9mc6zf"))))
490 (build-system ruby-build-system)
491 (native-inputs
492 `(("bundler" ,bundler)))
493 (synopsis "Generic connection pool for Ruby")
494 (description "Connection_pool provides a generic connection pooling
495interface for Ruby programs.")
496 (home-page "https://github.com/mperham/connection_pool")
497 (license license:expat)))
4c0aeb44
DT
498
499(define-public ruby-net-http-persistent
500 (package
501 (name "ruby-net-http-persistent")
502 (version "2.9.4")
503 (source (origin
504 (method url-fetch)
505 (uri (string-append
506 "https://github.com/drbrain/net-http-persistent/archive/v"
507 version ".tar.gz"))
508 (file-name (string-append name "-" version ".tar.gz"))
509 (sha256
510 (base32
511 "1q18vji31w8gfr6ajziqkqs8n5lzkw0bl00dm2a8s05zhavzw9j9"))))
512 (build-system ruby-build-system)
4c0aeb44
DT
513 (native-inputs
514 `(("ruby-connection-pool" ,ruby-connection-pool)
515 ("ruby-hoe" ,ruby-hoe)))
516 (synopsis "Persistent HTTP connection manager")
517 (description "Net::HTTP::Persistent manages persistent HTTP connections
518using Net::HTTP, supporting reconnection and retry according to RFC 2616.")
519 (home-page "https://github.com/drbrain/net-http-persistent")
520 (license license:expat)))
afbbdf77 521
2206e948
DT
522(define-public ruby-minitest
523 (package
524 (name "ruby-minitest")
525 (version "5.7.0")
526 (source (origin
527 (method git-fetch)
528 ;; No release tarballs nor git tags. This is the commit
529 ;; corresponding to the addition of the release notes to
530 ;; History.rdoc.
531 (uri (git-reference
532 (url "https://github.com/seattlerb/minitest.git")
533 (commit "e975248")))
534 (sha256
535 (base32
536 "09xjiahk7q8hid1i39ahrmghaslpj9n36zna72i3ah7kf1bh2l01"))))
537 (build-system ruby-build-system)
2206e948
DT
538 (native-inputs
539 `(("ruby-hoe" ,ruby-hoe)))
540 (synopsis "Small test suite library for Ruby")
541 (description "Minitest provides a complete suite of Ruby testing
542facilities supporting TDD, BDD, mocking, and benchmarking.")
543 (home-page "https://github.com/seattlerb/minitest")
544 (license license:expat)))
545
35130835
DT
546(define-public ruby-minitest-sprint
547 (package
548 (name "ruby-minitest-sprint")
549 (version "1.1.0")
550 (source (origin
551 (method git-fetch)
552 ;; Same story as ruby-minitest.
553 (uri (git-reference
554 (url "https://github.com/seattlerb/minitest-sprint.git")
555 (commit "49c02bc")))
556 (sha256
557 (base32
558 "0rbmxz94lqg5vjz60p8v2bzq8adwvmx501amvk0l124sfwmw94ms"))))
559 (build-system ruby-build-system)
35130835
DT
560 (native-inputs
561 `(("ruby-hoe" ,ruby-hoe)
562 ("ruby-minitest" ,ruby-minitest)))
563 (synopsis "Fast test suite runner for minitest")
564 (description "Minitest-sprint is a test runner for minitest that makes it
565easier to re-run individual failing tests.")
566 (home-page "https://github.com/seattlerb/minitest-sprint")
567 (license license:expat)))
568
0808e361
DT
569(define-public ruby-minitest-bacon
570 (package
571 (name "ruby-minitest-bacon")
572 (version "1.0.2")
573 (source (origin
574 (method git-fetch)
575 ;; Same story as ruby-minitest.
576 (uri (git-reference
577 (url "https://github.com/seattlerb/minitest-bacon.git")
578 (commit "38551d5")))
579 (sha256
580 (base32
581 "19r9fm41i0mm1xncqls8frbj1i9nr3sq1cx2mh878r6kdl02d70h"))))
582 (build-system ruby-build-system)
0808e361
DT
583 (native-inputs
584 `(("ruby-hoe" ,ruby-hoe)))
585 (inputs
586 `(("ruby-minitest" ,ruby-minitest)))
587 (synopsis "Bacon compatibility library for minitest")
588 (description "Minitest-bacon extends minitest with bacon-like
589functionality, making it easier to migrate test suites from bacon to minitest.")
590 (home-page "https://github.com/seattlerb/minitest-bacon")
591 (license license:expat)))
592
afbbdf77
DT
593(define-public ruby-daemons
594 (package
595 (name "ruby-daemons")
596 (version "1.2.2")
597 (source (origin
598 (method url-fetch)
599 (uri (string-append
600 "https://github.com/thuehlinger/daemons/archive/v"
601 version ".tar.gz"))
602 (file-name (string-append name "-" version ".tar.gz"))
603 (sha256
604 (base32
605 "1v5bpdvpvhk240pc7fkn44vfclppl44pp6wd42ipi5sd5lkk7zfd"))))
606 (build-system ruby-build-system)
607 (arguments
608 `(#:tests? #f)) ; no test suite
609 (synopsis "Daemonize Ruby programs")
610 (description "Daemons provides a way to wrap existing Ruby scripts to be
611run as a daemon and to be controlled by simple start/stop/restart commands.")
612 (home-page "https://github.com/thuehlinger/daemons")
613 (license license:expat)))
66e20863
DT
614
615(define-public ruby-git
616 (package
617 (name "ruby-git")
618 (version "1.2.9.1")
619 (source (origin
620 (method url-fetch)
621 (uri (string-append
622 "https://github.com/schacon/ruby-git/archive/v"
623 version ".tar.gz"))
624 (file-name (string-append name "-" version ".tar.gz"))
625 (sha256
626 (base32
627 "08zg20zc7f7yy34ix2qdd8jbiz7xhjc8alk370869sq3h75hs9jc"))))
628 (build-system ruby-build-system)
629 (arguments
630 '(#:phases (modify-phases %standard-phases
631 (add-before 'build 'patch-git-binary
632 (lambda* (#:key inputs #:allow-other-keys)
633 ;; Make the default git binary an absolute path to the
634 ;; store.
635 (let ((git (string-append (assoc-ref inputs "git")
636 "/bin/git")))
637 (substitute* '("lib/git/config.rb")
638 (("'git'")
639 (string-append "'" git "'")))
640 ;; Fix a test that expects the binary to be simply
641 ;; 'git'.
642 (substitute* '("tests/units/test_logger.rb")
643 (("def test_logger")
644 (string-append
645 "def test_logger\n"
646 "Git::Base.config.binary_path = 'git'")))
647 #t)))
648 (add-before 'check 'create-fake-home
649 (lambda _
650 ;; The test suite runs 'git config --global' commands,
651 ;; so a fake home directory is needed for them to
652 ;; succeed.
653 (let ((fake-home (string-append (getcwd) "/fake-home")))
654 (mkdir fake-home)
655 (setenv "HOME" fake-home)))))))
656 (inputs
657 `(("git" ,git)))
658 (synopsis "Ruby wrappers for Git")
659 (description "Ruby/Git is a Ruby library that can be used to create, read
660and manipulate Git repositories by wrapping system calls to the git binary.")
661 (home-page "https://github.com/schacon/ruby-git")
662 (license license:expat)))
71d3e2c2
DT
663
664(define-public ruby-slop
665 (package
666 (name "ruby-slop")
667 (version "4.1.0")
668 (source (origin
669 (method url-fetch)
670 (uri (string-append
671 "https://github.com/leejarvis/slop/archive/v"
672 version ".tar.gz"))
673 (file-name (string-append name "-" version ".tar.gz"))
674 (sha256
675 (base32
676 "0cqs50a0b99kjd19xpln8jpnki07cjyp3l7wxbfr44ycasr6nznh"))))
677 (build-system ruby-build-system)
678 (native-inputs
679 `(("ruby-minitest" ,ruby-minitest)))
680 (synopsis "Ruby command line option parser")
681 (description "Slop provides a Ruby domain specific language for gathering
682options and parsing command line flags.")
683 (home-page "https://github.com/leejarvis/slop")
684 (license license:expat)))
e778a549
DT
685
686(define-public ruby-multipart-post
687 (package
688 (name "ruby-multipart-post")
689 (version "2.0.0")
690 (source (origin
691 (method url-fetch)
692 (uri (string-append
693 "https://github.com/nicksieger/multipart-post/archive/v"
694 version ".tar.gz"))
695 (file-name (string-append name "-" version ".tar.gz"))
696 (sha256
697 (base32
698 "03n271i3knfx4j9aingxzz2bajd379dw9nswsllviqc177lq1anm"))))
699 (build-system ruby-build-system)
700 (native-inputs
701 `(("bundler" ,bundler)))
702 (synopsis "Multipart POST library for Ruby")
703 (description "Multipart-Post Adds multipart POST capability to Ruby's
704net/http library.")
705 (home-page "https://github.com/nicksieger/multipart-post")
706 (license license:expat)))