diff options
| author | James Munns <[email protected]> | 2024-05-12 21:33:19 +0000 |
|---|---|---|
| committer | GitHub <[email protected]> | 2024-05-12 21:33:19 +0000 |
| commit | 9556e935f1a481d242276716e872215291f03f61 (patch) | |
| tree | f38061934e65acc33d9e125d525140118e34545b | |
| parent | 4cade64ebd34bf93458f17cfe85c5f710d0ff13c (diff) | |
| parent | 61fa95f3539d4e0f645464068b609ce9f2146d91 (diff) | |
Merge pull request #2932 from embassy-rs/jamesmunns-patch-1
FAQ: add `patch.crates-io` example
| -rw-r--r-- | docs/modules/ROOT/pages/faq.adoc | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/docs/modules/ROOT/pages/faq.adoc b/docs/modules/ROOT/pages/faq.adoc index a074594cc..6c7126cd6 100644 --- a/docs/modules/ROOT/pages/faq.adoc +++ b/docs/modules/ROOT/pages/faq.adoc | |||
| @@ -290,3 +290,27 @@ General steps: | |||
| 290 | 5. Copy data to that region before using BDMA. | 290 | 5. Copy data to that region before using BDMA. |
| 291 | 291 | ||
| 292 | See link:/examples/stm32h7/src/bin/spi_bdma.rs[this example] for more details. | 292 | See link:/examples/stm32h7/src/bin/spi_bdma.rs[this example] for more details. |
| 293 | |||
| 294 | === How do I switch to the `main` branch? | ||
| 295 | |||
| 296 | Sometimes to test new changes or fixes, you'll want to switch your project to using a version from GitHub. | ||
| 297 | |||
| 298 | You can add a section to your `Cargo.toml` file like this, you'll need to patch ALL embassy crates to the same revision: | ||
| 299 | |||
| 300 | Using `patch` will replace all direct AND indirect dependencies. | ||
| 301 | |||
| 302 | See the link:https://embassy.dev/book/dev/new_project.html#_cargo_toml[new project docs] for more details on this approach. | ||
| 303 | |||
| 304 | [source,toml] | ||
| 305 | ---- | ||
| 306 | [patch.crates-io] | ||
| 307 | # make sure to get the latest git rev from github, you can see the latest one here: | ||
| 308 | # https://github.com/embassy-rs/embassy/commits/main/ | ||
| 309 | embassy-embedded-hal = { git = "https://github.com/embassy-rs/embassy", rev = "4cade64ebd34bf93458f17cfe85c5f710d0ff13c" } | ||
| 310 | embassy-executor = { git = "https://github.com/embassy-rs/embassy", rev = "4cade64ebd34bf93458f17cfe85c5f710d0ff13c" } | ||
| 311 | embassy-rp = { git = "https://github.com/embassy-rs/embassy", rev = "4cade64ebd34bf93458f17cfe85c5f710d0ff13c" } | ||
| 312 | embassy-sync = { git = "https://github.com/embassy-rs/embassy", rev = "4cade64ebd34bf93458f17cfe85c5f710d0ff13c" } | ||
| 313 | embassy-time = { git = "https://github.com/embassy-rs/embassy", rev = "4cade64ebd34bf93458f17cfe85c5f710d0ff13c" } | ||
| 314 | embassy-usb = { git = "https://github.com/embassy-rs/embassy", rev = "4cade64ebd34bf93458f17cfe85c5f710d0ff13c" } | ||
| 315 | embassy-usb-driver = { git = "https://github.com/embassy-rs/embassy", rev = "4cade64ebd34bf93458f17cfe85c5f710d0ff13c" } | ||
| 316 | ---- | ||
