Skip to content

Commit ca03fd8

Browse files
committedJul 11, 2024·
Include additional workspaces when loading manifests (resolves #722)
1 parent deeb2ac commit ca03fd8

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed
 

‎packages/knip/src/ConfigurationChief.ts

+4-2
Original file line numberDiff line numberDiff line change
@@ -229,12 +229,14 @@ export class ConfigurationChief {
229229
private async setWorkspaces() {
230230
this.ignoredWorkspacePatterns = this.getIgnoredWorkspacePatterns();
231231

232-
const [byName, byPkgName] = await mapWorkspaces(this.cwd, this.getListedWorkspaces());
232+
this.additionalWorkspaceNames = await this.getAdditionalWorkspaceNames();
233+
const workspaceNames = compact([...this.getListedWorkspaces(), ...this.additionalWorkspaceNames]);
234+
const [byName, byPkgName] = await mapWorkspaces(this.cwd, workspaceNames);
235+
233236
this.workspacePackages = byName;
234237
this.workspacePackagesByName = byPkgName;
235238
this.addRootPackage();
236239

237-
this.additionalWorkspaceNames = await this.getAdditionalWorkspaceNames();
238240
this.availableWorkspaceNames = this.getAvailableWorkspaceNames(byName.keys());
239241
this.availableWorkspacePkgNames = this.getAvailableWorkspacePkgNames(byPkgName.keys());
240242
this.availableWorkspaceDirs = this.availableWorkspaceNames

0 commit comments

Comments
 (0)
Please sign in to comment.