Skip to content
Fabulously kill processes. Cross-platform.
Branch: master
Clone or download
Latest commit 7ad0006 Mar 12, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
media
.editorconfig
.gitattributes Require Node.js 8 Dec 31, 2018
.gitignore Meta tweaks Sep 15, 2017
.npmrc Meta tweaks Sep 15, 2017
.travis.yml Require Node.js 8 Dec 31, 2018
fixture.js
index.d.ts
index.js
index.test-d.ts
license Meta tweaks Sep 15, 2017
package.json
readme.md Meta tweaks Mar 12, 2019
test.js Require Node.js 8 Dec 31, 2018

readme.md


fkill


Fabulously kill processes. Cross-platform.

Build Status

Works on macOS, Linux, Windows.

Install

$ npm install fkill

Usage

const fkill = require('fkill');

(async () => {
	await fkill(1337);
	console.log('Killed process');
})();

fkill('Safari');
fkill(':8080');

fkill([1337, 'Safari', ':8080']);

API

fkill(input, [options])

Returns a promise that resolves when the process is killed.

input

Type: number | string | Array<number | string>

One or more process IDs/names/ports to kill.

To kill a port, prefix it with a colon. For example: :8080.

options

Type: Object

force

Type: boolean
Default: false

Force kill the process.

tree

Type: boolean
Default: true

Kill all child processes along with the parent process. (Windows only)

ignoreCase

Type: boolean
Default: false

Ignore capitalization when killing a process.

Note that the case is always ignored on Windows.

Related

License

MIT © Sindre Sorhus

You can’t perform that action at this time.