Socket
Socket
Sign inDemoInstall

@rushstack/node-core-library

Package Overview
Dependencies
Maintainers
3
Versions
136
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rushstack/node-core-library - npm Package Compare versions

Comparing version 3.51.2 to 3.52.0

4

lib/FileSystem.d.ts

@@ -657,2 +657,6 @@ /// <reference types="node" />

/**
* Returns true if the error object indicates the target is not a directory (`ENOTDIR`).
*/
static isNotDirectoryError(error: Error): boolean;
/**
* Returns true if the error object indicates that the `unlink` system call failed

@@ -659,0 +663,0 @@ * due to a permissions issue (`EPERM`).

@@ -682,3 +682,3 @@ "use strict";

await FileSystem._wrapExceptionAsync(async () => {
fsx.copySync(options.sourcePath, options.destinationPath, {
await fsx.copy(options.sourcePath, options.destinationPath, {
dereference: !!options.dereferenceSymlinks,

@@ -953,2 +953,8 @@ errorOnExist: options.alreadyExistsBehavior === AlreadyExistsBehavior.Error,

/**
* Returns true if the error object indicates the target is not a directory (`ENOTDIR`).
*/
static isNotDirectoryError(error) {
return FileSystem.isErrnoException(error) && error.code === 'ENOTDIR';
}
/**
* Returns true if the error object indicates that the `unlink` system call failed

@@ -1087,2 +1093,6 @@ * due to a permissions issue (`EPERM`).

}
else if (FileSystem.isNotDirectoryError(error)) {
// eslint-disable-line @typescript-eslint/no-use-before-define
error.message = `Target is not a folder: ${error.path}\n${error.message}`;
}
}

@@ -1089,0 +1099,0 @@ }

6

lib/LockFile.d.ts

@@ -69,6 +69,8 @@ /**

/**
* Unlocks a file and removes it from disk.
* Unlocks a file and optionally removes it from disk.
* This can only be called once.
*
* @param deleteFile - Whether to delete the lockfile from disk. Defaults to true.
*/
release(): void;
release(deleteFile?: boolean): void;
/**

@@ -75,0 +77,0 @@ * Returns the initial state of the lock.

@@ -387,6 +387,8 @@ "use strict";

/**
* Unlocks a file and removes it from disk.
* Unlocks a file and optionally removes it from disk.
* This can only be called once.
*
* @param deleteFile - Whether to delete the lockfile from disk. Defaults to true.
*/
release() {
release(deleteFile = true) {
if (this.isReleased) {

@@ -396,3 +398,5 @@ throw new Error(`The lock for file "${path.basename(this._filePath)}" has already been released.`);

this._fileWriter.close();
FileSystem_1.FileSystem.deleteFile(this._filePath);
if (deleteFile) {
FileSystem_1.FileSystem.deleteFile(this._filePath);
}
this._fileWriter = undefined;

@@ -399,0 +403,0 @@ }

{
"name": "@rushstack/node-core-library",
"version": "3.51.2",
"version": "3.52.0",
"description": "Core libraries that every NodeJS toolchain project should use",

@@ -25,3 +25,3 @@ "main": "lib/index.js",

"@rushstack/eslint-config": "3.0.1",
"@rushstack/heft": "0.47.0",
"@rushstack/heft": "0.47.9",
"@rushstack/heft-node-rig": "1.10.0",

@@ -28,0 +28,0 @@ "@types/fs-extra": "7.0.0",

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc