Skip to content

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

Merged
SomeoneToIgnore merged 1 commit intozed-industries:mainfrom
moktamd:fix/zed-tasks-vscode-precedence
Mar 24, 2026
Merged

task: Skip .vscode tasks when .zed/tasks.json exists#51797
SomeoneToIgnore merged 1 commit intozed-industries:mainfrom
moktamd:fix/zed-tasks-vscode-precedence

Conversation

@moktamd
Copy link
Copy Markdown
Contributor

@moktamd moktamd commented Mar 18, 2026

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

Moves the .vscode task filtering from the modal presentation layer
down into the inventory's worktree_scenarios(), so all consumers
get the correct behavior. Also filters previously spawned .vscode
tasks from the used-tasks list when .zed tasks are present.

The previous fix in zed-industries#32590 only filtered .vscode tasks in the
task picker modal, missing other code paths and the used-tasks list.
@cla-bot
Copy link
Copy Markdown

cla-bot bot commented Mar 18, 2026

We require contributors to sign our Contributor License Agreement, and we don't have @moktamd on file. You can sign our CLA at https://zed.dev/cla. Once you've signed, post a comment here that says '@cla-bot check'.

@zed-community-bot zed-community-bot bot added the first contribution the author's first pull request to Zed. NOTE: the label application is automated via github actions label Mar 18, 2026
@SomeoneToIgnore SomeoneToIgnore self-assigned this Mar 24, 2026
@SomeoneToIgnore
Copy link
Copy Markdown
Contributor

@cla-bot check

@cla-bot cla-bot bot added the cla-signed The user has signed the Contributor License Agreement label Mar 24, 2026
@cla-bot
Copy link
Copy Markdown

cla-bot bot commented Mar 24, 2026

The cla-bot has been summoned, and re-checked this pull request!

Copy link
Copy Markdown
Contributor

@SomeoneToIgnore SomeoneToIgnore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be good to extract all the repeated filtering logic into a shared fn, but nonetheless great PR, thank you!

@SomeoneToIgnore SomeoneToIgnore enabled auto-merge (squash) March 24, 2026 15:11
@SomeoneToIgnore SomeoneToIgnore merged commit 2315856 into zed-industries:main Mar 24, 2026
40 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cla-signed The user has signed the Contributor License Agreement first contribution the author's first pull request to Zed. NOTE: the label application is automated via github actions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

.vscode/tasks.json is used when .zed/tasks.json presents

2 participants