1.68.1
.
You can also use rustup
yourself in Gitpod in order to switch to a different Rust version, or to install extra components. See the rustup book to learn more about rustup
itself.
Note: If you try to use rustup
in your repository’s .gitpod.Dockerfile, you might get the following error:
rustup
command in a login Bash shell, like so:
rustup-toolchain
file in the root of your repository. Say for example you need the nightly compiler for March 4th, 2020, you would create a rustup-toolchain
file and add the following
Repository | Description | Try it |
---|---|---|
template-rust-cli | Rust CLI template |
Note: This extension outputs emojis by default if the crate version is set at the latest. You can disable this by usingThe VS Code extension Crates makes it easier to manage your Cargo dependency versions.crates.upToDateDecorator
option in your preferences >
Cargo.toml
.
rustup target add x86_64-unknown-linux-musl
, for example in your .gitpod.Dockerfilecargo build --target x86_64-unknown-linux-musl
Native Debug
by webfreak. When you see it, click to install it for your project.
The next prerequisite is a Docker configuration.
If you already have a .gitpod.Dockerfile just add the following:
.gitpod.Dockerfile
with the following content:
Cargo.toml
file and find the name of the program.${workspaceFolder}/target/debug/<PROGRAM_NAME>
where <PROGRAM_NAME>
is the name of the program under the name field in the Cargo.toml
file.preLaunchTask
and set it to “cargo”type
to command
subcommand
to args
and the value to ["build"]
problemMatcher
field.type
and set it to process
label
and set it to cargo
.theia/
, and inside add a file called launch.json
, add the following to it:
.theia/
directory called tasks.json
with the following content:
Rocket
web-development framework