feat: add ignore filtering to directory listing
- Add `list_directory_filtered` function with ignore logic - Update `default_gitignore` with common VCS and build patterns - Integrate ignore filtering into `Workspace.list_dir` - Rename project to HeroPrompt in README - Update README features and usage descriptions
This commit is contained in:
@@ -222,7 +222,9 @@ pub:
|
||||
}
|
||||
|
||||
pub fn (wsp &Workspace) list_dir(rel_path string) ![]ListItem {
|
||||
items := codewalker.list_directory(wsp.base_path, rel_path)!
|
||||
// Create an ignore matcher with default patterns
|
||||
ignore_matcher := codewalker.gitignore_matcher_new()
|
||||
items := codewalker.list_directory_filtered(wsp.base_path, rel_path, &ignore_matcher)!
|
||||
mut out := []ListItem{}
|
||||
for item in items {
|
||||
out << ListItem{
|
||||
|
||||
Reference in New Issue
Block a user