@salesforce/plugin-deploy-retrieve 3.13.1 → 3.13.2-beta.1

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/package.json CHANGED
@@ -1,11 +1,12 @@
1
1
  {
2
2
  "name": "@salesforce/plugin-deploy-retrieve",
3
3
  "description": "deploy and retrieve commands for sf",
4
- "version": "3.13.1",
4
+ "version": "3.13.2-beta.1",
5
5
  "author": "Salesforce",
6
6
  "bugs": "https://github.com/forcedotcom/cli/issues",
7
7
  "dependencies": {
8
8
  "@oclif/core": "^4.0.28",
9
+ "@oclif/multi-stage-output": "^0.7.7",
9
10
  "@salesforce/apex-node": "^8.1.9",
10
11
  "@salesforce/core": "^8.6.1",
11
12
  "@salesforce/kit": "^3.2.3",
@@ -14,7 +15,8 @@
14
15
  "@salesforce/source-deploy-retrieve": "^12.7.4",
15
16
  "@salesforce/source-tracking": "^7.1.16",
16
17
  "@salesforce/ts-types": "^2.0.12",
17
- "ansis": "^3.3.2"
18
+ "ansis": "^3.3.2",
19
+ "terminal-link": "^3.0.0"
18
20
  },
19
21
  "devDependencies": {
20
22
  "@oclif/plugin-command-snapshot": "^5.2.17",
@@ -250,7 +252,7 @@
250
252
  "exports": "./lib/index.js",
251
253
  "type": "module",
252
254
  "sfdx": {
253
- "publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-deploy-retrieve/3.13.1.crt",
254
- "signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-deploy-retrieve/3.13.1.sig"
255
+ "publicKeyUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-deploy-retrieve/3.13.2-beta.1.crt",
256
+ "signatureUrl": "https://developer.salesforce.com/media/salesforce-cli/security/@salesforce/plugin-deploy-retrieve/3.13.2-beta.1.sig"
255
257
  }
256
258
  }
@@ -1,11 +0,0 @@
1
- import { MetadataApiDeploy } from '@salesforce/source-deploy-retrieve';
2
- import { Progress } from '@salesforce/sf-plugins-core';
3
- export declare class DeployProgress extends Progress {
4
- private deploy;
5
- private static OPTIONS;
6
- private lifecycle;
7
- constructor(deploy: MetadataApiDeploy, jsonEnabled?: boolean);
8
- start(): void;
9
- private updateTrackingProgress;
10
- private updateProgress;
11
- }
@@ -1,80 +0,0 @@
1
- /*
2
- * Copyright (c) 2022, salesforce.com, inc.
3
- * All rights reserved.
4
- * Licensed under the BSD 3-Clause license.
5
- * For full license text, see LICENSE.txt file in the repo root or https://opensource.org/licenses/BSD-3-Clause
6
- */
7
- import { envVars as env, EnvironmentVariable, Lifecycle, Messages, Logger } from '@salesforce/core';
8
- import { Progress } from '@salesforce/sf-plugins-core';
9
- Messages.importMessagesDirectoryFromMetaUrl(import.meta.url);
10
- const mdTransferMessages = Messages.loadMessages('@salesforce/plugin-deploy-retrieve', 'metadata.transfer');
11
- const showBar = Boolean(process.env.TERM !== 'dumb' && process.stdin.isTTY && env.getBoolean(EnvironmentVariable.SF_USE_PROGRESS_BAR, true));
12
- const logger = await Logger.child('deploy-progress');
13
- export class DeployProgress extends Progress {
14
- deploy;
15
- static OPTIONS = {
16
- title: 'Status',
17
- format: `%s: {status} ${showBar ? '| {bar} ' : ''}| {value}/{total} Components{errorInfo}{testInfo}{trackingInfo}`,
18
- barCompleteChar: '\u2588',
19
- barIncompleteChar: '\u2591',
20
- linewrap: true,
21
- // people really like to get text output in CI systems
22
- // they won't get the "bar" but will get the remaining template bits this way
23
- noTTYOutput: true,
24
- };
25
- lifecycle = Lifecycle.getInstance();
26
- constructor(deploy, jsonEnabled = false) {
27
- super(!jsonEnabled);
28
- this.deploy = deploy;
29
- }
30
- start() {
31
- super.start(0, { status: 'Waiting', trackingInfo: '', testInfo: '' }, DeployProgress.OPTIONS);
32
- // for sourceMember polling events
33
- this.lifecycle.on('sourceMemberPollingEvent', (event) => Promise.resolve(this.updateTrackingProgress(event)));
34
- this.deploy.onUpdate((data) => this.updateProgress(data));
35
- // any thing else should make one final update, then stop the progress bar
36
- this.deploy.onFinish((data) => {
37
- this.updateProgress(data.response);
38
- this.finish({ status: mdTransferMessages.getMessage(data.response.status) });
39
- });
40
- this.deploy.onCancel(() => this.stop());
41
- this.deploy.onError((error) => {
42
- this.stop();
43
- throw error;
44
- });
45
- }
46
- updateTrackingProgress(data) {
47
- const { remaining, original } = data;
48
- this.update(0, {
49
- status: 'Polling SourceMembers',
50
- trackingInfo: ` | Tracking: ${original - remaining}/${original}`,
51
- });
52
- }
53
- updateProgress(data) {
54
- // the numCompTot. isn't computed right away, wait to start until we know how many we have
55
- const testInfo = data.numberTestsTotal
56
- ? ` | ${data.numberTestsCompleted ?? 0}/${data.numberTestsTotal ?? 0} Tests${data.numberTestErrors ? `(Errors:${data.numberTestErrors})` : ''}`
57
- : '';
58
- const errorInfo = data.numberComponentErrors > 0 ? ` | Errors: ${data.numberComponentErrors}` : '';
59
- if (data.numberComponentsTotal) {
60
- this.setTotal(data.numberComponentsTotal);
61
- this.update(data.numberComponentsDeployed, {
62
- errorInfo: data.numberComponentErrors > 0 ? ` | Errors: ${data.numberComponentErrors}` : '',
63
- status: mdTransferMessages.getMessage(data.status),
64
- testInfo,
65
- });
66
- }
67
- else {
68
- let status;
69
- try {
70
- status = mdTransferMessages.getMessage(data.status);
71
- }
72
- catch (e) {
73
- logger.debug(`data.status message lookup failed for: ${data.status}`);
74
- status = 'Waiting';
75
- }
76
- this.update(0, { errorInfo, testInfo, status });
77
- }
78
- }
79
- }
80
- //# sourceMappingURL=progressBar.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"progressBar.js","sourceRoot":"","sources":["../../src/utils/progressBar.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,OAAO,IAAI,GAAG,EAAE,mBAAmB,EAAE,SAAS,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAEpG,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAGvD,QAAQ,CAAC,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