void-packages/srcpkgs/pnpm/template

27 lines
831 B
Bash

# Template file for 'pnpm'
pkgname=pnpm
version=9.1.3
revision=1
build_style=fetch
hostmakedepends="nodejs jq"
depends="nodejs"
short_desc="Fast, disk space efficient package manager"
maintainer="Bnyro <bnyro@tutanota.com>"
license="MIT"
homepage="https://pnpm.io/"
distfiles="https://registry.npmjs.org/pnpm/-/pnpm-${version}.tgz"
checksum=7f63001edc077f1cff96cacba901f350796287a2800dfa83fe898f94183e4f5f
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}"
# 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"
}