From 2673e476077f47b76fa11059122afc73ab09b2cc Mon Sep 17 00:00:00 2001 From: Sergio Gasquez Date: Thu, 8 Aug 2024 10:08:39 +0200 Subject: [PATCH 1/4] build: Use stable in all examples --- advanced/stack-overflow-detection/rust-toolchain.toml | 2 +- intro/blinky/rust-toolchain.toml | 2 +- intro/button-interrupt/rust-toolchain.toml | 2 +- intro/button/rust-toolchain.toml | 2 +- intro/defmt/rust-toolchain.toml | 2 +- intro/dma/rust-toolchain.toml | 2 +- intro/hello-world/rust-toolchain.toml | 2 +- intro/http-client/rust-toolchain.toml | 2 +- intro/panic/rust-toolchain.toml | 2 +- 9 files changed, 9 insertions(+), 9 deletions(-) diff --git a/advanced/stack-overflow-detection/rust-toolchain.toml b/advanced/stack-overflow-detection/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/advanced/stack-overflow-detection/rust-toolchain.toml +++ b/advanced/stack-overflow-detection/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/blinky/rust-toolchain.toml b/intro/blinky/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/intro/blinky/rust-toolchain.toml +++ b/intro/blinky/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/button-interrupt/rust-toolchain.toml b/intro/button-interrupt/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/intro/button-interrupt/rust-toolchain.toml +++ b/intro/button-interrupt/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/button/rust-toolchain.toml b/intro/button/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/intro/button/rust-toolchain.toml +++ b/intro/button/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/defmt/rust-toolchain.toml b/intro/defmt/rust-toolchain.toml index 804e8a7..23c8a7b 100644 --- a/intro/defmt/rust-toolchain.toml +++ b/intro/defmt/rust-toolchain.toml @@ -1,5 +1,5 @@ [toolchain] -channel = "nightly" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/dma/rust-toolchain.toml b/intro/dma/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/intro/dma/rust-toolchain.toml +++ b/intro/dma/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/hello-world/rust-toolchain.toml b/intro/hello-world/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/intro/hello-world/rust-toolchain.toml +++ b/intro/hello-world/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/http-client/rust-toolchain.toml b/intro/http-client/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/intro/http-client/rust-toolchain.toml +++ b/intro/http-client/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] diff --git a/intro/panic/rust-toolchain.toml b/intro/panic/rust-toolchain.toml index 446d6fe..e6c6255 100644 --- a/intro/panic/rust-toolchain.toml +++ b/intro/panic/rust-toolchain.toml @@ -1,4 +1,4 @@ [toolchain] -channel = "nightly-2023-11-14" +channel = "stable" components = ["rust-src"] targets = ["riscv32imc-unknown-none-elf"] From daf4a46576970606dd25a05e9745c49f3848f78e Mon Sep 17 00:00:00 2001 From: Sergio Gasquez Date: Thu, 8 Aug 2024 10:09:13 +0200 Subject: [PATCH 2/4] chore: Update devcontainer to use stable --- .devcontainer/Dockerfile | 4 ++-- .devcontainer/devcontainer.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile index d0e5551..49900fe 100644 --- a/.devcontainer/Dockerfile +++ b/.devcontainer/Dockerfile @@ -7,7 +7,7 @@ ENV LC_ALL=C.UTF-8 ENV LANG=C.UTF-8 ARG CONTAINER_USER=esp ARG CONTAINER_GROUP=esp -ARG NIGHTLY_VERSION=nightly-2023-11-14 +ARG RUST_CHANNEL=stable ARG ESP_BOARD=esp32c3 RUN apt-get update \ @@ -21,7 +21,7 @@ USER ${CONTAINER_USER} WORKDIR /home/${CONTAINER_USER} RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- \ - --default-toolchain ${NIGHTLY_VERSION} -y --profile minimal \ + --default-toolchain ${RUST_CHANNEL} -y --profile minimal \ --component rust-src,clippy,rustfmt --target riscv32imc-unknown-none-elf ENV PATH=${PATH}:$HOME/.cargo/bin diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index e04fd0a..3cb7714 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -6,7 +6,7 @@ "build": { "dockerfile": "Dockerfile", "args": { - "NIGHTLY_VERSION": "nightly-2023-11-14" + "RUST_CHANNEL": "stable" } }, "customizations": { From ae8a06887ae1f1a1b6aef211721208ff35a1a212 Mon Sep 17 00:00:00 2001 From: Sergio Gasquez Date: Thu, 8 Aug 2024 10:09:20 +0200 Subject: [PATCH 3/4] ci: Use stable --- .github/workflows/ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8f7a38e..3e5b143 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -31,7 +31,7 @@ jobs: - uses: dtolnay/rust-toolchain@v1 with: target: riscv32imc-unknown-none-elf - toolchain: nightly + toolchain: stable components: rust-src - run: cargo build --release From 4e53d7abfb3d9c7ec1adfdeff667e164746667e7 Mon Sep 17 00:00:00 2001 From: Sergio Gasquez Date: Thu, 8 Aug 2024 10:09:33 +0200 Subject: [PATCH 4/4] docs: Stable channel installation --- book/src/02_2_software.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/book/src/02_2_software.md b/book/src/02_2_software.md index 1c540d6..49b69c8 100644 --- a/book/src/02_2_software.md +++ b/book/src/02_2_software.md @@ -8,12 +8,11 @@ Follow the steps below for a default installation of the ESP32-C3 platform tooli ✅ If you haven't got Rust on your computer, obtain it via -Furthermore, for ESP32-C3, a [*nightly* version](https://rust-lang.github.io/rustup/concepts/channels.html#working-with-nightly-rust) of the Rust toolchain is currently required, for this training we will use `nightly-2023-11-14` version. -✅ Install *nightly* Rust and add support for the target architecture using the following command: +✅ Install Rust *stable* channel, if you haven't already, and add support for the target architecture using the following command: ```console -rustup toolchain install nightly-2023-11-14 --component rust-src --target riscv32imc-unknown-none-elf +rustup toolchain install stable --component rust-src --target riscv32imc-unknown-none-elf ``` 🔎 Rust is capable of cross-compiling to any supported target (see `rustup target list`). By default, only the native architecture of your system is installed.