@angular/cli 14.0.0-next.6 → 14.0.0-next.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cli/index.d.ts +0 -1
- package/lib/cli/index.js +3 -30
- package/lib/config/schema.json +22 -3
- package/lib/config/workspace-schema.d.ts +5 -0
- package/lib/init.js +2 -5
- package/package.json +19 -22
- package/src/analytics/analytics-collector.js +2 -0
- package/src/analytics/analytics.d.ts +1 -1
- package/src/analytics/analytics.js +39 -36
- package/src/command-builder/architect-base-command-module.d.ts +8 -1
- package/src/command-builder/architect-base-command-module.js +65 -3
- package/src/command-builder/architect-command-module.d.ts +4 -1
- package/src/command-builder/architect-command-module.js +40 -14
- package/src/command-builder/command-module.d.ts +4 -3
- package/src/command-builder/command-module.js +14 -7
- package/src/command-builder/command-runner.d.ts +1 -2
- package/src/command-builder/command-runner.js +69 -36
- package/src/command-builder/schematics-command-module.d.ts +3 -4
- package/src/command-builder/schematics-command-module.js +88 -48
- package/src/command-builder/utilities/normalize-options-middleware.d.ts +18 -0
- package/src/command-builder/utilities/normalize-options-middleware.js +59 -0
- package/src/command-builder/utilities/schematic-engine-host.d.ts +2 -2
- package/src/command-builder/utilities/schematic-engine-host.js +30 -17
- package/src/commands/add/cli.js +14 -14
- package/src/commands/add/long-description.md +1 -4
- package/src/commands/analytics/cli.d.ts +1 -1
- package/src/commands/analytics/info/cli.d.ts +1 -1
- package/src/commands/analytics/settings/cli.d.ts +1 -1
- package/src/commands/analytics/settings/cli.js +2 -2
- package/src/commands/cache/clean/cli.d.ts +17 -0
- package/src/commands/cache/clean/cli.js +32 -0
- package/src/commands/cache/cli.d.ts +17 -0
- package/src/commands/cache/cli.js +38 -0
- package/src/commands/cache/info/cli.d.ts +20 -0
- package/src/commands/cache/info/cli.js +82 -0
- package/src/commands/cache/long-description.md +53 -0
- package/src/commands/cache/settings/cli.d.ts +27 -0
- package/src/commands/cache/settings/cli.js +42 -0
- package/src/commands/cache/utilities.d.ts +11 -0
- package/src/commands/cache/utilities.js +49 -0
- package/src/commands/completion/cli.d.ts +16 -0
- package/src/commands/completion/cli.js +31 -0
- package/src/commands/completion/long-description.md +1 -0
- package/src/commands/config/cli.d.ts +1 -1
- package/src/commands/config/cli.js +15 -15
- package/src/commands/deploy/cli.d.ts +2 -1
- package/src/commands/deploy/cli.js +27 -13
- package/src/commands/doc/cli.d.ts +1 -1
- package/src/commands/e2e/cli.d.ts +3 -2
- package/src/commands/e2e/cli.js +14 -13
- package/src/commands/generate/cli.d.ts +11 -1
- package/src/commands/generate/cli.js +54 -23
- package/src/commands/lint/cli.d.ts +2 -1
- package/src/commands/lint/cli.js +6 -9
- package/src/commands/new/cli.d.ts +2 -0
- package/src/commands/new/cli.js +22 -6
- package/src/commands/run/cli.d.ts +2 -0
- package/src/commands/run/cli.js +24 -0
- package/src/commands/update/cli.d.ts +1 -0
- package/src/commands/update/cli.js +53 -23
- package/src/commands/update/schematic/index.js +27 -18
- package/src/commands/version/cli.d.ts +0 -1
- package/src/commands/version/cli.js +4 -23
- package/src/typings-bazel.d.ts +14 -0
- package/src/typings.d.ts +0 -13
- package/src/utilities/config.d.ts +5 -5
- package/src/utilities/config.js +27 -44
- package/src/{analytics/analytics-environment-options.d.ts → utilities/environment-options.d.ts} +3 -0
- package/src/utilities/environment-options.js +24 -0
- package/src/utilities/memoize.d.ts +15 -0
- package/src/utilities/memoize.js +69 -0
- package/src/utilities/package-manager.d.ts +33 -5
- package/src/utilities/package-manager.js +252 -71
- package/src/utilities/package-metadata.d.ts +15 -37
- package/src/utilities/package-metadata.js +10 -26
- package/src/utilities/package-tree.d.ts +2 -2
- package/src/utilities/prompt.d.ts +2 -0
- package/src/utilities/prompt.js +20 -3
- package/bin/postinstall/analytics-prompt.js +0 -27
- package/bin/postinstall/script.js +0 -16
- package/src/analytics/analytics-environment-options.js +0 -20
- package/src/utilities/install-package.d.ts +0 -16
- package/src/utilities/install-package.js +0 -193
- package/src/utilities/package-json.d.ts +0 -249
- package/src/utilities/package-json.js +0 -9
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* @license
|
|
4
|
-
* Copyright Google LLC All Rights Reserved.
|
|
5
|
-
*
|
|
6
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
7
|
-
* found in the LICENSE file at https://angular.io/license
|
|
8
|
-
*/
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.analyticsShareDisabled = exports.analyticsDisabled = void 0;
|
|
11
|
-
function isDisabled(variable) {
|
|
12
|
-
return variable === '0' || variable.toLowerCase() === 'false';
|
|
13
|
-
}
|
|
14
|
-
function isPresent(variable) {
|
|
15
|
-
return typeof variable === 'string' && variable !== '';
|
|
16
|
-
}
|
|
17
|
-
const analyticsVariable = process.env['NG_CLI_ANALYTICS'];
|
|
18
|
-
exports.analyticsDisabled = isPresent(analyticsVariable) && isDisabled(analyticsVariable);
|
|
19
|
-
const analyticsShareVariable = process.env['NG_CLI_ANALYTICS_SHARE'];
|
|
20
|
-
exports.analyticsShareDisabled = isPresent(analyticsShareVariable) && isDisabled(analyticsShareVariable);
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright Google LLC All Rights Reserved.
|
|
4
|
-
*
|
|
5
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
-
* found in the LICENSE file at https://angular.io/license
|
|
7
|
-
*/
|
|
8
|
-
import { PackageManager } from '../../lib/config/workspace-schema';
|
|
9
|
-
import { NgAddSaveDepedency } from './package-metadata';
|
|
10
|
-
export declare function installAllPackages(packageManager?: PackageManager, extraArgs?: string[], cwd?: string): Promise<1 | 0>;
|
|
11
|
-
export declare function installPackage(packageName: string, packageManager?: PackageManager, save?: Exclude<NgAddSaveDepedency, false>, extraArgs?: string[], cwd?: string): Promise<1 | 0>;
|
|
12
|
-
export declare function installTempPackage(packageName: string, packageManager?: PackageManager, extraArgs?: string[]): Promise<{
|
|
13
|
-
status: 1 | 0;
|
|
14
|
-
tempNodeModules: string;
|
|
15
|
-
}>;
|
|
16
|
-
export declare function runTempPackageBin(packageName: string, packageManager?: PackageManager, args?: string[]): Promise<number>;
|
|
@@ -1,193 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* @license
|
|
4
|
-
* Copyright Google LLC All Rights Reserved.
|
|
5
|
-
*
|
|
6
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
7
|
-
* found in the LICENSE file at https://angular.io/license
|
|
8
|
-
*/
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
10
|
-
exports.runTempPackageBin = exports.installTempPackage = exports.installPackage = exports.installAllPackages = void 0;
|
|
11
|
-
const child_process_1 = require("child_process");
|
|
12
|
-
const fs_1 = require("fs");
|
|
13
|
-
const os_1 = require("os");
|
|
14
|
-
const path_1 = require("path");
|
|
15
|
-
const workspace_schema_1 = require("../../lib/config/workspace-schema");
|
|
16
|
-
const spinner_1 = require("./spinner");
|
|
17
|
-
async function installAllPackages(packageManager = workspace_schema_1.PackageManager.Npm, extraArgs = [], cwd = process.cwd()) {
|
|
18
|
-
const packageManagerArgs = getPackageManagerArguments(packageManager);
|
|
19
|
-
const installArgs = [];
|
|
20
|
-
if (packageManagerArgs.installAll) {
|
|
21
|
-
installArgs.push(packageManagerArgs.installAll);
|
|
22
|
-
}
|
|
23
|
-
installArgs.push(packageManagerArgs.silent);
|
|
24
|
-
const spinner = new spinner_1.Spinner();
|
|
25
|
-
spinner.start('Installing packages...');
|
|
26
|
-
const bufferedOutput = [];
|
|
27
|
-
return new Promise((resolve, reject) => {
|
|
28
|
-
var _a, _b;
|
|
29
|
-
const childProcess = (0, child_process_1.spawn)(packageManager, [...installArgs, ...extraArgs], {
|
|
30
|
-
stdio: 'pipe',
|
|
31
|
-
shell: true,
|
|
32
|
-
cwd,
|
|
33
|
-
}).on('close', (code) => {
|
|
34
|
-
if (code === 0) {
|
|
35
|
-
spinner.succeed('Packages successfully installed.');
|
|
36
|
-
resolve(0);
|
|
37
|
-
}
|
|
38
|
-
else {
|
|
39
|
-
spinner.stop();
|
|
40
|
-
bufferedOutput.forEach(({ stream, data }) => stream.write(data));
|
|
41
|
-
spinner.fail('Package install failed, see above.');
|
|
42
|
-
reject(1);
|
|
43
|
-
}
|
|
44
|
-
});
|
|
45
|
-
(_a = childProcess.stdout) === null || _a === void 0 ? void 0 : _a.on('data', (data) => bufferedOutput.push({ stream: process.stdout, data: data }));
|
|
46
|
-
(_b = childProcess.stderr) === null || _b === void 0 ? void 0 : _b.on('data', (data) => bufferedOutput.push({ stream: process.stderr, data: data }));
|
|
47
|
-
});
|
|
48
|
-
}
|
|
49
|
-
exports.installAllPackages = installAllPackages;
|
|
50
|
-
async function installPackage(packageName, packageManager = workspace_schema_1.PackageManager.Npm, save = true, extraArgs = [], cwd = process.cwd()) {
|
|
51
|
-
const packageManagerArgs = getPackageManagerArguments(packageManager);
|
|
52
|
-
const installArgs = [
|
|
53
|
-
packageManagerArgs.install,
|
|
54
|
-
packageName,
|
|
55
|
-
packageManagerArgs.silent,
|
|
56
|
-
];
|
|
57
|
-
const spinner = new spinner_1.Spinner();
|
|
58
|
-
spinner.start('Installing package...');
|
|
59
|
-
if (save === 'devDependencies') {
|
|
60
|
-
installArgs.push(packageManagerArgs.saveDev);
|
|
61
|
-
}
|
|
62
|
-
const bufferedOutput = [];
|
|
63
|
-
return new Promise((resolve, reject) => {
|
|
64
|
-
var _a, _b;
|
|
65
|
-
const childProcess = (0, child_process_1.spawn)(packageManager, [...installArgs, ...extraArgs], {
|
|
66
|
-
stdio: 'pipe',
|
|
67
|
-
shell: true,
|
|
68
|
-
cwd,
|
|
69
|
-
}).on('close', (code) => {
|
|
70
|
-
if (code === 0) {
|
|
71
|
-
spinner.succeed('Package successfully installed.');
|
|
72
|
-
resolve(0);
|
|
73
|
-
}
|
|
74
|
-
else {
|
|
75
|
-
spinner.stop();
|
|
76
|
-
bufferedOutput.forEach(({ stream, data }) => stream.write(data));
|
|
77
|
-
spinner.fail('Package install failed, see above.');
|
|
78
|
-
reject(1);
|
|
79
|
-
}
|
|
80
|
-
});
|
|
81
|
-
(_a = childProcess.stdout) === null || _a === void 0 ? void 0 : _a.on('data', (data) => bufferedOutput.push({ stream: process.stdout, data: data }));
|
|
82
|
-
(_b = childProcess.stderr) === null || _b === void 0 ? void 0 : _b.on('data', (data) => bufferedOutput.push({ stream: process.stderr, data: data }));
|
|
83
|
-
});
|
|
84
|
-
}
|
|
85
|
-
exports.installPackage = installPackage;
|
|
86
|
-
async function installTempPackage(packageName, packageManager = workspace_schema_1.PackageManager.Npm, extraArgs) {
|
|
87
|
-
const tempPath = (0, fs_1.mkdtempSync)((0, path_1.join)((0, fs_1.realpathSync)((0, os_1.tmpdir)()), 'angular-cli-packages-'));
|
|
88
|
-
// clean up temp directory on process exit
|
|
89
|
-
process.on('exit', () => {
|
|
90
|
-
try {
|
|
91
|
-
(0, fs_1.rmdirSync)(tempPath, { recursive: true, maxRetries: 3 });
|
|
92
|
-
}
|
|
93
|
-
catch { }
|
|
94
|
-
});
|
|
95
|
-
// NPM will warn when a `package.json` is not found in the install directory
|
|
96
|
-
// Example:
|
|
97
|
-
// npm WARN enoent ENOENT: no such file or directory, open '/tmp/.ng-temp-packages-84Qi7y/package.json'
|
|
98
|
-
// npm WARN .ng-temp-packages-84Qi7y No description
|
|
99
|
-
// npm WARN .ng-temp-packages-84Qi7y No repository field.
|
|
100
|
-
// npm WARN .ng-temp-packages-84Qi7y No license field.
|
|
101
|
-
// While we can use `npm init -y` we will end up needing to update the 'package.json' anyways
|
|
102
|
-
// because of missing fields.
|
|
103
|
-
(0, fs_1.writeFileSync)((0, path_1.join)(tempPath, 'package.json'), JSON.stringify({
|
|
104
|
-
name: 'temp-cli-install',
|
|
105
|
-
description: 'temp-cli-install',
|
|
106
|
-
repository: 'temp-cli-install',
|
|
107
|
-
license: 'MIT',
|
|
108
|
-
}));
|
|
109
|
-
// setup prefix/global modules path
|
|
110
|
-
const packageManagerArgs = getPackageManagerArguments(packageManager);
|
|
111
|
-
const tempNodeModules = (0, path_1.join)(tempPath, 'node_modules');
|
|
112
|
-
// Yarn will not append 'node_modules' to the path
|
|
113
|
-
const prefixPath = packageManager === workspace_schema_1.PackageManager.Yarn ? tempNodeModules : tempPath;
|
|
114
|
-
const installArgs = [
|
|
115
|
-
...(extraArgs || []),
|
|
116
|
-
`${packageManagerArgs.prefix}="${prefixPath}"`,
|
|
117
|
-
packageManagerArgs.noLockfile,
|
|
118
|
-
];
|
|
119
|
-
return {
|
|
120
|
-
status: await installPackage(packageName, packageManager, true, installArgs, tempPath),
|
|
121
|
-
tempNodeModules,
|
|
122
|
-
};
|
|
123
|
-
}
|
|
124
|
-
exports.installTempPackage = installTempPackage;
|
|
125
|
-
async function runTempPackageBin(packageName, packageManager = workspace_schema_1.PackageManager.Npm, args = []) {
|
|
126
|
-
const { status: code, tempNodeModules } = await installTempPackage(packageName, packageManager);
|
|
127
|
-
if (code !== 0) {
|
|
128
|
-
return code;
|
|
129
|
-
}
|
|
130
|
-
// Remove version/tag etc... from package name
|
|
131
|
-
// Ex: @angular/cli@latest -> @angular/cli
|
|
132
|
-
const packageNameNoVersion = packageName.substring(0, packageName.lastIndexOf('@'));
|
|
133
|
-
const pkgLocation = (0, path_1.join)(tempNodeModules, packageNameNoVersion);
|
|
134
|
-
const packageJsonPath = (0, path_1.join)(pkgLocation, 'package.json');
|
|
135
|
-
// Get a binary location for this package
|
|
136
|
-
let binPath;
|
|
137
|
-
if ((0, fs_1.existsSync)(packageJsonPath)) {
|
|
138
|
-
const content = (0, fs_1.readFileSync)(packageJsonPath, 'utf-8');
|
|
139
|
-
if (content) {
|
|
140
|
-
const { bin = {} } = JSON.parse(content);
|
|
141
|
-
const binKeys = Object.keys(bin);
|
|
142
|
-
if (binKeys.length) {
|
|
143
|
-
binPath = (0, path_1.resolve)(pkgLocation, bin[binKeys[0]]);
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
if (!binPath) {
|
|
148
|
-
throw new Error(`Cannot locate bin for temporary package: ${packageNameNoVersion}.`);
|
|
149
|
-
}
|
|
150
|
-
const { status, error } = (0, child_process_1.spawnSync)(process.execPath, [binPath, ...args], {
|
|
151
|
-
stdio: 'inherit',
|
|
152
|
-
env: {
|
|
153
|
-
...process.env,
|
|
154
|
-
NG_DISABLE_VERSION_CHECK: 'true',
|
|
155
|
-
NG_CLI_ANALYTICS: 'false',
|
|
156
|
-
},
|
|
157
|
-
});
|
|
158
|
-
if (status === null && error) {
|
|
159
|
-
throw error;
|
|
160
|
-
}
|
|
161
|
-
return status || 0;
|
|
162
|
-
}
|
|
163
|
-
exports.runTempPackageBin = runTempPackageBin;
|
|
164
|
-
function getPackageManagerArguments(packageManager) {
|
|
165
|
-
switch (packageManager) {
|
|
166
|
-
case workspace_schema_1.PackageManager.Yarn:
|
|
167
|
-
return {
|
|
168
|
-
silent: '--silent',
|
|
169
|
-
saveDev: '--dev',
|
|
170
|
-
install: 'add',
|
|
171
|
-
prefix: '--modules-folder',
|
|
172
|
-
noLockfile: '--no-lockfile',
|
|
173
|
-
};
|
|
174
|
-
case workspace_schema_1.PackageManager.Pnpm:
|
|
175
|
-
return {
|
|
176
|
-
silent: '--silent',
|
|
177
|
-
saveDev: '--save-dev',
|
|
178
|
-
install: 'add',
|
|
179
|
-
installAll: 'install',
|
|
180
|
-
prefix: '--prefix',
|
|
181
|
-
noLockfile: '--no-lockfile',
|
|
182
|
-
};
|
|
183
|
-
default:
|
|
184
|
-
return {
|
|
185
|
-
silent: '--quiet',
|
|
186
|
-
saveDev: '--save-dev',
|
|
187
|
-
install: 'install',
|
|
188
|
-
installAll: 'install',
|
|
189
|
-
prefix: '--prefix',
|
|
190
|
-
noLockfile: '--no-package-lock',
|
|
191
|
-
};
|
|
192
|
-
}
|
|
193
|
-
}
|
|
@@ -1,249 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright Google LLC All Rights Reserved.
|
|
4
|
-
*
|
|
5
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
6
|
-
* found in the LICENSE file at https://angular.io/license
|
|
7
|
-
*/
|
|
8
|
-
/**
|
|
9
|
-
* This file was automatically generated by json-schema-to-typescript.
|
|
10
|
-
* DO NOT MODIFY IT BY HAND. Instead, modify the source JSONSchema file,
|
|
11
|
-
* and run json-schema-to-typescript to regenerate this file.
|
|
12
|
-
*/
|
|
13
|
-
export declare type JsonSchemaForNpmPackageJsonFiles = CoreProperties & JspmDefinition & ({
|
|
14
|
-
bundleDependencies?: BundledDependency;
|
|
15
|
-
[k: string]: any;
|
|
16
|
-
} | {
|
|
17
|
-
bundledDependencies?: BundledDependency;
|
|
18
|
-
[k: string]: any;
|
|
19
|
-
}) & {
|
|
20
|
-
[k: string]: any;
|
|
21
|
-
};
|
|
22
|
-
/**
|
|
23
|
-
* A person who has been involved in creating or maintaining this package
|
|
24
|
-
*/
|
|
25
|
-
export declare type Person = {
|
|
26
|
-
[k: string]: any;
|
|
27
|
-
} | string;
|
|
28
|
-
/**
|
|
29
|
-
* Run AFTER the package is published
|
|
30
|
-
*/
|
|
31
|
-
export declare type ScriptsPublishAfter = string;
|
|
32
|
-
/**
|
|
33
|
-
* Run AFTER the package is installed
|
|
34
|
-
*/
|
|
35
|
-
export declare type ScriptsInstallAfter = string;
|
|
36
|
-
/**
|
|
37
|
-
* Run BEFORE the package is uninstalled
|
|
38
|
-
*/
|
|
39
|
-
export declare type ScriptsUninstallBefore = string;
|
|
40
|
-
/**
|
|
41
|
-
* Run BEFORE bump the package version
|
|
42
|
-
*/
|
|
43
|
-
export declare type ScriptsVersionBefore = string;
|
|
44
|
-
/**
|
|
45
|
-
* Run by the 'npm test' command
|
|
46
|
-
*/
|
|
47
|
-
export declare type ScriptsTest = string;
|
|
48
|
-
/**
|
|
49
|
-
* Run by the 'npm stop' command
|
|
50
|
-
*/
|
|
51
|
-
export declare type ScriptsStop = string;
|
|
52
|
-
/**
|
|
53
|
-
* Run by the 'npm start' command
|
|
54
|
-
*/
|
|
55
|
-
export declare type ScriptsStart = string;
|
|
56
|
-
/**
|
|
57
|
-
* Run by the 'npm restart' command. Note: 'npm restart' will run the stop and start scripts if no restart script is provided.
|
|
58
|
-
*/
|
|
59
|
-
export declare type ScriptsRestart = string;
|
|
60
|
-
/**
|
|
61
|
-
* Array of package names that will be bundled when publishing the package.
|
|
62
|
-
*/
|
|
63
|
-
export declare type BundledDependency = string[];
|
|
64
|
-
export interface CoreProperties {
|
|
65
|
-
/**
|
|
66
|
-
* The name of the package.
|
|
67
|
-
*/
|
|
68
|
-
name?: string;
|
|
69
|
-
/**
|
|
70
|
-
* Version must be parseable by node-semver, which is bundled with npm as a dependency.
|
|
71
|
-
*/
|
|
72
|
-
version?: string;
|
|
73
|
-
/**
|
|
74
|
-
* This helps people discover your package, as it's listed in 'npm search'.
|
|
75
|
-
*/
|
|
76
|
-
description?: string;
|
|
77
|
-
/**
|
|
78
|
-
* This helps people discover your package as it's listed in 'npm search'.
|
|
79
|
-
*/
|
|
80
|
-
keywords?: string[];
|
|
81
|
-
/**
|
|
82
|
-
* The url to the project homepage.
|
|
83
|
-
*/
|
|
84
|
-
homepage?: string;
|
|
85
|
-
/**
|
|
86
|
-
* The url to your project's issue tracker and / or the email address to which issues should be reported. These are helpful for people who encounter issues with your package.
|
|
87
|
-
*/
|
|
88
|
-
bugs?: {
|
|
89
|
-
[k: string]: any;
|
|
90
|
-
} | string;
|
|
91
|
-
/**
|
|
92
|
-
* You should specify a license for your package so that people know how they are permitted to use it, and any restrictions you're placing on it.
|
|
93
|
-
*/
|
|
94
|
-
license?: string;
|
|
95
|
-
/**
|
|
96
|
-
* You should specify a license for your package so that people know how they are permitted to use it, and any restrictions you're placing on it.
|
|
97
|
-
*/
|
|
98
|
-
licenses?: {
|
|
99
|
-
type?: string;
|
|
100
|
-
url?: string;
|
|
101
|
-
[k: string]: any;
|
|
102
|
-
}[];
|
|
103
|
-
author?: Person;
|
|
104
|
-
/**
|
|
105
|
-
* A list of people who contributed to this package.
|
|
106
|
-
*/
|
|
107
|
-
contributors?: Person[];
|
|
108
|
-
/**
|
|
109
|
-
* A list of people who maintains this package.
|
|
110
|
-
*/
|
|
111
|
-
maintainers?: Person[];
|
|
112
|
-
/**
|
|
113
|
-
* The 'files' field is an array of files to include in your project. If you name a folder in the array, then it will also include the files inside that folder.
|
|
114
|
-
*/
|
|
115
|
-
files?: string[];
|
|
116
|
-
/**
|
|
117
|
-
* The main field is a module ID that is the primary entry point to your program.
|
|
118
|
-
*/
|
|
119
|
-
main?: string;
|
|
120
|
-
bin?: string | {
|
|
121
|
-
[k: string]: any;
|
|
122
|
-
};
|
|
123
|
-
/**
|
|
124
|
-
* Specify either a single file or an array of filenames to put in place for the man program to find.
|
|
125
|
-
*/
|
|
126
|
-
man?: string[];
|
|
127
|
-
directories?: {
|
|
128
|
-
/**
|
|
129
|
-
* If you specify a 'bin' directory, then all the files in that folder will be used as the 'bin' hash.
|
|
130
|
-
*/
|
|
131
|
-
bin?: string;
|
|
132
|
-
/**
|
|
133
|
-
* Put markdown files in here. Eventually, these will be displayed nicely, maybe, someday.
|
|
134
|
-
*/
|
|
135
|
-
doc?: string;
|
|
136
|
-
/**
|
|
137
|
-
* Put example scripts in here. Someday, it might be exposed in some clever way.
|
|
138
|
-
*/
|
|
139
|
-
example?: string;
|
|
140
|
-
/**
|
|
141
|
-
* Tell people where the bulk of your library is. Nothing special is done with the lib folder in any way, but it's useful meta info.
|
|
142
|
-
*/
|
|
143
|
-
lib?: string;
|
|
144
|
-
/**
|
|
145
|
-
* A folder that is full of man pages. Sugar to generate a 'man' array by walking the folder.
|
|
146
|
-
*/
|
|
147
|
-
man?: string;
|
|
148
|
-
test?: string;
|
|
149
|
-
[k: string]: any;
|
|
150
|
-
};
|
|
151
|
-
/**
|
|
152
|
-
* Specify the place where your code lives. This is helpful for people who want to contribute.
|
|
153
|
-
*/
|
|
154
|
-
repository?: {
|
|
155
|
-
[k: string]: any;
|
|
156
|
-
} | string;
|
|
157
|
-
/**
|
|
158
|
-
* The 'scripts' member is an object hash of script commands that are run at various times in the lifecycle of your package. The key is the lifecycle event, and the value is the command to run at that point.
|
|
159
|
-
*/
|
|
160
|
-
scripts?: {
|
|
161
|
-
/**
|
|
162
|
-
* Run BEFORE the package is published (Also run on local npm install without any arguments)
|
|
163
|
-
*/
|
|
164
|
-
prepublish?: string;
|
|
165
|
-
publish?: ScriptsPublishAfter;
|
|
166
|
-
postpublish?: ScriptsPublishAfter;
|
|
167
|
-
/**
|
|
168
|
-
* Run BEFORE the package is installed
|
|
169
|
-
*/
|
|
170
|
-
preinstall?: string;
|
|
171
|
-
install?: ScriptsInstallAfter;
|
|
172
|
-
postinstall?: ScriptsInstallAfter;
|
|
173
|
-
preuninstall?: ScriptsUninstallBefore;
|
|
174
|
-
uninstall?: ScriptsUninstallBefore;
|
|
175
|
-
/**
|
|
176
|
-
* Run AFTER the package is uninstalled
|
|
177
|
-
*/
|
|
178
|
-
postuninstall?: string;
|
|
179
|
-
preversion?: ScriptsVersionBefore;
|
|
180
|
-
version?: ScriptsVersionBefore;
|
|
181
|
-
/**
|
|
182
|
-
* Run AFTER bump the package version
|
|
183
|
-
*/
|
|
184
|
-
postversion?: string;
|
|
185
|
-
pretest?: ScriptsTest;
|
|
186
|
-
test?: ScriptsTest;
|
|
187
|
-
posttest?: ScriptsTest;
|
|
188
|
-
prestop?: ScriptsStop;
|
|
189
|
-
stop?: ScriptsStop;
|
|
190
|
-
poststop?: ScriptsStop;
|
|
191
|
-
prestart?: ScriptsStart;
|
|
192
|
-
start?: ScriptsStart;
|
|
193
|
-
poststart?: ScriptsStart;
|
|
194
|
-
prerestart?: ScriptsRestart;
|
|
195
|
-
restart?: ScriptsRestart;
|
|
196
|
-
postrestart?: ScriptsRestart;
|
|
197
|
-
[k: string]: string | undefined;
|
|
198
|
-
};
|
|
199
|
-
/**
|
|
200
|
-
* A 'config' hash can be used to set configuration parameters used in package scripts that persist across upgrades.
|
|
201
|
-
*/
|
|
202
|
-
config?: {
|
|
203
|
-
[k: string]: any;
|
|
204
|
-
};
|
|
205
|
-
dependencies?: Dependency;
|
|
206
|
-
devDependencies?: Dependency;
|
|
207
|
-
optionalDependencies?: Dependency;
|
|
208
|
-
peerDependencies?: Dependency;
|
|
209
|
-
engines?: {
|
|
210
|
-
[k: string]: string;
|
|
211
|
-
};
|
|
212
|
-
engineStrict?: boolean;
|
|
213
|
-
/**
|
|
214
|
-
* You can specify which operating systems your module will run on
|
|
215
|
-
*/
|
|
216
|
-
os?: string[];
|
|
217
|
-
/**
|
|
218
|
-
* If your code only runs on certain cpu architectures, you can specify which ones.
|
|
219
|
-
*/
|
|
220
|
-
cpu?: string[];
|
|
221
|
-
/**
|
|
222
|
-
* If your package is primarily a command-line application that should be installed globally, then set this value to true to provide a warning if it is installed locally.
|
|
223
|
-
*/
|
|
224
|
-
preferGlobal?: boolean;
|
|
225
|
-
/**
|
|
226
|
-
* If set to true, then npm will refuse to publish it.
|
|
227
|
-
*/
|
|
228
|
-
private?: boolean;
|
|
229
|
-
publishConfig?: {
|
|
230
|
-
[k: string]: any;
|
|
231
|
-
};
|
|
232
|
-
dist?: {
|
|
233
|
-
shasum?: string;
|
|
234
|
-
tarball?: string;
|
|
235
|
-
[k: string]: any;
|
|
236
|
-
};
|
|
237
|
-
readme?: string;
|
|
238
|
-
[k: string]: any;
|
|
239
|
-
}
|
|
240
|
-
/**
|
|
241
|
-
* Dependencies are specified with a simple hash of package name to version range. The version range is a string which has one or more space-separated descriptors. Dependencies can also be identified with a tarball or git URL.
|
|
242
|
-
*/
|
|
243
|
-
export interface Dependency {
|
|
244
|
-
[k: string]: string;
|
|
245
|
-
}
|
|
246
|
-
export interface JspmDefinition {
|
|
247
|
-
jspm?: CoreProperties;
|
|
248
|
-
[k: string]: any;
|
|
249
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
/**
|
|
3
|
-
* @license
|
|
4
|
-
* Copyright Google LLC All Rights Reserved.
|
|
5
|
-
*
|
|
6
|
-
* Use of this source code is governed by an MIT-style license that can be
|
|
7
|
-
* found in the LICENSE file at https://angular.io/license
|
|
8
|
-
*/
|
|
9
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|