diff options
| author | Adam <[email protected]> | 2025-09-02 06:20:08 -0500 |
|---|---|---|
| committer | Adam <[email protected]> | 2025-09-02 06:20:08 -0500 |
| commit | 97a41062c93059ff362080b7563354773b2643fb (patch) | |
| tree | 6322daf168880c8a8fa47a8c4e3ba873779aefa0 | |
| parent | 4a76224268f012ff7c22754e4eb624f151c05fe5 (diff) | |
| download | opencode-97a41062c93059ff362080b7563354773b2643fb.tar.gz opencode-97a41062c93059ff362080b7563354773b2643fb.zip | |
fix: file.list relative to root
| -rw-r--r-- | packages/opencode/src/file/index.ts | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/packages/opencode/src/file/index.ts b/packages/opencode/src/file/index.ts index a6dd08a80..fd846444a 100644 --- a/packages/opencode/src/file/index.ts +++ b/packages/opencode/src/file/index.ts @@ -154,13 +154,12 @@ export namespace File { if (exclude.includes(entry.name)) continue const fullPath = path.join(resolved, entry.name) const relativePath = path.relative(Instance.directory, fullPath) - const relativeToRoot = path.relative(Instance.worktree, fullPath) const type = entry.isDirectory() ? "directory" : "file" nodes.push({ name: entry.name, path: relativePath, type, - ignored: ignored(type === "directory" ? relativeToRoot + "/" : relativeToRoot), + ignored: ignored(type === "directory" ? relativePath + "/" : relativePath), }) } return nodes.sort((a, b) => { |
