forked from olcxjas-softworks/LarpixClient
fix gitignore again
This commit is contained in:
parent
ce5a1e330b
commit
5da5c2afe2
3329 changed files with 364540 additions and 3 deletions
33
electron/node_modules/rimraf/dist/esm/fix-eperm.js
generated
vendored
Normal file
33
electron/node_modules/rimraf/dist/esm/fix-eperm.js
generated
vendored
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
import { errorCode } from './error.js';
|
||||
import { chmodSync, promises } from './fs.js';
|
||||
import { ignoreENOENT, ignoreENOENTSync } from './ignore-enoent.js';
|
||||
const { chmod } = promises;
|
||||
export const fixEPERM = (fn) => async (path) => {
|
||||
try {
|
||||
return void (await ignoreENOENT(fn(path)));
|
||||
}
|
||||
catch (er) {
|
||||
if (errorCode(er) === 'EPERM') {
|
||||
if (!(await ignoreENOENT(chmod(path, 0o666).then(() => true), er))) {
|
||||
return;
|
||||
}
|
||||
return void (await fn(path));
|
||||
}
|
||||
throw er;
|
||||
}
|
||||
};
|
||||
export const fixEPERMSync = (fn) => (path) => {
|
||||
try {
|
||||
return void ignoreENOENTSync(() => fn(path));
|
||||
}
|
||||
catch (er) {
|
||||
if (errorCode(er) === 'EPERM') {
|
||||
if (!ignoreENOENTSync(() => (chmodSync(path, 0o666), true), er)) {
|
||||
return;
|
||||
}
|
||||
return void fn(path);
|
||||
}
|
||||
throw er;
|
||||
}
|
||||
};
|
||||
//# sourceMappingURL=fix-eperm.js.map
|
||||
Loading…
Add table
Add a link
Reference in a new issue