LoadGitignorePatterns reads and parses .gitignore patterns from the given repository root. Returns nil if the file is missing or unreadable.
(repoDir string)
| 63 | // LoadGitignorePatterns reads and parses .gitignore patterns from the given |
| 64 | // repository root. Returns nil if the file is missing or unreadable. |
| 65 | func LoadGitignorePatterns(repoDir string) []string { |
| 66 | stub := &Provider{repoDir: repoDir} |
| 67 | return stub.loadGitignorePatterns() |
| 68 | } |
| 69 | |
| 70 | // IsPathExcluded returns true when relPath matches any of the supplied |
| 71 | // gitignore-style patterns or any default excluded directory prefix |