[PATCH 0/3] Add shopify-cli ruby gem to packages

OpenSubmitted by Trevor Richards.
Details
One participant
  • Trevor Richards
Owner
unassigned
Severity
normal
T
T
Trevor Richards wrote on 19 Jun 22:18 +0200
(address . guix-patches@gnu.org)
cover.1655669882.git.trev@trevdev.ca
Hello there! The following patches facilitate the addition of
ruby-shopify-cli. They involve dependency upgrades, dependency
additions and the shopify-cli Ruby gem package itself.

All dependency changes have been checked with the refresh and
build command.

Thank you for considering these patches.

Trevor Richards (3):
Upgrade ruby-liquid to version 5.3.0.
Upgrade ruby-listen to 3.7.1.
Add package ruby-shopify-cli and its missing dependencies.

gnu/packages/ruby.scm | 101
+++++++++++++++++++++++++++++++++---------
1 file changed, 80 insertions(+), 21 deletions(-)

--
2.36.1
T
[PATCH 1/3] Upgrade ruby-liquid to version 5.3.0.
(address . 56101@debbugs.gnu.org)
3d771975553830f4650e37a0e9c904c0ae3b9b8a.1655669882.git.trev@trevdev.ca
* gnu/packages/ruby.scm (ruby-liquid): Update to latest version.
(ruby-liquid-4.0): New variable. Prevents dependency breakage for
Jekyll.

---
gnu/packages/ruby.scm | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)

