2021-04-12 06:06:53 +02:00
|
|
|
# Template file for 'pnpm'
|
|
|
|
pkgname=pnpm
|
2021-05-12 20:07:15 +02:00
|
|
|
version=6.3.0
|
2021-04-12 06:06:53 +02:00
|
|
|
revision=1
|
|
|
|
build_style=fetch
|
|
|
|
hostmakedepends="nodejs jq"
|
|
|
|
depends="nodejs"
|
|
|
|
short_desc="Fast, disk space efficient package manager"
|
|
|
|
maintainer="reback00 <reback00@protonmail.com>"
|
|
|
|
license="MIT"
|
|
|
|
homepage="https://pnpm.js.org/"
|
|
|
|
distfiles="https://registry.npmjs.org/${pkgname}/-/${pkgname}-${version}.tgz"
|
2021-05-12 20:07:15 +02:00
|
|
|
checksum=eebd1dfe4466e5e84fb83332c5bf0e970002eedcb1cae8922257a477d67c5636
|
2021-04-12 06:06:53 +02:00
|
|
|
python_version=3
|
|
|
|
|
|
|
|
do_install() {
|
|
|
|
npm install -g --user root --prefix "${DESTDIR}/usr" "${XBPS_SRCDISTDIR}/${pkgname}-${version}/${pkgname}-${version}.tgz"
|
|
|
|
local _npmdir="${DESTDIR}/usr/lib/node_modules/${pkgname}"
|
|
|
|
|
|
|
|
# Sort and cleanup package.json
|
|
|
|
jq '.|=with_entries(select(.key|test("_.+")|not))' "$_npmdir/package.json" > "$_npmdir/package.json"
|
|
|
|
chmod 644 "$_npmdir/package.json"
|
|
|
|
|
|
|
|
# Delete JS SourceMaps
|
|
|
|
find "${DESTDIR}/usr/lib" -depth -name '*.map' -delete
|
|
|
|
|
|
|
|
vlicense "$_npmdir/LICENSE"
|
|
|
|
vdoc "$_npmdir/README.md"
|
|
|
|
rm -rf "${DESTDIR}/usr/etc" "$_npmdir/LICENSE" "$_npmdir/README.md"
|
|
|
|
}
|