Skip to content

Commit 0bfe033

Browse files
feat: remove ts-prune config files in blockKnip (#2299)
## PR Checklist - [x] Addresses an existing open issue: fixes #2126 - [x] That issue was marked as [`status: accepting prs`](https://github.com/JoshuaKGoldberg/create-typescript-app/issues?q=is%3Aopen+is%3Aissue+label%3A%22status%3A+accepting+prs%22) - [x] Steps in [CONTRIBUTING.md](https://github.com/JoshuaKGoldberg/create-typescript-app/blob/main/.github/CONTRIBUTING.md) were taken ## Overview 🎁
1 parent 32ddd74 commit 0bfe033

File tree

4 files changed

+23
-5
lines changed

4 files changed

+23
-5
lines changed

cspell.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
"joshuakgoldberg",
2121
"mshick",
2222
"octoguide",
23-
"stefanzweifel"
23+
"stefanzweifel",
24+
"ts-prunerc"
2425
]
2526
}

src/blocks/blockKnip.test.ts

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,14 @@ describe("blockKnip", () => {
5959
},
6060
"block": [Function],
6161
},
62+
{
63+
"addons": {
64+
"files": [
65+
".ts-prunerc*",
66+
],
67+
},
68+
"block": [Function],
69+
},
6270
],
6371
"files": {
6472
"knip.json": "{"$schema":"https://unpkg.com/knip@5.71.0/schema.json","ignoreExportsUsedInFile":{"interface":true,"type":true}}",
@@ -122,6 +130,14 @@ describe("blockKnip", () => {
122130
},
123131
"block": [Function],
124132
},
133+
{
134+
"addons": {
135+
"files": [
136+
".ts-prunerc*",
137+
],
138+
},
139+
"block": [Function],
140+
},
125141
],
126142
"files": {
127143
"knip.json": "{"$schema":"https://unpkg.com/knip@5.71.0/schema.json","entry":["src/index.ts"],"ignoreDependencies":["abc","def"],"ignoreExportsUsedInFile":{"interface":true,"type":true},"project":["src/**/*.ts"]}",
@@ -184,10 +200,7 @@ describe("blockKnip", () => {
184200
{
185201
"addons": {
186202
"files": [
187-
".knip*",
188-
"knip.{c,m,t}*",
189-
"knip.js",
190-
"knip.jsonc",
203+
".ts-prunerc*",
191204
],
192205
},
193206
"block": [Function],

src/blocks/blockKnip.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ export const blockKnip = base.createBlock({
6868
},
6969
},
7070
}),
71+
blockRemoveFiles({
72+
files: [".ts-prunerc*"],
73+
}),
7174
],
7275
files: {
7376
"knip.json": JSON.stringify({

src/integration.test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ test("Producing the everything preset matches the files in this repository", asy
6767
"mshick",
6868
"octoguide",
6969
"stefanzweifel",
70+
"ts-prunerc",
7071
],
7172
}),
7273
blockESLint({

0 commit comments

Comments
 (0)