1CARGO-LOCATE-PROJECT(1) CARGO-LOCATE-PROJECT(1)
2
3
4
6 cargo-locate-project - Print a JSON representation of a Cargo.toml
7 file's location
8
10 cargo locate-project [OPTIONS]
11
13 This command will print a JSON object to stdout with the full path to
14 the Cargo.toml manifest.
15
16 See also cargo-metadata(1) which is capable of returning the path to a
17 workspace root.
18
20 Display Options
21 -v, --verbose
22 Use verbose output. May be specified twice for "very verbose"
23 output which includes extra output such as dependency warnings and
24 build script output. May also be specified with the term.verbose
25 config value
26 <https://doc.rust-lang.org/cargo/reference/config.html>.
27
28 -q, --quiet
29 No output printed to stdout.
30
31 --color WHEN
32 Control when colored output is used. Valid values:
33
34 · auto (default): Automatically detect if color support is
35 available on the terminal.
36
37 · always: Always display colors.
38
39 · never: Never display colors.
40
41 May also be specified with the term.color config value
42 <https://doc.rust-lang.org/cargo/reference/config.html>.
43
44 Manifest Options
45 --manifest-path PATH
46 Path to the Cargo.toml file. By default, Cargo searches for the
47 Cargo.toml file in the current directory or any parent directory.
48
49 Common Options
50 -h, --help
51 Prints help information.
52
53 -Z FLAG...
54 Unstable (nightly-only) flags to Cargo. Run cargo -Z help for
55 details.
56
58 See the reference
59 <https://doc.rust-lang.org/cargo/reference/environment-variables.html>
60 for details on environment variables that Cargo reads.
61
63 0
64 Cargo succeeded.
65
66 101
67 Cargo failed to complete.
68
70 1. Display the path to the manifest based on the current directory:
71
72 cargo locate-project
73
75 cargo(1), cargo-metadata(1)
76
77
78
79 2019-09-05 CARGO-LOCATE-PROJECT(1)