Skip to content

Commit

Permalink
Include gitattributes of ignored folders
Browse files Browse the repository at this point in the history
  • Loading branch information
Nixinova committed Mar 19, 2024
1 parent dbd443e commit 707dec4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/helpers/walk-tree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,12 @@ export default function walk(data: WalkInput): WalkOutput {
ignored.add(ignoredPaths);
}

// Add gitattributes if present
const gitattributesPath = paths.join(folder, '.gitattributes');
if (fs.existsSync(gitattributesPath)) {
allFiles.add(gitattributesPath);
}

// Loop through files and folders
for (const file of files) {
// Create absolute path for disc operations
Expand Down

0 comments on commit 707dec4

Please sign in to comment.