Skip to content

Commit

Permalink
Angular 16 migration - fix env scripts types (#9881)
Browse files Browse the repository at this point in the history
  • Loading branch information
dominikiwanekhyland authored and swapnil-verma-gl committed Jul 8, 2024
1 parent 55da291 commit 50792ac
Show file tree
Hide file tree
Showing 7 changed files with 7 additions and 18 deletions.
7 changes: 1 addition & 6 deletions lib/cli/scripts/audit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,6 @@ import { Command } from 'commander';

const program = new Command();

interface AuditCommandArgs {
package?: string;
outDir?: string;
}

/**
* Audit report command
*
Expand All @@ -51,7 +46,7 @@ export default function main(_args: string[], workingDir: string) {
exit(0);
}

const options = program.opts<AuditCommandArgs>();
const options = program.opts();

let packagePath = path.resolve(workingDir, 'package.json');

Expand Down
2 changes: 1 addition & 1 deletion lib/cli/scripts/check-cs-env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export default async function main() {
.option('-r, --retry [type]', 'retry ')
.parse(argv);

const opts = program.opts<CheckCsEnvArgs>();
const opts = program.opts();
await checkEnv(opts);
// TODO: https://alfresco.atlassian.net/browse/ACS-5873
// await checkDiskSpaceFullEnv();
Expand Down
2 changes: 1 addition & 1 deletion lib/cli/scripts/check-plugin-env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ export default async function main() {
.option('--ui, --uiName [type]', 'uiName', 'Deployed app UI type on activiti-cloud')
.parse(argv);

const options = program.opts<CheckPluginArgs>();
const options = program.opts();

pluginEnv = new CheckEnv(options.host, options.username, options.password, options.clientId);
await pluginEnv.checkEnv();
Expand Down
2 changes: 1 addition & 1 deletion lib/cli/scripts/init-aae-env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -755,7 +755,7 @@ export default async function main() {
return;
}

const options = initializeDefaultToken(program.opts());
const options = initializeDefaultToken(program.opts() as ConfigArgs);

args = {
host: options.host,
Expand Down
2 changes: 1 addition & 1 deletion lib/cli/scripts/init-acs-env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export default async function main() {
.option('-u, --username [type]', 'username ')
.parse(argv);

const opts = program.opts<InitAcsEnvArgs>();
const opts = program.opts();
await checkEnv(opts);

logger.info(`***** Step initialize ACS *****`);
Expand Down
2 changes: 1 addition & 1 deletion lib/cli/scripts/init-aps-env.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ export default async function main() {
.option('--license [type]', 'APS license S3 path ')
.parse(argv);

const opts = program.opts<InitApsEnvArgs>();
const opts = program.opts();
await checkEnv(opts);

logger.info(`***** Step 1 - Check License *****`);
Expand Down
8 changes: 1 addition & 7 deletions lib/cli/scripts/licenses.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,6 @@ import * as ejs from 'ejs';
import { Command } from 'commander';

const program = new Command();

interface LicensesCommandArgs {
package?: string;
outDir?: string;
}

interface PackageInfo {
name: string;
description: string;
Expand Down Expand Up @@ -115,7 +109,7 @@ export default function main(_args: string[], workingDir: string) {
exit(0);
}

const options = program.opts<LicensesCommandArgs>();
const options = program.opts();
let packagePath = path.resolve(workingDir, 'package.json');

if (options.package) {
Expand Down

0 comments on commit 50792ac

Please sign in to comment.