Skip to content

Commit 9c41267

Browse files
Dimitar KerezovMitko-Kerezov
authored andcommitted
Fix comments
1 parent 0b70f39 commit 9c41267

26 files changed

Lines changed: 137 additions & 117 deletions

lib/commands/add-platform.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export class AddPlatformCommand implements ICommand {
99
}
1010

1111
public async execute(args: string[]): Promise<void> {
12-
await this.$platformService.addPlatforms(args, this.$options.platformTemplate, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk }, this.$options.frameworkPath);
12+
await this.$platformService.addPlatforms(args, this.$options.platformTemplate, this.$projectData, this.$options.provision, this.$options.frameworkPath);
1313
}
1414

1515
public async canExecute(args: string[]): Promise<boolean> {

lib/commands/appstore-upload.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ export class PublishIOS implements ICommand {
1515
private $options: IOptions,
1616
private $prompter: IPrompter,
1717
private $devicePlatformsConstants: Mobile.IDevicePlatformsConstants) {
18-
this.$projectData.initializeProjectData();
19-
}
18+
this.$projectData.initializeProjectData();
19+
}
2020

2121
private get $platformsData(): IPlatformsData {
2222
return this.$injector.resolve("platformsData");
@@ -71,12 +71,12 @@ export class PublishIOS implements ICommand {
7171
};
7272
this.$logger.info("Building .ipa with the selected mobile provision and/or certificate.");
7373
// This is not very correct as if we build multiple targets we will try to sign all of them using the signing identity here.
74-
await this.$platformService.preparePlatform(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
74+
await this.$platformService.preparePlatform(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, this.$options);
7575
await this.$platformService.buildPlatform(platform, iOSBuildConfig, this.$projectData);
7676
ipaFilePath = this.$platformService.lastOutputPath(platform, iOSBuildConfig, this.$projectData);
7777
} else {
7878
this.$logger.info("No .ipa, mobile provision or certificate set. Perfect! Now we'll build .xcarchive and let Xcode pick the distribution certificate and provisioning profile for you when exporting .ipa for AppStore submission.");
79-
await this.$platformService.preparePlatform(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
79+
await this.$platformService.preparePlatform(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, this.$options);
8080

8181
let platformData = this.$platformsData.getPlatformData(platform, this.$projectData);
8282
let iOSProjectService = <IOSProjectService>platformData.platformProjectService;

lib/commands/build.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ export class BuildCommandBase {
99
public async executeCore(args: string[]): Promise<void> {
1010
let platform = args[0].toLowerCase();
1111
const appFilesUpdaterOptions: IAppFilesUpdaterOptions = { bundle: this.$options.bundle, release: this.$options.release };
12-
await this.$platformService.preparePlatform(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
12+
await this.$platformService.preparePlatform(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, this.$options);
1313
this.$options.clean = true;
1414
const buildConfig: IBuildConfig = {
1515
buildForDevice: this.$options.forDevice,

lib/commands/clean-app.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@ export class CleanAppCommandBase {
22
constructor(protected $options: IOptions,
33
protected $projectData: IProjectData,
44
private $platformService: IPlatformService) {
5-
this.$projectData.initializeProjectData();
6-
}
5+
this.$projectData.initializeProjectData();
6+
}
77

88
public async execute(args: string[]): Promise<void> {
99
let platform = args[0].toLowerCase();
1010
const appFilesUpdaterOptions: IAppFilesUpdaterOptions = { bundle: this.$options.bundle, release: this.$options.release };
11-
return this.$platformService.cleanDestinationApp(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
11+
return this.$platformService.cleanDestinationApp(platform, appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, this.$options);
1212
}
1313
}
1414

lib/commands/debug.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export abstract class DebugPlatformCommand implements ICommand {
4141

4242
const appFilesUpdaterOptions: IAppFilesUpdaterOptions = { bundle: this.$options.bundle, release: this.$options.release };
4343

44-
await this.$platformService.deployPlatform(this.$devicesService.platform, appFilesUpdaterOptions, deployOptions, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
44+
await this.$platformService.deployPlatform(this.$devicesService.platform, appFilesUpdaterOptions, deployOptions, this.$projectData, this.$options);
4545
this.$config.debugLivesync = true;
4646
let applicationReloadAction = async (deviceAppData: Mobile.IDeviceAppData): Promise<void> => {
4747
let projectData: IProjectData = this.$injector.resolve("projectData");

lib/commands/deploy.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ export class DeployOnDeviceCommand implements ICommand {
2727
keyStorePassword: this.$options.keyStorePassword,
2828
keyStorePath: this.$options.keyStorePath
2929
};
30-
return this.$platformService.deployPlatform(args[0], appFilesUpdaterOptions, deployOptions, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
30+
return this.$platformService.deployPlatform(args[0], appFilesUpdaterOptions, deployOptions, this.$projectData, this.$options);
3131
}
3232

3333
public async canExecute(args: string[]): Promise<boolean> {

lib/commands/emulate.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ export class EmulateCommandBase {
33
private $projectData: IProjectData,
44
private $logger: ILogger,
55
private $platformService: IPlatformService) {
6-
this.$projectData.initializeProjectData();
7-
}
6+
this.$projectData.initializeProjectData();
7+
}
88

99
public async executeCore(args: string[]): Promise<void> {
1010
this.$logger.warn(`Emulate command is deprecated and will soon be removed. Please use "tns run <platform>" instead. All options available for "tns emulate" are present in "tns run" command. To run on all available emulators, use "tns run <platform> --emulator".`);
@@ -27,7 +27,7 @@ export class EmulateCommandBase {
2727
keyStorePassword: this.$options.keyStorePassword,
2828
keyStorePath: this.$options.keyStorePath
2929
};
30-
return this.$platformService.emulatePlatform(args[0], appFilesUpdaterOptions, emulateOptions, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
30+
return this.$platformService.emulatePlatform(args[0], appFilesUpdaterOptions, emulateOptions, this.$projectData, this.$options.provision);
3131
}
3232
}
3333

lib/commands/install.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ export class InstallCommand implements ICommand {
3131
const frameworkPackageData = this.$projectDataService.getNSValue(this.$projectData.projectDir, platformData.frameworkPackageName);
3232
if (frameworkPackageData && frameworkPackageData.version) {
3333
try {
34-
await this.$platformService.addPlatforms([`${platform}@${frameworkPackageData.version}`], this.$options.platformTemplate, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk }, this.$options.frameworkPath);
34+
await this.$platformService.addPlatforms([`${platform}@${frameworkPackageData.version}`], this.$options.platformTemplate, this.$projectData, this.$options, this.$options.frameworkPath);
3535
} catch (err) {
3636
error = `${error}${EOL}${err}`;
3737
}

lib/commands/platform-clean.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,11 @@ export class CleanCommand implements ICommand {
55
private $projectData: IProjectData,
66
private $platformService: IPlatformService,
77
private $errors: IErrors) {
8-
this.$projectData.initializeProjectData();
9-
}
8+
this.$projectData.initializeProjectData();
9+
}
1010

1111
public async execute(args: string[]): Promise<void> {
12-
await this.$platformService.cleanPlatforms(args, this.$options.platformTemplate, this.$projectData, {provision: this.$options.provision, sdk: this.$options.sdk });
12+
await this.$platformService.cleanPlatforms(args, this.$options.platformTemplate, this.$projectData, this.$options);
1313
}
1414

1515
public async canExecute(args: string[]): Promise<boolean> {

lib/commands/prepare.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,12 @@ export class PrepareCommand implements ICommand {
55
private $platformService: IPlatformService,
66
private $projectData: IProjectData,
77
private $platformCommandParameter: ICommandParameter) {
8-
this.$projectData.initializeProjectData();
9-
}
8+
this.$projectData.initializeProjectData();
9+
}
1010

1111
public async execute(args: string[]): Promise<void> {
1212
const appFilesUpdaterOptions: IAppFilesUpdaterOptions = { bundle: this.$options.bundle, release: this.$options.release };
13-
await this.$platformService.preparePlatform(args[0], appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, { provision: this.$options.provision, sdk: this.$options.sdk });
13+
await this.$platformService.preparePlatform(args[0], appFilesUpdaterOptions, this.$options.platformTemplate, this.$projectData, this.$options);
1414
}
1515

1616
public async canExecute(args: string[]): Promise<boolean> {

0 commit comments

Comments
 (0)