From d71b2bc5dfd1e3b840e705053be5a0b3e0967827 Mon Sep 17 00:00:00 2001 From: Lin Yihai Date: Fri, 22 Dec 2023 07:02:26 +0800 Subject: [PATCH] chore(doc): doc for custom subcommands --- src/doc/src/reference/external-tools.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/doc/src/reference/external-tools.md b/src/doc/src/reference/external-tools.md index bb379aeb046..d4338879f45 100644 --- a/src/doc/src/reference/external-tools.md +++ b/src/doc/src/reference/external-tools.md @@ -265,6 +265,10 @@ cargo `(?[^ ]+)` into an invocation of an external tool `cargo-${command}`. The external tool must be present in one of the user's `$PATH` directories. +> **Note**: Cargo defaults to prioritizing external tools in `$CARGO_HOME/bin` +> over `$PATH`. Users can override this precedence by adding `$CARGO_HOME/bin` +> to `$PATH`. + When Cargo invokes a custom subcommand, the first argument to the subcommand will be the filename of the custom subcommand, as usual. The second argument will be the subcommand name itself. For example, the second argument would be