guard against missing project directory

This commit is contained in:
Wendy Smoak 2026-02-15 10:12:49 -05:00
parent b318d9242e
commit 64e5a9c696
1 changed files with 3 additions and 0 deletions

View File

@ -321,6 +321,9 @@ class CodexSetup extends BaseIdeSetup {
if (location === 'project' && projectDir) {
return path.join(projectDir, '.agents', 'skills');
}
if (location === 'project' && !projectDir) {
throw new Error('projectDir is required for project-scoped skill installation');
}
return path.join(os.homedir(), '.agents', 'skills');
}