@dotcom-tool-kit/base 1.1.9 → 1.2.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.md CHANGED
@@ -51,6 +51,22 @@
51
51
  * devDependencies
52
52
  * @dotcom-tool-kit/config bumped from ^1.0.11 to ^1.0.12
53
53
 
54
+ ### Dependencies
55
+
56
+ * The following workspace dependencies were updated
57
+ * dependencies
58
+ * @dotcom-tool-kit/conflict bumped from ^1.0.0 to ^1.0.1
59
+ * devDependencies
60
+ * @dotcom-tool-kit/config bumped from ^1.0.12 to ^1.1.0
61
+ * @dotcom-tool-kit/plugin bumped from ^1.0.0 to ^1.1.0
62
+
63
+ ## [1.2.0](https://github.com/Financial-Times/dotcom-tool-kit/compare/base-v1.1.10...base-v1.2.0) (2025-03-03)
64
+
65
+
66
+ ### Features
67
+
68
+ * **base:** pass cwd into init method ([b6cc028](https://github.com/Financial-Times/dotcom-tool-kit/commit/b6cc028129138869866f88860d544f5056668080))
69
+
54
70
  ## [1.1.5](https://github.com/Financial-Times/dotcom-tool-kit/compare/base-v1.1.4...base-v1.1.5) (2025-01-14)
55
71
 
56
72
 
package/lib/init.d.ts CHANGED
@@ -1,12 +1,15 @@
1
1
  import type { Logger } from 'winston';
2
2
  import { typeSymbol } from './symbols';
3
3
  import { Base } from './base';
4
+ export type InitContext = {
5
+ cwd: string;
6
+ };
4
7
  export declare abstract class Init extends Base {
5
8
  logger: Logger;
6
9
  constructor(logger: Logger);
7
10
  static get [typeSymbol](): symbol;
8
11
  get [typeSymbol](): symbol;
9
- abstract init(): Promise<void>;
12
+ abstract init(context: InitContext): Promise<void>;
10
13
  }
11
14
  export type InitConstructor = {
12
15
  new (logger: Logger): Init;
package/lib/init.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"init.d.ts","sourceRoot":"","sources":["../src/init.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,S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A"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dotcom-tool-kit/base",
3
- "version": "1.1.9",
3
+ "version": "1.2.0",
4
4
  "description": "",
5
5
  "main": "lib",
6
6
  "scripts": {
@@ -10,15 +10,15 @@
10
10
  "author": "",
11
11
  "license": "ISC",
12
12
  "dependencies": {
13
- "@dotcom-tool-kit/conflict": "^1.0.0",
13
+ "@dotcom-tool-kit/conflict": "^1.0.1",
14
14
  "@dotcom-tool-kit/logger": "^4.1.1",
15
15
  "@dotcom-tool-kit/validated": "^1.0.2",
16
16
  "semver": "^7.5.4",
17
17
  "winston": "^3.11.0"
18
18
  },
19
19
  "devDependencies": {
20
- "@dotcom-tool-kit/config": "^1.0.12",
21
- "@dotcom-tool-kit/plugin": "^1.0.0",
20
+ "@dotcom-tool-kit/config": "^1.1.0",
21
+ "@dotcom-tool-kit/plugin": "^1.1.0",
22
22
  "type-fest": "^4.29.1",
23
23
  "winston": "^3.11.0",
24
24
  "zod": "^3.22.4"
package/src/init.ts CHANGED
@@ -2,6 +2,10 @@ import type { Logger } from 'winston'
2
2
  import { initSymbol, typeSymbol } from './symbols'
3
3
  import { Base } from './base'
4
4
 
5
+ export type InitContext = {
6
+ cwd: string
7
+ }
8
+
5
9
  export abstract class Init extends Base {
6
10
  logger: Logger
7
11
 
@@ -18,7 +22,7 @@ export abstract class Init extends Base {
18
22
  return initSymbol
19
23
  }
20
24
 
21
- abstract init(): Promise<void>
25
+ abstract init(context: InitContext): Promise<void>
22
26
  }
23
27
 
24
28
  export type InitConstructor = {