Toggle diff (52 lines)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 800ab194fe..47b4714f92 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -11185,13 +11185,13 @@ (define-public ruby-mercenary
 (define-public ruby-liquid
   (package
     (name "ruby-liquid")
-    (version "4.0.0")
+    (version "5.3.0")
     (source (origin
               (method url-fetch)
               (uri (rubygems-uri "liquid" version))
               (sha256
                (base32
- 
                 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))
+ 
"0b3nmab5vvn48mr0yrp5cryvdi1xw749jrkca0wwciv0wcb8y50v"))))
     (build-system ruby-build-system)
     (arguments `(#:tests? #f)); No rakefile
     (home-page "https://shopify.github.io/liquid/")
@@ -11200,6 +11200,17 @@ (define-public ruby-liquid
 to load dynamic content on storefronts.")
     (license license:expat)))
 
+(define-public ruby-liquid-4.0
+  (package
+    (inherit ruby-liquid)
+    (version "4.0.0")
+    (source (origin
+              (method url-fetch)
+              (uri (rubygems-uri "liquid" version))
+              (sha256
+               (base32
+ 
"17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))))
+
 (define-public ruby-forwardable-extended
   (package
     (name "ruby-forwardable-extended")
@@ -11313,7 +11324,7 @@ (define-public jekyll
        ("ruby-jekyll-sass-converter" ,ruby-jekyll-sass-converter)
        ("ruby-jekyll-watch" ,ruby-jekyll-watch)
        ("ruby-kramdown" ,ruby-kramdown-parser-gfm)
-       ("ruby-liquid" ,ruby-liquid)
+       ("ruby-liquid" ,ruby-liquid-4.0)
        ("ruby-mercenary" ,ruby-mercenary)
        ("ruby-pathutil" ,ruby-pathutil)
        ("ruby-rouge" ,ruby-rouge)
-- 
2.36.1
-----BEGIN PGP SIGNATURE-----

iIYEARYIAC4WIQTXT7EGCbVt/Iwh9m+FRs+EoT3V7wUCYq/teRAcdHJldkB0cmV2
ZGV2LmNhAAoJEIVGz4ShPdXvuSEA/jPO6QtE/48DXWhKT57SV5quc/ICBjbn/jow
ifba5VoxAP9VpSugC24BfztbDJEI8gVVUPEd2GbFBn1TKmTP10V+Cw==
=hpN/
-----END PGP SIGNATURE-----

T
[PATCH 2/3] Upgrade ruby-listen to 3.7.1.
(address . 56101@debbugs.gnu.org)
8d26f80f2644bf1c1c6b56fe683cd33d8f6501ea.1655669882.git.trev@trevdev.ca
* gnu/packages/ruby.scm (ruby-listen): Update to latest version

The tests that were set up for version 3.2.0 did not pass for
version 3.7.1. I
do not know Ruby well enough to appreciate why they are failing. A
related
issue is in the comments.

---
gnu/packages/ruby.scm | 21 +++------------------
1 file changed, 3 insertions(+), 18 deletions(-)

Toggle diff (48 lines)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 47b4714f92..058ec87934 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -6207,7 +6207,7 @@ (define-public ruby-rb-fsevent
 (define-public ruby-listen
   (package
     (name "ruby-listen")
-    (version "3.2.0")
+    (version "3.7.1")
     (source
      (origin
        ;; The gem does not include a Rakefile, so fetch from the 
        Git
@@ -6219,24 +6219,9 @@ (define-public ruby-listen
        (file-name (git-file-name name version))
        (sha256
         (base32
- 
          "1hkp1g6hk5clsmbd001gkc12ma6s459x820piajyasv61m87if24"))))
+ 
"113ixsssv7y5j85766hvha5mw5bwwbck0plj8166rigbb05qwp9w"))))
     (build-system ruby-build-system)
-    (arguments
-     `(#:test-target "spec"
-       #:phases
-       (modify-phases %standard-phases
-         (add-after 'unpack 'fix-files-in-gemspec
-           (lambda _
-             (substitute* "listen.gemspec"
-               (("`git ls-files -z`") "`find . -type f -printf 
                '%P\\\\0' |sort -z`"))
-             #t))
-         (add-before 'check 'remove-unnecessary-dependencies'
-           (lambda _
-             (substitute* "Rakefile"
-               ;; Rubocop is for code linting, and is unnecessary 
                   for running
-               ;; the tests.
-               ((".*rubocop.*") ""))
-             #t)))))
+    (arguments `(#:tests? #f)) ; 
https://github.com/guard/listen/issues/558
     (native-inputs
      (list bundler ruby-rspec))
     (inputs
-- 
2.36.1
T
[PATCH 3/3] Add package ruby-shopify-cli and its missing dependencies.
(address . 56101@debbugs.gnu.org)
1e7a45bc194f94577a82639b9212d162ab111529.1655669882.git.trev@trevdev.ca
* gnu/packages/ruby.scm (ruby-bugsnag): New package.
(ruby-theme-check): New package.
(ruby-shopify-cli): New package.

---
gnu/packages/ruby.scm | 63
+++++++++++++++++++++++++++++++++++++++++++
1 file changed, 63 insertions(+)

Toggle diff (92 lines)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 058ec87934..1637be8c1b 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -28,6 +28,7 @@
 ;;; Copyright © 2021 EuAndreh <eu@euandre.org>
 ;;; Copyright © 2020 Tomás Ortín Fernández 
 <tomasortin@mailbox.org>
 ;;; Copyright © 2021 Giovanni Biscuolo <g@xelera.eu>
+;;; Copyright © 2022 Trevor Richards <trev@trevdev.ca>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -11196,6 +11197,68 @@ (define-public ruby-liquid-4.0
                (base32
                 "17fa0jgwm9a935fyvzy8bysz7j5n1vf1x2wzqkdfd5k08dbw3x2y"))))))
 
+(define-public ruby-bugsnag
+  (package
+   (name "ruby-bugsnag")
+   (version "6.24.2")
+   (source (origin
+             (method url-fetch)
+             (uri (rubygems-uri "bugsnag" version))
+             (sha256
+              (base32
+ 
"0vlsqawqy8jn6cy03zcqw944p323zmr2lgadbw00m5r4lqc3bll4"))))
+   (arguments '(#:tests? #f)) ; No rakefile
+   (build-system ruby-build-system)
+   (propagated-inputs (list ruby-concurrent))
+   (synopsis "Ruby notifier for bugsnag.com")
+   (description "The Bugsnag exception reporter for Ruby gives 
you instant
+ notification of exceptions thrown from your Rails, Sinatra, Rack 
or plain
+ Ruby app.")
+   (home-page "https://github.com/bugsnag/bugsnag-ruby")
+   (license license:expat)))
+
+(define-public ruby-theme-check
+  (package
+   (name "ruby-theme-check")
+   (version "1.10.3")
+   (source (origin
+             (method url-fetch)
+             (uri (rubygems-uri "theme-check" version))
+             (sha256
+              (base32
+ 
"00sqbnbz6bspdzgmcdiziql1lvf0gzxk74hlvwcqsdka78bg0nk0"))))
+   (build-system ruby-build-system)
+   (arguments '(#:tests? #f))
+   (inputs `(("ruby-liquid" ,ruby-liquid)
+             ("ruby-nokogiri" ,ruby-nokogiri)
+             ("ruby-parser" ,ruby-parser)))
+   (propagated-inputs (list ruby-liquid ruby-nokogiri 
ruby-parser))
+   (synopsis "A Shopify Theme Linter")
+   (description "This package provides a Shopify Theme Linter")
+   (home-page "https://github.com/Shopify/theme-check")
+   (license license:expat)))
+
+(define-public ruby-shopify-cli
+  (package
+    (name "ruby-shopify-cli")
+    (version "2.19.0")
+    (source (origin
+              (method url-fetch)
+              (uri (rubygems-uri "shopify-cli" version))
+              (sha256
+               (base32
+ 
"1fcqc8bpai3pnp77v4im2l92p40jnqikch8s5336lc4gp498vfb5"))))
+    (build-system ruby-build-system)
+    (inputs `(("ruby-bugsnag" ,ruby-bugsnag)
+              ("ruby-listen"  ,ruby-listen)
+              ("ruby-theme-check" ,ruby-theme-check)))
+    (arguments '(#:tests? #f))
+    (synopsis "Shopify CLI helps you build Shopify themes and 
apps")
+    (description "Use Shopify CLI to automate and enhance your 
local
+ development workflow.")
+    (home-page "https://github.com/Shopify/shopify-cli")
+    (license license:expat)))
+
 (define-public ruby-forwardable-extended
   (package
     (name "ruby-forwardable-extended")
-- 
2.36.1
-----BEGIN PGP SIGNATURE-----

iIYEARYIAC4WIQTXT7EGCbVt/Iwh9m+FRs+EoT3V7wUCYq/vkBAcdHJldkB0cmV2
ZGV2LmNhAAoJEIVGz4ShPdXvW8sBAKNe6MZb6zzRle0QLv+uJ8vLFBPJRTo11gUd
OXdhgVC1AP40WJkhU6Ytf/r4rC0auI1vRiFV2q3DbRyAS8oFuT5wAw==
=DUmB
-----END PGP SIGNATURE-----

T
T
Trevor Richards wrote on 20 Jun 23:44 +0200
[PATCH] propagate dependencies that need to be on PATH
(address . 56101@debbugs.gnu.org)
1b2527defa502577492bc0d58b7e27f5e7aa50e3.1655766358.git.trev@trevdev.ca
It looks like I had declared some package dependencies
incorrectly. They fact that they worked after I installed them was
sheer luck. This patch should correct the dependency chain and
update the PATH correctly.

* gnu/packages/ruby.scm (ruby-theme-check): Correct dependencies
(ruby-shopify-cli): Correct dependencies

---
gnu/packages/ruby.scm | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)

Toggle diff (31 lines)
diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm
index 1637be8c1b..190322c644 100644
--- a/gnu/packages/ruby.scm
+++ b/gnu/packages/ruby.scm
@@ -11229,9 +11229,6 @@ (define-public ruby-theme-check
                "00sqbnbz6bspdzgmcdiziql1lvf0gzxk74hlvwcqsdka78bg0nk0"))))
    (build-system ruby-build-system)
    (arguments '(#:tests? #f))
-   (inputs `(("ruby-liquid" ,ruby-liquid)
-             ("ruby-nokogiri" ,ruby-nokogiri)
-             ("ruby-parser" ,ruby-parser)))
    (propagated-inputs (list ruby-liquid ruby-nokogiri 
    ruby-parser))
    (synopsis "A Shopify Theme Linter")
    (description "This package provides a Shopify Theme Linter")
@@ -11249,9 +11246,8 @@ (define-public ruby-shopify-cli
                (base32
                 "1fcqc8bpai3pnp77v4im2l92p40jnqikch8s5336lc4gp498vfb5"))))
     (build-system ruby-build-system)
-    (inputs `(("ruby-bugsnag" ,ruby-bugsnag)
-              ("ruby-listen"  ,ruby-listen)
-              ("ruby-theme-check" ,ruby-theme-check)))
+    (inputs (list ruby-bugsnag ruby-listen))
+    (propagated-inputs (list ruby-theme-check))
     (arguments '(#:tests? #f))
     (synopsis "Shopify CLI helps you build Shopify themes and 
     apps")
     (description "Use Shopify CLI to automate and enhance your 
     local
-- 
2.36.1
-----BEGIN PGP SIGNATURE-----

iIYEARYIAC4WIQTXT7EGCbVt/Iwh9m+FRs+EoT3V7wUCYrD+8xAcdHJldkB0cmV2
ZGV2LmNhAAoJEIVGz4ShPdXv8qUBAI8iaUQ09+wX/GzA8SLaNYpw8qliZasIJLFR
nnz/oUJZAQDeXTsZLyucbPT3QfSNMtAssSqaAApm2YDiG0lkvQqQBA==
=74OM
-----END PGP SIGNATURE-----

?