@ankhorage/devtools 1.5.2 → 1.6.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.
@@ -1,11 +1,23 @@
1
1
  /**
2
- * Canonical Bun runtime policy for Ankhorage repositories.
2
+ * Canonical runtime/tooling policies for Ankhorage repositories.
3
3
  *
4
- * Import this from `@ankhorage/devtools/policy` when another package needs to inspect
5
- * the managed Bun version without defining an independent version authority.
4
+ * Import these from `@ankhorage/devtools/policy` when another package needs to inspect
5
+ * the managed Bun or Node baseline without defining an independent version authority.
6
6
  */
7
7
  export declare const bunRuntimePolicy: {
8
8
  readonly packageManager: "bun@1.3.14";
9
9
  readonly typesRange: "^1.3.14";
10
10
  readonly version: "1.3.14";
11
11
  };
12
+ /**
13
+ * Canonical Node LTS baseline for Node-based Ankhorage tooling and CI execution.
14
+ *
15
+ * Bun remains the repository package manager/primary command runtime where configured;
16
+ * this policy makes Node-based tooling deterministic instead of inheriting the ambient
17
+ * Node version from a CI runner image.
18
+ */
19
+ export declare const nodeRuntimePolicy: {
20
+ readonly engineRange: "24.x";
21
+ readonly major: 24;
22
+ readonly setupVersion: "24";
23
+ };
@@ -1,11 +1,23 @@
1
1
  /**
2
- * Canonical Bun runtime policy for Ankhorage repositories.
2
+ * Canonical runtime/tooling policies for Ankhorage repositories.
3
3
  *
4
- * Import this from `@ankhorage/devtools/policy` when another package needs to inspect
5
- * the managed Bun version without defining an independent version authority.
4
+ * Import these from `@ankhorage/devtools/policy` when another package needs to inspect
5
+ * the managed Bun or Node baseline without defining an independent version authority.
6
6
  */
7
7
  export const bunRuntimePolicy = {
8
8
  packageManager: 'bun@1.3.14',
9
9
  typesRange: '^1.3.14',
10
10
  version: '1.3.14',
11
11
  };
12
+ /**
13
+ * Canonical Node LTS baseline for Node-based Ankhorage tooling and CI execution.
14
+ *
15
+ * Bun remains the repository package manager/primary command runtime where configured;
16
+ * this policy makes Node-based tooling deterministic instead of inheriting the ambient
17
+ * Node version from a CI runner image.
18
+ */
19
+ export const nodeRuntimePolicy = {
20
+ engineRange: '24.x',
21
+ major: 24,
22
+ setupVersion: '24',
23
+ };
@@ -24,6 +24,11 @@ jobs:
24
24
  with:
25
25
  bun-version: '__ANKH_BUN_VERSION__'
26
26
 
27
+ - name: Setup Node
28
+ uses: actions/setup-node@v4
29
+ with:
30
+ node-version: '__ANKH_NODE_VERSION__'
31
+
27
32
  - name: Install dependencies
28
33
  run: bun install --frozen-lockfile
29
34
 
@@ -32,7 +32,7 @@ jobs:
32
32
  - name: Setup Node for npm publishing
33
33
  uses: actions/setup-node@v4
34
34
  with:
35
- node-version: 24
35
+ node-version: '__ANKH_NODE_VERSION__'
36
36
  registry-url: https://registry.npmjs.org
37
37
 
38
38
  - name: Update npm
@@ -1,6 +1,7 @@
1
1
  import { readFile } from 'node:fs/promises';
2
- import { bunRuntimePolicy } from '../../policy/bunRuntimePolicy.js';
2
+ import { bunRuntimePolicy, nodeRuntimePolicy } from '../../policy/bunRuntimePolicy.js';
3
3
  const BUN_VERSION_TOKEN = '__ANKH_BUN_VERSION__';
4
+ const NODE_VERSION_TOKEN = '__ANKH_NODE_VERSION__';
4
5
  export const workflowManagedFiles = [
5
6
  createWorkflowDefinition('.github/workflows/ci.yml', './files/ci.yml'),
6
7
  createWorkflowDefinition('.github/workflows/release.yml', './files/release.yml'),
@@ -11,7 +12,9 @@ function createWorkflowDefinition(relativePath, sourcePath) {
11
12
  relativePath,
12
13
  render: async () => {
13
14
  const template = await readFile(sourceUrl, 'utf8');
14
- return template.replaceAll(BUN_VERSION_TOKEN, bunRuntimePolicy.version);
15
+ return template
16
+ .replaceAll(BUN_VERSION_TOKEN, bunRuntimePolicy.version)
17
+ .replaceAll(NODE_VERSION_TOKEN, nodeRuntimePolicy.setupVersion);
15
18
  },
16
19
  };
17
20
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ankhorage/devtools",
3
- "version": "1.5.2",
3
+ "version": "1.6.0",
4
4
  "description": "Shared development tools and repository standards for Ankhorage",
5
5
  "license": "MIT",
6
6
  "homepage": "https://github.com/ankhorage/devtools#readme",