Relative Content

Tag Archive for rustrust-cargo

How to cache Cargo packages in the Github CI workflow?

I have a GitHub CI that uses a Cargo package. But each time, CI is run, it takes approx. 6 minutes to build the package. Is there a way to cache the binary so that on the next run, it does not have to build it again?

When to set a dependencies to optional in Rust cargo.toml?

I am a novice of rust and try to read some projects for studying. In this binance api connector rust project. Some dependencies are set to be optional but others not. What is the considerations that some dependencies should be set to optional while others not?

Using Rust cargo in Visual Studio Cde. Error: Unable to execute: “sh” “-c” “../gmp-src/configure –enable-fat –disable-shared –with-pic”

I am very new to coding with Rust, so I might not understand many things yet. Among other crates, I have been trying to install the Symbolica crate to use in my project. Up to this point, there has not been any problem at all when installing all other crates. The way I have been doing so is by inputting name_of_crate = "version". When saving the file, the rust analyzer has been building automatically. But when I attempt to install Symbolica, it has been different. It gives me the following error:

How do I tell Cargo to update dependencies beyond the current versions of my project?

I have a simple project that relies on pyo3. Currently/previously, it was using version 0.20.0, but recently a new version has landed which is version 0.21.2. I am looking for a Cargo command that will update the dependency, even if that then means I have to go back through the source and fix any breaking changes that were introduced. However, if I run:

How do determine which crate is using which version is a Cargo.lock file?

I’m trying to start up a project that uses an STM32, LVGL Rust bindings, and a Gc9a01. The LVGL binding provides a callback function that passes an DisplayRefresh object that has the area of the screen to render to, and a method called .into_pixels<C>() where C is the pixel color format, in this case Rgb565.