fix: Properly ignore ignored folders when generating /onboard context
Signed-off-by: Fred Bricon <fbricon@gmail.com>
This commit is contained in:
parent
d7ef0a3b1b
commit
f7bca6a61d
1 changed files with 5 additions and 2 deletions
|
|
@ -73,7 +73,10 @@ async function getEntriesFilteredByIgnore(dir: string, ide: IDE) {
|
|||
ig = ig.add(igPatterns);
|
||||
}
|
||||
|
||||
const filteredEntries = entries.filter((entry) => !ig.ignores(entry.name));
|
||||
const filteredEntries = entries.filter((entry) => {
|
||||
const name = entry.isDirectory() ? `${entry.name}/` : entry.name;
|
||||
return !ig.ignores(name);
|
||||
});
|
||||
|
||||
return filteredEntries;
|
||||
}
|
||||
|
|
@ -117,7 +120,7 @@ async function gatherProjectContext(
|
|||
|
||||
function createOnboardingPrompt(context: string): string {
|
||||
return `
|
||||
As a helpful AI assistant, your task is to onboard a new developer to this project.
|
||||
As a helpful AI assistant, your task is to onboard a new developer to this project.
|
||||
Use the following context about the project structure, READMEs, and dependency files to create a comprehensive overview:
|
||||
|
||||
${context}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue