New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

ensure-port

Package Overview
Dependencies
Maintainers
1
Versions
15
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ensure-port - npm Package Compare versions

Comparing version 1.1.0 to 1.2.0

4

dist/cjs/ensure-port.js

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

const create_listening_server_1 = require("create-listening-server");
const find_cache_dir_1 = require("./find-cache-dir");
const find_cache_dir_js_1 = require("./find-cache-dir.js");
class Ports {

@@ -18,3 +18,3 @@ constructor({ startPort = 8000, endPort = 9000, strategy = 'random' } = {}, { fs = node_1.nodeFs, rootDir = process.cwd() } = {}) {

this.initialEdges = { start: this.start, end: this.end, reached: false };
const tempDir = (0, find_cache_dir_1.findCacheDir)('ensure-port', { fs: this.fs, rootDir: this.rootDir });
const tempDir = (0, find_cache_dir_js_1.findCacheDir)('ensure-port', { fs: this.fs, rootDir: this.rootDir });
if (tempDir) {

@@ -21,0 +21,0 @@ this.fs.ensureDirectorySync(tempDir);

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.findCacheDir = void 0;
const package_dir_1 = require("./package-dir");
const package_dir_js_1 = require("./package-dir.js");
function findCacheDir(name, { fs, rootDir }) {

@@ -11,3 +11,3 @@ if (process.env.CACHE_DIR && !['true', 'false', '1', '0'].includes(process.env.CACHE_DIR)) {

}
rootDir = (0, package_dir_1.packageDirectory)({ fs, cwd: rootDir !== null && rootDir !== void 0 ? rootDir : process.cwd() });
rootDir = (0, package_dir_js_1.packageDirectory)({ fs, cwd: rootDir !== null && rootDir !== void 0 ? rootDir : process.cwd() });
if (!rootDir) {

@@ -14,0 +14,0 @@ return;

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

export { Ports, PortsOptions, PortsParameters } from './ensure-port';
export { Ports, PortsOptions, PortsParameters } from './ensure-port.js';
//# sourceMappingURL=index.d.ts.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.Ports = void 0;
var ensure_port_1 = require("./ensure-port");
Object.defineProperty(exports, "Ports", { enumerable: true, get: function () { return ensure_port_1.Ports; } });
var ensure_port_js_1 = require("./ensure-port.js");
Object.defineProperty(exports, "Ports", { enumerable: true, get: function () { return ensure_port_js_1.Ports; } });
//# sourceMappingURL=index.js.map
import { nodeFs } from '@file-services/node';
import { safeListeningHttpServer } from 'create-listening-server';
import { findCacheDir } from './find-cache-dir';
import { findCacheDir } from './find-cache-dir.js';
export class Ports {

@@ -5,0 +5,0 @@ constructor({ startPort = 8000, endPort = 9000, strategy = 'random' } = {}, { fs = nodeFs, rootDir = process.cwd() } = {}) {

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

import { packageDirectory } from './package-dir';
import { packageDirectory } from './package-dir.js';
export function findCacheDir(name, { fs, rootDir }) {

@@ -3,0 +3,0 @@ if (process.env.CACHE_DIR && !['true', 'false', '1', '0'].includes(process.env.CACHE_DIR)) {

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

export { Ports, PortsOptions, PortsParameters } from './ensure-port';
export { Ports, PortsOptions, PortsParameters } from './ensure-port.js';
//# sourceMappingURL=index.d.ts.map

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

export { Ports } from './ensure-port';
export { Ports } from './ensure-port.js';
//# sourceMappingURL=index.js.map
{
"name": "ensure-port",
"version": "1.1.0",
"version": "1.2.0",
"description": "Makes sure you get an available port",

@@ -41,15 +41,15 @@ "main": "dist/cjs/index.js",

"@types/mocha": "^9.1.1",
"@types/node": "^17.0.30",
"@typescript-eslint/eslint-plugin": "^5.21.0",
"@typescript-eslint/parser": "^5.21.0",
"eslint": "^8.14.0",
"@types/node": "^18.0.0",
"@typescript-eslint/eslint-plugin": "^5.29.0",
"@typescript-eslint/parser": "^5.29.0",
"eslint": "^8.18.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-no-only-tests": "^2.6.0",
"expect": "^28.0.2",
"jest-util": "^28.0.2",
"mocha": "^9.2.2",
"pleb": "^4.0.3",
"expect": "^28.1.1",
"jest-util": "^28.1.1",
"mocha": "^10.0.0",
"pleb": "^5.1.0",
"rimraf": "^3.0.2",
"ts-expect": "^1.3.0",
"typescript": "^4.7.0-dev.20220430"
"typescript": "^4.7.4"
},

@@ -56,0 +56,0 @@ "dependencies": {

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

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

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