From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp1 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id YOOGF8rwu2HcNAEAgWs5BA (envelope-from ) for ; Fri, 17 Dec 2021 03:07:06 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp1 with LMTPS id wAFEE8rwu2EUbAAAbx9fmQ (envelope-from ) for ; Fri, 17 Dec 2021 02:07:06 +0000 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 0F2CB32968 for ; Fri, 17 Dec 2021 03:07:06 +0100 (CET) Received: from localhost ([::1]:53502 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1my2eG-0005FZ-6E for larch@yhetil.org; Thu, 16 Dec 2021 21:07:04 -0500 Received: from eggs.gnu.org ([209.51.188.92]:55148) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1my2dO-0004RV-1J for guix-patches@gnu.org; Thu, 16 Dec 2021 21:06:10 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:54064) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1my2dN-000821-Mx for guix-patches@gnu.org; Thu, 16 Dec 2021 21:06:09 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1my2dN-0005DZ-Hh for guix-patches@gnu.org; Thu, 16 Dec 2021 21:06:09 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#51838] [PATCH v5 30/45] gnu: Add node-file-uri-to-path. Resent-From: Philip McGrath Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 17 Dec 2021 02:06:09 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 51838 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 51838@debbugs.gnu.org Cc: Timothy Sample , Pierre Langlois , Jelle Licht , Philip McGrath , Liliana Marie Prikler Received: via spool by 51838-submit@debbugs.gnu.org id=B51838.163970676219934 (code B ref 51838); Fri, 17 Dec 2021 02:06:09 +0000 Received: (at 51838) by debbugs.gnu.org; 17 Dec 2021 02:06:02 +0000 Received: from localhost ([127.0.0.1]:37359 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1my2dG-0005BB-14 for submit@debbugs.gnu.org; Thu, 16 Dec 2021 21:06:02 -0500 Received: from mail-qt1-f170.google.com ([209.85.160.170]:38635) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1my2d8-00059w-Pn for 51838@debbugs.gnu.org; Thu, 16 Dec 2021 21:05:55 -0500 Received: by mail-qt1-f170.google.com with SMTP id 8so1200349qtx.5 for <51838@debbugs.gnu.org>; Thu, 16 Dec 2021 18:05:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=philipmcgrath.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=TMEGHgjDqWvJ21ZVQG9fhDd/jUJbOW/c1B/jRRJdX8A=; b=iRav/mS3sI6POV+Tjv1aLY/XHH4vXklsHzOlTBK7jQnR19skdAH8NioV0DGD62Oglk rqOSmX6slm7dBWMQQfb/Gh//8ltVfxgK+r7CTm9cjfxEki0YsvCizxUBAy2sdiZELHBu RCrx38vIawhOj1EAcoX00uOMhxMdnhTMWb+WNKVZBcR9KdTRtNMa6pMQAQxxiHBUaKnm XjoDUdv1Cq5/hO345MCJIH+dCks7LR87CbFqI9GwyRMW+y2g3w91f+s7JGeSaOCxJ1Go yhiKv3rGuNF5+KWGLkM9vMQFP6ZPvmoektU610Zu5P6mCUofc1Gu7ZZhq33SDjVZUPjx n1pw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=TMEGHgjDqWvJ21ZVQG9fhDd/jUJbOW/c1B/jRRJdX8A=; b=JTH2WGY2qi7yQ6L5zNbVq1iNPkFNirj71EuNcKaa/hd/AVmv8m0DSq38Mfbv5jdBUC iSmvBe24hHaCnW8/V6K8zat8D4rN+xlBN/pAgMUpnXZznRO/2aevIY/J7pYwzqyzbD+j 9LcaeLjHUZI7fJnAoQWPJK2/QK5gCyhp81IuiOG8oKWo0MYUsz6rK8gj0pz4amBqtYA8 HlhRB/4jN0qu/QMc2C3K5aIP8FdRQyOcKNdOOe2njFSunLngxW0Zt4AO41AABu6RBpgt Xhq6NFFowQ/hY5Dg9iNV6HRmWuuaGW/3bM8EMn8gsBgDySOa8L4yTpBXv56ClXUvkfl9 HQ2Q== X-Gm-Message-State: AOAM533F7UspoKYq+xzqmcpeyI3VDgY68DPc+9VQEsBWWnjKlSfROWdj wY7y7+1iK7k5AjYbuI7ahJHeUMB0rUe9pgcHEOg= X-Google-Smtp-Source: ABdhPJxMvtZ7hnAZye0LILM5yULYJhcVx1QZ9WAPetgMAjIfG/Px3w9LoogAday05uz93UoPL2+lLw== X-Received: by 2002:ac8:5991:: with SMTP id e17mr713356qte.344.1639706749435; Thu, 16 Dec 2021 18:05:49 -0800 (PST) Received: from localhost (c-73-125-89-242.hsd1.fl.comcast.net. [73.125.89.242]) by smtp.gmail.com with ESMTPSA id br43sm3955646qkb.57.2021.12.16.18.05.48 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 16 Dec 2021 18:05:49 -0800 (PST) From: Philip McGrath Date: Thu, 16 Dec 2021 21:03:10 -0500 Message-Id: <20211217020325.520821-31-philip@philipmcgrath.com> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20211217020325.520821-1-philip@philipmcgrath.com> References: <20211213060107.129223-1-philip@philipmcgrath.com> <20211217020325.520821-1-philip@philipmcgrath.com> MIME-Version: 1.0 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: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: "Guix-patches" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1639706826; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: 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=TMEGHgjDqWvJ21ZVQG9fhDd/jUJbOW/c1B/jRRJdX8A=; b=t7lAO+MulaXgY9DxwtEOZ3XqIaFJRs1O2zUACrJ8fe/NhYA3bzTgfcBV7Kum+6FRc6oI0e H0JkThdH2ODm+KaB1mBUnmtwthCEksA+BdB8TV0jc7n1qpjKHGl2jNqE278xGeOT9CYObc PGsuvIoEtjcHusk0E3JQx6fBr5be57TGkCR4No7d68eiNd00pXJCdvUafDe5jn6PWMUm5m KMd6JHGMVD7wN+UPVUp/buGaPy5LNyHNFFwZS/VVEvY5nPiopu4N7p0WKBz6o8U7plZzno J8jl1CmPxC1UZauFoBjYpPXIWo/Mpwf0peMI022pazO515pWEfBI0He+VWPZhQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1639706826; a=rsa-sha256; cv=none; b=g4ja8uT11QIoWX7LoDUzXqIKtC3uZUSMx/SvGI0r+ir/wgDsB0LFY+AD+sMWx7HEkWCasC 1sxrE9M00CvItM8MbeUe8bAOinW0GFoV0HRJA47UEneharrKijcAteqjbEEbQjMtQhWGQ0 hPkDLHd8ZCnznOjThPbNVcXbL+m1yJpWoa1LSS/sY5P88+chmlW3y+TZHBqDhiFp031qnT 87r/DI1RBgvF28FsP5mhqu+jMLRMgQLywswK/vNDS9+211GmgoJc9w+ihBHjGx+4nkm3bH kaKpFBFr0CMJloS3y4ogzpiDGbkXXmf2JAaUZTHrpBG4ixXUFkthtpPAYFya1A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=philipmcgrath.com header.s=google header.b="iRav/mS3"; dmarc=none; 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" X-Migadu-Spam-Score: -0.49 Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=philipmcgrath.com header.s=google header.b="iRav/mS3"; dmarc=none; 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" X-Migadu-Queue-Id: 0F2CB32968 X-Spam-Score: -0.49 X-Migadu-Scanner: scn0.migadu.com X-TUID: IQMttEByWm8g * gnu/packages/node-xyz.scm (node-file-uri-to-path): New variable. --- gnu/packages/node-xyz.scm | 55 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 55 insertions(+) diff --git a/gnu/packages/node-xyz.scm b/gnu/packages/node-xyz.scm index f5297c869b..c9afe8ccd2 100644 --- a/gnu/packages/node-xyz.scm +++ b/gnu/packages/node-xyz.scm @@ -24,6 +24,7 @@ (define-module (gnu packages node-xyz) #:use-module ((guix licenses) #:prefix license:) #:use-module (gnu packages sqlite) #:use-module (gnu packages python) + #:use-module (gnu packages web) #:use-module (guix gexp) #:use-module (guix packages) #:use-module (guix git-download) @@ -780,3 +781,57 @@ (define-public node-sqlite3 non-blocking bindings for SQLite3, written in modern C++ and tested for memory leaks.") (license license:bsd-3))) + +(define-public node-file-uri-to-path + (package + (name "node-file-uri-to-path") + (version "2.0.0") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/TooTallNate/file-uri-to-path") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 "08l779az44czm12xdhgcrnzpqw34s59hbrlfphs7g9y2k26drqav")))) + (native-inputs + (list esbuild)) + (build-system node-build-system) + (arguments + `(#:absent-dependencies + `("@types/mocha" + "@types/node" + "@typescript-eslint/eslint-plugin" + "@typescript-eslint/parser" + "cpy-cli" + "eslint" + "eslint-config-airbnb" + "eslint-config-prettier" + "eslint-import-resolver-typescript" + "eslint-plugin-import" + "eslint-plugin-jsx-a11y" + "eslint-plugin-react" + "mocha" + "rimraf" + "typescript") + #:phases + (modify-phases %standard-phases + (replace 'build + (lambda* (#:key inputs native-inputs #:allow-other-keys) + (copy-recursively "src" "dist") + (invoke (string-append + (assoc-ref (or native-inputs inputs) "esbuild") + "/bin/esbuild") + "dist/index.ts" + "--outfile=dist/src/index.js" + "--format=cjs" + "--sourcemap" + "--platform=node")))) + #:tests? #f)) + (home-page "https://github.com/TooTallNate/file-uri-to-path") + (synopsis "Convert a @code{file:} URI to a file path") + (description "This package provides a function to convert a @code{file:} +URI to a file path. It accepts a @code{file:} URI and returns a file path +suitable for use with the @code{fs} module functions.") + (license license:expat))) -- 2.32.0