[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#51838] [PATCH v9 26/41] gnu: Add node-file-uri-to-path.
From: |
Philip McGrath |
Subject: |
[bug#51838] [PATCH v9 26/41] gnu: Add node-file-uri-to-path. |
Date: |
Sat, 8 Jan 2022 03:42:14 -0500 |
* 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 9682582eec..c35ae10990 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)
@@ -829,3 +830,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
+ `(#:phases
+ (modify-phases %standard-phases
+ (add-after 'patch-dependencies 'delete-dependencies
+ (lambda args
+ (delete-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"))))
+ (replace 'build
+ (lambda* (#:key inputs native-inputs #:allow-other-keys)
+ (copy-recursively "src" "dist")
+ (invoke (search-input-file (or native-inputs inputs)
+ "/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
- [bug#51838] [PATCH v9 18/41] gnu: Add node-inherits., (continued)
- [bug#51838] [PATCH v9 18/41] gnu: Add node-inherits., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 11/41] gnu: node-llparse-frontend-bootstrap: Use 'delete-dependencies'., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 14/41] gnu: node-wrappy: Use 'delete-dependencies'., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 15/41] gnu: node-once: Use 'delete-dependencies'., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 12/41] gnu: node-llparse-bootstrap: Use 'delete-dependencies'., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 23/41] gnu: Add node-openzwave-shared., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 21/41] gnu: Add node-readable-stream., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 19/41] gnu: Add node-safe-buffer., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 20/41] gnu: Add node-string-decoder., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 22/41] gnu: Add node-nan., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 26/41] gnu: Add node-file-uri-to-path.,
Philip McGrath <=
- [bug#51838] [PATCH v9 29/41] gnu: Add node-ms., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 24/41] gnu: Add node-addon-api., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 28/41] gnu: Add node-segfault-handler., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 25/41] gnu: Add node-sqlite3., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 30/41] gnu: Add node-debug., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 27/41] gnu: Add node-bindings., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 31/41] gnu: Add node-serialport-binding-abstract., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 32/41] gnu: Add node-serialport-parser-delimiter., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 33/41] gnu: Add node-serialport-parser-readline., Philip McGrath, 2022/01/08
- [bug#51838] [PATCH v9 35/41] gnu: Add node-serialport-parser-regex., Philip McGrath, 2022/01/08