1
0
mirror of https://github.com/google/comprehensive-rust.git synced 2025-08-11 01:12:11 +02:00

Make install-tools command work from any directory in the workspace. (#2725)

This fixes #2708 by creating a CARGO_WORKSPACE_DIR env variable to act
as an anchor path, allowing the installation of mdbook-exerciser and
mdbook-course to succeed from any directory within the repository. Based
on the approach mentioned here:
https://github.com/rust-lang/cargo/issues/3946#issuecomment-973132993

---------

Co-authored-by: Eric Githinji <egithinji@google.com>
This commit is contained in:
Eric Githinji
2025-05-06 09:55:55 +03:00
committed by GitHub
parent d0d8168c56
commit 291c2b08e3
2 changed files with 16 additions and 3 deletions

View File

@@ -2,3 +2,8 @@
# We use this alias for task automation in the project.
# See README in xtask directory.
xtask = "run --package xtask --"
[env]
# To provide an anchor to the root of the workspace when working with paths.
# See https://github.com/rust-lang/cargo/issues/3946#issuecomment-973132993
CARGO_WORKSPACE_DIR = { value = "", relative = true }