summary refs log tree commit diff
path: root/gnu/packages/ruby.scm
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2020-07-08 21:54:35 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2020-07-08 21:54:35 -0400
commit1097fdbea75c2e9cc7c8a72c50a812def6ce62e6 (patch)
tree22cce51900fc5e6dc0e36caeec7c25b2c3bdcd48 /gnu/packages/ruby.scm
parent92ebbaad0924dcca8061604384452cd8e09965b3 (diff)
downloadguix-1097fdbea75c2e9cc7c8a72c50a812def6ce62e6.tar.gz
gnu: ruby_version: Update to 1.0.2.
* gnu/packages/ruby.scm (ruby_version): Update to 1.0.2.
[phases]: Adapt the fix-dependencies phase.
[native-inputs]: Add ruby-rdoc and ruby-rubygems-tasks.  Remove bundler.
[description]: Reformat.
Diffstat (limited to 'gnu/packages/ruby.scm')
-rw-r--r--gnu/packages/ruby.scm30
1 files changed, 13 insertions, 17 deletions
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index a9b800acfd..172dd4fe60 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -7581,44 +7581,40 @@ display width of strings in Ruby.")
 (define-public ruby_version
   (package
     (name "ruby_version")
-    (version "1.0.1")
+    (version "1.0.2")
     (source
      (origin
        (method url-fetch)
        (uri (rubygems-uri "ruby_version" version))
        (sha256
         (base32
-         "0854i1bjy56176anr05l5m0vc81nl53c7fyfg7sljj62m1d64dgj"))))
+         "0lvc7bd5ps3w2vq2wb02i0pi3vfcx2rnckx2ix4rjym1qf52kb2j"))))
     (build-system ruby-build-system)
     (arguments
-     '(#:phases
+     `(#:phases
        (modify-phases %standard-phases
          (add-before 'check 'fix-dependencies
            (lambda _
              ;; Remove the Gemfile.lock, as we want to use Guix packages at
              ;; whatever versions.
              (delete-file "Gemfile.lock")
-             ;; Remove the incldued gem file as it's unnecessary.
-             (delete-file "pkg/ruby_version-1.0.0.gem")
+             ;; Remove the included gem files as they unnecessary.
+             (delete-file-recursively "pkg/")
+             ;; Accept any version of rake, rdoc and rspec
              (substitute* "ruby_version.gemspec"
-               ;; Don't require rdoc and rubygems-tasks as they're unnecessary
-               ((".*rdoc.*") "\n")
-               ((".*rubygems-tasks.*") "\n")
-               ;; Accept any version of rake and rspec
                (("%q<rake.*") "%q<rake>)\n")
+               (("%q<rdoc.*") "%q<rdoc>)\n")
                (("%q<rspec.*") "%q<rspec>)\n"))
-             ;; Remove the use of rubygems-tasks from the Rakefile, as it's
-             ;; unnecessary.
+             ;; Do not use bundler.
              (substitute* "Rakefile"
-               (("^require 'rubygems/tasks'") "")
-               (("Gem::Tasks.new") ""))
+               (("Bundler\\.setup.*") "nil\n"))
              #t)))))
     (native-inputs
-     `(("bundler" ,bundler)
-       ("ruby-rspec" ,ruby-rspec)))
+     `(("ruby-rdoc" ,ruby-rdoc)
+       ("ruby-rspec" ,ruby-rspec)
+       ("ruby-rubygems-tasks", ruby-rubygems-tasks)))
     (synopsis "Ruby library to help check the Ruby version")
-    (description
-     "@code{ruby_version} provides a @code{RubyVersion} module to simplify
+    (description "@code{ruby_version} provides a @code{RubyVersion} module to simplify
 checking for the right Ruby version in software.")
     (home-page "https://github.com/janlelis/ruby_version")
     (license license:expat)))