Fix hasActionsWorkflows throwing if workflows folder doesn't exist

This commit is contained in:
Michael B. Gale
2025-09-05 21:11:33 +01:00
parent ab82675d3b
commit e045f5eeb4
2 changed files with 2 additions and 2 deletions

View File

@@ -341,7 +341,7 @@ const baseWorkflowsPath = ".github/workflows";
*/
export function hasActionsWorkflows(sourceRoot: string): boolean {
const workflowsPath = path.resolve(sourceRoot, baseWorkflowsPath);
const stats = fs.lstatSync(workflowsPath);
const stats = fs.lstatSync(workflowsPath, { throwIfNoEntry: false });
return (
stats !== undefined &&
stats.isDirectory() &&