# tasks: Add experimental support for user-defined task variables \(\#13699\) · gitcafe/zed

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

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

Visibility: public

Requested revision: bac6e2fee77e612b38062ee2ebeed702447e397a

Requested commit: bac6e2fee77e612b38062ee2ebeed702447e397a

Commit: bac6e2fee77e612b38062ee2ebeed702447e397a

Tree: c88dec7a412894ba1e45527733a2a2d135a531f3

Author: Piotr Osiewicz

Committer: GitHub

## Message

```
tasks: Add experimental support for user-defined task variables (#13699)

Context:
@bennetbo spotted a regression in handling of `cargo run` task in zed
repo following a merge of #13658. We've started invoking `cargo run`
from the folder of an active file whereas previously we did it from the
workspace root. We brainstormed few solutions that involved adding a
separate task that gets invoked at a workspace level, but I realized
that a cleaner solution may be to finally add user-configured task
variables. This way, we can choose which crate to run by default at a
workspace level.

This has been originally brought up in the context of javascript tasks
in
https://github.com/zed-industries/zed/pull/12118#issuecomment-2129232114

Note that this is intended for internal use only for the time being.
/cc @RemcoSmitsDev we should be unblocked on having runner-dependant
tasks now.

Release notes:

- N/A
```

## Parents

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

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