# task: Skip \.vscode tasks when \.zed/tasks.json exists \(\#51797\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/2315856b3f409c16bfa1c32a75385a7417c3f23d)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: 2315856b3f409c16bfa1c32a75385a7417c3f23d

Requested commit: 2315856b3f409c16bfa1c32a75385a7417c3f23d

Commit: 2315856b3f409c16bfa1c32a75385a7417c3f23d

Tree: dfa50ededdb7bf36f7322b8bf6161d7e1b8b4f8e

Author: moktamd

Committer: GitHub

## Message

```
task: Skip .vscode tasks when .zed/tasks.json exists (#51797)

Fixes #51733

The previous fix in #32590 only filtered `.vscode` tasks at the modal
presentation layer, so they still appeared in other code paths and in
the used-tasks list. This moves the filtering into
`worktree_scenarios()` in the task inventory, so all consumers see the
correct behavior.

Changes:
- `InventoryFor::worktree_scenarios()` now skips `.vscode` entries when
`.zed` entries exist for the same worktree
- `used_and_current_resolved_tasks()` filters previously spawned
`.vscode` tasks from the used-tasks list
- Removes the now-redundant `.vscode` filter from the task picker modal

Release Notes:

- Fixed .vscode/tasks.json still being used when .zed/tasks.json is
present

Co-authored-by: moktamd <moktamd@users.noreply.github.com>
```

## Parents

- [e9d1419c23f05325049c3dfe9742f627914a1e6c](https://git.cafe/gitcafe/zed/commit/e9d1419c23f05325049c3dfe9742f627914a1e6c?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/2315856b3f409c16bfa1c32a75385a7417c3f23d?format=markdown)
