@salesforce/core-bundle 8.2.9 → 8.4.0

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/lib/index.d.ts CHANGED
@@ -4556,6 +4556,8 @@ declare module '@salesforce/core-bundle/sfProject' {
4556
4556
  static getFileName(): string;
4557
4557
  static getDefaultOptions(isGlobal?: boolean): ConfigFile.Options;
4558
4558
  read(): Promise<ProjectJson>;
4559
+ /** force a reread of the project contents if you know they may have been modified */
4560
+ refreshSync(): SfProjectJson;
4559
4561
  readSync(): ProjectJson;
4560
4562
  write(): Promise<ProjectJson>;
4561
4563
  writeSync(): ProjectJson;
@@ -4665,6 +4667,12 @@ declare module '@salesforce/core-bundle/sfProject' {
4665
4667
  * @ignore
4666
4668
  */
4667
4669
  protected constructor(path: string);
4670
+ /**
4671
+ * Clear the cache to force reading from disk.
4672
+ *
4673
+ * *NOTE: Only call this method if you must and you know what you are doing.*
4674
+ */
4675
+ static clearInstances(): void;
4668
4676
  /**
4669
4677
  * Get a Project from a given path or from the working directory.
4670
4678
  *
package/lib/index.js CHANGED
@@ -4629,7 +4629,7 @@ var require_package = __commonJS({
4629
4629
  "package.json"(exports2, module2) {
4630
4630
  module2.exports = {
4631
4631
  name: "@salesforce/core-bundle",
4632
- version: "8.2.9",
4632
+ version: "8.4.0",
4633
4633
  description: "Core libraries to interact with SFDX projects, orgs, and APIs.",
4634
4634
  main: "lib/index",
4635
4635
  types: "lib/index.d.ts",
@@ -94968,6 +94968,11 @@ var require_sfProject = __commonJS({
94968
94968
  this.validateKeys();
94969
94969
  return contents;
94970
94970
  }
94971
+ /** force a reread of the project contents if you know they may have been modified */
94972
+ refreshSync() {
94973
+ super.readSync(false, true);
94974
+ return this;
94975
+ }
94971
94976
  readSync() {
94972
94977
  const contents = super.readSync();
94973
94978
  this.validateKeys();
@@ -95193,6 +95198,14 @@ var require_sfProject = __commonJS({
95193
95198
  constructor(path) {
95194
95199
  this.path = path;
95195
95200
  }
95201
+ /**
95202
+ * Clear the cache to force reading from disk.
95203
+ *
95204
+ * *NOTE: Only call this method if you must and you know what you are doing.*
95205
+ */
95206
+ static clearInstances() {
95207
+ _SfProject.instances.clear();
95208
+ }
95196
95209
  /**
95197
95210
  * Get a Project from a given path or from the working directory.
95198
95211
  *
@@ -109155,6 +109168,7 @@ var require_scratchOrgInfoGenerator = __commonJS({
109155
109168
  try {
109156
109169
  const fileData = await node_fs_1.promises.readFile(definitionFile, "utf8");
109157
109170
  const defFileContents = (0, kit_1.parseJson)(fileData);
109171
+ delete defFileContents["$schema"];
109158
109172
  return defFileContents;
109159
109173
  } catch (err) {
109160
109174
  const error = err;
@@ -124396,7 +124410,7 @@ var require_testSetup = __commonJS({
124396
124410
  Object.values(testContext.SANDBOXES).forEach((theSandbox) => theSandbox.restore());
124397
124411
  testContext.configStubs = {};
124398
124412
  stateAggregator_12.StateAggregator.clearInstance();
124399
- sfProject_12.SfProject.instances.clear();
124413
+ sfProject_12.SfProject.clearInstances();
124400
124414
  delete configAggregator_12.ConfigAggregator.instance;
124401
124415
  };
124402
124416
  exports2.restoreContext = restoreContext;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salesforce/core-bundle",
3
- "version": "8.2.9",
3
+ "version": "8.4.0",
4
4
  "description": "Core libraries to interact with SFDX projects, orgs, and APIs.",
5
5
  "main": "lib/index",
6
6
  "types": "lib/index.d.ts",