16 lines
436 B
Bash
16 lines
436 B
Bash
which curl &> /dev/null || ( sudo apt update; sudo apt install curl -y ) # Install curl if not already installed
|
|
|
|
# Install rust
|
|
curl https://sh.rustup.rs -sSf | sh -s -- -y
|
|
|
|
# Configure current shell
|
|
source $HOME/.cargo/env
|
|
|
|
# If fish is used, adding cargo to path
|
|
if [ -x $HOME/.config/fish ] ; then
|
|
fish -c 'set -Up fish_user_paths ~/.cargo/bin'
|
|
fi
|
|
|
|
# Adding dev tools
|
|
rustup component add rust-analysis
|
|
rustup component add rls
|