mirror of
https://github.com/termux/termux-packages.git
synced 2025-08-08 01:32:08 +00:00
22 lines
853 B
Diff
22 lines
853 B
Diff
--- ./deps/npm/lib/commands/install.js.orig 2023-01-17 18:37:18.553261550 +0530
|
|
+++ ./deps/npm/lib/commands/install.js 2023-01-17 18:44:48.711879839 +0530
|
|
@@ -118,6 +118,18 @@
|
|
throw e
|
|
}
|
|
}
|
|
+ try {
|
|
+ if (forced) {
|
|
+ log.warn(
|
|
+ 'install',
|
|
+ `Force installing npm version unpatched version of ${npmManifest.version}. This is very likely to break installation of global packages using npm. See https://github.com/termux/termux-packages/issues/13293`
|
|
+ )
|
|
+ } else {
|
|
+ throw new Error("Can't install npm globally as it will very likely break installation of global packages using npm. See https://github.com/termux/termux-packages/issues/13293")
|
|
+ }
|
|
+ } catch(e) {
|
|
+ throw e
|
|
+ }
|
|
}
|
|
|
|
// don't try to install the prefix into itself
|