Can I specify that Cargo’s Git dependencies fetch with `--depth 1`?

After a quick search, it seems the answer is no for the current version of Cargo, so I posted this question on IRLO.

Since I need to use cksumvfs—a feature not yet officially supported by rusqlite—I created a fork of rusqlite and tried to add the Git repository URL of that fork to the project’s dependencies. However, since rusqlite is a relatively large project, Cargo appears to fetch the entire history, which significantly slows down the first compilation. This is just a repository with a history of tens of megabytes in size—I can’t even imagine how slow and space-consuming it would be if the repository were hundreds of megabytes or even gigabytes in size. Therefore, using --depth 1 or fetching only the specific commit needed might be a better option.

We want this too but have generally been limited by libgit2.

We have unstable support at Unstable Features - The Cargo Book

Small correction: originally we were limited by a git hosting service advising us against it because of the server load involved with different aspects of the protocol. They no longer raise that objection and so it has just been libgit2.