chore: adds setup.sh and updates rust to set default upon install and removes unused repos

This commit is contained in:
Menno van Leeuwen 2024-08-26 11:24:00 +02:00
parent c4c5e7850f
commit d4fc347bf9
Signed by: vleeuwenmenno
SSH Key Fingerprint: SHA256:OJFmjANpakwD3F2Rsws4GLtbdz1TJ5tkQF0RZmF0TRE
3 changed files with 32 additions and 3 deletions

View File

@ -21,6 +21,7 @@ ensure_rust_installed() {
printfe "%s\n" "red" "Failed to install Rust"
exit 1
fi
rustup default stable
printfe "%s\n" "green" " - Rust installed successfully"
fi

View File

@ -95,9 +95,6 @@ config:
apt:
repos:
- ppa:nilarimogard/webupd8
- ppa:alexlarsson/flatpak
apps:
- zsh
- git

31
setup.sh Executable file
View File

@ -0,0 +1,31 @@
#!/bin/bash
# Prepare, we need at least these minimal packages to continue ...
sudo apt update
sudo apt install curl zsh nala pipx apt-transport-https ca-certificates gnupg -y
# Ensure shyaml is available
echo "Ensuring shyaml is installed..."
if [ ! -x "$(command -v shyaml)" ]; then
echo " - shyaml is not installed, installing it..."
pipx install shyaml
fi
echo "Ensuring pyenv is installed..."
if [ ! -d "$HOME/.pyenv" ]; then
curl https://pyenv.run | bash
else
echo " - pyenv is already installed"
fi
sed -i -e '$a\'$'\n''export PATH=$PATH:$HOME/.local/bin' ~/.bashrc
sed -i -e '$a\'$'\n''export PATH=$PATH:~/dotfiles/bin' ~/.bashrc
sed -i -e '$a\'$'\n''export PATH=$PATH:$HOME/.local/bin' ~/.zshrc
sed -i -e '$a\'$'\n''export PATH=$PATH:~/dotfiles/bin' ~/.zshrc
echo "#########################################################"
echo "# #"
echo "# !!! RESTART YOUR TERMINAL BEFORE YOU CONTINUE !!! #"
echo "# !!! Continue with 'dotf update' !!! #"
echo "# #"
echo "#########################################################"