textrun-make 0.6.0 → 0.7.1

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/LICENSE ADDED
@@ -0,0 +1,23 @@
1
+ SPDX-License-Identifier: ISC
2
+
3
+ Copyright 2026 Kevin Goslar
4
+
5
+ Permission to use, copy, modify, and/or distribute this software
6
+ for any purpose with or without fee is hereby granted,
7
+ provided that the above copyright notice
8
+ and this permission notice appear in all copies.
9
+
10
+ THE SOFTWARE IS PROVIDED “AS IS”
11
+ AND THE AUTHOR DISCLAIMS ALL WARRANTIES
12
+ WITH REGARD TO THIS SOFTWARE
13
+ INCLUDING ALL IMPLIED WARRANTIES
14
+ OF MERCHANTABILITY AND FITNESS.
15
+
16
+ IN NO EVENT SHALL THE AUTHOR BE LIABLE
17
+ FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES
18
+ OR ANY DAMAGES WHATSOEVER
19
+ RESULTING FROM LOSS OF USE, DATA OR PROFITS,
20
+ WHETHER IN AN ACTION OF CONTRACT,
21
+ NEGLIGENCE OR OTHER TORTIOUS ACTION,
22
+ ARISING OUT OF OR IN CONNECTION WITH
23
+ THE USE OR PERFORMANCE OF THIS SOFTWARE.
@@ -1,6 +1,6 @@
1
- import { promises as fs } from "fs";
1
+ import { promises as fs } from "node:fs";
2
+ import * as os from "node:os";
2
3
  import { styleText } from "node:util";
3
- import * as os from "os";
4
4
  import * as textRunner from "text-runner-engine";
5
5
  import { makefileTargets } from "../helpers/makefile-targets.js";
6
6
  /** verifies that the Makefile in the sourceDir contains the enclosed target */
@@ -15,12 +15,13 @@ export async function command(action) {
15
15
  else {
16
16
  action.name(`make commands: ${styleText("cyan", wants.join(", "))}`);
17
17
  }
18
- const makefilePath = action.configuration.sourceDir.joinStr(action.location.file.directory().platformified(), action.region[0].attributes["dir"] || ".", "Makefile");
18
+ const makefilePath = action.configuration.sourceDir.joinStr(action.location.file.directory().platformified(), action.region[0].attributes.dir || ".", "Makefile");
19
19
  const makefileContent = await fs.readFile(makefilePath, "utf8");
20
20
  const haves = makefileTargets(makefileContent);
21
21
  for (const want of wants) {
22
22
  if (!haves.includes(want)) {
23
- throw new Error(`Makefile does not contain command make ${styleText("cyan", want)} but these targets: ${styleText("cyan", haves.join(", "))}`);
23
+ const targets = styleText("cyan", haves.join(", "));
24
+ throw new Error(`Makefile does not contain command make ${styleText("cyan", want)} but these targets: ${targets}`);
24
25
  }
25
26
  }
26
27
  }
@@ -1,4 +1,4 @@
1
- import { promises as fs } from "fs";
1
+ import { promises as fs } from "node:fs";
2
2
  import { styleText } from "node:util";
3
3
  import { makefileTargets } from "../helpers/makefile-targets.js";
4
4
  /** verifies that the Makefile in the sourceDir contains the enclosed target */
@@ -8,11 +8,12 @@ export async function target(action) {
8
8
  throw new Error("Empty make target");
9
9
  }
10
10
  action.name(`make target ${styleText("cyan", target)}`);
11
- const makePath = action.configuration.sourceDir.joinStr(action.region[0].attributes["dir"] || ".", "Makefile");
11
+ const makePath = action.configuration.sourceDir.joinStr(action.region[0].attributes.dir || ".", "Makefile");
12
12
  const makefile = await fs.readFile(makePath, "utf8");
13
13
  const targets = makefileTargets(makefile);
14
14
  if (!targets.includes(target)) {
15
- throw new Error(`Makefile does not contain target ${styleText("cyan", target)} but these ones: ${styleText("cyan", targets.join(", "))}`);
15
+ const targetText = styleText("cyan", targets.join(", "));
16
+ throw new Error(`Makefile does not contain target ${styleText("cyan", target)} but these ones: ${targetText}`);
16
17
  }
17
18
  }
18
19
  //# sourceMappingURL=target.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "textrun-make",
3
- "version": "0.6.0",
3
+ "version": "0.7.1",
4
4
  "license": "ISC",
5
5
  "type": "module",
6
6
  "exports": "./dist/index.js",
@@ -11,22 +11,22 @@
11
11
  "build": "tsc -p tsconfig-build.json",
12
12
  "cuke": "cucumber-js --format=progress",
13
13
  "doc": "text-runner",
14
- "fix": "eslint --fix --ignore-pattern=dist/ . && dprint fmt && sort-package-json --quiet && ../tools/rta ghokin fmt replace features",
15
- "lint": "dprint check && sort-package-json --check --quiet && eslint --ignore-pattern=dist/ . && depcheck --config=../.depcheckrc",
14
+ "fix": "biome check --write --unsafe && dprint fmt && sort-package-json --quiet && ../tools/rta ghokin fmt replace features",
15
+ "lint": "biome check --error-on-warnings && dprint check && sort-package-json --check --quiet && depcheck --config=../.depcheckrc",
16
16
  "reset": "rm -rf dist && yarn run build",
17
17
  "unit": "node --test --import tsx 'src/**/*.test.ts'"
18
18
  },
19
19
  "dependencies": {
20
- "text-runner-engine": "7.4.0"
20
+ "text-runner-engine": "7.5.1"
21
21
  },
22
22
  "devDependencies": {
23
23
  "shared-cucumber-steps": "*",
24
- "text-runner": "7.4.0",
25
- "textrun-action": "0.6.0",
26
- "textrun-extension": "0.6.0",
27
- "textrun-npm": "0.6.0",
28
- "textrun-workspace": "0.6.0",
29
- "tsx": "4.20.6"
24
+ "text-runner": "7.5.1",
25
+ "textrun-action": "0.7.1",
26
+ "textrun-extension": "0.7.1",
27
+ "textrun-npm": "0.7.1",
28
+ "textrun-workspace": "0.7.1",
29
+ "tsx": "4.21.0"
30
30
  },
31
- "gitHead": "a173b524f1afa311e27fa7aa847acc2ddf6b1cbb"
31
+ "gitHead": "ffa7b993386ef88d6f199373e97d9c39e3ea3ac4"
32
32
  }