@salesforce/packaging 0.0.34 → 0.0.35

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/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [0.0.35](https://github.com/forcedotcom/packaging/compare/v0.0.34...v0.0.35) (2022-09-09)
6
+
7
+ ### Bug Fixes
8
+
9
+ - apply fixes from qa issues ([2949f18](https://github.com/forcedotcom/packaging/commit/2949f1875da2e953977769cd1a8b4d8131fbdc1a))
10
+
5
11
  ### [0.0.34](https://github.com/forcedotcom/packaging/compare/v0.0.33...v0.0.34) (2022-09-08)
6
12
 
7
13
  ### Bug Fixes
@@ -34,6 +34,11 @@ const SELECT_PACKAGE_CONTAINER_OPTIONS = 'SELECT ContainerOptions FROM Package2
34
34
  const SELECT_PACKAGE_VERSION_CONTAINER_OPTIONS = 'SELECT Package2ContainerOptions FROM SubscriberPackageVersion';
35
35
  // Add this to query calls to only show released package versions in the output
36
36
  const releasedOnlyFilter = ' AND IsReleased = true';
37
+ const sortAncestryNodeData = (a, b) => {
38
+ const aVersion = new versionNumber_1.VersionNumber(a.options.node.MajorVersion, a.options.node.MinorVersion, a.options.node.PatchVersion, a.options.node.BuildNumber);
39
+ const bVersion = new versionNumber_1.VersionNumber(b.options.node.MajorVersion, b.options.node.MinorVersion, b.options.node.PatchVersion, b.options.node.BuildNumber);
40
+ return aVersion.compareTo(bVersion);
41
+ };
37
42
  /**
38
43
  * A class that represents the package ancestry graph.
39
44
  */
@@ -310,11 +315,7 @@ class AncestryJsonProducer {
310
315
  producers.push(this);
311
316
  while (producers.length > 0) {
312
317
  const producer = producers.shift();
313
- producer.data.children.sort((a, b) => {
314
- const aVersion = new versionNumber_1.VersionNumber(a.data.MajorVersion, a.data.MinorVersion, a.data.PatchVersion, a.data.BuildNumber);
315
- const bVersion = new versionNumber_1.VersionNumber(b.data.MajorVersion, b.data.MinorVersion, b.data.PatchVersion, b.data.BuildNumber);
316
- return aVersion.compareTo(bVersion);
317
- });
318
+ producer.children.sort(sortAncestryNodeData);
318
319
  producers.push(...producer.children);
319
320
  }
320
321
  return this.data.children[0];
@@ -356,6 +357,7 @@ class AncestryDotProducer {
356
357
  if (producer.options) {
357
358
  dotLines.push(AncestryDotProducer.buildDotNode(producer));
358
359
  }
360
+ producer.children.sort(sortAncestryNodeData);
359
361
  producers.push(...producer.children);
360
362
  }
361
363
  producers.push(this);
@@ -14,8 +14,7 @@ const xmldom_1 = require("@xmldom/xmldom");
14
14
  const core_1 = require("@salesforce/core");
15
15
  const kit_1 = require("@salesforce/kit");
16
16
  core_1.Messages.importMessagesDirectory(__dirname);
17
- // TODO: need to transfer these messages
18
- const profileApiMessages = core_1.Messages.loadMessages('@salesforce/packaging', 'messages');
17
+ const profileApiMessages = core_1.Messages.loadMessages('@salesforce/packaging', 'profile-api');
19
18
  /*
20
19
  * This class provides functions used to re-write .profiles in the workspace when creating a package2 version.
21
20
  * All profiles found in the workspaces are extracted out and then re-written to only include metadata in the profile
@@ -256,22 +255,22 @@ class ProfileInformation {
256
255
  this.settingsRemoved.push(setting);
257
256
  }
258
257
  logDebug() {
259
- let info = profileApiMessages.getMessage('profile_api.addProfileToPackage', [this.ProfileName, this.ProfilePath]);
258
+ let info = profileApiMessages.getMessage('addProfileToPackage', [this.ProfileName, this.ProfilePath]);
260
259
  this.settingsRemoved.forEach((setting) => {
261
- info += '\n\t' + profileApiMessages.getMessage('profile_api.removeProfileSetting', [setting, this.ProfileName]);
260
+ info += '\n\t' + profileApiMessages.getMessage('removeProfileSetting', [setting, this.ProfileName]);
262
261
  });
263
262
  if (!this.IsPackaged) {
264
- info += '\n\t' + profileApiMessages.getMessage('profile_api.removeProfile', [this.ProfileName]);
263
+ info += '\n\t' + profileApiMessages.getMessage('removeProfile', [this.ProfileName]);
265
264
  }
266
265
  info += '\n';
267
266
  return info;
268
267
  }
269
268
  logInfo() {
270
269
  if (this.IsPackaged) {
271
- return profileApiMessages.getMessage('profile_api.addProfileToPackage', [this.ProfileName, this.ProfilePath]);
270
+ return profileApiMessages.getMessage('addProfileToPackage', [this.ProfileName, this.ProfilePath]);
272
271
  }
273
272
  else {
274
- return profileApiMessages.getMessage('profile_api.profileNotIncluded', [this.ProfileName]);
273
+ return profileApiMessages.getMessage('profileNotIncluded', [this.ProfileName]);
275
274
  }
276
275
  }
277
276
  }
@@ -267,3 +267,19 @@ No subscriber package was found for seed id: %s'
267
267
  # idOrAliasNotFound
268
268
 
269
269
  Can't find package with id or alias: %s
270
+
271
+ # unlockedPackageError
272
+
273
+ Can’t display package ancestry. Package ancestry is available only for second-generation managed packages. Retry this command and specify a second-generation managed package or package version.
274
+
275
+ # noVersionsError
276
+
277
+ Can’t display package ancestry. The specified package has no associated released package versions. Retry this command after you create and promote at least one package version.
278
+
279
+ # invalidId
280
+
281
+ Can’t display the ancestry tree for %s. Specify a valid package ID (starts with 0Ho) or package version ID (starts with 04t), and try creating the ancestry tree again.
282
+
283
+ # versionNotFound
284
+
285
+ Can’t display the ancestry tree for %s. Verify the package version number (starts with 04t) or the package version alias listed in the sfdx-project.json file, and try creating the ancestry tree again.
@@ -69,3 +69,7 @@ release notes URL
69
69
  # postInstallUrl
70
70
 
71
71
  post-install URL
72
+
73
+ # malformedUrl
74
+
75
+ The %s value "%s" from the command line or sfdx-project.json is not in the correct format for a URL. It must be a valid URL in the format "http://salesforce.com". More information: https://nodejs.org/api/url.html#url_url_strings_and_url_objects
@@ -0,0 +1,15 @@
1
+ # addProfileToPackage
2
+
3
+ The profile "%s" from the "%s" directory was added to this package version.
4
+
5
+ # removeProfileSetting
6
+
7
+ The "%s" profile setting was removed from the "%s" profile.
8
+
9
+ # removeProfile
10
+
11
+ The "%s" profile has been removed from the package because its settings don't correspond with anything in the package version.
12
+
13
+ # profileNotIncluded
14
+
15
+ The "%s" profile was not added to the package because its settings don't correspond to anything in the package version."
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/packaging",
3
- "version": "0.0.34",
3
+ "version": "0.0.35",
4
4
  "description": "packing libraries to Salesforce packaging platform",
5
5
  "main": "lib/exported",
6
6
  "types": "lib/exported.d.ts",