diff options
author | Christopher Baines <mail@cbaines.net> | 2019-02-17 17:23:57 +0000 |
---|---|---|
committer | Christopher Baines <christopher.baines@digital.cabinet-office.gov.uk> | 2019-02-24 20:34:02 +0000 |
commit | 5d02acaac8bcdf50cb47f609d9e42efe68a29f9d (patch) | |
tree | f8ae41d803260813925d26f55dba86a5170f9f25 /gnu | |
parent | 86679dac1c25972a0269714eaabf7f96ef2c36d9 (diff) | |
download | gnu-guix-5d02acaac8bcdf50cb47f609d9e42efe68a29f9d.tar gnu-guix-5d02acaac8bcdf50cb47f609d9e42efe68a29f9d.tar.gz |
gnu: Add ruby-autoprefixer-rails.
* gnu/packages/rails.scm (ruby-autoprefixer-rails): New variable.
Diffstat (limited to 'gnu')
-rw-r--r-- | gnu/packages/rails.scm | 53 |
1 files changed, 53 insertions, 0 deletions
diff --git a/gnu/packages/rails.scm b/gnu/packages/rails.scm index 339b68d580..2c2954e9cb 100644 --- a/gnu/packages/rails.scm +++ b/gnu/packages/rails.scm @@ -22,6 +22,7 @@ #:use-module (guix download) #:use-module (guix git-download) #:use-module (guix packages) + #:use-module (gnu packages node) #:use-module (gnu packages ruby) #:use-module (guix build-system ruby)) @@ -123,6 +124,58 @@ API.") "https://github.com/banister/debug_inspector") (license license:expat))) +(define-public ruby-autoprefixer-rails + (package + (name "ruby-autoprefixer-rails") + (version "9.4.7") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "autoprefixer-rails" version)) + (sha256 + (base32 + "0fxbfl3xrrjj84n98x24yzxbz4nvm6c492dxj41kkrl9z97ga13i")))) + (build-system ruby-build-system) + (arguments + '(#:test-target "spec" + #:phases + (modify-phases %standard-phases + (add-after 'extract-gemspec 'remove-unnecessary-dependencies + (lambda _ + ;; Remove the testing of compass, as it's use is deprecated, and + ;; it's unpackaged for Guix + (substitute* "autoprefixer-rails.gemspec" + ((".*%q<compass>.*") "\n") + (("\"spec/compass_spec\\.rb\"\\.freeze, ") "")) + (delete-file "spec/compass_spec.rb") + + (substitute* "Gemfile" + ;; Remove overly strict requirement on sprockets + ((", '>= 4\\.0\\.0\\.beta1'") "") + ;; The mini_racer gem isn't packaged yet, and it's not directly + ;; required, as other backends for ruby-execjs can be used. + (("gem 'mini_racer'") "") + ;; For some reason, this is required for the gems to be picked + ;; up + (("gemspec") "gemspec\ngem 'tzinfo-data'\ngem 'sass'")) + #t))))) + (native-inputs + `(("bundler" ,bundler) + ("ruby-rails" ,ruby-rails) + ("ruby-rspec-rails" ,ruby-rspec-rails) + ;; This is needed for a test, but I'm unsure why + ("ruby-sass" ,ruby-sass) + ;; This is used as the ruby-execjs runtime + ("node" ,node))) + (propagated-inputs + `(("ruby-execjs" ,ruby-execjs))) + (synopsis "Parse CSS and add vendor prefixes to CSS rules") + (description + "Parse CSS and add vendor prefixes to CSS rules using values from the Can +I Use website.") + (home-page "https://github.com/ai/autoprefixer-rails") + (license license:expat))) + (define-public ruby-activemodel (package (name "ruby-activemodel") |