ZIm/crates/tasks_ui
Dhruvin Gandhi ae076fa415
task: Add ZED_RELATIVE_DIR task variable (#31657)
This is my first contribution to zed, let me know if I missed anything.

There is no corresponding issue/discussion.

`$ZED_RELATIVE_DIR` can be used in cases where a task's command's
filesystem namespace (e.g. inside a container) is different than the
host, where absolute paths cannot work.

I modified `relative_path` to `relative_file` after the addition of
`relative_dir`.

For top-level files, where `relative_file.parent() == Some("")`, I use
`"."` for `$ZED_RELATIVE_DIR`, which is a valid relative path in both
*nix and windows.

Thank you for building zed, and open-sourcing it. I hope to contribute
more as I use it as my primary editor.

Release Notes:

- Added ZED_RELATIVE_DIR (path to current file's directory relative to
worktree root) task variable.
2025-05-29 11:50:36 +02:00
..
src task: Add ZED_RELATIVE_DIR task variable (#31657) 2025-05-29 11:50:36 +02:00
Cargo.toml debugger: Add console indicator and resolve debug configs from NewSessionModal (#28489) 2025-04-10 22:29:03 +00:00
LICENSE-GPL Rename runnables into tasks (#8119) 2024-02-21 14:56:43 +02:00