You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ cargo make print-target-dir[cargo-make] INFO - cargo make 0.32.17[cargo-make] INFO - Project: project[cargo-make] INFO - Build File: Makefile.toml[cargo-make] INFO - Task: print-target-dir[cargo-make] INFO - Profile: development[cargo-make] INFO - Running Task: print-target-dirTarget Dir: target[cargo-make] INFO - Build Done in 0.03 seconds.
Found target: (equivalent to) /path/to/workspace/project/target
Expected target: /path/to/workspace/target
The expected target can be found by running cargo metadata, in key target_directory:
$ cargo metadata --format-version 1 --no-deps
(Possible) Solution
I would personally suggest using cargo metadata to get the target directory, instead of trying to guess it by manually looking at the environment.
The text was updated successfully, but these errors were encountered:
@ark0f worth to check suggestion from @pheki before pushing #554
i actually already trigger cargo metadata as part of the flow so we can use this info as suggeted.
Describe The Bug
If a crate is in a workspace, CARGO_MAKE_CRATE_TARGET_DIRECTORY will still be in the current directory instead of the root of the workspace
To Reproduce
$ mkdir workspace $ cd workspace $ cargo new project
\
before$
if you're editing the file manually)print-target-dir
task for projectOutput
Found target: (equivalent to)
/path/to/workspace/project/target
Expected target:
/path/to/workspace/target
The expected target can be found by running
cargo metadata
, in keytarget_directory
:(Possible) Solution
I would personally suggest using cargo metadata to get the target directory, instead of trying to guess it by manually looking at the environment.
The text was updated successfully, but these errors were encountered: