summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <mail@cbaines.net>2019-01-27 13:01:01 +0000
committerChristopher Baines <christopher.baines@digital.cabinet-office.gov.uk>2019-01-29 22:56:12 +0000
commit5efde317534e81b94eb31a6fccd2dc531bfeb0eb (patch)
tree713c427158ac800baf038df2e6506add64ff3d78
parent8ecc6e8c9a090186e8d1cb65adf534c74452ad9e (diff)
downloadgnu-guix-5efde317534e81b94eb31a6fccd2dc531bfeb0eb.tar
gnu-guix-5efde317534e81b94eb31a6fccd2dc531bfeb0eb.tar.gz
gnu: Add ruby-rainbow.
Required for ruby-rubocop. * gnu/packages/ruby.scm (ruby-rainbow): New variable.
-rw-r--r--gnu/packages/ruby.scm32
1 files changed, 32 insertions, 0 deletions
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 747c8f6186..fc543332f9 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -3773,6 +3773,38 @@ clickjacking, directory traversal, session hijacking and IP spoofing.")
(home-page "https://github.com/sinatra/sinatra/tree/master/rack-protection")
(license license:expat)))
+(define-public ruby-rainbow
+ (package
+ (name "ruby-rainbow")
+ (version "3.0.0")
+ (source
+ (origin
+ (method url-fetch)
+ (uri (rubygems-uri "rainbow" version))
+ (sha256
+ (base32
+ "0bb2fpjspydr6x0s8pn1pqkzmxszvkfapv0p4627mywl7ky4zkhk"))))
+ (build-system ruby-build-system)
+ (arguments
+ '(#:phases
+ (modify-phases %standard-phases
+ ;; Run rspec directly, to avoid requiring Rubocop which is used from
+ ;; the Rakefile.
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "rspec"))
+ #t)))))
+ (native-inputs
+ `(("bundler" ,bundler)
+ ("ruby-rspec" ,ruby-rspec)))
+ (synopsis "Colorize printed text on ANSI terminals")
+ (description
+ "@code{rainbow} provides a string presenter object to colorize strings by
+wrapping them in ANSI escape codes.")
+ (home-page "https://github.com/sickill/rainbow")
+ (license license:expat)))
+
(define-public ruby-contest
(package
(name "ruby-contest")