First Commit of new way of building the Platform

This commit is contained in:
Luis Fernando Molina committed 2020-01-28 17:27:23 +01:00
1 parent e48cf0dae5
commit 40e60b42cc
4616 files changed
+713402

No files matched your search

+439
View File
@@ -0,0 +1,439 @@
{
">=6.0.0 <6.3.0": [
"--debug",
"--debug-brk",
"--icu-data-dir",
"--no-deprecation",
"--no-warnings",
"--port",
"--prof-process",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=6.3.0 <6.9.0": [
"--debug",
"--debug-brk",
"--icu-data-dir",
"--inspect",
"--no-deprecation",
"--no-warnings",
"--port",
"--prof-process",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=6.9.0 <6.11.0": [
"--debug",
"--debug-brk",
"--icu-data-dir",
"--inspect",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--port",
"--prof-process",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
"~6.11.0": [
"--debug",
"--debug-brk",
"--icu-data-dir",
"--inspect",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--port",
"--prof-process",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=6.12.0 <8.0.0": [
"--debug",
"--debug-brk",
"--icu-data-dir",
"--inspect",
"--inspect-brk",
"--inspect-port",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--port",
"--prof-process",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=8.0.0 <8.2.0": [
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--max-old-space-size",
"--napi-modules",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=8.2.0 <8.4.0": [
"--abort-on-uncaught-exception",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--max-old-space-size",
"--napi-modules",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
"~8.4.0": [
"--abort-on-uncaught-exception",
"--expose-http2",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--max-old-space-size",
"--napi-modules",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=8.5.0 <8.8.0": [
"--abort-on-uncaught-exception",
"--experimental-modules",
"--expose-http2",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--max-old-space-size",
"--napi-modules",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=8.8.0 <8.12.0": [
"--abort-on-uncaught-exception",
"--experimental-modules",
"--expose-http2",
"--force-async-hooks-checks",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--max-old-space-size",
"--napi-modules",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=8.12.0 <10.0.0": [
"--abort-on-uncaught-exception",
"--experimental-modules",
"--expose-http2",
"--force-async-hooks-checks",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--max-old-space-size",
"--napi-modules",
"--no-deprecation",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-event-file-pattern",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=10.0.0 <10.3.0": [
"--enable-fips",
"--experimental-modules",
"--experimental-repl-await",
"--experimental-vm-modules",
"--force-fips",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--napi-modules",
"--no-deprecation",
"--no-force-async-hooks-checks",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-event-file-pattern",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=10.3.0 <10.5.0": [
"--enable-fips",
"--experimental-modules",
"--experimental-repl-await",
"--experimental-vm-modules",
"--force-fips",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--napi-modules",
"--no-deprecation",
"--no-force-async-hooks-checks",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--prof",
"--prof-process",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-event-file-pattern",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=10.5.0 <10.7.0": [
"--enable-fips",
"--experimental-modules",
"--experimental-repl-await",
"--experimental-vm-modules",
"--experimental-worker",
"--force-fips",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--napi-modules",
"--no-deprecation",
"--no-force-async-hooks-checks",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--prof",
"--prof-process",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-event-file-pattern",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
],
">=10.7.0 <10.10.0": [
"--enable-fips",
"--experimental-modules",
"--experimental-repl-await",
"--experimental-vm-modules",
"--experimental-worker",
"--force-fips",
"--icu-data-dir",
"--inspect-brk",
"--inspect-port",
"--inspect",
"--loader",
"--napi-modules",
"--no-deprecation",
"--no-force-async-hooks-checks",
"--no-warnings",
"--openssl-config",
"--pending-deprecation",
"--prof",
"--prof-process",
"--redirect-warnings",
"--require",
"--throw-deprecation",
"--title",
"--tls-cipher-list",
"--trace-deprecation",
"--trace-event-categories",
"--trace-event-file-pattern",
"--trace-events-enabled",
"--trace-sync-io",
"--trace-warnings",
"--track-heap-objects",
"--use-bundled-ca",
"--use-openssl-ca",
"--v8-pool-size",
"--zero-fill-buffers",
"-r"
]
}
+62
View File
@@ -0,0 +1,62 @@
'use strict';
const semver = require('semver');
const flags = require('./flags.json');
const getDescriptors = require('object.getownpropertydescriptors');
const replaceUnderscoresRegex = /_/g;
const leadingDashesRegex = /^--?/;
const trailingValuesRegex = /=.*$/;
const replace = Function.call.bind(String.prototype.replace);
const has = Function.call.bind(Set.prototype.has);
const test = Function.call.bind(RegExp.prototype.test);
const [allowedNodeEnvironmentFlags, detectedSemverRange] = Object.keys(
flags
).reduce(
(acc, range) =>
acc ||
(semver.satisfies(process.version, range) ? [flags[range], range] : acc),
null
);
const trimLeadingDashes = flag => replace(flag, leadingDashesRegex, '');
class NodeEnvironmentFlagsSet extends Set {
constructor(...args) {
super(...args);
this.add = () => this;
}
delete() {
return false;
}
clear() {}
has(key) {
if (typeof key === 'string') {
key = replace(key, replaceUnderscoresRegex, '-');
if (test(leadingDashesRegex, key)) {
key = replace(key, trailingValuesRegex, '');
return has(this, key);
}
return has(nodeFlags, key);
}
return false;
}
}
const nodeFlags = Object.defineProperties(
new Set(allowedNodeEnvironmentFlags.map(trimLeadingDashes)),
getDescriptors(Set.prototype)
);
Object.freeze(NodeEnvironmentFlagsSet.prototype.constructor);
Object.freeze(NodeEnvironmentFlagsSet.prototype);
exports.allowedNodeEnvironmentFlags = Object.freeze(
new NodeEnvironmentFlagsSet(allowedNodeEnvironmentFlags)
);
exports.detectedSemverRange = detectedSemverRange;
+3
View File
@@ -0,0 +1,3 @@
'use strict';
module.exports = require('./polyfill')();
+100
View File
@@ -0,0 +1,100 @@
{
"_args": [
[
"node-environment-flags@1.0.5",
"C:\\Users\\Luis\\source\\repos\\AAMasters\\WebServer"
]
],
"_from": "node-environment-flags@1.0.5",
"_id": "node-environment-flags@1.0.5",
"_inBundle": false,
"_integrity": "sha512-VNYPRfGfmZLx0Ye20jWzHUjyTW/c+6Wq+iLhDzUI4XmhrDd9l/FozXV3F2xOaXjvp0co0+v1YSR3CMP6g+VvLQ==",
"_location": "/node-environment-flags",
"_phantomChildren": {},
"_requested": {
"type": "version",
"registry": true,
"raw": "node-environment-flags@1.0.5",
"name": "node-environment-flags",
"escapedName": "node-environment-flags",
"rawSpec": "1.0.5",
"saveSpec": null,
"fetchSpec": "1.0.5"
},
"_requiredBy": [
"/mocha"
],
"_resolved": "https://registry.npmjs.org/node-environment-flags/-/node-environment-flags-1.0.5.tgz",
"_spec": "1.0.5",
"_where": "C:\\Users\\Luis\\source\\repos\\AAMasters\\WebServer",
"author": {
"name": "Christopher Hiller",
"email": "boneskull@boneskull.com",
"url": "https://boneskull.com/"
},
"bugs": {
"url": "https://github.com/boneskull/node-environment-flags/issues"
},
"dependencies": {
"object.getownpropertydescriptors": "^2.0.3",
"semver": "^5.7.0"
},
"description": "> Polyfill/shim for `process.allowedNodeEnvironmentFlags`",
"devDependencies": {
"eslint": "^5.9.0",
"eslint-config-prettier": "^3.3.0",
"eslint-config-semistandard": "^13.0.0",
"eslint-config-standard": "^12.0.0",
"eslint-plugin-import": "^2.14.0",
"eslint-plugin-node": "^8.0.0",
"eslint-plugin-prettier": "^3.0.0",
"eslint-plugin-promise": "^4.0.1",
"eslint-plugin-standard": "^4.0.0",
"husky": "^1.1.3",
"lint-staged": "^8.0.4",
"mocha": "^5.2.0",
"nyc": "^13.3.0",
"prettier-eslint-cli": "^4.7.1",
"semantic-release": "^15.13.8",
"travis-deploy-once": "^5.0.9",
"unexpected": "^10.39.1"
},
"files": [
"implementation.js",
"flags.json",
"index.js",
"polyfill.js",
"shim.js"
],
"homepage": "https://github.com/boneskull/node-environment-flags#readme",
"husky": {
"hooks": {
"pre-commit": "lint-staged"
}
},
"keywords": [],
"license": "Apache-2.0",
"lint-staged": {
"*.{js,json}": [
"prettier-eslint --write",
"git add"
]
},
"main": "index.js",
"name": "node-environment-flags",
"prettier": {
"singleQuote": true,
"bracketSpacing": false
},
"repository": {
"type": "git",
"url": "git+https://github.com/boneskull/node-environment-flags.git"
},
"scripts": {
"format": "prettier-eslint --write \"*.js\" \"*.json\" \"test/**/*.js\"",
"semantic-release": "semantic-release",
"test": "mocha",
"travis-deploy-once": "travis-deploy-once"
},
"version": "1.0.5"
}
+8
View File
@@ -0,0 +1,8 @@
'use strict';
module.exports = () => {
if (typeof process.allowedNodeEnvironmentFlags === 'object') {
return process.allowedNodeEnvironmentFlags;
}
return require('./implementation').allowedNodeEnvironmentFlags;
};
+16
View File
@@ -0,0 +1,16 @@
'use strict';
const getPolyfill = require('./polyfill');
module.exports = () => {
const polyfill = getPolyfill();
if (polyfill !== process.allowedNodeEnvironmentFlags) {
Object.defineProperty(process, 'allowedNodeEnvironmentFlags', {
writable: true,
enumerable: true,
configurable: true,
value: polyfill
});
}
return polyfill;
};