Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

portfinder

Package Overview
Dependencies
Maintainers
2
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

portfinder - npm Package Compare versions

Comparing version 1.0.28 to 1.0.29

15

lib/portfinder.d.ts

@@ -37,2 +37,17 @@ /**

/**
* Set the lowest port to begin any port search from.
*/
export setBasePort(port: number);
/**
* The highest port to end any port search from.
*/
export let highestPort: number;
/**
* Set the higheset port to end any port search from.
*/
export setHighestPort(port: number);
/**
* Responds with a unbound port on the current machine.

@@ -39,0 +54,0 @@ */

@@ -90,2 +90,10 @@ /*

//
// ### function setBasePort (port)
// #### @port {Number} The new base port
//
exports.setBasePort = function (port) {
exports.basePort = port;
}
//
// ### @highestPort {Number}

@@ -97,2 +105,10 @@ // Largest port number is an unsigned short 2**16 -1=65335

//
// ### function setHighestPort (port)
// #### @port {Number} The new highest port
//
exports.setHighestPort = function (port) {
exports.highestPort = port;
}
//
// ### @basePath {string}

@@ -99,0 +115,0 @@ // Default path to begin any socket search from

11

package.json
{
"name": "portfinder",
"description": "A simple tool to find an open port on the current machine",
"version": "1.0.28",
"version": "1.0.29",
"author": "Charlie Robbins <charlie.robbins@gmail.com>",

@@ -19,9 +19,8 @@ "repository": {

"dependencies": {
"async": "^2.6.2",
"debug": "^3.1.1",
"mkdirp": "^0.5.5"
"async": "^2.6.4",
"debug": "^3.2.7",
"mkdirp": "^0.5.6"
},
"devDependencies": {
"glob": "^7.1.4",
"vows": "^0.8.2"
"vows": "^0.8.3"
},

@@ -28,0 +27,0 @@ "main": "./lib/portfinder",

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

# node-portfinder [![Build Status](https://api.travis-ci.org/http-party/node-portfinder.svg)](https://travis-ci.org/http-party/node-portfinder)
# node-portfinder [![CI](https://github.com/http-party/node-portfinder/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/http-party/node-portfinder/actions/workflows/ci.yml)

@@ -6,3 +6,3 @@ ## Installation

``` bash
$ [sudo] npm install portfinder
$ npm install portfinder
```

@@ -24,3 +24,3 @@

Or with promise (if Promise are supported) :
Or with promise (if `Promise`s are supported) :

@@ -46,5 +46,5 @@ ``` js

### Ports search scope
### Ports search scope
By default `portfinder` will start searching from `8000` and scan until maximum port number (`65535`) is reached.
By default `portfinder` will start searching from `8000` and scan until maximum port number (`65535`) is reached.

@@ -54,4 +54,4 @@ You can change this globally by setting:

```js
portfinder.basePort = 3000; // default: 8000
portfinder.highestPort = 3333; // default: 65535
portfinder.setBasePort(3000); // default: 8000
portfinder.setHighestPort(3333); // default: 65535
```

@@ -74,5 +74,5 @@

#### Author: [Charlie Robbins][0]
#### Maintainer: [Erik Trom][1]
#### Author/Maintainer: [Erik Trom][1]
#### License: MIT/X11
[0]: http://nodejitsu.com
[1]: https://github.com/eriktrom
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