treated as the start of the `<cargo-opts>`.
* `<cargo-opts>` are terminated by `--` (which is removed) or the
- first argument which does not start with a `-`.
+ first argument which does not start with a `-` or `+`.
(It is not possible to get nailing-cargo to pass the value `--`
as a separate argument to a cargo global option, but cargo global
then in the builtin arch alias list. The builtin list is
equivalent to:
- ```
+```
[arch]
RPI="arm-unknown-linux-gnueabihf"
WASM="wasm32-unknown-unknown"
- ```
+```
* `-o` | `--online` | `-O` | `--offline`
* `lock_update`: cargo will want to update `Cargo.lock`. (The `-u` and `-U` options override this.)
* `online`: this subcommand makes no sense to run offline. (The `-o` and `-O` options, and the configuration, can override this.)
- * `edits`: The purpose of this subcommand is to edit the source tree. Enables `--edit-sources` mode.
+ * `edits`: The purpose of this subcommand is to edit the source tree. Produces warning if `--edit-sources` mode not specified.
* `!target`: cargo would reject `--target=<arch>`; in this case nailing-cargo's `-T` option is ineffective.
* `!target-dir`: cargo would reject `--target-dir`, so don't pass it. (Usually we pass `--target-dir=target` when we pass `--manifest-path`, since cargo's default is `target` in the same directory as `Cargo.toml`.)
+ * `linkfarm-shallow`: Make the default be `--linkfarm=shallow`. This is the default for `miri` and can also be used for other subcommands which do not understandg `--manifest-path` properly.
+ * `linkfarm-gitclean`: Make the defaults be `--linkfarm=git` and `--preclean-build=src`.
There are also some properties which should not be needed, but are
provided for completeness. Do not use these to solve the problem
nailing-cargo thinks cargo is going to update `Cargo.lock`.
* `git`: Make a deep linkfarm, with subdirectories. Symlink
- those objects tracked by git.
+ those objects tracked by git. This is the default for
+ `cargo publish`.
- * `git`: Make a deep linkfarm and symlink every nondirectory found
+ * `full`: Make a deep linkfarm and symlink every nondirectory found
in the source tree. This will including all sorts of junk,
including for example editor backup files.
lockfile update, controls whether the linkfarm is kept afterwards.
Overrides the `oot.clean` config option. (Default: keep.)
+ * `--[no-]preclean-build[=no|src|full]`: When doing an out-of-tree
+ build, controls whether the build directory is purged of leftover
+ contents *before* the build is run. The usual default is `no`.
+ For `cargo publish`, the default is `src`, which deletes
+ everything except the directory `target`. `full` means to clean
+ out that too.
+
* `--leave-nailed`: At the end, leave all the `Cargo.toml` files in
their edited state, rather than (trying to) clean them up. To
clean this up later, run `nailing-cargo` again without this option.