me
/
guix
Archived
1
0
Fork 0

build: ruby: Run 'rake gem' when gemspec is missing.

* guix/build/ruby-build-system.scm (build): Run 'rake gem' when there is no
  gemspec in the source tree.

Co-Authored-By: David Thompson <davet@gnu.org>
master
pjotrp 2015-07-05 18:00:22 +02:00 committed by David Thompson
parent 795c01f31d
commit 76ae915ec8
1 changed files with 9 additions and 2 deletions

View File

@ -1,5 +1,6 @@
;;; GNU Guix --- Functional package management for GNU ;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2014 David Thompson <davet@gnu.org> ;;; Copyright © 2015 David Thompson <davet@gnu.org>
;;; Copyright © 2015 Pjotr Prins <pjotr.public01@thebird.nl>
;;; ;;;
;;; This file is part of GNU Guix. ;;; This file is part of GNU Guix.
;;; ;;;
@ -49,7 +50,13 @@ directory."
(define build (define build
(lambda _ (lambda _
(zero? (system* "gem" "build" (first-matching-file "\\.gemspec$"))))) (match (find-files "." "\\.gemspec$")
;; No gemspec, try 'rake gem' instead.
(()
(zero? (system* "rake" "gem")))
;; Build the first matching gemspec.
((gemspec . _)
(zero? (system* "gem" "build" gemspec))))))
(define* (check #:key tests? test-target #:allow-other-keys) (define* (check #:key tests? test-target #:allow-other-keys)
(if tests? (if tests?