Install Rust#

Compiler#

%%bash

curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

Verify

%%bash 

rustc --version
cargo --version
rustup --version
rustc 1.57.0 (f1edd0429 2021-11-29)
cargo 1.57.0 (b2e52d7ca 2021-10-21)
rustup 1.24.3 (ce5817a94 2021-05-31)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: The currently active `rustc` version is `rustc 1.57.0 (f1edd0429 2021-11-29)`

Rust Jupyter Kernel#

%%bash

# https://github.com/google/evcxr/blob/main/evcxr_jupyter/README.md
cargo install evcxr_jupyter
evcxr_jupyter --install

# make sure the kernel finds the rust tools ... (since the path is not setup when Jupyter starts)
sudo ln -s ~/.cargo/bin/cargo /usr/local/bin/cargo

Now the kernel is available from the Launcher. A restart of the micropython service may be needed.