Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

nativescript-cloud

Package Overview
Dependencies
Maintainers
7
Versions
123
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nativescript-cloud - npm Package Compare versions

Comparing version 1.18.2 to 1.19.0

0

docs/accept-eula.md

@@ -0,0 +0,0 @@ # tns accept eula

@@ -0,0 +0,0 @@ # tns account features

@@ -0,0 +0,0 @@ # tns account usage

@@ -0,0 +0,0 @@ # tns account

@@ -0,0 +0,0 @@ # tns cloud build

@@ -0,0 +0,0 @@ # tns cloud clean workspace

@@ -0,0 +0,0 @@ # tns cloud codesign

@@ -0,0 +0,0 @@ # tns cloud deploy

@@ -0,0 +0,0 @@ # tns cloud dev-apple-login

@@ -0,0 +0,0 @@ # tns cloud lib version

@@ -0,0 +0,0 @@ # tns cloud publish android

@@ -0,0 +0,0 @@ # tns cloud publish ios

@@ -0,0 +0,0 @@ # tns cloud run android

@@ -0,0 +0,0 @@ # tns cloud run ios

@@ -0,0 +0,0 @@ # tns cloud run

@@ -0,0 +0,0 @@ # tns dev-login

@@ -0,0 +0,0 @@ # tns login

@@ -0,0 +0,0 @@ # tns logout

@@ -0,0 +0,0 @@ # tns policy accept

@@ -0,0 +0,0 @@ # tns user

1

lib/account-utils.js

@@ -34,1 +34,2 @@ "use strict";

$injector.register("nsAccountUtils", AccountUtils);
//# sourceMappingURL=account-utils.js.map

@@ -20,5 +20,7 @@ "use strict";

$injector.require("nsCloudPlatformsData", path.join(__dirname, "cloud-platforms-data"));
// Cloud operation.
$injector.require("nsCloudOperationFactory", path.join(__dirname, "cloud-operation", "cloud-operation-factory"));
$injector.require("nsCloudCommunicationChannelFactory", path.join(__dirname, "cloud-operation", "communication", "communication-channel-factory"));
$injector.require("nsCloudWebSocketFactory", path.join(__dirname, "cloud-operation", "communication", "websocket-factory"));
// Public API.
$injector.requirePublicClass("nsCloudApplicationService", path.join(__dirname, "services", "application-service"));

@@ -37,3 +39,5 @@ $injector.requirePublicClass("nsCloudAuthenticationService", path.join(__dirname, "services", "authentication-service"));

$injector.requirePublicClass("nsCloudConfigManager", path.join(__dirname, "cloud-config-manager"));
// TODO: Remove in 2.0.0 - currently this service is not used, but it has been publicly exposed, so we cannot remove it without bumping the major version.
$injector.requirePublicClass("nsCloudKinveyEulaService", path.join(__dirname, "services", "kinvey-eula-service"));
// Services.
$injector.require("nsCloudServerAuthService", path.join(__dirname, "services", "server", "server-auth-service"));

@@ -60,2 +64,3 @@ $injector.require("nsCloudServerBuildService", path.join(__dirname, "services", "server", "server-build-service"));

$injector.require("nsCloudPlatformService", path.join(__dirname, "services", "cloud-platform-service"));
// Commands.
$injector.requireCommand("config|*get", path.join(__dirname, "commands", "config", "config-get"));

@@ -85,1 +90,2 @@ $injector.requireCommand("config|apply", path.join(__dirname, "commands", "config", "config-apply"));

$injector.requireCommand("cloud|clean|workspace", path.join(__dirname, "commands", "clean", "clean-cloud-workspace"));
//# sourceMappingURL=bootstrap.js.map

@@ -22,1 +22,2 @@ "use strict";

$injector.register("nsCloudAndroidBundleValidatorHelper", CloudAndroidBundleValidatorHelper);
//# sourceMappingURL=cloud-android-bundle-validator-helper.js.map

@@ -102,1 +102,2 @@ "use strict";

$injector.register("nsCloudBuildHelper", CloudBuildHelper);
//# sourceMappingURL=cloud-build-helper.js.map

@@ -5,2 +5,3 @@ "use strict";

