@lage-run/config 0.2.0 → 0.3.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/CHANGELOG.json CHANGED
@@ -2,7 +2,43 @@
2
2
  "name": "@lage-run/config",
3
3
  "entries": [
4
4
  {
5
- "date": "Wed, 26 Apr 2023 04:56:07 GMT",
5
+ "date": "Thu, 25 May 2023 15:45:38 GMT",
6
+ "tag": "@lage-run/config_v0.3.0",
7
+ "version": "0.3.0",
8
+ "comments": {
9
+ "minor": [
10
+ {
11
+ "author": "altinokd@microsoft.com",
12
+ "package": "@lage-run/config",
13
+ "commit": "c2bf5ab7a31c05a11e9488a92d58ef0f74bc3e9d",
14
+ "comment": "Do not read config in targetWorker, instead pass CacheOptions as part of workerdata"
15
+ }
16
+ ]
17
+ }
18
+ },
19
+ {
20
+ "date": "Mon, 08 May 2023 22:27:16 GMT",
21
+ "tag": "@lage-run/config_v0.2.1",
22
+ "version": "0.2.1",
23
+ "comments": {
24
+ "patch": [
25
+ {
26
+ "author": "beachball",
27
+ "package": "@lage-run/config",
28
+ "comment": "Bump @lage-run/scheduler-types to v0.3.9",
29
+ "commit": "5a132808f166179bc316a279c9e11a13d3a39103"
30
+ },
31
+ {
32
+ "author": "beachball",
33
+ "package": "@lage-run/config",
34
+ "comment": "Bump @lage-run/target-graph to v0.8.6",
35
+ "commit": "5a132808f166179bc316a279c9e11a13d3a39103"
36
+ }
37
+ ]
38
+ }
39
+ },
40
+ {
41
+ "date": "Wed, 26 Apr 2023 04:56:20 GMT",
6
42
  "tag": "@lage-run/config_v0.2.0",
7
43
  "version": "0.2.0",
8
44
  "comments": {
package/CHANGELOG.md CHANGED
@@ -1,12 +1,29 @@
1
1
  # Change Log - @lage-run/config
2
2
 
3
- This log was last generated on Wed, 26 Apr 2023 04:56:07 GMT and should not be manually modified.
3
+ This log was last generated on Thu, 25 May 2023 15:45:38 GMT and should not be manually modified.
4
4
 
5
5
  <!-- Start content -->
6
6
 
7
+ ## 0.3.0
8
+
9
+ Thu, 25 May 2023 15:45:38 GMT
10
+
11
+ ### Minor changes
12
+
13
+ - Do not read config in targetWorker, instead pass CacheOptions as part of workerdata (altinokd@microsoft.com)
14
+
15
+ ## 0.2.1
16
+
17
+ Mon, 08 May 2023 22:27:16 GMT
18
+
19
+ ### Patches
20
+
21
+ - Bump @lage-run/scheduler-types to v0.3.9
22
+ - Bump @lage-run/target-graph to v0.8.6
23
+
7
24
  ## 0.2.0
8
25
 
9
- Wed, 26 Apr 2023 04:56:07 GMT
26
+ Wed, 26 Apr 2023 04:56:20 GMT
10
27
 
11
28
  ### Minor changes
12
29
 
@@ -4,10 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  });
5
5
  Object.defineProperty(exports, "getConcurrency", {
6
6
  enumerable: true,
7
- get: ()=>getConcurrency
7
+ get: function() {
8
+ return getConcurrency;
9
+ }
8
10
  });
9
- const _os = /*#__PURE__*/ _interopRequireDefault(require("os"));
10
- function _interopRequireDefault(obj) {
11
+ const _os = /*#__PURE__*/ _interop_require_default(require("os"));
12
+ function _interop_require_default(obj) {
11
13
  return obj && obj.__esModule ? obj : {
12
14
  default: obj
13
15
  };
package/lib/getConfig.js CHANGED
@@ -4,17 +4,19 @@ Object.defineProperty(exports, "__esModule", {
4
4
  });
5
5
  Object.defineProperty(exports, "getConfig", {
6
6
  enumerable: true,
7
- get: ()=>getConfig
7
+ get: function() {
8
+ return getConfig;
9
+ }
8
10
  });
9
- const _os = /*#__PURE__*/ _interopRequireDefault(require("os"));
10
- const _readConfigFileJs = require("./readConfigFile.js");
11
- function _interopRequireDefault(obj) {
11
+ const _os = /*#__PURE__*/ _interop_require_default(require("os"));
12
+ const _readConfigFile = require("./readConfigFile.js");
13
+ function _interop_require_default(obj) {
12
14
  return obj && obj.__esModule ? obj : {
13
15
  default: obj
14
16
  };
15
17
  }
16
18
  async function getConfig(cwd) {
17
- const config = await (0, _readConfigFileJs.readConfigFile)(cwd) || {};
19
+ const config = await (0, _readConfigFile.readConfigFile)(cwd) || {};
18
20
  return {
19
21
  cacheOptions: config?.cacheOptions ?? {},
20
22
  ignore: config?.ignore ?? [],
@@ -9,8 +9,12 @@ function _export(target, all) {
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- getMaxWorkersPerTask: ()=>getMaxWorkersPerTask,
13
- getMaxWorkersPerTaskFromOptions: ()=>getMaxWorkersPerTaskFromOptions
12
+ getMaxWorkersPerTask: function() {
13
+ return getMaxWorkersPerTask;
14
+ },
15
+ getMaxWorkersPerTaskFromOptions: function() {
16
+ return getMaxWorkersPerTaskFromOptions;
17
+ }
14
18
  });
15
19
  function getMaxWorkersPerTask(pipelineConfig, concurrency) {
16
20
  const maxWorkersPerTask = new Map();
package/lib/index.js CHANGED
@@ -9,13 +9,23 @@ function _export(target, all) {
9
9
  });
10
10
  }
11
11
  _export(exports, {
12
- getConfig: ()=>_getConfigJs.getConfig,
13
- getConcurrency: ()=>_getConcurrencyJs.getConcurrency,
14
- getMaxWorkersPerTask: ()=>_getMaxWorkersPerTaskJs.getMaxWorkersPerTask,
15
- getMaxWorkersPerTaskFromOptions: ()=>_getMaxWorkersPerTaskJs.getMaxWorkersPerTaskFromOptions,
16
- readConfigFile: ()=>_readConfigFileJs.readConfigFile
12
+ getConfig: function() {
13
+ return _getConfig.getConfig;
14
+ },
15
+ getConcurrency: function() {
16
+ return _getConcurrency.getConcurrency;
17
+ },
18
+ getMaxWorkersPerTask: function() {
19
+ return _getMaxWorkersPerTask.getMaxWorkersPerTask;
20
+ },
21
+ getMaxWorkersPerTaskFromOptions: function() {
22
+ return _getMaxWorkersPerTask.getMaxWorkersPerTaskFromOptions;
23
+ },
24
+ readConfigFile: function() {
25
+ return _readConfigFile.readConfigFile;
26
+ }
17
27
  });
18
- const _getConfigJs = require("./getConfig.js");
19
- const _getConcurrencyJs = require("./getConcurrency.js");
20
- const _getMaxWorkersPerTaskJs = require("./getMaxWorkersPerTask.js");
21
- const _readConfigFileJs = require("./readConfigFile.js");
28
+ const _getConfig = require("./getConfig.js");
29
+ const _getConcurrency = require("./getConcurrency.js");
30
+ const _getMaxWorkersPerTask = require("./getMaxWorkersPerTask.js");
31
+ const _readConfigFile = require("./readConfigFile.js");
@@ -4,14 +4,16 @@ Object.defineProperty(exports, "__esModule", {
4
4
  });
5
5
  Object.defineProperty(exports, "readConfigFile", {
6
6
  enumerable: true,
7
- get: ()=>readConfigFile
7
+ get: function() {
8
+ return readConfigFile;
9
+ }
8
10
  });
9
11
  const _cosmiconfig = require("cosmiconfig");
10
- const _workspaceTools = require("workspace-tools");
12
+ const _workspacetools = require("workspace-tools");
11
13
  const ConfigModuleName = "lage";
12
14
  async function readConfigFile(cwd) {
13
15
  // Verify presence of git
14
- const root = (0, _workspaceTools.getWorkspaceRoot)(cwd);
16
+ const root = (0, _workspacetools.getWorkspaceRoot)(cwd);
15
17
  if (!root) {
16
18
  throw new Error("This must be called inside a codebase that is part of a JavaScript workspace.");
17
19
  }
@@ -1,5 +1,8 @@
1
- import type { Config as BackfillCacheOptions } from "backfill-config";
2
- export type CacheOptions = BackfillCacheOptions & {
1
+ import type { Config as BackfillCacheOptions, CustomStorageConfig } from "backfill-config";
2
+ export type LageBackfillCacheOptions = Omit<BackfillCacheOptions, "cacheStorageConfig"> & {
3
+ cacheStorageConfig: Exclude<BackfillCacheOptions["cacheStorageConfig"], CustomStorageConfig>;
4
+ };
5
+ export type CacheOptions = LageBackfillCacheOptions & {
3
6
  environmentGlob: string[];
4
7
  cacheKey: string;
5
8
  writeRemoteCache: boolean;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lage-run/config",
3
- "version": "0.2.0",
3
+ "version": "0.3.0",
4
4
  "description": "Config management for Lage",
5
5
  "repository": {
6
6
  "type": "git",
@@ -22,8 +22,8 @@
22
22
  "dependencies": {
23
23
  "backfill-config": "^6.3.1",
24
24
  "@lage-run/logger": "^1.3.0",
25
- "@lage-run/scheduler-types": "^0.3.8",
26
- "@lage-run/target-graph": "^0.8.4",
25
+ "@lage-run/scheduler-types": "^0.3.9",
26
+ "@lage-run/target-graph": "^0.8.6",
27
27
  "workspace-tools": "^0.34.0",
28
28
  "cosmiconfig": "^7.0.0"
29
29
  },