@pnpm/fs.indexed-pkg-importer 1100.0.35 → 1100.0.37
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/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,21 @@
|
|
|
1
1
|
# @pnpm/fs.indexed-pkg-importer
|
|
2
2
|
|
|
3
|
+
## 1100.0.37
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- `pnpm prune --prod` no longer fails with `ERR_PNPM_EXDEV` when `node_modules` was copied from an earlier Docker build stage [#17424](https://github.com/pnpm/pnpm/issues/17424).
|
|
8
|
+
|
|
9
|
+
## 1100.0.36
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- `pnpm deploy` now keeps a deployed symlink to a directory inside the project even if the directory is not among the deployed files, such as a link into `node_modules` [#17288](https://github.com/pnpm/pnpm/issues/17288).
|
|
14
|
+
|
|
15
|
+
- Updated dependencies:
|
|
16
|
+
- @pnpm/core-loggers@1101.0.4
|
|
17
|
+
- @pnpm/store.controller-types@1101.3.5
|
|
18
|
+
|
|
3
19
|
## 1100.0.35
|
|
4
20
|
|
|
5
21
|
### Patch Changes
|
|
@@ -17,7 +17,9 @@ export function copyInternalSymlink(src, dest, links) {
|
|
|
17
17
|
if (escapesDir(links.writtenDir, resolved))
|
|
18
18
|
return false;
|
|
19
19
|
if (!links.imported.has(path.relative(links.writtenDir, resolved).split(path.sep).join('/'))) {
|
|
20
|
-
|
|
20
|
+
const isDir = isDirectory(src);
|
|
21
|
+
if (links.symlinkTargets !== 'internal' || !isDir)
|
|
22
|
+
return isDir;
|
|
21
23
|
}
|
|
22
24
|
if (process.platform !== 'win32') {
|
|
23
25
|
fs.symlinkSync(target, dest);
|
package/lib/importIndexedDir.js
CHANGED
|
@@ -239,7 +239,7 @@ function symlinkDirs(opts, filenames, dirs) {
|
|
|
239
239
|
imported.add(entry);
|
|
240
240
|
}
|
|
241
241
|
}
|
|
242
|
-
return { ...dirs, imported };
|
|
242
|
+
return { ...dirs, imported, symlinkTargets: opts.symlinkTargets };
|
|
243
243
|
}
|
|
244
244
|
function importEntry(importFile, src, dest, links) {
|
|
245
245
|
if (links != null && fs.lstatSync(src).isSymbolicLink() && copyInternalSymlink(src, dest, links))
|
package/lib/overwriteDir.js
CHANGED
|
@@ -85,21 +85,35 @@ function backupAndRemoveTargetAfterFailedDisplace(newDir, aside, err) {
|
|
|
85
85
|
switch (err.code) {
|
|
86
86
|
case 'ENOENT':
|
|
87
87
|
return undefined;
|
|
88
|
-
// Windows refuses to rename a directory a process runs from
|
|
88
|
+
// Windows refuses to rename a directory a process runs from, and an
|
|
89
|
+
// overlay filesystem refuses to rename one from a lower layer; copy a
|
|
89
90
|
// backup to `aside` before removing `newDir` in place so a failed
|
|
90
91
|
// stage rename can still restore the previous package.
|
|
91
92
|
case 'EPERM':
|
|
92
93
|
case 'EACCES':
|
|
93
94
|
case 'EBUSY':
|
|
95
|
+
case 'EXDEV':
|
|
94
96
|
try {
|
|
95
97
|
fs.cpSync(newDir, aside, { recursive: true, verbatimSymlinks: true });
|
|
96
|
-
rimrafSync(newDir);
|
|
97
|
-
return aside;
|
|
98
98
|
}
|
|
99
|
-
catch (
|
|
99
|
+
catch (copyErr) {
|
|
100
100
|
removeQuietly(aside);
|
|
101
|
-
throw
|
|
101
|
+
throw copyErr;
|
|
102
|
+
}
|
|
103
|
+
try {
|
|
104
|
+
rimrafSync(newDir);
|
|
105
|
+
}
|
|
106
|
+
catch (removeErr) {
|
|
107
|
+
// `newDir` may be partly deleted; copy the missing entries back from
|
|
108
|
+
// `aside`, and keep `aside` on disk if even that fails.
|
|
109
|
+
try {
|
|
110
|
+
fs.cpSync(aside, newDir, { recursive: true, verbatimSymlinks: true, force: false });
|
|
111
|
+
removeQuietly(aside);
|
|
112
|
+
}
|
|
113
|
+
catch { }
|
|
114
|
+
throw removeErr;
|
|
102
115
|
}
|
|
116
|
+
return aside;
|
|
103
117
|
default:
|
|
104
118
|
throw err;
|
|
105
119
|
}
|
package/lib/removeQuarantine.js
CHANGED
|
@@ -49,7 +49,7 @@ function removeQuarantineFromChunk(filePaths) {
|
|
|
49
49
|
});
|
|
50
50
|
}
|
|
51
51
|
catch (err) {
|
|
52
|
-
// `xattr -d` exits non-zero when a file
|
|
52
|
+
// `xattr -d` exits non-zero when a file has no quarantine xattr to
|
|
53
53
|
// remove ("No such xattr"), which is the common, expected case. It also
|
|
54
54
|
// reports "No such file" for entries the importer legitimately dropped or
|
|
55
55
|
// renamed (e.g. case-insensitive filename conflicts). Surface only errors
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pnpm/fs.indexed-pkg-importer",
|
|
3
|
-
"version": "1100.0.
|
|
3
|
+
"version": "1100.0.37",
|
|
4
4
|
"description": "Replicates indexed directories using hard links, copies, or cloning",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pnpm",
|
|
@@ -37,10 +37,10 @@
|
|
|
37
37
|
"test": "test"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@pnpm/core-loggers": "1101.0.
|
|
40
|
+
"@pnpm/core-loggers": "1101.0.4",
|
|
41
41
|
"@pnpm/error": "1100.2.2",
|
|
42
42
|
"@pnpm/fs.graceful-fs": "1100.2.5",
|
|
43
|
-
"@pnpm/store.controller-types": "1101.3.
|
|
43
|
+
"@pnpm/store.controller-types": "1101.3.5",
|
|
44
44
|
"@pnpm/text.sanitize": "1100.0.1",
|
|
45
45
|
"@reflink/reflink": "0.1.19",
|
|
46
46
|
"@zkochan/rimraf": "^4.0.0",
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@jest/globals": "30.4.1",
|
|
59
|
-
"@pnpm/fs.indexed-pkg-importer": "1100.0.
|
|
59
|
+
"@pnpm/fs.indexed-pkg-importer": "1100.0.37",
|
|
60
60
|
"@pnpm/logger": "1100.0.0",
|
|
61
|
-
"@pnpm/prepare": "1100.0.
|
|
61
|
+
"@pnpm/prepare": "1100.0.39",
|
|
62
62
|
"@types/fs-extra": "^11.0.4"
|
|
63
63
|
},
|
|
64
64
|
"engines": {
|