feat: v6.0.0-alpha.0 - the future is now
This commit is contained in:
@@ -6,7 +6,7 @@ const ignore = require('ignore');
|
||||
// These complement .gitignore and are applied regardless of VCS presence.
|
||||
const DEFAULT_PATTERNS = [
|
||||
// Project/VCS
|
||||
'**/.bmad-core/**',
|
||||
'**/.bmad-method/**',
|
||||
'**/.git/**',
|
||||
'**/.svn/**',
|
||||
'**/.hg/**',
|
||||
@@ -154,13 +154,7 @@ async function parseGitignore(gitignorePath) {
|
||||
async function loadIgnore(rootDir, extraPatterns = []) {
|
||||
const ig = ignore();
|
||||
const gitignorePath = path.join(rootDir, '.gitignore');
|
||||
const flattenIgnorePath = path.join(rootDir, '.bmad-flattenignore');
|
||||
const patterns = [
|
||||
...(await readIgnoreFile(gitignorePath)),
|
||||
...DEFAULT_PATTERNS,
|
||||
...(await readIgnoreFile(flattenIgnorePath)),
|
||||
...extraPatterns,
|
||||
];
|
||||
const patterns = [...(await readIgnoreFile(gitignorePath)), ...DEFAULT_PATTERNS, ...extraPatterns];
|
||||
// De-duplicate
|
||||
const unique = [...new Set(patterns.map(String))];
|
||||
ig.add(unique);
|
||||
|
||||
Reference in New Issue
Block a user