Files
haikuports/sys-apps/npm/npm-10.9.2.recipe
2024-12-12 17:02:10 +01:00

44 lines
958 B
Bash
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
SUMMARY="A JavaScript package manager"
DESCRIPTION="npm is a JavaScript package manager for Nodejs."
HOMEPAGE="https://npmjs.com"
COPYRIGHT="2016-present, npm, Inc. and Contributors"
LICENSE="BSD (2-clause)"
REVISION="1"
SOURCE_URI="https://github.com/npm/cli/archive/v$portVersion.tar.gz"
SOURCE_DIR="cli-$portVersion"
CHECKSUM_SHA256="6b19afc5ba4bf92108ec366feaf82107fc137274c42158588b2cf9117bc870dc"
ARCHITECTURES="x86_64 !x86_gcc2"
PROVIDES="
npm = $portVersion
cmd:npm = $portVersion
cmd:npx = $portVersion
"
REQUIRES="
cmd:node > 20
"
BUILD_PREREQUIRES="
cmd:git
cmd:node >= 20
"
BUILD()
{
node scripts/resetdeps.js
node . run build -w docs
}
INSTALL()
{
node . install -g --prefix="$prefix" "$(node . pack --ignore-scripts | tail -1)"
}
TEST()
{
# Suites: 2 failed, 100 passed, 102 of 102 completed
# Asserts: 5 failed, 4656 passed, 6 skip, of 46
node . run test --ignore-scripts
}