Skip to content

Commit

Permalink
fix(cli): Deprecate doctor and lab commands (#4945)
Browse files Browse the repository at this point in the history
  • Loading branch information
dtarnawsky authored Jan 10, 2023
1 parent f586a18 commit 6fcf882
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 8 deletions.
6 changes: 3 additions & 3 deletions packages/@ionic/cli/src/commands/capacitor/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,17 @@ export class BuildCommand extends CapacitorCommand implements CommandPreRun {
const footnotes: Footnote[] = [
{
id: 'capacitor-native-config-docs',
url: 'https://capacitor.ionicframework.com/docs/basics/configuring-your-app',
url: 'https://capacitorjs.com/docs/basics/configuring-your-app',
shortUrl: 'https://ion.link/capacitor-native-config-docs',
},
{
id: 'capacitor-ios-config-docs',
url: 'https://capacitor.ionicframework.com/docs/ios/configuration',
url: 'https://capacitorjs.com/docs/ios/configuration',
shortUrl: 'https://ion.link/capacitor-ios-config-docs',
},
{
id: 'capacitor-android-config-docs',
url: 'https://capacitor.ionicframework.com/docs/android/configuration',
url: 'https://capacitorjs.com/docs/android/configuration',
shortUrl: 'https://ion.link/capacitor-android-config-docs',
},
];
Expand Down
3 changes: 2 additions & 1 deletion packages/@ionic/cli/src/commands/doctor/check.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { contains, validate } from '@ionic/cli-framework';
import { contains, MetadataGroup, validate } from '@ionic/cli-framework';

import { CommandLineInputs, CommandLineOptions, CommandMetadata, IAilment } from '../../definitions';
import { isTreatableAilment } from '../../guards';
Expand All @@ -13,6 +13,7 @@ export class DoctorCheckCommand extends DoctorCommand {
name: 'check',
type: 'project',
summary: 'Check the health of your Ionic project',
groups: [MetadataGroup.DEPRECATED],
description: `
This command detects and prints common issues and suggested steps to fix them.
Expand Down
2 changes: 2 additions & 0 deletions packages/@ionic/cli/src/commands/doctor/list.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { MetadataGroup } from '@ionic/cli-framework';
import { strcmp } from '@ionic/cli-framework/utils/string';
import { columnar } from '@ionic/utils-terminal';

Expand All @@ -14,6 +15,7 @@ export class DoctorListCommand extends DoctorCommand {
name: 'list',
type: 'project',
summary: 'List all issues and their identifiers',
groups: [MetadataGroup.DEPRECATED],
description: `
Issues can have various tags:
- ${strong('treatable')}: ${input('ionic doctor treat')} can attempt to fix the issue
Expand Down
3 changes: 2 additions & 1 deletion packages/@ionic/cli/src/commands/doctor/treat.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { contains, validate } from '@ionic/cli-framework';
import { contains, MetadataGroup, validate } from '@ionic/cli-framework';

import { CommandLineInputs, CommandLineOptions, CommandMetadata, TreatableAilment } from '../../definitions';
import { isExitCodeException, isTreatableAilment } from '../../guards';
Expand All @@ -16,6 +16,7 @@ export class DoctorTreatCommand extends DoctorCommand {
name: 'treat',
type: 'project',
summary: 'Attempt to fix issues in your Ionic project',
groups: [MetadataGroup.DEPRECATED],
description: `
This command detects and attempts to fix common issues. Before a fix is attempted, the steps are printed and a confirmation prompt is displayed.
Expand Down
7 changes: 4 additions & 3 deletions packages/@ionic/cli/src/commands/serve.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@ export class ServeCommand extends Command implements CommandPreRun {
name: 'lab-host',
summary: 'Use specific host for Ionic Lab server',
default: 'localhost',
groups: [MetadataGroup.ADVANCED],
groups: [MetadataGroup.HIDDEN, MetadataGroup.ADVANCED],
spec: { value: 'host' },
hint: weak('(--lab)'),
},
{
name: 'lab-port',
summary: 'Use specific port for Ionic Lab server',
default: DEFAULT_LAB_PORT.toString(),
groups: [MetadataGroup.ADVANCED],
groups: [MetadataGroup.HIDDEN, MetadataGroup.ADVANCED],
spec: { value: 'port' },
hint: weak('(--lab)'),
},
Expand Down Expand Up @@ -56,10 +56,11 @@ export class ServeCommand extends Command implements CommandPreRun {
summary: 'Test your apps on multiple platform types in the browser',
type: Boolean,
aliases: ['l'],
groups: [MetadataGroup.HIDDEN],
},
];

const exampleCommands = ['', '--external', '--lab'];
const exampleCommands = ['', '--external'];
const footnotes: Footnote[] = [];

let description = `
Expand Down

0 comments on commit 6fcf882

Please sign in to comment.