Socket
Socket
Sign inDemoInstall

nx-cloud

Package Overview
Dependencies
Maintainers
2
Versions
153
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nx-cloud - npm Package Compare versions

Comparing version 16.4.0-beta.3 to 16.4.0-beta.4

2

bin/nx-cloud.js

@@ -20,3 +20,3 @@ #!/usr/bin/env node

// explicitly so we are able to access installed dependencies
(0, resolution_helpers_1.addPackageNodeModulesToNodeRequirePath)();
(0, resolution_helpers_1.addPackageAncestorNodeModulesToNodeRequirePath)();
const command = process.argv[2];

@@ -23,0 +23,0 @@ const options = JSON.parse(stripJsonComments((0, fs_1.readFileSync)(`nx.json`).toString())).tasksRunnerOptions.default.options;

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

// directory to NODE_PATH so light client can resolve properly.
(0, resolution_helpers_1.addPackageNodeModulesToNodeRequirePath)();
(0, resolution_helpers_1.addPackageAncestorNodeModulesToNodeRequirePath)();
(0, debug_logger_1.debugLog)('Using light client');

@@ -25,0 +25,0 @@ const { version, fullPath } = yield (0, update_manager_1.verifyOrUpdateCloudBundle)(options);

@@ -1,1 +0,1 @@

export declare function addPackageNodeModulesToNodeRequirePath(): void;
export declare function addPackageAncestorNodeModulesToNodeRequirePath(): void;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.addPackageNodeModulesToNodeRequirePath = void 0;
exports.addPackageAncestorNodeModulesToNodeRequirePath = void 0;
const path_1 = require("path");
const module_1 = require("module");
function addPackageNodeModulesToNodeRequirePath() {
addToNodePath((0, path_1.join)(__dirname, "../../.."));
const debug_logger_1 = require("./debug-logger");
const fs_1 = require("fs");
function addPackageAncestorNodeModulesToNodeRequirePath() {
const ancestorNodeModules = findAncestorNodeModules(__dirname, []);
(0, debug_logger_1.debugLog)('Ancestor Node Modules Found: ', ancestorNodeModules);
ancestorNodeModules.forEach(addToNodePath);
// Re-initialize the paths into require
module_1.Module._initPaths();
}
exports.addPackageNodeModulesToNodeRequirePath = addPackageNodeModulesToNodeRequirePath;
exports.addPackageAncestorNodeModulesToNodeRequirePath = addPackageAncestorNodeModulesToNodeRequirePath;
function addToNodePath(dir) {
(0, debug_logger_1.debugLog)('Adding dir to NODE_PATH for resolution: ', dir);
// NODE_PATH is a delimited list of paths.

@@ -28,2 +33,16 @@ // The delimiter is different for windows.

}
function findAncestorNodeModules(startPath, collector) {
let currentPath = (0, path_1.isAbsolute)(startPath) ? startPath : (0, path_1.resolve)(startPath);
while (currentPath !== (0, path_1.dirname)(currentPath)) {
const potentialNodeModules = (0, path_1.join)(currentPath, 'node_modules');
if ((0, fs_1.existsSync)(potentialNodeModules)) {
collector.push(potentialNodeModules);
}
if ((0, fs_1.existsSync)((0, path_1.join)(currentPath, 'nx.json'))) {
break;
}
currentPath = (0, path_1.dirname)(currentPath);
}
return collector;
}
//# sourceMappingURL=resolution-helpers.js.map
{
"name": "nx-cloud",
"version": "16.4.0-beta.3",
"version": "16.4.0-beta.4",
"description": "Distributed caching and task execution for Lerna and Nx",

@@ -32,3 +32,3 @@ "keywords": [

"open": "~8.4.0",
"@nrwl/nx-cloud": "16.4.0-beta.3",
"@nrwl/nx-cloud": "16.4.0-beta.4",
"@swc/helpers": "0.5.1"

@@ -35,0 +35,0 @@ },

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