-
-
Notifications
You must be signed in to change notification settings - Fork 33.8k
Open
Labels
confirmed-bugIssues with confirmed bugs.Issues with confirmed bugs.fsIssues and PRs related to the fs subsystem / file system.Issues and PRs related to the fs subsystem / file system.
Description
For example... on Linux, where file names are just byte sequences...
const { writeFileSync, existsSync, globSync } = require('node:fs');
const path = Buffer.from([0xe9]);
writeFileSync(path, 'hello');
existsSync(path); // true
console.log(globSync('[^a-z]')); // [ '�' ] non-utf8 bytes in the file name end up replaced.The globSync, et. al APIs likely need an encoding option that instructs it to return the filenames as Buffer objects.
silverwind
Metadata
Metadata
Assignees
Labels
confirmed-bugIssues with confirmed bugs.Issues with confirmed bugs.fsIssues and PRs related to the fs subsystem / file system.Issues and PRs related to the fs subsystem / file system.