From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms8.migadu.com with LMTPS id UHijGwjvxGXrMwEAqHPOHw:P1 (envelope-from ) for ; Thu, 08 Feb 2024 16:11:04 +0100 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id UHijGwjvxGXrMwEAqHPOHw (envelope-from ) for ; Thu, 08 Feb 2024 16:11:04 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=rimm.ee header.s=herman header.b=K8HMDgRW; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1707405064; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=pFvneAouSrfQO/51rjgFqoW/jRpwUKKG6YQLPdyX0GQ=; b=CWvOcwvwI7Nl52K5rLV7wJSxiy8SN3vvKqNjLUb+m77EVGrhMM2G9HPzvNmunyeyw1A5ud 8IRh41oa9EDk56rm8ge/lVU9WmXnnHUw56rqIba0vKsmDyKPfcB4lwKJCYkuThjWxp/sU2 Z/jowkaaTSmwt+oHEk+VqgwHO0p7yNsAcV/t9Aoyb4NLloJvGJ+BPYFvVyG9a2G4fEiP28 kAh2XJk1vNsZLyzNbBnfS09mszUsayxHQ8xaBGzMZDh9vIGW7s+RvgPbbW+a7qWc/fgO9t W38QQXwOJdAS9+949qRFOT424vzesIUevBr/QNTmqk/3j7VgDofAWKo8p45otw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=rimm.ee header.s=herman header.b=K8HMDgRW; dmarc=pass (policy=none) header.from=gnu.org; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1707405064; a=rsa-sha256; cv=none; b=DJP6APSqb5oZP2q8Ijc45SDS+nSSpfkLDNQCCIESrqE3aAqNBDPki7lB97dotrcFtfSiBO K9ZMbZ8iQceZ2n12wQR1axOM49Ptk0jBA8uuv1wNtXg0YdQbW1uV0BrTATbWsm4qv7XyR5 z6tQPxojENxFIPKGKucxIJrors9E9AyFSeuAvui4nJQrV4us7PlMgq5BKkGaZI84Fq/XgG TSdNfvvXZuCId8ILH5dXlDFCg1r+Bl0/vAUdkk4P4ZKZN/iPslNjXawdXGxP8OzdifVqUf eqP/r8VMv713CqRltvXnzKg0wpy6sGE09IxTMiEgdjrWhykDFp7kasprTVH9ew== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id ED52030409 for ; Thu, 8 Feb 2024 16:11:03 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rY638-0004hI-FL; Thu, 08 Feb 2024 10:10:50 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rY636-0004gt-2Z for guix-patches@gnu.org; Thu, 08 Feb 2024 10:10:48 -0500 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rY635-0007tT-7U for guix-patches@gnu.org; Thu, 08 Feb 2024 10:10:47 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rY63J-0003Px-KF for guix-patches@gnu.org; Thu, 08 Feb 2024 10:11:01 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#54358] [PATCH] gnu: parinfer-rust: Add phase to install Vim and Kakoune plugins. References: <20220312220030.17172-1-paren@disroot.org> In-Reply-To: <20220312220030.17172-1-paren@disroot.org> Resent-From: Herman Rimm Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Thu, 08 Feb 2024 15:11:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54358 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 54358@debbugs.gnu.org Cc: "\(unmatched-parenthesis" Received: via spool by 54358-submit@debbugs.gnu.org id=B54358.170740505513123 (code B ref 54358); Thu, 08 Feb 2024 15:11:01 +0000 Received: (at 54358) by debbugs.gnu.org; 8 Feb 2024 15:10:55 +0000 Received: from localhost ([127.0.0.1]:33428 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rY63D-0003PZ-1r for submit@debbugs.gnu.org; Thu, 08 Feb 2024 10:10:55 -0500 Received: from 81-205-150-117.fixed.kpn.net ([81.205.150.117]:47059 helo=email.rimm.ee) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rY638-0003P5-FM for 54358@debbugs.gnu.org; Thu, 08 Feb 2024 10:10:52 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rimm.ee; s=herman; t=1707405027; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=pFvneAouSrfQO/51rjgFqoW/jRpwUKKG6YQLPdyX0GQ=; b=K8HMDgRWdd67DEG+lQ196VgTT24RanZdJvCJZbRizNnQ4/zW5mnVAMzK/eTsUPlADixARy LMpGWHc8Z7PhK45s3TAQGkpRwYdvw+kFmNmTjDF4McYkMy5XdwAEIwawp87EuvlOmNVKwX iptGisJcOD2Mt0xM9rW5qcHkPnZI+0BLudxSmjZC1R+E+NmR1pYBMs3GbPw0JhtzOj0/jj O8Vh1Oi8Pm4SsO6vRU9SmVIeEO9rssP9mma5h+X5UhDZV5xdiTxDbL23PzquH27siyFgEk LvACK7c9VAg6x1br7JsGFhme0xDlMv+BnNAuGED3Ah6O6MvSlbHETxGOIQV1EQ== Received: by 81-205-150-117.fixed.kpn.net (OpenSMTPD) with ESMTPSA id 8e5f46fa (TLSv1.3:TLS_CHACHA20_POLY1305_SHA256:256:NO); Thu, 8 Feb 2024 15:10:27 +0000 (UTC) Date: Thu, 8 Feb 2024 16:10:15 +0100 Message-ID: X-Mailer: git-send-email 2.41.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-to: Herman Rimm X-ACL-Warn: , Herman Rimm via Guix-patches From: Herman Rimm via Guix-patches via Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -7.17 X-Spam-Score: -7.17 X-Migadu-Queue-Id: ED52030409 X-Migadu-Scanner: mx12.migadu.com X-TUID: oiFWXdbxLk4z From: "(unmatched-parenthesis" * gnu/packages/text-editors.scm (rust-parinfer)[arguments]: Install the bundled Vim and Kakoune plugins. [outputs]: Add 'plugin' output. [description]: Specify how to refer to output. Change-Id: I881315481ec08c59576c4530ae72b877c399fc66 --- Hi, I think it's fine to have this patch as a separate issue, since it also adds the Vim editor plugin. The plugins and shared library are installed to the 'plugin' output. The Vim plugin shared library path is patched. Cheers, Herman gnu/packages/text-editors.scm | 32 +++++++++++++++++++++++++++++--- 1 file changed, 29 insertions(+), 3 deletions(-) diff --git a/gnu/packages/text-editors.scm b/gnu/packages/text-editors.scm index 3fefd59a19..b4d3c23e42 100644 --- a/gnu/packages/text-editors.scm +++ b/gnu/packages/text-editors.scm @@ -31,6 +31,8 @@ ;;; Copyright © 2023 Maxim Cournoyer ;;; Copyright © 2023 Jaeme Sifat ;;; Copyright © 2023 David Pflug +;;; Copyright © 2024 ( +;;; Copyright © 2024 Herman Rimm ;;; ;;; This file is part of GNU Guix. ;;; @@ -308,7 +310,10 @@ (define-public parinfer-rust (sha256 (base32 "0hj5in5h7pj72m4ag80ing513fh65q8xlsf341qzm3vmxm3y3jgd")) (file-name (git-file-name name version)))) + (properties + `((output-synopsis "plugin" "Plugins with shared libraries"))) (build-system cargo-build-system) + (outputs (list "out" "plugin")) (arguments `(#:cargo-inputs (("rust-getopts" ,rust-getopts-0.2) @@ -318,15 +323,36 @@ (define-public parinfer-rust ("rust-serde-json" ,rust-serde-json-1) ("rust-serde-derive" ,rust-serde-derive-1) ("rust-unicode-segmentation" ,rust-unicode-segmentation-1) - ("rust-unicode-width" ,rust-unicode-width-0.1)))) + ("rust-unicode-width" ,rust-unicode-width-0.1)) + #:phases + (modify-phases %standard-phases + (add-after 'install 'install-plugins-and-libs + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "plugin")) + (lib (string-append out "/lib")) + (vimfiles (string-append out "/share/vim/vimfiles/" + "pack/guix/start/parinfer")) + (doc (string-append vimfiles "/doc")) + (plugin (string-append vimfiles "/plugin")) + (autoload (string-append out "/share/kak/autoload"))) + (with-directory-excursion "target/release" + (install-file "libparinfer_rust.so" lib)) + (copy-recursively "doc" doc) + (copy-recursively "plugin" plugin) + (copy-recursively "rc" autoload) + (substitute* (string-append plugin "/parinfer.vim") + (("(let s:libdir = ).*" all libdir) + (format #f "~a'~a'\n" libdir lib))))))))) (inputs (list clang)) (home-page "https://github.com/justinbarclay/parinfer-rust") (synopsis "Infer parentheses for Clojure, Lisp and Scheme") (description "Parinfer is a plugin for Kakoune, Vim, Neovim and Emacs that infers -parentheses and indentation. This library can be called from other editors that -can load dynamic libraries.") +parentheses and indentation. This library can be called from other +editors that can load dynamic libraries. @code{gexp-input} can be used +to refer to the 'plugin' output of this package, within a +@code{home-environment} record.") (license license:expat))) (define-public joe base-commit: 7d3aa578ef0b7fcfcddf0623f806ec625aab6ccd -- 2.41.0