@alexaegis/autotool-plugin-vitest 0.3.3 → 0.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/index.cjs +27 -28
- package/index.d.ts.map +1 -1
- package/index.js +27 -28
- package/index.spec.d.ts +2 -0
- package/index.spec.d.ts.map +1 -0
- package/package.json +16 -15
- package/index.cjs.map +0 -1
- package/index.js.map +0 -1
package/index.cjs
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
const predicate = require("@alexaegis/predicate");
|
|
3
4
|
const node_path = require("node:path");
|
|
4
5
|
const name = "@alexaegis/autotool-plugin-vitest";
|
|
5
6
|
const description = "Setup vitest";
|
|
6
|
-
const version = "0.
|
|
7
|
+
const version = "0.4.0";
|
|
7
8
|
const license = "MIT";
|
|
8
9
|
const archetype = {
|
|
9
10
|
platform: "node",
|
|
@@ -28,7 +29,7 @@ const scripts = {
|
|
|
28
29
|
"lint:es": "turbo run lint:es_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
29
30
|
"lint:es_": "eslint --max-warnings=0 --fix --no-error-on-unmatched-pattern .",
|
|
30
31
|
"lint:format": "turbo run lint:format_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
31
|
-
"lint:format_": "prettier --
|
|
32
|
+
"lint:format_": "prettier --cache-location .cache/prettier --check .",
|
|
32
33
|
"lint:md": "turbo run lint:md_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
33
34
|
"lint:md_": "remark --frail --no-stdout --silently-ignore .",
|
|
34
35
|
"lint:tsc": "turbo run lint:tsc_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
@@ -37,7 +38,7 @@ const scripts = {
|
|
|
37
38
|
publint_: "publint dist",
|
|
38
39
|
all: "turbo run all_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
39
40
|
format: "turbo run format_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
40
|
-
format_: "prettier --
|
|
41
|
+
format_: "prettier --cache-location .cache/prettier --write .",
|
|
41
42
|
test: "turbo run test_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
42
43
|
test_: "vitest --passWithNoTests --coverage --run",
|
|
43
44
|
"test:watch": "vitest --passWithNoTests --coverage"
|
|
@@ -55,22 +56,23 @@ const exports$1 = {
|
|
|
55
56
|
"./readme": "./readme.md"
|
|
56
57
|
};
|
|
57
58
|
const dependencies = {
|
|
58
|
-
"@alexaegis/coverage-tools": "^0.
|
|
59
|
-
"@alexaegis/logging": "^0.
|
|
60
|
-
"
|
|
59
|
+
"@alexaegis/coverage-tools": "^0.4.0",
|
|
60
|
+
"@alexaegis/logging": "^0.4.0",
|
|
61
|
+
"@alexaegis/predicate": "^0.4.0",
|
|
62
|
+
"autotool-plugin": "^0.1.1"
|
|
61
63
|
};
|
|
62
64
|
const devDependencies = {
|
|
63
|
-
"@alexaegis/eslint-config-vitest": "^0.
|
|
64
|
-
"@alexaegis/ts": "^0.
|
|
65
|
-
"@alexaegis/vite": "^0.
|
|
66
|
-
"@alexaegis/vitest": "^0.
|
|
65
|
+
"@alexaegis/eslint-config-vitest": "^0.4.0",
|
|
66
|
+
"@alexaegis/ts": "^0.4.0",
|
|
67
|
+
"@alexaegis/vite": "^0.4.0",
|
|
68
|
+
"@alexaegis/vitest": "^0.4.0",
|
|
67
69
|
"@lcov-viewer/cli": "^1.3.0",
|
|
68
|
-
"@types/node": "^20.
|
|
69
|
-
"@vitest/coverage-v8": "^0.32.
|
|
70
|
-
publint: "^0.1.
|
|
71
|
-
typescript: "^5.1.
|
|
70
|
+
"@types/node": "^20.4.0",
|
|
71
|
+
"@vitest/coverage-v8": "^0.32.4",
|
|
72
|
+
publint: "^0.1.16",
|
|
73
|
+
typescript: "^5.1.6",
|
|
72
74
|
vite: "^4.3.9",
|
|
73
|
-
vitest: "^0.32.
|
|
75
|
+
vitest: "^0.32.4"
|
|
74
76
|
};
|
|
75
77
|
const packageJson = {
|
|
76
78
|
name,
|
|
@@ -87,6 +89,7 @@ const packageJson = {
|
|
|
87
89
|
dependencies,
|
|
88
90
|
devDependencies
|
|
89
91
|
};
|
|
92
|
+
const appOrLib = predicate.or(predicate.equal("app"), predicate.equal("lib"));
|
|
90
93
|
const plugin = (_options) => {
|
|
91
94
|
return {
|
|
92
95
|
name: packageJson.name,
|
|
@@ -97,12 +100,9 @@ const plugin = (_options) => {
|
|
|
97
100
|
packageKind: "root",
|
|
98
101
|
data: {
|
|
99
102
|
scripts: {
|
|
100
|
-
test: "turbo run test_ --concurrency 16 --cache-dir .cache/turbo"
|
|
101
|
-
"merge-coverage": "merge-workspace-lcov-reports && lcov-viewer lcov -o ./coverage ./coverage/lcov.info"
|
|
103
|
+
test: "turbo run test_ --concurrency 16 --cache-dir .cache/turbo && merge-workspace-lcov-reports && lcov-viewer lcov -o ./coverage ./coverage/lcov.info"
|
|
102
104
|
},
|
|
103
105
|
devDependencies: {
|
|
104
|
-
"@vitest/coverage-c8": void 0,
|
|
105
|
-
// TODO: remove once cascaded
|
|
106
106
|
"@vitest/coverage-v8": packageJson.devDependencies["@vitest/coverage-v8"],
|
|
107
107
|
"@lcov-viewer/cli": packageJson.devDependencies["@lcov-viewer/cli"],
|
|
108
108
|
"@alexaegis/coverage-tools": packageJson.dependencies["@alexaegis/coverage-tools"]
|
|
@@ -115,7 +115,7 @@ const plugin = (_options) => {
|
|
|
115
115
|
packageKind: "regular",
|
|
116
116
|
packageJsonFilter: {
|
|
117
117
|
archetype: {
|
|
118
|
-
kind:
|
|
118
|
+
kind: appOrLib
|
|
119
119
|
}
|
|
120
120
|
},
|
|
121
121
|
data: {
|
|
@@ -131,10 +131,10 @@ const plugin = (_options) => {
|
|
|
131
131
|
executor: "packageJson",
|
|
132
132
|
packageKind: "regular",
|
|
133
133
|
packageJsonFilter: {
|
|
134
|
-
name:
|
|
134
|
+
name: predicate.not(predicate.or(predicate.equal("@alexaegis/vite"), predicate.equal("@alexaegis/vitest"))),
|
|
135
135
|
// Don't add it for itself and 'vite' it would cause a circle
|
|
136
136
|
archetype: {
|
|
137
|
-
kind:
|
|
137
|
+
kind: appOrLib
|
|
138
138
|
}
|
|
139
139
|
},
|
|
140
140
|
data: {
|
|
@@ -149,9 +149,9 @@ const plugin = (_options) => {
|
|
|
149
149
|
executor: "fileCopy",
|
|
150
150
|
packageJsonFilter: {
|
|
151
151
|
archetype: {
|
|
152
|
-
kind:
|
|
152
|
+
kind: appOrLib,
|
|
153
153
|
platform: "web",
|
|
154
|
-
framework:
|
|
154
|
+
framework: predicate.not(predicate.equal("svelte"))
|
|
155
155
|
}
|
|
156
156
|
},
|
|
157
157
|
packageKind: "regular",
|
|
@@ -165,9 +165,9 @@ const plugin = (_options) => {
|
|
|
165
165
|
executor: "fileCopy",
|
|
166
166
|
packageJsonFilter: {
|
|
167
167
|
archetype: {
|
|
168
|
-
kind:
|
|
168
|
+
kind: appOrLib,
|
|
169
169
|
platform: "node",
|
|
170
|
-
framework:
|
|
170
|
+
framework: predicate.not(predicate.equal("svelte"))
|
|
171
171
|
}
|
|
172
172
|
},
|
|
173
173
|
packageKind: "regular",
|
|
@@ -181,7 +181,7 @@ const plugin = (_options) => {
|
|
|
181
181
|
executor: "fileCopy",
|
|
182
182
|
packageJsonFilter: {
|
|
183
183
|
archetype: {
|
|
184
|
-
kind:
|
|
184
|
+
kind: appOrLib,
|
|
185
185
|
framework: "svelte"
|
|
186
186
|
}
|
|
187
187
|
},
|
|
@@ -196,4 +196,3 @@ const plugin = (_options) => {
|
|
|
196
196
|
};
|
|
197
197
|
exports.default = plugin;
|
|
198
198
|
exports.plugin = plugin;
|
|
199
|
-
//# sourceMappingURL=index.cjs.map
|
package/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,cAAc,EAA6B,MAAM,iBAAiB,CAAC;AAMjF,eAAO,MAAM,MAAM,EAAE,cAwGpB,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
package/index.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import { or, equal, not } from "@alexaegis/predicate";
|
|
1
2
|
import { join } from "node:path";
|
|
2
3
|
const name = "@alexaegis/autotool-plugin-vitest";
|
|
3
4
|
const description = "Setup vitest";
|
|
4
|
-
const version = "0.
|
|
5
|
+
const version = "0.4.0";
|
|
5
6
|
const license = "MIT";
|
|
6
7
|
const archetype = {
|
|
7
8
|
platform: "node",
|
|
@@ -26,7 +27,7 @@ const scripts = {
|
|
|
26
27
|
"lint:es": "turbo run lint:es_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
27
28
|
"lint:es_": "eslint --max-warnings=0 --fix --no-error-on-unmatched-pattern .",
|
|
28
29
|
"lint:format": "turbo run lint:format_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
29
|
-
"lint:format_": "prettier --
|
|
30
|
+
"lint:format_": "prettier --cache-location .cache/prettier --check .",
|
|
30
31
|
"lint:md": "turbo run lint:md_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
31
32
|
"lint:md_": "remark --frail --no-stdout --silently-ignore .",
|
|
32
33
|
"lint:tsc": "turbo run lint:tsc_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
@@ -35,7 +36,7 @@ const scripts = {
|
|
|
35
36
|
publint_: "publint dist",
|
|
36
37
|
all: "turbo run all_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
37
38
|
format: "turbo run format_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
38
|
-
format_: "prettier --
|
|
39
|
+
format_: "prettier --cache-location .cache/prettier --write .",
|
|
39
40
|
test: "turbo run test_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
40
41
|
test_: "vitest --passWithNoTests --coverage --run",
|
|
41
42
|
"test:watch": "vitest --passWithNoTests --coverage"
|
|
@@ -53,22 +54,23 @@ const exports = {
|
|
|
53
54
|
"./readme": "./readme.md"
|
|
54
55
|
};
|
|
55
56
|
const dependencies = {
|
|
56
|
-
"@alexaegis/coverage-tools": "^0.
|
|
57
|
-
"@alexaegis/logging": "^0.
|
|
58
|
-
"
|
|
57
|
+
"@alexaegis/coverage-tools": "^0.4.0",
|
|
58
|
+
"@alexaegis/logging": "^0.4.0",
|
|
59
|
+
"@alexaegis/predicate": "^0.4.0",
|
|
60
|
+
"autotool-plugin": "^0.1.1"
|
|
59
61
|
};
|
|
60
62
|
const devDependencies = {
|
|
61
|
-
"@alexaegis/eslint-config-vitest": "^0.
|
|
62
|
-
"@alexaegis/ts": "^0.
|
|
63
|
-
"@alexaegis/vite": "^0.
|
|
64
|
-
"@alexaegis/vitest": "^0.
|
|
63
|
+
"@alexaegis/eslint-config-vitest": "^0.4.0",
|
|
64
|
+
"@alexaegis/ts": "^0.4.0",
|
|
65
|
+
"@alexaegis/vite": "^0.4.0",
|
|
66
|
+
"@alexaegis/vitest": "^0.4.0",
|
|
65
67
|
"@lcov-viewer/cli": "^1.3.0",
|
|
66
|
-
"@types/node": "^20.
|
|
67
|
-
"@vitest/coverage-v8": "^0.32.
|
|
68
|
-
publint: "^0.1.
|
|
69
|
-
typescript: "^5.1.
|
|
68
|
+
"@types/node": "^20.4.0",
|
|
69
|
+
"@vitest/coverage-v8": "^0.32.4",
|
|
70
|
+
publint: "^0.1.16",
|
|
71
|
+
typescript: "^5.1.6",
|
|
70
72
|
vite: "^4.3.9",
|
|
71
|
-
vitest: "^0.32.
|
|
73
|
+
vitest: "^0.32.4"
|
|
72
74
|
};
|
|
73
75
|
const packageJson = {
|
|
74
76
|
name,
|
|
@@ -85,6 +87,7 @@ const packageJson = {
|
|
|
85
87
|
dependencies,
|
|
86
88
|
devDependencies
|
|
87
89
|
};
|
|
90
|
+
const appOrLib = or(equal("app"), equal("lib"));
|
|
88
91
|
const plugin = (_options) => {
|
|
89
92
|
return {
|
|
90
93
|
name: packageJson.name,
|
|
@@ -95,12 +98,9 @@ const plugin = (_options) => {
|
|
|
95
98
|
packageKind: "root",
|
|
96
99
|
data: {
|
|
97
100
|
scripts: {
|
|
98
|
-
test: "turbo run test_ --concurrency 16 --cache-dir .cache/turbo"
|
|
99
|
-
"merge-coverage": "merge-workspace-lcov-reports && lcov-viewer lcov -o ./coverage ./coverage/lcov.info"
|
|
101
|
+
test: "turbo run test_ --concurrency 16 --cache-dir .cache/turbo && merge-workspace-lcov-reports && lcov-viewer lcov -o ./coverage ./coverage/lcov.info"
|
|
100
102
|
},
|
|
101
103
|
devDependencies: {
|
|
102
|
-
"@vitest/coverage-c8": void 0,
|
|
103
|
-
// TODO: remove once cascaded
|
|
104
104
|
"@vitest/coverage-v8": packageJson.devDependencies["@vitest/coverage-v8"],
|
|
105
105
|
"@lcov-viewer/cli": packageJson.devDependencies["@lcov-viewer/cli"],
|
|
106
106
|
"@alexaegis/coverage-tools": packageJson.dependencies["@alexaegis/coverage-tools"]
|
|
@@ -113,7 +113,7 @@ const plugin = (_options) => {
|
|
|
113
113
|
packageKind: "regular",
|
|
114
114
|
packageJsonFilter: {
|
|
115
115
|
archetype: {
|
|
116
|
-
kind:
|
|
116
|
+
kind: appOrLib
|
|
117
117
|
}
|
|
118
118
|
},
|
|
119
119
|
data: {
|
|
@@ -129,10 +129,10 @@ const plugin = (_options) => {
|
|
|
129
129
|
executor: "packageJson",
|
|
130
130
|
packageKind: "regular",
|
|
131
131
|
packageJsonFilter: {
|
|
132
|
-
name:
|
|
132
|
+
name: not(or(equal("@alexaegis/vite"), equal("@alexaegis/vitest"))),
|
|
133
133
|
// Don't add it for itself and 'vite' it would cause a circle
|
|
134
134
|
archetype: {
|
|
135
|
-
kind:
|
|
135
|
+
kind: appOrLib
|
|
136
136
|
}
|
|
137
137
|
},
|
|
138
138
|
data: {
|
|
@@ -147,9 +147,9 @@ const plugin = (_options) => {
|
|
|
147
147
|
executor: "fileCopy",
|
|
148
148
|
packageJsonFilter: {
|
|
149
149
|
archetype: {
|
|
150
|
-
kind:
|
|
150
|
+
kind: appOrLib,
|
|
151
151
|
platform: "web",
|
|
152
|
-
framework:
|
|
152
|
+
framework: not(equal("svelte"))
|
|
153
153
|
}
|
|
154
154
|
},
|
|
155
155
|
packageKind: "regular",
|
|
@@ -163,9 +163,9 @@ const plugin = (_options) => {
|
|
|
163
163
|
executor: "fileCopy",
|
|
164
164
|
packageJsonFilter: {
|
|
165
165
|
archetype: {
|
|
166
|
-
kind:
|
|
166
|
+
kind: appOrLib,
|
|
167
167
|
platform: "node",
|
|
168
|
-
framework:
|
|
168
|
+
framework: not(equal("svelte"))
|
|
169
169
|
}
|
|
170
170
|
},
|
|
171
171
|
packageKind: "regular",
|
|
@@ -179,7 +179,7 @@ const plugin = (_options) => {
|
|
|
179
179
|
executor: "fileCopy",
|
|
180
180
|
packageJsonFilter: {
|
|
181
181
|
archetype: {
|
|
182
|
-
kind:
|
|
182
|
+
kind: appOrLib,
|
|
183
183
|
framework: "svelte"
|
|
184
184
|
}
|
|
185
185
|
},
|
|
@@ -196,4 +196,3 @@ export {
|
|
|
196
196
|
plugin as default,
|
|
197
197
|
plugin
|
|
198
198
|
};
|
|
199
|
-
//# sourceMappingURL=index.js.map
|
package/index.spec.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.spec.d.ts","sourceRoot":"","sources":["../../../src/index.spec.ts"],"names":[],"mappings":""}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alexaegis/autotool-plugin-vitest",
|
|
3
3
|
"description": "Setup vitest",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.4.0",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"private": false,
|
|
7
7
|
"archetype": {
|
|
@@ -54,22 +54,23 @@
|
|
|
54
54
|
"./readme": "./readme.md"
|
|
55
55
|
},
|
|
56
56
|
"dependencies": {
|
|
57
|
-
"@alexaegis/coverage-tools": "^0.
|
|
58
|
-
"@alexaegis/logging": "^0.
|
|
59
|
-
"
|
|
57
|
+
"@alexaegis/coverage-tools": "^0.4.0",
|
|
58
|
+
"@alexaegis/logging": "^0.4.0",
|
|
59
|
+
"@alexaegis/predicate": "^0.4.0",
|
|
60
|
+
"autotool-plugin": "^0.1.1"
|
|
60
61
|
},
|
|
61
62
|
"devDependencies": {
|
|
62
|
-
"@alexaegis/eslint-config-vitest": "^0.
|
|
63
|
-
"@alexaegis/ts": "^0.
|
|
64
|
-
"@alexaegis/vite": "^0.
|
|
65
|
-
"@alexaegis/vitest": "^0.
|
|
63
|
+
"@alexaegis/eslint-config-vitest": "^0.4.0",
|
|
64
|
+
"@alexaegis/ts": "^0.4.0",
|
|
65
|
+
"@alexaegis/vite": "^0.4.0",
|
|
66
|
+
"@alexaegis/vitest": "^0.4.0",
|
|
66
67
|
"@lcov-viewer/cli": "^1.3.0",
|
|
67
|
-
"@types/node": "^20.
|
|
68
|
-
"@vitest/coverage-v8": "^0.32.
|
|
69
|
-
"publint": "^0.1.
|
|
70
|
-
"typescript": "^5.1.
|
|
68
|
+
"@types/node": "^20.4.0",
|
|
69
|
+
"@vitest/coverage-v8": "^0.32.4",
|
|
70
|
+
"publint": "^0.1.16",
|
|
71
|
+
"typescript": "^5.1.6",
|
|
71
72
|
"vite": "^4.3.9",
|
|
72
|
-
"vitest": "^0.32.
|
|
73
|
+
"vitest": "^0.32.4"
|
|
73
74
|
},
|
|
74
75
|
"scripts": {
|
|
75
76
|
"build": "turbo run build-lib_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
@@ -79,7 +80,7 @@
|
|
|
79
80
|
"lint:es": "turbo run lint:es_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
80
81
|
"lint:es_": "eslint --max-warnings=0 --fix --no-error-on-unmatched-pattern .",
|
|
81
82
|
"lint:format": "turbo run lint:format_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
82
|
-
"lint:format_": "prettier --
|
|
83
|
+
"lint:format_": "prettier --cache-location .cache/prettier --check .",
|
|
83
84
|
"lint:md": "turbo run lint:md_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
84
85
|
"lint:md_": "remark --frail --no-stdout --silently-ignore .",
|
|
85
86
|
"lint:tsc": "turbo run lint:tsc_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
@@ -88,7 +89,7 @@
|
|
|
88
89
|
"publint_": "publint dist",
|
|
89
90
|
"all": "turbo run all_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
90
91
|
"format": "turbo run format_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
91
|
-
"format_": "prettier --
|
|
92
|
+
"format_": "prettier --cache-location .cache/prettier --write .",
|
|
92
93
|
"test": "turbo run test_ --concurrency 16 --cache-dir .cache/turbo --filter @alexaegis/autotool-plugin-vitest",
|
|
93
94
|
"test_": "vitest --passWithNoTests --coverage --run",
|
|
94
95
|
"test:watch": "vitest --passWithNoTests --coverage"
|
package/index.cjs.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../src/index.ts"],"sourcesContent":["import { type AutotoolPlugin, type AutotoolPluginObject } from 'autotool-plugin';\nimport { join } from 'node:path';\nimport packageJson from '../package.json';\n\nexport const plugin: AutotoolPlugin = (_options): AutotoolPluginObject => {\n\treturn {\n\t\tname: packageJson.name,\n\t\telements: [\n\t\t\t{\n\t\t\t\tdescription: 'workspace test scripts and devDependencies',\n\t\t\t\texecutor: 'packageJson',\n\t\t\t\tpackageKind: 'root',\n\t\t\t\tdata: {\n\t\t\t\t\tscripts: {\n\t\t\t\t\t\ttest: 'turbo run test_ --concurrency 16 --cache-dir .cache/turbo',\n\t\t\t\t\t\t'merge-coverage':\n\t\t\t\t\t\t\t'merge-workspace-lcov-reports && lcov-viewer lcov -o ./coverage ./coverage/lcov.info',\n\t\t\t\t\t},\n\t\t\t\t\tdevDependencies: {\n\t\t\t\t\t\t'@vitest/coverage-c8': undefined, // TODO: remove once cascaded\n\t\t\t\t\t\t'@vitest/coverage-v8': packageJson.devDependencies['@vitest/coverage-v8'],\n\t\t\t\t\t\t'@lcov-viewer/cli': packageJson.devDependencies['@lcov-viewer/cli'],\n\t\t\t\t\t\t'@alexaegis/coverage-tools':\n\t\t\t\t\t\t\tpackageJson.dependencies['@alexaegis/coverage-tools'],\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package test scripts',\n\t\t\t\texecutor: 'packageJson',\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tdata: {\n\t\t\t\t\tscripts: {\n\t\t\t\t\t\ttest: 'turbo run test_ --concurrency 16 --cache-dir .cache/turbo --filter ${packageName}',\n\t\t\t\t\t\ttest_: 'vitest --passWithNoTests --coverage --run',\n\t\t\t\t\t\t'test:watch': 'vitest --passWithNoTests --coverage',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package test devDependencies',\n\t\t\t\texecutor: 'packageJson',\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tname: /^(?!@alexaegis\\/vite(st)?).*$/, // Don't add it for itself and 'vite' it would cause a circle\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tdata: {\n\t\t\t\t\tdevDependencies: {\n\t\t\t\t\t\t'@alexaegis/vitest': packageJson.devDependencies['@alexaegis/vitest'],\n\t\t\t\t\t\tvitest: packageJson.devDependencies.vitest,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package vitest config file for web packages',\n\t\t\t\texecutor: 'fileCopy',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t\tplatform: 'web',\n\t\t\t\t\t\tframework: /^(?!svelte).*$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tformatWithPrettier: true,\n\t\t\t\tsourceFile: join('static', 'package-web-vitest.config.ts'),\n\t\t\t\ttargetFile: 'vitest.config.ts',\n\t\t\t\tsourcePluginPackageName: packageJson.name,\n\t\t\t},\n\n\t\t\t{\n\t\t\t\tdescription: 'package vitest config file for node packages',\n\t\t\t\texecutor: 'fileCopy',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t\tplatform: 'node',\n\t\t\t\t\t\tframework: /^(?!svelte).*$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tformatWithPrettier: true,\n\t\t\t\tsourceFile: join('static', 'package-node-vitest.config.ts'),\n\t\t\t\ttargetFile: 'vitest.config.ts',\n\t\t\t\tsourcePluginPackageName: packageJson.name,\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package vitest config file for svelte packages',\n\t\t\t\texecutor: 'fileCopy',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t\tframework: 'svelte',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tformatWithPrettier: true,\n\t\t\t\tsourceFile: join('static', 'package-svelte-vitest.config.ts'),\n\t\t\t\ttargetFile: 'vitest.config.ts',\n\t\t\t\tsourcePluginPackageName: packageJson.name,\n\t\t\t},\n\t\t],\n\t};\n};\n\nexport default plugin;\n"],"names":["join"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIa,MAAA,SAAyB,CAAC,aAAmC;AAClE,SAAA;AAAA,IACN,MAAM,YAAY;AAAA,IAClB,UAAU;AAAA,MACT;AAAA,QACC,aAAa;AAAA,QACb,UAAU;AAAA,QACV,aAAa;AAAA,QACb,MAAM;AAAA,UACL,SAAS;AAAA,YACR,MAAM;AAAA,YACN,kBACC;AAAA,UACF;AAAA,UACA,iBAAiB;AAAA,YAChB,uBAAuB;AAAA;AAAA,YACvB,uBAAuB,YAAY,gBAAgB,qBAAqB;AAAA,YACxE,oBAAoB,YAAY,gBAAgB,kBAAkB;AAAA,YAClE,6BACC,YAAY,aAAa,2BAA2B;AAAA,UACtD;AAAA,QACD;AAAA,MACD;AAAA,MACA;AAAA,QACC,aAAa;AAAA,QACb,UAAU;AAAA,QACV,aAAa;AAAA,QACb,mBAAmB;AAAA,UAClB,WAAW;AAAA,YACV,MAAM;AAAA,UACP;AAAA,QACD;AAAA,QACA,MAAM;AAAA,UACL,SAAS;AAAA,YACR,MAAM;AAAA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,MACtC;AAAA,IACD;AAAA,EAAA;AAEF;;;"}
|
package/index.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../src/index.ts"],"sourcesContent":["import { type AutotoolPlugin, type AutotoolPluginObject } from 'autotool-plugin';\nimport { join } from 'node:path';\nimport packageJson from '../package.json';\n\nexport const plugin: AutotoolPlugin = (_options): AutotoolPluginObject => {\n\treturn {\n\t\tname: packageJson.name,\n\t\telements: [\n\t\t\t{\n\t\t\t\tdescription: 'workspace test scripts and devDependencies',\n\t\t\t\texecutor: 'packageJson',\n\t\t\t\tpackageKind: 'root',\n\t\t\t\tdata: {\n\t\t\t\t\tscripts: {\n\t\t\t\t\t\ttest: 'turbo run test_ --concurrency 16 --cache-dir .cache/turbo',\n\t\t\t\t\t\t'merge-coverage':\n\t\t\t\t\t\t\t'merge-workspace-lcov-reports && lcov-viewer lcov -o ./coverage ./coverage/lcov.info',\n\t\t\t\t\t},\n\t\t\t\t\tdevDependencies: {\n\t\t\t\t\t\t'@vitest/coverage-c8': undefined, // TODO: remove once cascaded\n\t\t\t\t\t\t'@vitest/coverage-v8': packageJson.devDependencies['@vitest/coverage-v8'],\n\t\t\t\t\t\t'@lcov-viewer/cli': packageJson.devDependencies['@lcov-viewer/cli'],\n\t\t\t\t\t\t'@alexaegis/coverage-tools':\n\t\t\t\t\t\t\tpackageJson.dependencies['@alexaegis/coverage-tools'],\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package test scripts',\n\t\t\t\texecutor: 'packageJson',\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tdata: {\n\t\t\t\t\tscripts: {\n\t\t\t\t\t\ttest: 'turbo run test_ --concurrency 16 --cache-dir .cache/turbo --filter ${packageName}',\n\t\t\t\t\t\ttest_: 'vitest --passWithNoTests --coverage --run',\n\t\t\t\t\t\t'test:watch': 'vitest --passWithNoTests --coverage',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package test devDependencies',\n\t\t\t\texecutor: 'packageJson',\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tname: /^(?!@alexaegis\\/vite(st)?).*$/, // Don't add it for itself and 'vite' it would cause a circle\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tdata: {\n\t\t\t\t\tdevDependencies: {\n\t\t\t\t\t\t'@alexaegis/vitest': packageJson.devDependencies['@alexaegis/vitest'],\n\t\t\t\t\t\tvitest: packageJson.devDependencies.vitest,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package vitest config file for web packages',\n\t\t\t\texecutor: 'fileCopy',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t\tplatform: 'web',\n\t\t\t\t\t\tframework: /^(?!svelte).*$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tformatWithPrettier: true,\n\t\t\t\tsourceFile: join('static', 'package-web-vitest.config.ts'),\n\t\t\t\ttargetFile: 'vitest.config.ts',\n\t\t\t\tsourcePluginPackageName: packageJson.name,\n\t\t\t},\n\n\t\t\t{\n\t\t\t\tdescription: 'package vitest config file for node packages',\n\t\t\t\texecutor: 'fileCopy',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t\tplatform: 'node',\n\t\t\t\t\t\tframework: /^(?!svelte).*$/,\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tformatWithPrettier: true,\n\t\t\t\tsourceFile: join('static', 'package-node-vitest.config.ts'),\n\t\t\t\ttargetFile: 'vitest.config.ts',\n\t\t\t\tsourcePluginPackageName: packageJson.name,\n\t\t\t},\n\t\t\t{\n\t\t\t\tdescription: 'package vitest config file for svelte packages',\n\t\t\t\texecutor: 'fileCopy',\n\t\t\t\tpackageJsonFilter: {\n\t\t\t\t\tarchetype: {\n\t\t\t\t\t\tkind: /^(app|lib)$/,\n\t\t\t\t\t\tframework: 'svelte',\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\tpackageKind: 'regular',\n\t\t\t\tformatWithPrettier: true,\n\t\t\t\tsourceFile: join('static', 'package-svelte-vitest.config.ts'),\n\t\t\t\ttargetFile: 'vitest.config.ts',\n\t\t\t\tsourcePluginPackageName: packageJson.name,\n\t\t\t},\n\t\t],\n\t};\n};\n\nexport default plugin;\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIa,MAAA,SAAyB,CAAC,aAAmC;AAClE,SAAA;AAAA,IACN,MAAM,YAAY;AAAA,IAClB,UAAU;AAAA,MACT;AAAA,QACC,aAAa;AAAA,QACb,UAAU;AAAA,QACV,aAAa;AAAA,QACb,MAAM;AAAA,UACL,SAAS;AAAA,YACR,MAAM;AAAA,YACN,kBACC;AAAA,UACF;AAAA,UACA,iBAAiB;AAAA,YAChB,uBAAuB;AAAA;AAAA,YACvB,uBAAuB,YAAY,gBAAgB,qBAAqB;AAAA,YACxE,oBAAoB,YAAY,gBAAgB,kBAAkB;AAAA,YAClE,6BACC,YAAY,aAAa,2BAA2B;AAAA,UACtD;AAAA,QACD;AAAA,MACD;AAAA,MACA;AAAA,QACC,aAAa;AAAA,QACb,UAAU;AAAA,QACV,aAAa;AAAA,QACb,mBAAmB;AAAA,UACl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