Skip to content

fix: do not require signing when the aab will not be deployed by the CLI #5085

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

Merged
merged 1 commit into from
Oct 18, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 3 additions & 7 deletions lib/commands/build.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { ANDROID_RELEASE_BUILD_ERROR_MESSAGE, AndroidAppBundleMessages, ANDROID_APP_BUNDLE_SIGNING_ERROR_MESSAGE } from "../constants";
import { ANDROID_RELEASE_BUILD_ERROR_MESSAGE, AndroidAppBundleMessages } from "../constants";
import { ValidatePlatformCommandBase } from "./command-base";
import { hasValidAndroidSigning } from "../common/helpers";

Expand Down Expand Up @@ -124,12 +124,8 @@ export class BuildAndroidCommand extends BuildCommandBase implements ICommand {
this.$androidBundleValidatorHelper.validateRuntimeVersion(this.$projectData);
let canExecute = await super.canExecuteCommandBase(platform, { notConfiguredEnvOptions: { hideSyncToPreviewAppOption: true } });
if (canExecute) {
if ((this.$options.release || this.$options.aab) && !hasValidAndroidSigning(this.$options)) {
if (this.$options.release) {
this.$errors.failWithHelp(ANDROID_RELEASE_BUILD_ERROR_MESSAGE);
} else {
this.$errors.failWithHelp(ANDROID_APP_BUNDLE_SIGNING_ERROR_MESSAGE);
}
if (this.$options.release && !hasValidAndroidSigning(this.$options)) {
this.$errors.failWithHelp(ANDROID_RELEASE_BUILD_ERROR_MESSAGE);
}

canExecute = await super.validateArgs(args, platform);
Expand Down