How do I install rust?

I once experience a -2 error with the executables installed by rustup: Do rustup installed components such as rls supposed to be usable on NixOS? so I use the

I use the stable toolchain so I don’t mind using the packages rustc, cargo directly.