-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.projenrc.ts
78 lines (69 loc) · 1.98 KB
/
.projenrc.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
import { cdk, javascript, TextFile } from "projen";
import { Vitest } from "./src";
const nodeVersion = "22.12.0";
const project = new cdk.JsiiProject({
author: "Niko Virtala",
authorAddress: "[email protected]",
defaultReleaseBranch: "main",
deps: ["projen"],
description: "Vitest component for projen Node.js projects",
dependabot: false,
depsUpgradeOptions: {
workflowOptions: {
labels: ["auto-approve", "auto-merge"],
},
},
autoApproveOptions: {
secret: "GITHUB_TOKEN",
allowedUsernames: ["nikovirtala"],
},
mergify: true,
autoMerge: true,
jest: false,
jsiiVersion: "~5.7.0",
license: "MIT",
licensed: true,
majorVersion: 1,
minNodeVersion: nodeVersion,
name: "projen-vitest",
npmAccess: javascript.NpmAccess.PUBLIC,
packageManager: javascript.NodePackageManager.PNPM,
packageName: "@nikovirtala/projen-vitest",
peerDeps: ["projen", "constructs"],
pnpmVersion: "9",
prettier: true,
prettierOptions: {
settings: {
printWidth: 120,
tabWidth: 4,
trailingComma: javascript.TrailingComma.ALL,
},
},
projenrcTs: true,
releaseToNpm: true,
repositoryUrl: "https://github.com/nikovirtala/projen-vitest.git",
typescriptVersion: "5.7.2",
});
project.eslint?.addOverride({
files: ["*"],
rules: {
"import/no-extraneous-dependencies": ["warn"],
},
});
project.npmrc.addConfig("node-linker", "hoisted");
new Vitest(project);
project.vscode?.extensions.addRecommendations("dbaeumer.vscode-eslint", "esbenp.prettier-vscode");
project.vscode?.settings.addSettings({
"editor.codeActionsOnSave": {
"source.fixAll": "explicit",
},
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true,
"editor.tabSize": 4,
});
new TextFile(project, ".nvmrc", {
committed: true,
readonly: true,
lines: ["v" + nodeVersion],
});
project.synth();