From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:470:142:3::10]:57776) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i8WRh-0004qc-00 for guix-patches@gnu.org; Thu, 12 Sep 2019 17:16:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i8WRf-0002Hi-7W for guix-patches@gnu.org; Thu, 12 Sep 2019 17:16:04 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:35310) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1i8WRd-0002G4-UK for guix-patches@gnu.org; Thu, 12 Sep 2019 17:16:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1i8WRd-0007ic-Oh for guix-patches@gnu.org; Thu, 12 Sep 2019 17:16:01 -0400 Subject: [bug#37365] [PATCH] - Amendment: Enable tests Resent-Message-ID: References: <87tv9k3ks0.fsf@rekahsoft.ca> <87o8zr34gz.fsf@rekahsoft.ca> <20190911073719.GH977@E5400> From: "Collin J. Doering" In-reply-to: <20190911073719.GH977@E5400> Date: Thu, 12 Sep 2019 17:15:06 -0400 Message-ID: <87k1ad2p45.fsf@rekahsoft.ca> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Efraim Flashner Cc: 37365@debbugs.gnu.org --=-=-= Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" --==-=-= Content-Type: text/plain Hi Efraim, Firstly, thanks for taking the time to review this. I have attached updated patches with your suggested changes. On 11 Sep 2019 at 03:37, Efraim Flashner wrote: > These should be two patches, the first one to add the ruby package and > the second to add the zsh package. Makes sense. > >> + (replace 'install >> + (lambda* (#:key outputs #:allow-other-keys) >> + (let* ((out (assoc-ref outputs "out")) >> + (install-path (string-append out "/share/zsh/plugins/zsh-autosuggestions"))) >> + (mkdir-p install-path) >> + (invoke "make" "all") >> + (copy-file "zsh-autosuggestions.zsh" (string-append install-path "/zsh-autosuggestions.zsh")) >> + #t)))))) > > I don't use zsh so I'm asking without knowing anything about the > directory structure, is %out/share/zsh/plugins/zsh-autosuggestions the > correct folder? The only folder I currently have after zsh is > site-functions. > > (ins)efraim@E5400 ~$ tree .guix-profile/share/zsh/ > .guix-profile/share/zsh/ > site-functions > _mpv -> /gnu/store/acrlmdnmrkivbdrry756pf9grsx2x814-mpv-0.29.1/share/zsh/site-functions/_mpv > _vifm -> /gnu/store/1l9b676paigfc3fx9r8h6h2k5d33wrhk-vifm-0.10.1/share/zsh/site-functions/_vifm > _wgetpaste -> /gnu/store/k5g3fa3i59yxy3n9vf8lm1nfbz5whq2i-wgetpaste-2.29/share/zsh/site-functions/_wgetpaste I did some more looking into this (as I just copied what I saw done for a few zsh plugin packages for archlinux). The directories you list above (namely .../'share/zsh/site-functions/_...') are for zsh site-functions (begin with an underscore) and not plugins that extend the functionality of zsh (which will have to be sourced from the users `~/.zshrc`). Something like this should do: source ~/.guix-profile/share/zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.zsh Anyways, I think that `.../share/zsh/plugins//...` is a good place for this (and any other zsh plugins). WDYT? Finally, you will find an updated patch set attached to this email that includes splitting the ruby package out into its own patch, as well as minor touch up to be more consistent with naming throughout the rest of the guix code base. Kind regards, --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAEBCAAdFiEE+NVG868371PRtki+e03rkyErMCIFAl16tVoACgkQe03rkyEr MCLRQQgAmiH/kpNx5aREFI9e9D8IU6MMA20WkagikSR34etHZH2EoLujI5aUAMO8 tmSW+o6upqqEzdyikCqmW+C8qeZLtoWzNTNs7H4K8xAgMFfZiujKdXoIwemExFTE tJNxO+SjNoE6iVcrdJxPH81AP9SRz0WiCTtl89+LJ+N25K7JDpEgKyiGGM6TQamL gaKuLRVchdllc4BpYaxRhSpaH2jgXk3s2UIUOikcZBqOnkai7RXN1MpOtrQHUhtD DoX8oAobk9Q07J1RwbBZGJT0FfC5H9AefOkihT5UKn/WGpSv+y8LzCEjQEThirph YZ4UQd388UBe/EMR/JEF2+nYXF2eCg== =Rrpq -----END PGP SIGNATURE----- --==-=-=-- --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: attachment; filename=0001-gnu-Add-ruby-rspec-wait.patch Content-Transfer-Encoding: quoted-printable Content-Description: 0001-gnu-Add-ruby-rspec-wait.patch >From 00e3e91719ce049b04415bda07588357eb776d48 Mon Sep 17 00:00:00 2001 From: "Collin J. Doering" Date: Thu, 12 Sep 2019 17:09:00 -0400 Subject: [PATCH 1/2] gnu: Add ruby-rspec-wait * gnu/packages/ruby.scm (ruby-rspec-wait): New variable. Signed-off-by: Collin J. Doering --- gnu/packages/ruby.scm | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/ruby.scm b/gnu/packages/ruby.scm index ef9792bc0f..110e5e21ac 100644 --- a/gnu/packages/ruby.scm +++ b/gnu/packages/ruby.scm @@ -17,6 +17,7 @@ ;;; Copyright =C2=A9 2019 Mikhail Kirillov ;;; Copyright =C2=A9 2019 Jelle Licht ;;; Copyright =C2=A9 2019 Brian Leung +;;; Copyright =C2=A9 2019 Collin J. Doering ;;; ;;; This file is part of GNU Guix. ;;; @@ -670,6 +671,32 @@ RSpec tests.") (home-page "https://github.com/dblock/rspec-rerun") (license license:expat))) =20 +(define-public ruby-rspec-wait + (package + (name "ruby-rspec-wait") + (version "0.0.9") + (source + (origin + (method url-fetch) + (uri (rubygems-uri "rspec-wait" version)) + (sha256 + (base32 + "0gvj1bp5ccx001dyvcgk2j49s5sl6vs9fdaqqb08z3bd1554hsww")))) + (build-system ruby-build-system) + (arguments + '(#:phases (modify-phases %standard-phases + (replace 'check + (lambda _ + (invoke "rake" "spec")))))) + (native-inputs + `(("bundler" ,bundler))) + (propagated-inputs `(("ruby-rspec" ,ruby-rspec))) + (synopsis "Wait for conditions in RSpec") + (description "Wait for conditions in RSpec") + (home-page + "https://github.com/laserlemon/rspec-wait") + (license license:expat))) + (define-public ruby-rspec (package (name "ruby-rspec") --=20 2.23.0 --=-=-= Content-Type: text/x-patch; charset=utf-8 Content-Disposition: attachment; filename=0002-gnu-Add-zsh-autosuggestions.patch Content-Transfer-Encoding: quoted-printable Content-Description: 0001-gnu-Add-zsh-autosuggestions.patch >From 2497a3b3337b72ac932a0edad9c0729325a69870 Mon Sep 17 00:00:00 2001 From: "Collin J. Doering" Date: Thu, 12 Sep 2019 17:09:07 -0400 Subject: [PATCH 2/2] gnu: Add zsh-autosuggestions * gnu/packages/shellutils.scm (zsh-autosuggestions): New variable. Signed-off-by: Collin J. Doering --- gnu/packages/shellutils.scm | 48 +++++++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/gnu/packages/shellutils.scm b/gnu/packages/shellutils.scm index f7542ea759..847cd931b3 100644 --- a/gnu/packages/shellutils.scm +++ b/gnu/packages/shellutils.scm @@ -5,6 +5,7 @@ ;;; Copyright =C2=A9 2017 Stefan Reich=C3=B6r ;;; Copyright =C2=A9 2018 Tobias Geerinckx-Rice ;;; Copyright =C2=A9 2018 Benjamin Slade +;;; Copyright =C2=A9 2019 Collin J. Doering ;;; ;;; This file is part of GNU Guix. ;;; @@ -33,11 +34,58 @@ #:use-module (gnu packages ncurses) #:use-module (gnu packages readline) #:use-module (gnu packages pkg-config) + #:use-module (gnu packages ruby) + #:use-module (gnu packages tmux) + #:use-module (gnu packages shells) #:use-module (guix utils) #:use-module (guix build-system gnu) #:use-module (guix build-system go) #:use-module (guix build-system python)) =20 +(define-public zsh-autosuggestions + (package + (name "zsh-autosuggestions") + (version "0.6.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/zsh-users/zsh-autosuggestions= .git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1h8h2mz9wpjpymgl2p7pc146c1jgb3dggpvzwm9ln3in336wl95c")))) + (build-system gnu-build-system) + (native-inputs + `(("tmux" ,tmux) + ("zsh" ,zsh) + ("ruby" ,ruby) + ("ruby-rspec" ,ruby-rspec) + ("ruby-rspec-wait" ,ruby-rspec-wait) + ("ruby-pry" ,ruby-pry) + ("ruby-byebug" ,ruby-byebug))) + (arguments + '(#:phases + (modify-phases %standard-phases + (delete 'configure) + (replace 'check ; Tests use ruby's bundler; instead execute rspec= directly + (lambda _ + (setenv "TMUX_TMPDIR" (getenv "TMPDIR")) + (setenv "SHELL" (which "zsh")) + (invoke "rspec"))) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (zsh-plugins (string-append out "/share/zsh/plugins/zs= h-autosuggestions"))) + (invoke "make" "all") + (install-file "zsh-autosuggestions.zsh" zsh-plugins) + #t)))))) + (synopsis "Fish-like autosuggestions for zsh") + (description + "Fish-like fast/unobtrusive autosuggestions for zsh. It suggests com= mands as you type.") + (home-page "https://github.com/zsh-users/zsh-autosuggestions.git") + (license license:expat))) + (define-public envstore (package (name "envstore") --=20 2.23.0 --=-=-= Content-Type: text/plain -- Collin J. Doering http://rekahsoft.ca http://blog.rekahsoft.ca http://git.rekahsoft.ca --=-=-=--