Updated the files.
This commit is contained in:
parent
1553e6b971
commit
753967d4f5
23418 changed files with 3784666 additions and 0 deletions
273
my-app/node_modules/human-signals/build/src/core.js
generated
vendored
Executable file
273
my-app/node_modules/human-signals/build/src/core.js
generated
vendored
Executable file
|
@ -0,0 +1,273 @@
|
|||
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.SIGNALS=void 0;
|
||||
|
||||
const SIGNALS=[
|
||||
{
|
||||
name:"SIGHUP",
|
||||
number:1,
|
||||
action:"terminate",
|
||||
description:"Terminal closed",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGINT",
|
||||
number:2,
|
||||
action:"terminate",
|
||||
description:"User interruption with CTRL-C",
|
||||
standard:"ansi"},
|
||||
|
||||
{
|
||||
name:"SIGQUIT",
|
||||
number:3,
|
||||
action:"core",
|
||||
description:"User interruption with CTRL-\\",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGILL",
|
||||
number:4,
|
||||
action:"core",
|
||||
description:"Invalid machine instruction",
|
||||
standard:"ansi"},
|
||||
|
||||
{
|
||||
name:"SIGTRAP",
|
||||
number:5,
|
||||
action:"core",
|
||||
description:"Debugger breakpoint",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGABRT",
|
||||
number:6,
|
||||
action:"core",
|
||||
description:"Aborted",
|
||||
standard:"ansi"},
|
||||
|
||||
{
|
||||
name:"SIGIOT",
|
||||
number:6,
|
||||
action:"core",
|
||||
description:"Aborted",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGBUS",
|
||||
number:7,
|
||||
action:"core",
|
||||
description:
|
||||
"Bus error due to misaligned, non-existing address or paging error",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGEMT",
|
||||
number:7,
|
||||
action:"terminate",
|
||||
description:"Command should be emulated but is not implemented",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGFPE",
|
||||
number:8,
|
||||
action:"core",
|
||||
description:"Floating point arithmetic error",
|
||||
standard:"ansi"},
|
||||
|
||||
{
|
||||
name:"SIGKILL",
|
||||
number:9,
|
||||
action:"terminate",
|
||||
description:"Forced termination",
|
||||
standard:"posix",
|
||||
forced:true},
|
||||
|
||||
{
|
||||
name:"SIGUSR1",
|
||||
number:10,
|
||||
action:"terminate",
|
||||
description:"Application-specific signal",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGSEGV",
|
||||
number:11,
|
||||
action:"core",
|
||||
description:"Segmentation fault",
|
||||
standard:"ansi"},
|
||||
|
||||
{
|
||||
name:"SIGUSR2",
|
||||
number:12,
|
||||
action:"terminate",
|
||||
description:"Application-specific signal",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGPIPE",
|
||||
number:13,
|
||||
action:"terminate",
|
||||
description:"Broken pipe or socket",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGALRM",
|
||||
number:14,
|
||||
action:"terminate",
|
||||
description:"Timeout or timer",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGTERM",
|
||||
number:15,
|
||||
action:"terminate",
|
||||
description:"Termination",
|
||||
standard:"ansi"},
|
||||
|
||||
{
|
||||
name:"SIGSTKFLT",
|
||||
number:16,
|
||||
action:"terminate",
|
||||
description:"Stack is empty or overflowed",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGCHLD",
|
||||
number:17,
|
||||
action:"ignore",
|
||||
description:"Child process terminated, paused or unpaused",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGCLD",
|
||||
number:17,
|
||||
action:"ignore",
|
||||
description:"Child process terminated, paused or unpaused",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGCONT",
|
||||
number:18,
|
||||
action:"unpause",
|
||||
description:"Unpaused",
|
||||
standard:"posix",
|
||||
forced:true},
|
||||
|
||||
{
|
||||
name:"SIGSTOP",
|
||||
number:19,
|
||||
action:"pause",
|
||||
description:"Paused",
|
||||
standard:"posix",
|
||||
forced:true},
|
||||
|
||||
{
|
||||
name:"SIGTSTP",
|
||||
number:20,
|
||||
action:"pause",
|
||||
description:"Paused using CTRL-Z or \"suspend\"",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGTTIN",
|
||||
number:21,
|
||||
action:"pause",
|
||||
description:"Background process cannot read terminal input",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGBREAK",
|
||||
number:21,
|
||||
action:"terminate",
|
||||
description:"User interruption with CTRL-BREAK",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGTTOU",
|
||||
number:22,
|
||||
action:"pause",
|
||||
description:"Background process cannot write to terminal output",
|
||||
standard:"posix"},
|
||||
|
||||
{
|
||||
name:"SIGURG",
|
||||
number:23,
|
||||
action:"ignore",
|
||||
description:"Socket received out-of-band data",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGXCPU",
|
||||
number:24,
|
||||
action:"core",
|
||||
description:"Process timed out",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGXFSZ",
|
||||
number:25,
|
||||
action:"core",
|
||||
description:"File too big",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGVTALRM",
|
||||
number:26,
|
||||
action:"terminate",
|
||||
description:"Timeout or timer",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGPROF",
|
||||
number:27,
|
||||
action:"terminate",
|
||||
description:"Timeout or timer",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGWINCH",
|
||||
number:28,
|
||||
action:"ignore",
|
||||
description:"Terminal window size changed",
|
||||
standard:"bsd"},
|
||||
|
||||
{
|
||||
name:"SIGIO",
|
||||
number:29,
|
||||
action:"terminate",
|
||||
description:"I/O is available",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGPOLL",
|
||||
number:29,
|
||||
action:"terminate",
|
||||
description:"Watched event",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGINFO",
|
||||
number:29,
|
||||
action:"ignore",
|
||||
description:"Request for process information",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGPWR",
|
||||
number:30,
|
||||
action:"terminate",
|
||||
description:"Device running out of power",
|
||||
standard:"systemv"},
|
||||
|
||||
{
|
||||
name:"SIGSYS",
|
||||
number:31,
|
||||
action:"core",
|
||||
description:"Invalid system call",
|
||||
standard:"other"},
|
||||
|
||||
{
|
||||
name:"SIGUNUSED",
|
||||
number:31,
|
||||
action:"terminate",
|
||||
description:"Invalid system call",
|
||||
standard:"other"}];exports.SIGNALS=SIGNALS;
|
||||
//# sourceMappingURL=core.js.map
|
1
my-app/node_modules/human-signals/build/src/core.js.map
generated
vendored
Executable file
1
my-app/node_modules/human-signals/build/src/core.js.map
generated
vendored
Executable file
File diff suppressed because one or more lines are too long
52
my-app/node_modules/human-signals/build/src/main.d.ts
generated
vendored
Executable file
52
my-app/node_modules/human-signals/build/src/main.d.ts
generated
vendored
Executable file
|
@ -0,0 +1,52 @@
|
|||
/**
|
||||
* Object whose keys are signal names and values are signal objects.
|
||||
*/
|
||||
export declare const signalsByName: { [signalName: string]: Signal }
|
||||
/**
|
||||
* Object whose keys are signal numbers and values are signal objects.
|
||||
*/
|
||||
export declare const signalsByNumber: { [signalNumber: string]: Signal }
|
||||
|
||||
export declare type SignalAction =
|
||||
| 'terminate'
|
||||
| 'core'
|
||||
| 'ignore'
|
||||
| 'pause'
|
||||
| 'unpause'
|
||||
export declare type SignalStandard =
|
||||
| 'ansi'
|
||||
| 'posix'
|
||||
| 'bsd'
|
||||
| 'systemv'
|
||||
| 'other'
|
||||
|
||||
export declare type Signal = {
|
||||
/**
|
||||
* Standard name of the signal, for example 'SIGINT'.
|
||||
*/
|
||||
name: string
|
||||
/**
|
||||
* Code number of the signal, for example 2. While most number are cross-platform, some are different between different OS.
|
||||
*/
|
||||
number: number
|
||||
/**
|
||||
* Human-friendly description for the signal, for example 'User interruption with CTRL-C'.
|
||||
*/
|
||||
description: string
|
||||
/**
|
||||
* Whether the current OS can handle this signal in Node.js using process.on(name, handler). The list of supported signals is OS-specific.
|
||||
*/
|
||||
supported: boolean
|
||||
/**
|
||||
* What is the default action for this signal when it is not handled.
|
||||
*/
|
||||
action: SignalAction
|
||||
/**
|
||||
* Whether the signal's default action cannot be prevented. This is true for SIGTERM, SIGKILL and SIGSTOP.
|
||||
*/
|
||||
forced: boolean
|
||||
/**
|
||||
* Which standard defined that signal.
|
||||
*/
|
||||
standard: SignalStandard
|
||||
}
|
71
my-app/node_modules/human-signals/build/src/main.js
generated
vendored
Executable file
71
my-app/node_modules/human-signals/build/src/main.js
generated
vendored
Executable file
|
@ -0,0 +1,71 @@
|
|||
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.signalsByNumber=exports.signalsByName=void 0;var _os=require("os");
|
||||
|
||||
var _signals=require("./signals.js");
|
||||
var _realtime=require("./realtime.js");
|
||||
|
||||
|
||||
|
||||
const getSignalsByName=function(){
|
||||
const signals=(0,_signals.getSignals)();
|
||||
return signals.reduce(getSignalByName,{});
|
||||
};
|
||||
|
||||
const getSignalByName=function(
|
||||
signalByNameMemo,
|
||||
{name,number,description,supported,action,forced,standard})
|
||||
{
|
||||
return{
|
||||
...signalByNameMemo,
|
||||
[name]:{name,number,description,supported,action,forced,standard}};
|
||||
|
||||
};
|
||||
|
||||
const signalsByName=getSignalsByName();exports.signalsByName=signalsByName;
|
||||
|
||||
|
||||
|
||||
|
||||
const getSignalsByNumber=function(){
|
||||
const signals=(0,_signals.getSignals)();
|
||||
const length=_realtime.SIGRTMAX+1;
|
||||
const signalsA=Array.from({length},(value,number)=>
|
||||
getSignalByNumber(number,signals));
|
||||
|
||||
return Object.assign({},...signalsA);
|
||||
};
|
||||
|
||||
const getSignalByNumber=function(number,signals){
|
||||
const signal=findSignalByNumber(number,signals);
|
||||
|
||||
if(signal===undefined){
|
||||
return{};
|
||||
}
|
||||
|
||||
const{name,description,supported,action,forced,standard}=signal;
|
||||
return{
|
||||
[number]:{
|
||||
name,
|
||||
number,
|
||||
description,
|
||||
supported,
|
||||
action,
|
||||
forced,
|
||||
standard}};
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
||||
const findSignalByNumber=function(number,signals){
|
||||
const signal=signals.find(({name})=>_os.constants.signals[name]===number);
|
||||
|
||||
if(signal!==undefined){
|
||||
return signal;
|
||||
}
|
||||
|
||||
return signals.find(signalA=>signalA.number===number);
|
||||
};
|
||||
|
||||
const signalsByNumber=getSignalsByNumber();exports.signalsByNumber=signalsByNumber;
|
||||
//# sourceMappingURL=main.js.map
|
1
my-app/node_modules/human-signals/build/src/main.js.map
generated
vendored
Executable file
1
my-app/node_modules/human-signals/build/src/main.js.map
generated
vendored
Executable file
|
@ -0,0 +1 @@
|
|||
{"version":3,"sources":["../../src/main.js"],"names":["getSignalsByName","signals","reduce","getSignalByName","signalByNameMemo","name","number","description","supported","action","forced","standard","signalsByName","getSignalsByNumber","length","SIGRTMAX","signalsA","Array","from","value","getSignalByNumber","Object","assign","signal","findSignalByNumber","undefined","find","constants","signalA","signalsByNumber"],"mappings":"2HAAA;;AAEA;AACA;;;;AAIA,KAAMA,CAAAA,gBAAgB,CAAG,UAAW;AAClC,KAAMC,CAAAA,OAAO,CAAG,yBAAhB;AACA,MAAOA,CAAAA,OAAO,CAACC,MAAR,CAAeC,eAAf,CAAgC,EAAhC,CAAP;AACD,CAHD;;AAKA,KAAMA,CAAAA,eAAe,CAAG;AACtBC,gBADsB;AAEtB,CAAEC,IAAF,CAAQC,MAAR,CAAgBC,WAAhB,CAA6BC,SAA7B,CAAwCC,MAAxC,CAAgDC,MAAhD,CAAwDC,QAAxD,CAFsB;AAGtB;AACA,MAAO;AACL,GAAGP,gBADE;AAEL,CAACC,IAAD,EAAQ,CAAEA,IAAF,CAAQC,MAAR,CAAgBC,WAAhB,CAA6BC,SAA7B,CAAwCC,MAAxC,CAAgDC,MAAhD,CAAwDC,QAAxD,CAFH,CAAP;;AAID,CARD;;AAUO,KAAMC,CAAAA,aAAa,CAAGZ,gBAAgB,EAAtC,C;;;;;AAKP,KAAMa,CAAAA,kBAAkB,CAAG,UAAW;AACpC,KAAMZ,CAAAA,OAAO,CAAG,yBAAhB;AACA,KAAMa,CAAAA,MAAM,CAAGC,mBAAW,CAA1B;AACA,KAAMC,CAAAA,QAAQ,CAAGC,KAAK,CAACC,IAAN,CAAW,CAAEJ,MAAF,CAAX,CAAuB,CAACK,KAAD,CAAQb,MAAR;AACtCc,iBAAiB,CAACd,MAAD,CAASL,OAAT,CADF,CAAjB;;AAGA,MAAOoB,CAAAA,MAAM,CAACC,MAAP,CAAc,EAAd,CAAkB,GAAGN,QAArB,CAAP;AACD,CAPD;;AASA,KAAMI,CAAAA,iBAAiB,CAAG,SAASd,MAAT,CAAiBL,OAAjB,CAA0B;AAClD,KAAMsB,CAAAA,MAAM,CAAGC,kBAAkB,CAAClB,MAAD,CAASL,OAAT,CAAjC;;AAEA,GAAIsB,MAAM,GAAKE,SAAf,CAA0B;AACxB,MAAO,EAAP;AACD;;AAED,KAAM,CAAEpB,IAAF,CAAQE,WAAR,CAAqBC,SAArB,CAAgCC,MAAhC,CAAwCC,MAAxC,CAAgDC,QAAhD,EAA6DY,MAAnE;AACA,MAAO;AACL,CAACjB,MAAD,EAAU;AACRD,IADQ;AAERC,MAFQ;AAGRC,WAHQ;AAIRC,SAJQ;AAKRC,MALQ;AAMRC,MANQ;AAORC,QAPQ,CADL,CAAP;;;AAWD,CAnBD;;;;AAuBA,KAAMa,CAAAA,kBAAkB,CAAG,SAASlB,MAAT,CAAiBL,OAAjB,CAA0B;AACnD,KAAMsB,CAAAA,MAAM,CAAGtB,OAAO,CAACyB,IAAR,CAAa,CAAC,CAAErB,IAAF,CAAD,GAAcsB,cAAU1B,OAAV,CAAkBI,IAAlB,IAA4BC,MAAvD,CAAf;;AAEA,GAAIiB,MAAM,GAAKE,SAAf,CAA0B;AACxB,MAAOF,CAAAA,MAAP;AACD;;AAED,MAAOtB,CAAAA,OAAO,CAACyB,IAAR,CAAaE,OAAO,EAAIA,OAAO,CAACtB,MAAR,GAAmBA,MAA3C,CAAP;AACD,CARD;;AAUO,KAAMuB,CAAAA,eAAe,CAAGhB,kBAAkB,EAA1C,C","sourcesContent":["import { constants } from 'os'\n\nimport { getSignals } from './signals.js'\nimport { SIGRTMAX } from './realtime.js'\n\n// Retrieve `signalsByName`, an object mapping signal name to signal properties.\n// We make sure the object is sorted by `number`.\nconst getSignalsByName = function() {\n const signals = getSignals()\n return signals.reduce(getSignalByName, {})\n}\n\nconst getSignalByName = function(\n signalByNameMemo,\n { name, number, description, supported, action, forced, standard },\n) {\n return {\n ...signalByNameMemo,\n [name]: { name, number, description, supported, action, forced, standard },\n }\n}\n\nexport const signalsByName = getSignalsByName()\n\n// Retrieve `signalsByNumber`, an object mapping signal number to signal\n// properties.\n// We make sure the object is sorted by `number`.\nconst getSignalsByNumber = function() {\n const signals = getSignals()\n const length = SIGRTMAX + 1\n const signalsA = Array.from({ length }, (value, number) =>\n getSignalByNumber(number, signals),\n )\n return Object.assign({}, ...signalsA)\n}\n\nconst getSignalByNumber = function(number, signals) {\n const signal = findSignalByNumber(number, signals)\n\n if (signal === undefined) {\n return {}\n }\n\n const { name, description, supported, action, forced, standard } = signal\n return {\n [number]: {\n name,\n number,\n description,\n supported,\n action,\n forced,\n standard,\n },\n }\n}\n\n// Several signals might end up sharing the same number because of OS-specific\n// numbers, in which case those prevail.\nconst findSignalByNumber = function(number, signals) {\n const signal = signals.find(({ name }) => constants.signals[name] === number)\n\n if (signal !== undefined) {\n return signal\n }\n\n return signals.find(signalA => signalA.number === number)\n}\n\nexport const signalsByNumber = getSignalsByNumber()\n"],"file":"src/main.js"}
|
19
my-app/node_modules/human-signals/build/src/realtime.js
generated
vendored
Executable file
19
my-app/node_modules/human-signals/build/src/realtime.js
generated
vendored
Executable file
|
@ -0,0 +1,19 @@
|
|||
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.SIGRTMAX=exports.getRealtimeSignals=void 0;
|
||||
const getRealtimeSignals=function(){
|
||||
const length=SIGRTMAX-SIGRTMIN+1;
|
||||
return Array.from({length},getRealtimeSignal);
|
||||
};exports.getRealtimeSignals=getRealtimeSignals;
|
||||
|
||||
const getRealtimeSignal=function(value,index){
|
||||
return{
|
||||
name:`SIGRT${index+1}`,
|
||||
number:SIGRTMIN+index,
|
||||
action:"terminate",
|
||||
description:"Application-specific signal (realtime)",
|
||||
standard:"posix"};
|
||||
|
||||
};
|
||||
|
||||
const SIGRTMIN=34;
|
||||
const SIGRTMAX=64;exports.SIGRTMAX=SIGRTMAX;
|
||||
//# sourceMappingURL=realtime.js.map
|
1
my-app/node_modules/human-signals/build/src/realtime.js.map
generated
vendored
Executable file
1
my-app/node_modules/human-signals/build/src/realtime.js.map
generated
vendored
Executable file
|
@ -0,0 +1 @@
|
|||
{"version":3,"sources":["../../src/realtime.js"],"names":["getRealtimeSignals","length","SIGRTMAX","SIGRTMIN","Array","from","getRealtimeSignal","value","index","name","number","action","description","standard"],"mappings":";AACO,KAAMA,CAAAA,kBAAkB,CAAG,UAAW;AAC3C,KAAMC,CAAAA,MAAM,CAAGC,QAAQ,CAAGC,QAAX,CAAsB,CAArC;AACA,MAAOC,CAAAA,KAAK,CAACC,IAAN,CAAW,CAAEJ,MAAF,CAAX,CAAuBK,iBAAvB,CAAP;AACD,CAHM,C;;AAKP,KAAMA,CAAAA,iBAAiB,CAAG,SAASC,KAAT,CAAgBC,KAAhB,CAAuB;AAC/C,MAAO;AACLC,IAAI,CAAG,QAAOD,KAAK,CAAG,CAAE,EADnB;AAELE,MAAM,CAAEP,QAAQ,CAAGK,KAFd;AAGLG,MAAM,CAAE,WAHH;AAILC,WAAW,CAAE,wCAJR;AAKLC,QAAQ,CAAE,OALL,CAAP;;AAOD,CARD;;AAUA,KAAMV,CAAAA,QAAQ,CAAG,EAAjB;AACO,KAAMD,CAAAA,QAAQ,CAAG,EAAjB,C","sourcesContent":["// List of realtime signals with information about them\nexport const getRealtimeSignals = function() {\n const length = SIGRTMAX - SIGRTMIN + 1\n return Array.from({ length }, getRealtimeSignal)\n}\n\nconst getRealtimeSignal = function(value, index) {\n return {\n name: `SIGRT${index + 1}`,\n number: SIGRTMIN + index,\n action: 'terminate',\n description: 'Application-specific signal (realtime)',\n standard: 'posix',\n }\n}\n\nconst SIGRTMIN = 34\nexport const SIGRTMAX = 64\n"],"file":"src/realtime.js"}
|
35
my-app/node_modules/human-signals/build/src/signals.js
generated
vendored
Executable file
35
my-app/node_modules/human-signals/build/src/signals.js
generated
vendored
Executable file
|
@ -0,0 +1,35 @@
|
|||
"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.getSignals=void 0;var _os=require("os");
|
||||
|
||||
var _core=require("./core.js");
|
||||
var _realtime=require("./realtime.js");
|
||||
|
||||
|
||||
|
||||
const getSignals=function(){
|
||||
const realtimeSignals=(0,_realtime.getRealtimeSignals)();
|
||||
const signals=[..._core.SIGNALS,...realtimeSignals].map(normalizeSignal);
|
||||
return signals;
|
||||
};exports.getSignals=getSignals;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
const normalizeSignal=function({
|
||||
name,
|
||||
number:defaultNumber,
|
||||
description,
|
||||
action,
|
||||
forced=false,
|
||||
standard})
|
||||
{
|
||||
const{
|
||||
signals:{[name]:constantSignal}}=
|
||||
_os.constants;
|
||||
const supported=constantSignal!==undefined;
|
||||
const number=supported?constantSignal:defaultNumber;
|
||||
return{name,number,description,supported,action,forced,standard};
|
||||
};
|
||||
//# sourceMappingURL=signals.js.map
|
1
my-app/node_modules/human-signals/build/src/signals.js.map
generated
vendored
Executable file
1
my-app/node_modules/human-signals/build/src/signals.js.map
generated
vendored
Executable file
|
@ -0,0 +1 @@
|
|||
{"version":3,"sources":["../../src/signals.js"],"names":["getSignals","realtimeSignals","signals","SIGNALS","map","normalizeSignal","name","number","defaultNumber","description","action","forced","standard","constantSignal","constants","supported","undefined"],"mappings":"gGAAA;;AAEA;AACA;;;;AAIO,KAAMA,CAAAA,UAAU,CAAG,UAAW;AACnC,KAAMC,CAAAA,eAAe,CAAG,kCAAxB;AACA,KAAMC,CAAAA,OAAO,CAAG,CAAC,GAAGC,aAAJ,CAAa,GAAGF,eAAhB,EAAiCG,GAAjC,CAAqCC,eAArC,CAAhB;AACA,MAAOH,CAAAA,OAAP;AACD,CAJM,C;;;;;;;;AAYP,KAAMG,CAAAA,eAAe,CAAG,SAAS;AAC/BC,IAD+B;AAE/BC,MAAM,CAAEC,aAFuB;AAG/BC,WAH+B;AAI/BC,MAJ+B;AAK/BC,MAAM,CAAG,KALsB;AAM/BC,QAN+B,CAAT;AAOrB;AACD,KAAM;AACJV,OAAO,CAAE,CAAE,CAACI,IAAD,EAAQO,cAAV,CADL;AAEFC,aAFJ;AAGA,KAAMC,CAAAA,SAAS,CAAGF,cAAc,GAAKG,SAArC;AACA,KAAMT,CAAAA,MAAM,CAAGQ,SAAS,CAAGF,cAAH,CAAoBL,aAA5C;AACA,MAAO,CAAEF,IAAF,CAAQC,MAAR,CAAgBE,WAAhB,CAA6BM,SAA7B,CAAwCL,MAAxC,CAAgDC,MAAhD,CAAwDC,QAAxD,CAAP;AACD,CAdD","sourcesContent":["import { constants } from 'os'\n\nimport { SIGNALS } from './core.js'\nimport { getRealtimeSignals } from './realtime.js'\n\n// Retrieve list of know signals (including realtime) with information about\n// them\nexport const getSignals = function() {\n const realtimeSignals = getRealtimeSignals()\n const signals = [...SIGNALS, ...realtimeSignals].map(normalizeSignal)\n return signals\n}\n\n// Normalize signal:\n// - `number`: signal numbers are OS-specific. This is taken into account by\n// `os.constants.signals`. However we provide a default `number` since some\n// signals are not defined for some OS.\n// - `forced`: set default to `false`\n// - `supported`: set value\nconst normalizeSignal = function({\n name,\n number: defaultNumber,\n description,\n action,\n forced = false,\n standard,\n}) {\n const {\n signals: { [name]: constantSignal },\n } = constants\n const supported = constantSignal !== undefined\n const number = supported ? constantSignal : defaultNumber\n return { name, number, description, supported, action, forced, standard }\n}\n"],"file":"src/signals.js"}
|
Loading…
Add table
Add a link
Reference in a new issue