commit: 2b135f4fa2c144e244beca9e3bd69d3baa45cee5
parent ad9f6a166951ede414039c40ac57f1dc6b08d244
Author: Haelwenn (lanodan) Monnier <contact@hacktivis.me>
Date: Sun, 14 Aug 2022 13:45:58 +0200
dev-nodejs/semver: new package, add 7.3.7
Diffstat:
2 files changed, 35 insertions(+), 0 deletions(-)
diff --git a/dev-nodejs/semver/Manifest b/dev-nodejs/semver/Manifest
@@ -0,0 +1 @@
+DIST semver-7.3.7.tar.gz 49347 BLAKE2B c27870e33a15764817fd6fc1c5e7f87743f2b0b4b8504e616b7ba0702783cc28d64d3222133f9404e4d5e77928b19bef65c9fa3128fd217b4c4a6d4a85fc1264 SHA512 dba4086da00b20cfad9dc3427fc6b4c5ede9ead5da0546fb7f1f119d541126537d6fa09e7edaa6b89487a294bdad69214d01bad8478e5c0cbad3ccff75adae8a
diff --git a/dev-nodejs/semver/semver-7.3.7.ebuild b/dev-nodejs/semver/semver-7.3.7.ebuild
@@ -0,0 +1,34 @@
+# Copyright 2022 Haelwenn (lanodan) Monnier <contact@hacktivis.me>
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit nodejs
+
+DESCRIPTION="semantic version parser used by npm"
+HOMEPAGE="https://github.com/npm/node-semver"
+SRC_URI="https://github.com/npm/node-semver/archive/refs/tags/v${PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/node-${P}"
+LICENSE="ISC"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="test"
+
+#RESTRICT="!test? ( test )"
+#DEPEND="test? ( dev-nodejs/tap )"
+RDEPEND="dev-nodejs/lru-cache"
+
+RESTRICT="test"
+
+src_install() {
+ insinto "${NODEJS_SITELIB}${PN}"
+ doins package.json
+
+ cat package.json | jq -r .files[] | while read pkg
+ do
+ doins -r "$pkg"
+ done
+
+ fperms 755 "${NODEJS_SITELIB}${PN}/bin/semver.js"
+ dosym "${NODEJS_SITELIB}${PN}/bin/semver.js" "${EPREFIX}/usr/bin/semver"
+}