diff options
| author | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2026-02-13 19:32:15 +1100 |
|---|---|---|
| committer | Brad Lewis <22850972+BradLewis@users.noreply.github.com> | 2026-02-13 19:32:15 +1100 |
| commit | 4da5fac453c0e902a75a0cf0455088d06bc43ec6 (patch) | |
| tree | 36c01eb3b9ba57856625060d770dc764d549c22a | |
| parent | d828854b608c184077dfef15e447b4c952f01406 (diff) | |
Fix workspace symbols search with os changes
| -rw-r--r-- | src/server/workspace_symbols.odin | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/server/workspace_symbols.odin b/src/server/workspace_symbols.odin index f732e8b..de346d1 100644 --- a/src/server/workspace_symbols.odin +++ b/src/server/workspace_symbols.odin @@ -11,8 +11,8 @@ import "src:common" dir_blacklist :: []string{"node_modules", ".git"} WorkspaceCache :: struct { - time: time.Time, - pkgs: [dynamic]string, + time: time.Time, + pkgs: [dynamic]string, } @(thread_local, private = "file") @@ -32,12 +32,13 @@ get_workspace_symbols :: proc(query: string) -> (workspace_symbols: []WorkspaceS defer os.walker_destroy(&w) for info in os.walker_walk(&w) { if info.type == .Directory { - dir := filepath.dir(info.fullpath, context.temp_allocator) + dir := strings.clone(info.fullpath, context.temp_allocator) dir_name := filepath.base(dir) found := false for blacklist in dir_blacklist { if blacklist == dir_name { found = true + os.walker_skip_dir(&w) break } } |