Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove --help-json leftovers. #12331

Merged
merged 2 commits into from
Sep 20, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/angular/cli/models/architect-command.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ export abstract class ArchitectCommand<
}

if ((!targetSpec.project || !targetSpec.target) && !this.multiTarget) {
if (options.help || options.helpJson) {
if (options.help) {
// This is a special case where we just return.
return;
}
Expand Down
1 change: 0 additions & 1 deletion packages/angular/cli/models/command.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ import {

export interface BaseCommandOptions {
help?: boolean | string;
helpJson?: boolean;
}

export abstract class Command<T extends BaseCommandOptions = BaseCommandOptions> {
Expand Down
2 changes: 1 addition & 1 deletion packages/angular/cli/models/interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export enum OptionType {
}

/**
* An option description. This is exposed when using `ng --help-json`.
* An option description. This is exposed when using `ng --help=json`.
*/
export interface Option {
/**
Expand Down
2 changes: 1 addition & 1 deletion scripts/snapshots.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ export default async function(opts: SnapshotsOptions, logger: logging.Logger) {
for (const commandName of Object.keys(commands)) {
const options = { cwd: newProjectRoot };
const childLogger = logger.createChild(commandName);
const stdout = _exec(ngPath, [commandName, '--help-json'], options, childLogger);
const stdout = _exec(ngPath, [commandName, '--help=json'], options, childLogger);
if (stdout.trim()) {
fs.writeFileSync(path.join(helpOutputRoot, commandName + '.json'), stdout);
}
Expand Down