@coalescesoftware/coa 1.0.113 → 1.0.116

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bin/Plan/Plan.js DELETED
@@ -1,41 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
- }) : (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- o[k2] = m[k];
8
- }));
9
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
10
- Object.defineProperty(o, "default", { enumerable: true, value: v });
11
- }) : function(o, v) {
12
- o["default"] = v;
13
- });
14
- var __importStar = (this && this.__importStar) || function (mod) {
15
- if (mod && mod.__esModule) return mod;
16
- var result = {};
17
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
18
- __setModuleDefault(result, mod);
19
- return result;
20
- };
21
- var __importDefault = (this && this.__importDefault) || function (mod) {
22
- return (mod && mod.__esModule) ? mod : { "default": mod };
23
- };
24
- Object.defineProperty(exports, "__esModule", { value: true });
25
- exports.CreatePlan = void 0;
26
- const Shared = __importStar(require("@coalescesoftware/shared"));
27
- const fs_1 = __importDefault(require("fs"));
28
- const CreatePlan = (path, environmentID, token, message) => {
29
- const fsSettings = {
30
- fs: fs_1.default,
31
- dir: path,
32
- };
33
- return Shared.DeployOperations.CreatePlanCLI(environmentID, fsSettings, token, Shared.Templates.PlatformType.snowflake)
34
- .then(result => {
35
- const { plan } = result;
36
- plan.gitInfo = { commit: { message: message }, oid: "" };
37
- return result;
38
- });
39
- };
40
- exports.CreatePlan = CreatePlan;
41
- //# sourceMappingURL=Plan.js.map
@@ -1,65 +0,0 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
- }) : (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- o[k2] = m[k];
8
- }));
9
- var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
10
- Object.defineProperty(o, "default", { enumerable: true, value: v });
11
- }) : function(o, v) {
12
- o["default"] = v;
13
- });
14
- var __importStar = (this && this.__importStar) || function (mod) {
15
- if (mod && mod.__esModule) return mod;
16
- var result = {};
17
- if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
18
- __setModuleDefault(result, mod);
19
- return result;
20
- };
21
- Object.defineProperty(exports, "__esModule", { value: true });
22
- exports.RefreshWithCLI = void 0;
23
- const Shared = __importStar(require("@coalescesoftware/shared"));
24
- const CommonCLI = __importStar(require("../CommonCLI/CommonCLI"));
25
- const CryptoJS = require("crypto-js");
26
- const v8 = require("v8");
27
- Shared.Snowflake.CryptoJS = CryptoJS;
28
- Shared.Snowflake.salt = CryptoJS.lib.WordArray.random(128 / 8);
29
- Shared.Snowflake.v8 = v8;
30
- const LogCLI = Shared.Logging.GetLogger(Shared.Logging.LoggingArea.CLI);
31
- /**
32
- *
33
- * @param token
34
- * @param runInfo
35
- * @returns
36
- */
37
- const RefreshWithCLI = (token, runInfo) => {
38
- let firebase;
39
- let logContext;
40
- let RunSQL, teamDetails;
41
- return Shared.SchedulerOperations.AuthenticateFirebaseTokenAndRetrieveTeamInfoForCLI(token, undefined)
42
- .then((teamInfoAndFirebase) => {
43
- const { teamInfo: { fbUserID: userID, fbTeamID: teamID } } = teamInfoAndFirebase;
44
- firebase = teamInfoAndFirebase.firebase;
45
- const environmentID = runInfo.runDetails.environmentID;
46
- logContext = Shared.Logging.CreateLogContext(teamID, environmentID, userID);
47
- const connectionCache = new Shared.Snowflake.ConnectionStorageClass();
48
- RunSQL = Shared.SQLExecutorCreators.CreateRunSQLWithoutScheduler(teamInfoAndFirebase, connectionCache);
49
- LogCLI.infoContext(logContext, "Starting refresh (CLI)");
50
- return CommonCLI.GetUserConnectionForCLI(userID, runInfo);
51
- })
52
- .then((connection) => {
53
- return Shared.SchedulerOperations.HandleRefresh(runInfo, teamDetails, RunSQL, connection);
54
- })
55
- .then(({ runCounter, runCompletion }) => {
56
- const cleanupPromise = CommonCLI.CleanupCLIJob(runCompletion, firebase, logContext, "Refresh");
57
- return {
58
- runCounter,
59
- runCompletion: cleanupPromise,
60
- logContext,
61
- };
62
- });
63
- };
64
- exports.RefreshWithCLI = RefreshWithCLI;
65
- //# sourceMappingURL=Refresh.js.map