We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d40feaf commit bcfa63aCopy full SHA for bcfa63a
1 file changed
packages/opencode/src/file/index.ts
@@ -276,11 +276,16 @@ export namespace File {
276
const project = Instance.project
277
let ignored = (_: string) => false
278
if (project.vcs === "git") {
279
+ const ig = ignore()
280
const gitignore = Bun.file(path.join(Instance.worktree, ".gitignore"))
281
if (await gitignore.exists()) {
- const ig = ignore().add(await gitignore.text())
282
- ignored = ig.ignores.bind(ig)
+ ig.add(await gitignore.text())
283
}
284
+ const ignoreFile = Bun.file(path.join(Instance.worktree, ".ignore"))
285
+ if (await ignoreFile.exists()) {
286
+ ig.add(await ignoreFile.text())
287
+ }
288
+ ignored = ig.ignores.bind(ig)
289
290
const resolved = dir ? path.join(Instance.directory, dir) : Instance.directory
291
const nodes: Node[] = []
0 commit comments