{{#option “--lockfile-path
PATH”}} Changes the path of the lockfile from the default (<workspace_root>/Cargo.lock
) to PATH. PATH must end with Cargo.lock
(e.g. --lockfile-path /tmp/temporary-lockfile/Cargo.lock
). Note that providing --lockfile-path
will ignore existing lockfile at the default path, and instead will either use the lockfile from PATH, or write a new lockfile into the provided PATH if it doesn't exist. This flag can be used to run most commands in read-only directories, writing lockfile into the provided PATH.
This option is only available on the nightly channel and requires the -Z unstable-options
flag to enable (see #14421). {{/option}}