class CloudConfigManager {
/* don't require logger and everything that has logger as dependency in config.js due to cyclic dependency */
constructor($fs, $options) {

@@ -38,5 +39,8 @@ this.$fs = $fs;

const serviceConfig = config.cloudServices[serviceName];
// When we want to use localhost or PR builds for cloud services
// we need to return the specified full domain name.
if (serviceConfig.fullHostName) {
return serviceConfig.fullHostName;
}
// If we want to use the official domains we need the domain name and the subdomain for the service.
return `${serviceConfig.subdomain}.${config.domainName}`;

@@ -92,1 +96,2 @@ }

$injector.register("nsCloudConfigManager", CloudConfigManager);
//# sourceMappingURL=cloud-config-manager.js.map

@@ -69,1 +69,2 @@ "use strict";

exports.CloudOperationBase = CloudOperationBase;
//# sourceMappingURL=cloud-operation-base.js.map

@@ -23,1 +23,2 @@ "use strict";

$injector.register("nsCloudOperationFactory", CloudOperationFactory);
//# sourceMappingURL=cloud-operation-factory.js.map

24

lib/cloud-operation/cloud-operation-v1.js

@@ -63,3 +63,9 @@ "use strict";

this.statusCheckInterval = setInterval(() => __awaiter(this, void 0, void 0, function* () {
this.serverStatus = yield this.$nsCloudS3Helper.getJsonObjectFromS3File(this.serverResponse.statusUrl);
const status = this.serverStatus && this.serverStatus.status;
if (status === CloudOperationV1.OPERATION_IN_PROGRESS_STATUS) {
this.serverStatus = yield this.$nsCloudS3Helper.getJsonObjectFromS3File(this.serverResponse.statusUrl);
}
if (!this.hasLogPollCompleted) {
return;
}
if (this.serverStatus.status === CloudOperationV1.OPERATION_COMPLETE_STATUS) {

@@ -88,8 +94,13 @@ clearInterval(this.statusCheckInterval);

this.logsCheckInterval = setInterval(() => __awaiter(this, void 0, void 0, function* () {
yield this.getCloudOperationLogs();
const status = this.serverStatus.status;
if (status === cloud_operation_base_1.CloudOperationBase.OPERATION_COMPLETE_STATUS || status === cloud_operation_base_1.CloudOperationBase.OPERATION_FAILED_STATUS) {
clearInterval(this.logsCheckInterval);
if (this.snoozeLogPoll) {
return;
}
const hasCompleted = this.serverStatus.status !== cloud_operation_base_1.CloudOperationBase.OPERATION_IN_PROGRESS_STATUS;
if (hasCompleted) {
clearInterval(this.logsCheckInterval);
}
this.snoozeLogPoll = true;
yield this.getCloudOperationLogs();
this.snoozeLogPoll = false;
this.hasLogPollCompleted = hasCompleted;
}), CloudOperationV1.OPERATION_STATUS_CHECK_INTERVAL);

@@ -101,2 +112,3 @@ }

const logs = yield this.$nsCloudS3Helper.getContentOfS3File(this.serverResponse.outputUrl);
// The logs variable will contain the full server log and we need to log only the logs that we don't have.
const contentToLog = this.$nsCloudOutputFilter.filter(logs.substr(this.outputCursorPosition));

@@ -117,2 +129,3 @@ if (contentToLog) {

catch (err) {
// Ignore the error from getting the server output because the task can finish even if there is error.
this.$logger.trace(`Error while getting server logs: ${err}`);

@@ -126,1 +139,2 @@ }

module.exports = CloudOperationV1;
//# sourceMappingURL=cloud-operation-v1.js.map

@@ -58,2 +58,3 @@ "use strict";

this.communicationChannel.once(constants_1.CloudCommunicationEvents.CLOSE, closeHandler);
// Subscribe here for messages to proxy serverHello.
this.communicationChannel.on(constants_1.CloudCommunicationEvents.MESSAGE, (m) => this.emit(constants_1.CloudCommunicationEvents.MESSAGE, m));

@@ -98,1 +99,2 @@ yield this.communicationChannel.connect();

module.exports = CloudOperationV2;
//# sourceMappingURL=cloud-operation-v2.js.map

@@ -164,1 +164,2 @@ "use strict";

exports.CommunicationChannelBase = CommunicationChannelBase;
//# sourceMappingURL=communication-channel-base.js.map

@@ -18,1 +18,2 @@ "use strict";

$injector.register("nsCloudCommunicationChannelFactory", CommunicationChannelFactory);
//# sourceMappingURL=communication-channel-factory.js.map

@@ -84,1 +84,2 @@ "use strict";

exports.WebSocketCommunicationChannel = WebSocketCommunicationChannel;
//# sourceMappingURL=websocket-channel.js.map

@@ -11,1 +11,2 @@ "use strict";

$injector.register("nsCloudWebSocketFactory", WebSocketFactory);
//# sourceMappingURL=websocket-factory.js.map

@@ -7,16 +7,16 @@ "use strict";

return {
accountId: { type: "string", hasSensitiveValue: true },
apiVersion: { type: "string", hasSensitiveValue: false },
local: { type: "boolean", hasSensitiveValue: false },
serverProto: { type: "string", hasSensitiveValue: true },
namespace: { type: "string", hasSensitiveValue: true },
instanceId: { type: "string", hasSensitiveValue: false },
sharedCloud: { type: "boolean", hasSensitiveValue: false },
workflow: { type: "object", hasSensitiveValue: true },
vmTemplateName: { type: "string", hasSensitiveValue: false },
track: { type: "string", default: constants_1.DEFAULT_ANDROID_PUBLISH_TRACK, hasSensitiveValue: false },
appleApplicationSpecificPassword: { type: "string", hasSensitiveValue: true },
appleSessionBase64: { type: "string", hasSensitiveValue: true },
otp: { type: "string", hasSensitiveValue: false },
outputPath: { type: "string", hasSensitiveValue: false }
accountId: { type: "string" /* String */, hasSensitiveValue: true },
apiVersion: { type: "string" /* String */, hasSensitiveValue: false },
local: { type: "boolean" /* Boolean */, hasSensitiveValue: false },
serverProto: { type: "string" /* String */, hasSensitiveValue: true },
namespace: { type: "string" /* String */, hasSensitiveValue: true },
instanceId: { type: "string" /* String */, hasSensitiveValue: false },
sharedCloud: { type: "boolean" /* Boolean */, hasSensitiveValue: false },
workflow: { type: "object" /* Object */, hasSensitiveValue: true },
vmTemplateName: { type: "string" /* String */, hasSensitiveValue: false },
track: { type: "string" /* String */, default: constants_1.DEFAULT_ANDROID_PUBLISH_TRACK, hasSensitiveValue: false },
appleApplicationSpecificPassword: { type: "string" /* String */, hasSensitiveValue: true },
appleSessionBase64: { type: "string" /* String */, hasSensitiveValue: true },
otp: { type: "string" /* String */, hasSensitiveValue: false },
outputPath: { type: "string" /* String */, hasSensitiveValue: false }
};

@@ -27,1 +27,2 @@ }

$injector.register("nsCloudOptionsProvider", CloudOptionsProvider);
//# sourceMappingURL=cloud-options-provider.js.map

@@ -7,7 +7,8 @@ "use strict";

let result = this.filterBpcMetadata(logs)
.replace(new RegExp("(\\\\r\\\\n)|(\\\\n)", "gm"), os_1.EOL)
.replace(/(\\\\t)/g, "\t")
.replace(/((\n)|(\r\n)){1,}/gm, os_1.EOL)
.replace(/\\u001b\[0G/g, "\u001b")
.replace(new RegExp("(\\\\r\\\\n)|(\\\\n)", "gm"), os_1.EOL) // Unescape new lines.
.replace(/(\\\\t)/g, "\t") // Unescape tabs.
.replace(/((\n)|(\r\n)){1,}/gm, os_1.EOL) // Replace consecutive blank lines.
.replace(/\\u001b\[0G/g, "\u001b") // Unescape the escape character.
.trim();
// The logs in S3 have "" around the whole content. We don't need them.
if (result) {

@@ -24,3 +25,3 @@ if (result.startsWith(`"`)) {

filterBpcMetadata(logs) {
return logs.replace(/\[(([0-9]){2,2}:){2,2}[0-9].\.[0-9]*\]\W*?\[.*?\] {0,3}/g, "");
return logs.replace(/\[(([0-9]){2,2}:){2,2}[0-9].\.[0-9]*\]\W*?\[.*?\] {0,3}/g, ""); // Replace the log timestamp and log level.
}

@@ -30,1 +31,2 @@ }

$injector.register("nsCloudOutputFilter", CloudOutputFilter);
//# sourceMappingURL=cloud-output-filter.js.map

@@ -22,1 +22,2 @@ "use strict";

$injector.register("nsCloudPlatformsData", CloudPlatformsData);
//# sourceMappingURL=cloud-platforms-data.js.map

@@ -30,1 +30,2 @@ "use strict";

$injector.registerCommand("accept|eula", AcceptEulaCommand);
//# sourceMappingURL=accept-eula-command.js.map

@@ -26,1 +26,2 @@ "use strict";

exports.AccountCommandBase = AccountCommandBase;
//# sourceMappingURL=account-command-base.js.map

@@ -43,1 +43,2 @@ "use strict";

$injector.registerCommand("account|*list", AccountListCommand);
//# sourceMappingURL=account-list.js.map

@@ -46,1 +46,2 @@ "use strict";

$injector.registerCommand("account|features", FeaturesCommand);
//# sourceMappingURL=features.js.map

@@ -79,1 +79,2 @@ "use strict";

$injector.registerCommand("account|usage", UsageCommand);
//# sourceMappingURL=usage.js.map

@@ -84,3 +84,4 @@ "use strict";

pathToCertificate,
certificatePassword: this.$options.keyStorePassword
certificatePassword: this.$options.keyStorePassword,
aab: this.$options.aab
},

@@ -123,2 +124,3 @@ iOSBuildData: {

if (!helpers_2.isInteractive() && (!credentials.username || !credentials.password)) {
// We are in the CI/CD scenario but we don't have all credentials.
this.$nsCloudErrorsService.fail("Please provide Apple ID and Apple ID password");

@@ -181,1 +183,2 @@ }

$injector.register("nsCloudBuildCommandHelper", BuildCommandHelper);
//# sourceMappingURL=build-command-helper.js.map

@@ -39,2 +39,3 @@ "use strict";

try {
// We want to use the project data only when no parameters are provided.
this.$projectData.initializeProjectData();

@@ -45,2 +46,3 @@ appIdentifier = this.$projectData.projectIdentifiers || this.$projectData.projectId;

catch (err) {
// We are not in project and the app id and project name parameters are not provided.
appIdentifier = yield this.promptForAppId();

@@ -51,2 +53,3 @@ projectName = yield this.promptForProjectName();

else if (args.length === 1) {
// Only app id is provided. We need to ask for project name if we can.
appIdentifier = yield this.getParameterValue(args[0], () => this.promptForAppId());

@@ -56,2 +59,3 @@ projectName = yield this.promptForProjectName();

else {
// Both app id and project name are provided as parameters.
appIdentifier = yield this.getParameterValue(args[0], () => this.promptForAppId());

@@ -91,1 +95,2 @@ projectName = yield this.getParameterValue(args[1], () => this.promptForProjectName());

$injector.registerCommand(["cloud|clean|workspace"], CleanCloudWorkspace);
//# sourceMappingURL=clean-cloud-workspace.js.map

@@ -13,3 +13,3 @@ "use strict";

class CloudBuildCommand extends interactive_cloud_command_1.InteractiveCloudCommand {
constructor($nsCloudProcessService, $nsCloudErrorsService, $logger, $prompter, $nsCloudEulaCommandHelper, $nsCloudBuildCommandHelper, $nsCloudBuildService, $nsCloudOptionsProvider, $options, $projectData, $nsCloudAndroidBundleValidatorHelper) {
constructor($nsCloudProcessService, $nsCloudErrorsService, $logger, $prompter, $nsCloudEulaCommandHelper, $nsCloudBuildCommandHelper, $nsCloudBuildService, $nsCloudOptionsProvider, $options, $projectData) {
super($nsCloudBuildService, $nsCloudProcessService, $nsCloudErrorsService, $logger, $prompter);

@@ -25,3 +25,2 @@ this.$nsCloudErrorsService = $nsCloudErrorsService;

this.$projectData = $projectData;
this.$nsCloudAndroidBundleValidatorHelper = $nsCloudAndroidBundleValidatorHelper;
this.$projectData.initializeProjectData();

@@ -35,3 +34,2 @@ }

yield this.$nsCloudEulaCommandHelper.ensureEulaIsAccepted();
this.$nsCloudAndroidBundleValidatorHelper.validateNoAab();
if (!args || !args.length) {

@@ -55,1 +53,2 @@ this.$nsCloudErrorsService.failWithHelp("Provide platform.");

$injector.registerCommand(["build|cloud", "cloud|build"], CloudBuildCommand);
//# sourceMappingURL=cloud-build.js.map

@@ -27,2 +27,3 @@ "use strict";

this.$nsCloudCodesignService = $nsCloudCodesignService;
// Currently only iOS codesign generation is supported.
this.platform = this.$devicePlatformsConstants.iOS;

@@ -74,1 +75,2 @@ this.$projectData.initializeProjectData();

$injector.registerCommand("codesign|cloud", CloudCodesignCommand);
//# sourceMappingURL=cloud-codesign.js.map

@@ -56,1 +56,2 @@ "use strict";

$injector.registerCommand(["deploy|cloud", "cloud|deploy"], CloudDeploy);
//# sourceMappingURL=cloud-deploy.js.map

@@ -60,1 +60,2 @@ "use strict";

$injector.registerCommand("cloud|dev-apple-login", CloudDevAppleLogin);
//# sourceMappingURL=cloud-dev-apple-login.js.map

@@ -25,1 +25,2 @@ "use strict";

$injector.registerCommand("cloud|lib|version", CloudLibVersion);
//# sourceMappingURL=cloud-lib-version.js.map

@@ -128,1 +128,2 @@ "use strict";

$injector.registerCommand("cloud|publish|ios", CloudPublishIos);
//# sourceMappingURL=cloud-publish.js.map

@@ -88,1 +88,2 @@ "use strict";

$injector.registerCommand(["run|cloud|android", "cloud|run|android"], CloudRunAndroidCommand);
//# sourceMappingURL=cloud-run.js.map

@@ -33,1 +33,2 @@ "use strict";

$injector.registerCommand("config|apply", ConfigApplyCommand);
//# sourceMappingURL=config-apply.js.map

@@ -24,1 +24,2 @@ "use strict";

$injector.registerCommand("config|*get", ConfigGetCommand);
//# sourceMappingURL=config-get.js.map

@@ -26,1 +26,2 @@ "use strict";

$injector.registerCommand("config|reset", ConfigResetCommand);
//# sourceMappingURL=config-reset.js.map

@@ -33,1 +33,2 @@ "use strict";

$injector.registerCommand("config|set", ConfigApplyCommand);
//# sourceMappingURL=config-set.js.map

@@ -45,1 +45,2 @@ "use strict";

$injector.registerCommand("dev-login", DevLoginCommand);
//# sourceMappingURL=dev-login.js.map

@@ -46,1 +46,2 @@ "use strict";

$injector.register("nsCloudEulaCommandHelper", EulaCommandHelper);
//# sourceMappingURL=eula-command-helper.js.map

@@ -35,2 +35,3 @@ "use strict";

else {
// Print one new line because we print the cloud operation output on the same line.
this.$logger.info();

@@ -68,1 +69,2 @@ if (msg.body.inputType === "password") {

exports.InteractiveCloudCommand = InteractiveCloudCommand;
//# sourceMappingURL=interactive-cloud-command.js.map

@@ -37,1 +37,2 @@ "use strict";

$injector.registerCommand("login", LoginCommand);
//# sourceMappingURL=login.js.map

@@ -26,1 +26,2 @@ "use strict";

$injector.registerCommand("logout", LogoutCommand);
//# sourceMappingURL=logout.js.map

@@ -41,1 +41,2 @@ "use strict";

$injector.registerCommand("policy|accept", PolicyAcceptCommand);
//# sourceMappingURL=policy-accept-command.js.map

@@ -36,1 +36,2 @@ "use strict";

$injector.registerCommand("user", UserCommand);
//# sourceMappingURL=user.js.map

@@ -147,1 +147,2 @@ "use strict";

exports.CloudCommunicationChannelExitCodes = CloudCommunicationChannelExitCodes;
//# sourceMappingURL=constants.js.map
"use strict";
//# sourceMappingURL=cloud-output-filter.js.map

@@ -53,1 +53,2 @@ "use strict";

exports.getProjectId = getProjectId;
//# sourceMappingURL=helpers.js.map

@@ -62,1 +62,2 @@ "use strict";

$injector.register("nsCloudHttpServer", HttpServer);
//# sourceMappingURL=http-server.js.map

@@ -39,1 +39,2 @@ "use strict";

$injector.register("nsCloudItmsServicesPlistHelper", ItmsServicesPlistHelper);
//# sourceMappingURL=itms-services-plist-helper.js.map

@@ -28,1 +28,2 @@ "use strict";

$injector.register("nsCloudS3Helper", S3Helper);
//# sourceMappingURL=s3-helper.js.map

@@ -61,1 +61,2 @@ "use strict";

$injector.register("nsCloudAccountsService", AccountsService);
//# sourceMappingURL=accounts-service.js.map

@@ -56,1 +56,2 @@ "use strict";

$injector.register("nsCloudApplicationService", ApplicationService);
//# sourceMappingURL=application-service.js.map

@@ -34,2 +34,3 @@ "use strict";

}
// Start the localhost server to wait for the login response.
let timeoutID = undefined;

@@ -151,2 +152,3 @@ let authCompleteResolveAction;

yield this.refreshCurrentUserToken();
// We don't want to check the state of the new access token because it will be valid.
return true;

@@ -177,1 +179,2 @@ }

$injector.register("nsCloudAuthenticationService", AuthenticationService);
//# sourceMappingURL=authentication-service.js.map

@@ -41,1 +41,2 @@ "use strict";

$injector.register("nsCloudAppleService", CloudAppleService);
//# sourceMappingURL=cloud-apple-service.js.map

@@ -152,1 +152,2 @@ "use strict";

$injector.register("nsCloudBuildPropertiesService", CloudBuildPropertiesService);
//# sourceMappingURL=cloud-build-properties-service.js.map

@@ -52,2 +52,5 @@ "use strict";

}
/**
* Here only for backwards compatibility. Deleting this will require a major version change as it is used in NativeScript Sidekick.
*/
getBuildOutputDirectory(options) {

@@ -115,2 +118,5 @@ return this.getServerOperationOutputDirectory(options);

}
if (androidBuildData && androidBuildData.aab) {
additionalCliFlags.push("--aab");
}
if (projectSettings.env) {

@@ -145,2 +151,3 @@ const envOptions = _.map(projectSettings.env, (value, key) => `--env.${key}=${value}`);

if (!buildResult.buildItems || !buildResult.buildItems.length) {
// Something failed.
this.$nsCloudErrorsService.fail(`Build failed. Reason is: ${buildResult.errors}. Additional information: ${buildResult.stderr}.`);

@@ -152,3 +159,4 @@ }

platform,
emulator: iOSBuildData && !iOSBuildData.buildForDevice
emulator: iOSBuildData && !iOSBuildData.buildForDevice,
extension: androidBuildData && androidBuildData.aab ? "aab" : null
});

@@ -173,2 +181,5 @@ this.$logger.info(`The result of ${buildInformationString} successfully downloaded. OutputFilePath: ${localBuildResult}`);

};
// In case HMR is passed, do not save the hashes as the files generated in the cloud may differ from the local ones.
// We need to get the hashes from the cloud build, so until we have it, it is safer to execute fullSync after build.
// This way we'll be sure HMR is working with cloud builds as it will rely on the local files.
const platformData = this.$nsCloudPlatformsData.getPlatformData(platform, this.$projectDataService.getProjectData(projectSettings.projectDir));

@@ -208,2 +219,4 @@ if (this.$filesHashService.saveHashesForProject && !projectSettings.useHotModuleReload) {

this.emitStepChanged(cloudOperationId, constants.BUILD_STEP_NAME.PREPARE, constants.BUILD_STEP_PROGRESS.START);
// HACK: Ensure __PACKAGE__ is interpolated in app.gradle file in the user project.
// In case we don't interpolate every other cloud android build is bound to fail because it would set the application's identifier to __PACKAGE__
const userAppGradleFilePath = path.join(projectData.appResourcesDirectoryPath, this.$devicePlatformsConstants.Android, "app.gradle");

@@ -259,2 +272,7 @@ if (this.$fs.exists(userAppGradleFilePath)) {

};
/** Although the nativescript-cloud is an extension that is used only with nativescript projects,
* current implementation of the builder daemon will not add default framework. This breaks tooling when incremental build is
* performed. Passing the framework=tns here is more consistent that adding conditional
* behavior in the tooling.
*/
const result = {

@@ -292,2 +310,3 @@ cloudOperationId: settings.cloudOperationId,

getBuildResultUrl(buildResult) {
// We expect only one buildResult - .ipa, .apk ...
return this.getServerResults(buildResult)[0].fullPath;

@@ -335,1 +354,2 @@ }

$injector.register("nsCloudBuildService", CloudBuildService);
//# sourceMappingURL=cloud-build-service.js.map

@@ -70,2 +70,3 @@ "use strict";

if (!codesignResult.buildItems || !codesignResult.buildItems.length) {
// Something failed.
let errText = codesignResult.errors || "";

@@ -115,1 +116,2 @@ if (errText.indexOf("403 Forbidden") > -1) {

$injector.register("nsCloudCodesignService", CloudCodesignService);
//# sourceMappingURL=cloud-codesign-service.js.map

@@ -26,1 +26,2 @@ "use strict";

$injector.register("nsCloudConfigurationService", CloudConfigurationService);
//# sourceMappingURL=cloud-configuration-service.js.map

@@ -51,1 +51,2 @@ "use strict";

$injector.register("nsCloudEncryptionService", CloudEncryptionService);
//# sourceMappingURL=cloud-encryption-service.js.map

@@ -64,2 +64,3 @@ "use strict";

}
// TODO: Remove Promise, reason: writeFile - blocked as other implementation of the interface has async operation.
loadUserSettingsFile() {

@@ -77,2 +78,4 @@ return __awaiter(this, void 0, void 0, function* () {

this.$fs.writeFile(this.userSettingsFilePath, null);
// when running under 'sudo' we create the <path to home dir>/.local/share/.nativescript-cli dir with root as owner
// and other Applications cannot access this directory anymore. (bower/heroku/etc)
if (process.env.SUDO_USER) {

@@ -97,2 +100,3 @@ for (const dir of unexistingDirs) {

while (true) {
// this directory won't be created.
if (this.$fs.exists(currentDir)) {

@@ -109,1 +113,2 @@ break;

$injector.register("nsCloudEncryptionSettingsService", EncryptionSettingsService);
//# sourceMappingURL=cloud-encryption-settings-service.js.map

@@ -116,1 +116,2 @@ "use strict";

$injector.register("nsCloudPlatformService", CloudPlatformService);
//# sourceMappingURL=cloud-platform-service.js.map

@@ -121,1 +121,2 @@ "use strict";

$injector.register("nsCloudProjectService", CloudProjectService);
//# sourceMappingURL=cloud-project-service.js.map

@@ -127,2 +127,3 @@ "use strict";

}
// Taken from: https://github.com/fastlane/fastlane/blob/master/fastlane_core/lib/fastlane_core/itunes_transporter.rb#L100
CloudPublishService.ITMS_ERROR_REGEX = /\[Transporter Error Output\]:.*/g;

@@ -132,1 +133,2 @@ CloudPublishService.GENERAL_ERROR_REGEX = /\[!\].*/g;

$injector.register("nsCloudPublishService", CloudPublishService);
//# sourceMappingURL=cloud-publish-service.js.map

@@ -110,5 +110,5 @@ "use strict";

}
downloadServerResults(serverResult, serverOutputOptions) {
downloadServerResults(serverResult, outputOptions) {
return __awaiter(this, void 0, void 0, function* () {
const destinationDir = this.getServerOperationOutputDirectory(serverOutputOptions);
const destinationDir = this.getServerOperationOutputDirectory(outputOptions);
this.$fs.ensureDirectoryExists(destinationDir);

@@ -119,5 +119,10 @@ const serverResultObjs = this.getServerResults(serverResult);

this.$logger.info(`Result url: ${serverResultObj.fullPath}`);
const targetFileName = path.join(destinationDir, serverResultObj.filename);
let filename = serverResultObj.filename;
if (outputOptions.extension) {
filename = `${path.parse(filename).name}.${outputOptions.extension}`;
}
const targetFileName = path.join(destinationDir, filename);
targetFileNames.push(targetFileName);
const targetFile = this.$fs.createWriteStream(targetFileName);
// Download the output file.
yield this.$httpClient.httpRequest({

@@ -161,3 +166,6 @@ url: serverResultObj.fullPath,

const logger = this.$logger;
// Print the output on the same line to have cool effects like loading indicators.
// The cloud process will take care of the new lines.
if (logger.printInfoMessageOnSameLine) {
// Used in CLI before 6.0.0
logger.printInfoMessageOnSameLine(msg);

@@ -172,1 +180,2 @@ }

exports.CloudService = CloudService;
//# sourceMappingURL=cloud-service.js.map

@@ -75,1 +75,2 @@ "use strict";

$injector.register("nsCloudServicesPolicyService", CloudServicesPolicyService);
//# sourceMappingURL=cloud-services-policy-service.js.map

@@ -38,1 +38,2 @@ "use strict";

$injector.register("nsCloudErrorsService", ErrorsService);
//# sourceMappingURL=errors-service.js.map

@@ -25,5 +25,7 @@ "use strict";

}
// Exposed for Sidekick
getEulaData() {
return this.getEulaDataWithCache();
}
// CLI always uses this one
getEulaDataWithCache() {

@@ -60,2 +62,4 @@ return __awaiter(this, void 0, void 0, function* () {

}
// At this point we should have already downloaded the EULA, so just get the info for local file.
// If it does not exist - we were unable to download it.
const currentEulaHash = yield this.getLocalEulaHash();

@@ -123,2 +127,4 @@ if (!currentEulaHash) {

getLockOptions() {
// We'll retry 100 times and time between retries is 100ms, i.e. full wait in case we are unable to get lock will be 10 seconds.
// In case lock is older than 13 seconds, consider it stale and try to get a new lock.
return {

@@ -151,1 +157,2 @@ retryWait: 100,

exports.EulaServiceBase = EulaServiceBase;
//# sourceMappingURL=eula-service-base.js.map

@@ -21,1 +21,2 @@ "use strict";

$injector.register("nsCloudEulaService", EulaService);
//# sourceMappingURL=eula-service.js.map

@@ -47,2 +47,3 @@ "use strict";

this.$logger.trace("Setting core.autocrlf to false");
// Commit line ending as is, do not allow git to change them.
yield this.executeCommand(projectSettings, ["config", "--local", "core.autocrlf", "false"]);

@@ -89,2 +90,7 @@ }

const gitMinorVersion = ~~match[2];
// After version 2.9.x git prompt for credential with Windows Credential Manager first then query over the rest of the credential managers.
// If credential.helper is configured to the empty string,
// this resets the helper list to empty (so you may override a helper set by a lower-priority config file by configuring the empty-string helper,
// followed by whatever set of helpers you would like).
// https://git-scm.com/docs/gitcredentials
if (this.$hostInfo.isWindows) {

@@ -236,4 +242,10 @@ if (gitMajorVersion === GitService.MINIMAL_GIT_MAJOR_VERSION &&

GitService.MINIMAL_GIT_MINOR_VERSION = 9;
/**
* Used when we want to force creation of new local repository after release of nativescript-cloud package.
* Just increment this version and new local repositories will be created for each project.
* Required for cases where we want to change some git settings in the repo and ensure they are pushed in the cloud.
*/
GitService.GIT_REPO_VERSION = "v1";
exports.GitService = GitService;
$injector.register("nsCloudGitService", GitService);
//# sourceMappingURL=git-service.js.map

@@ -30,1 +30,2 @@ "use strict";

$injector.register("nsCloudHashService", HashService);
//# sourceMappingURL=hash-service.js.map

@@ -5,2 +5,3 @@ "use strict";

const eula_service_base_1 = require("./eula-service-base");
// TODO: Remove in 2.0.0 - currently this service is not used, but it has been publicly exposed, so we cannot remove it without bumping the major version.
class KinveyEulaService extends eula_service_base_1.EulaServiceBase {

@@ -22,1 +23,2 @@ constructor($fs, $httpClient, $nsCloudLockService, $logger, $nsCloudHashService, $settingsService, $userSettingsService) {

$injector.register("nsCloudKinveyEulaService", KinveyEulaService);
//# sourceMappingURL=kinvey-eula-service.js.map

@@ -46,5 +46,8 @@ "use strict";

updateAuthService(input) {
// The Kinvey api does not accept {} for customized login.
if (_.isEmpty(input.authService.customizedLogin)) {
delete input.authService.customizedLogin;
}
// The Kinvey api does not accept null for provider.authentication.
// The api docs say it should accept null but...
if (_.isEmpty(input.authService.provider.authentication)) {

@@ -77,2 +80,4 @@ delete input.authService.provider.authentication;

catch (err) {
// Currently there is bug in the Kinvey backend - after the default auth service for an environment is
// deleted, the defaultAuthServiceId property is not changed. That's why we need to handle the error and return null.
if (err && err.response && err.response.statusCode === 404) {

@@ -141,1 +146,2 @@ return null;

$injector.register("nsCloudKinveyService", KinveyService);
//# sourceMappingURL=kinvey-service.js.map

@@ -42,1 +42,2 @@ "use strict";

$injector.register("nsCloudKinveyUserService", KinveyUserService);
//# sourceMappingURL=kinvey-user-service.js.map

@@ -11,2 +11,4 @@ "use strict";

Object.defineProperty(exports, "__esModule", { value: true });
// This service is here only for backwards compatibility.
// We can delete it when we require at least {N} CLI 5.4.0.
class NsCouldLockService {

@@ -49,1 +51,2 @@ constructor($injector) {

$injector.register("nsCloudLockService", NsCouldLockService);
//# sourceMappingURL=lock-service.js.map

@@ -18,1 +18,2 @@ "use strict";

$injector.register("nsCloudPackageInfoService", PackageInfoService);
//# sourceMappingURL=package-info-service.js.map

@@ -91,1 +91,2 @@ "use strict";

$injector.register("nsCloudPolicyService", PolicyService);
//# sourceMappingURL=policy-service.js.map

@@ -20,1 +20,2 @@ "use strict";

$injector.register("nsCloudPolyfillService", PolyfillService);
//# sourceMappingURL=polyfill-service.js.map
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
// TODO: Delete this once we do not support NativeScript CLI below 5.4.0
class CloudProcessService {

@@ -25,1 +26,2 @@ constructor($nsCloudPolyfillService) {

$injector.register("nsCloudProcessService", CloudProcessService);
//# sourceMappingURL=process-service.js.map

@@ -61,2 +61,3 @@ "use strict";

return __awaiter(this, void 0, void 0, function* () {
// Intentionally left blank - no need to accept Kinvey EULA.
});

@@ -67,1 +68,2 @@ }

$injector.register("nsCloudKinveyRequestService", KinveyRequestService);
//# sourceMappingURL=kinvey-request-service.js.map

@@ -23,1 +23,2 @@ "use strict";

$injector.register("nsCloudMBaasProxy", MBaasProxy);
//# sourceMappingURL=mbaas-proxy.js.map

@@ -15,1 +15,2 @@ "use strict";

$injector.register("nsCloudMBaasRequestService", MBaasRequestService);
//# sourceMappingURL=mbaas-request-service.js.map

@@ -29,1 +29,2 @@ "use strict";

$injector.register("nsCloudServerAccountsService", ServerAccountsService);
//# sourceMappingURL=server-accounts-service.js.map

@@ -44,1 +44,2 @@ "use strict";

$injector.register("nsCloudServerAuthService", ServerAuthService);
//# sourceMappingURL=server-auth-service.js.map

@@ -33,1 +33,2 @@ "use strict";

$injector.register("nsCloudServerBuildService", ServerBuildService);
//# sourceMappingURL=server-build-service.js.map

@@ -17,1 +17,2 @@ "use strict";

$injector.register("nsCloudServerProjectService", ServerProjectService);
//# sourceMappingURL=server-project-service.js.map

@@ -21,5 +21,7 @@ "use strict";

try {
// Try to send the request.
return yield this.proxyService.call(options);
}
catch (requestError) {
// If the server returns 401 we must try to get new access token using the refresh token and retry the request.
if (requestError.response && requestError.response.statusCode === constants_1.HTTP_STATUS_CODES.UNAUTHORIZED) {

@@ -51,1 +53,2 @@ this.$logger.trace("Access token expired. Trying to issue a new one.");

$injector.register("nsCloudServerRequestService", ServerRequestService);
//# sourceMappingURL=server-request-service.js.map

@@ -61,1 +61,2 @@ "use strict";

exports.ServerServiceBase = ServerServiceBase;
//# sourceMappingURL=server-service-base.js.map

@@ -86,2 +86,3 @@ "use strict";

let result;
// When we use localhost we don't have api version and we use the url path as is.
if (!apiVersion) {

@@ -91,2 +92,3 @@ result = urlPath;

else {
// In case we use PR build or the official services we must prepend the api version to the url path.
result = `${apiVersion}/${urlPath}`;

@@ -105,1 +107,2 @@ }

$injector.register("nsCloudServerServicesProxy", ServerServicesProxy);
//# sourceMappingURL=server-services-proxy.js.map

@@ -18,1 +18,2 @@ "use strict";

$injector.register("nsCloudTelerikUserService", TelerikUserService);
//# sourceMappingURL=telerik-user-service.js.map

@@ -40,2 +40,3 @@ "use strict";

requestOpts.headers = requestOpts.headers || {};
// It is vital we set this, else the http request comes out as chunked and S3 doesn't support chunked requests
requestOpts.headers["Content-Length"] = requestOpts.body.length;

@@ -54,1 +55,2 @@ try {

$injector.register("nsCloudUploadService", UploadService);
//# sourceMappingURL=upload-service.js.map

@@ -75,1 +75,2 @@ "use strict";

exports.UserServiceBase = UserServiceBase;
//# sourceMappingURL=user-service-base.js.map

@@ -51,1 +51,2 @@ "use strict";

$injector.register("nsCloudUserService", UserService);
//# sourceMappingURL=user-service.js.map

@@ -87,2 +87,3 @@ "use strict";

const prerelease = semver.prerelease(versionRangeOptions.versionString);
// Append -0 if dealing with a prerelease in order to get the latest prerelease available
const prereleaseString = prerelease ? "-0" : "";

@@ -97,1 +98,2 @@ const major = semver.major(versionRangeOptions.versionString);

$injector.register("nsCloudVersionService", VersionService);
//# sourceMappingURL=version-service.js.map

@@ -0,0 +0,0 @@ =========================================================================

{
"name": "nativescript-cloud",
"version": "1.18.2",
"version": "1.19.0",
"description": "Used for cloud support in NativeScript CLI",

@@ -109,2 +109,2 @@ "main": "lib/bootstrap.js",

}
}
}

@@ -0,0 +0,0 @@ # nativescript-cloud

Allow cloud build usage according to your NativeScript Sidekick subscription plan.

@@ -0,0 +0,0 @@ {

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc