@pnpm/exec.prepare-package 1000.0.26 → 1100.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -4
- package/package.json +13 -13
package/lib/index.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ import type { AllowBuild } from '@pnpm/types';
|
|
|
2
2
|
export interface PreparePackageOptions {
|
|
3
3
|
allowBuild?: AllowBuild;
|
|
4
4
|
ignoreScripts?: boolean;
|
|
5
|
-
rawConfig: Record<string, unknown>;
|
|
6
5
|
unsafePerm?: boolean;
|
|
6
|
+
userAgent?: string;
|
|
7
7
|
}
|
|
8
8
|
export declare function preparePackage(opts: PreparePackageOptions, gitRootDir: string, subDir: string): Promise<{
|
|
9
9
|
shouldBeBuilt: boolean;
|
package/lib/index.js
CHANGED
|
@@ -7,7 +7,6 @@ import { runLifecycleHook } from '@pnpm/exec.lifecycle';
|
|
|
7
7
|
import { safeReadPackageJsonFromDir } from '@pnpm/pkg-manifest.reader';
|
|
8
8
|
import { rimraf } from '@zkochan/rimraf';
|
|
9
9
|
import { preferredPM } from 'preferred-pm';
|
|
10
|
-
import { omit } from 'ramda';
|
|
11
10
|
// We don't run prepublishOnly to prepare the dependency.
|
|
12
11
|
// This might be counterintuitive as prepublishOnly is where a lot of packages put their build scripts.
|
|
13
12
|
// However, neither npm nor Yarn run prepublishOnly of git-hosted dependencies (checked on npm v10 and Yarn v3).
|
|
@@ -36,11 +35,9 @@ allowBuilds:
|
|
|
36
35
|
const execOpts = {
|
|
37
36
|
depPath: `${manifest.name}@${manifest.version}`,
|
|
38
37
|
pkgRoot: pkgDir,
|
|
39
|
-
// We can't prepare a package without running its lifecycle scripts.
|
|
40
|
-
// An alternative solution could be to throw an exception.
|
|
41
|
-
rawConfig: omit(['ignore-scripts'], opts.rawConfig),
|
|
42
38
|
rootModulesDir: pkgDir, // We don't need this property but there is currently no way to not set it.
|
|
43
39
|
unsafePerm: Boolean(opts.unsafePerm),
|
|
40
|
+
userAgent: opts.userAgent,
|
|
44
41
|
};
|
|
45
42
|
try {
|
|
46
43
|
const installScriptName = `${pm}-install`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pnpm/exec.prepare-package",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "1100.0.1",
|
|
4
4
|
"description": "Prepares a Git-hosted package",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pnpm",
|
|
@@ -28,18 +28,18 @@
|
|
|
28
28
|
"execa": "npm:safe-execa@0.3.0",
|
|
29
29
|
"preferred-pm": "^5.0.0",
|
|
30
30
|
"ramda": "npm:@pnpm/ramda@0.28.1",
|
|
31
|
-
"@pnpm/error": "
|
|
32
|
-
"@pnpm/
|
|
33
|
-
"@pnpm/types": "
|
|
34
|
-
"@pnpm/
|
|
31
|
+
"@pnpm/error": "1100.0.0",
|
|
32
|
+
"@pnpm/pkg-manifest.reader": "1100.0.1",
|
|
33
|
+
"@pnpm/types": "1101.0.0",
|
|
34
|
+
"@pnpm/exec.lifecycle": "1100.0.1"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
37
|
-
"@types/ramda": "0.
|
|
37
|
+
"@types/ramda": "0.31.1",
|
|
38
38
|
"load-json-file": "^7.0.1",
|
|
39
|
-
"@pnpm/
|
|
40
|
-
"@pnpm/prepare": "
|
|
41
|
-
"@pnpm/test-
|
|
42
|
-
"@pnpm/test-
|
|
39
|
+
"@pnpm/prepare": "1100.0.1",
|
|
40
|
+
"@pnpm/exec.prepare-package": "1100.0.1",
|
|
41
|
+
"@pnpm/test-ipc-server": "1100.0.0",
|
|
42
|
+
"@pnpm/test-fixtures": "1100.0.0"
|
|
43
43
|
},
|
|
44
44
|
"engines": {
|
|
45
45
|
"node": ">=22.13"
|
|
@@ -49,8 +49,8 @@
|
|
|
49
49
|
},
|
|
50
50
|
"scripts": {
|
|
51
51
|
"lint": "eslint \"src/**/*.ts\" \"test/**/*.ts\"",
|
|
52
|
-
"test": "
|
|
53
|
-
"compile": "tsgo --build &&
|
|
54
|
-
"
|
|
52
|
+
"test": "pn compile && pn .test",
|
|
53
|
+
"compile": "tsgo --build && pn lint --fix",
|
|
54
|
+
".test": "cross-env NODE_OPTIONS=\"$NODE_OPTIONS --experimental-vm-modules --disable-warning=ExperimentalWarning --disable-warning=DEP0169\" jest"
|
|
55
55
|
}
|
|
56
56
|
}
|