mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-06-28 14:20:12 +00:00
find-process: Provides its own types (#39609)
This commit is contained in:
committed by
Nathan Shively-Sanders
parent
8b279a1f92
commit
de4836c8a8
@@ -1302,6 +1302,12 @@
|
||||
"sourceRepoURL": "https://github.com/sindresorhus/filter-console",
|
||||
"asOfVersion": "0.1.1"
|
||||
},
|
||||
{
|
||||
"libraryName": "find-process",
|
||||
"typingsPackageName": "find-process",
|
||||
"sourceRepoURL": "https://github.com/yibn2008/find-process",
|
||||
"asOfVersion": "1.2.0"
|
||||
},
|
||||
{
|
||||
"libraryName": "find-java-home",
|
||||
"typingsPackageName": "find-java-home",
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
/// <reference types="node" />
|
||||
|
||||
import find = require('find-process');
|
||||
|
||||
find('pid', 12345).then((processList) => {
|
||||
processList.forEach((ps) => {
|
||||
console.log('Full command with args: ' + ps.cmd);
|
||||
console.log('User group ID (for *nix): ' + ps.gid);
|
||||
console.log('command/process name: ' + ps.name);
|
||||
console.log('Process ID: ' + ps.pid);
|
||||
console.log('Parent process ID: ' + ps.ppid);
|
||||
console.log('User ID (for *nix): ' + ps.uid);
|
||||
});
|
||||
}, (err) => {
|
||||
console.log(err.stack || err);
|
||||
});
|
||||
10
types/find-process/index.d.ts
vendored
10
types/find-process/index.d.ts
vendored
@@ -1,10 +0,0 @@
|
||||
// Type definitions for find-process 1.1
|
||||
// Project: https://github.com/yibn2008/find-process
|
||||
// Definitions by: Buaban Buataitom <https://github.com/buaban>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.3
|
||||
|
||||
declare function find(by: string, value: string | number): Promise<Array<{ pid: string, ppid: string, uid: string, gid: string, name: string, cmd: string }>>;
|
||||
declare namespace find {}
|
||||
|
||||
export = find;
|
||||
@@ -1,16 +0,0 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": ["es6"],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": ["../"],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": ["index.d.ts", "find-process-tests.ts"]
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
{
|
||||
"extends": "dtslint/dt.json"
|
||||
}
|
||||
Reference in New Issue
Block a user