This repository has been archived on 2023-11-07. You can view files and clone it, but cannot push or open issues or pull requests.
dotfiles.old/setup.sh

49 lines
1.6 KiB
Bash
Raw Normal View History

2023-06-15 19:57:11 +00:00
#!/bin/bash
export PATH=$PATH:$HOME/.local/bin
# starship
command -v starship &> /dev/null || mkdir -p $HOME/.local/bin && curl -sS https://starship.rs/install.sh | sudo -E sh -s -- --yes --bin-dir $HOME/.local/bin
# pfetch
command -v pfetch &> /dev/null || curl -L https://github.com/Gobidev/pfetch-rs/releases/latest/download/pfetch-linux-gnu-x86_64.tar.gz | sudo tar -xvz -C $HOME/.local/bin
2023-06-15 19:57:11 +00:00
# Go
sudo rm -rf /usr/local/go || sudo mkdir -p /usr/local/go && curl -L https://go.dev/dl/go1.20.5.linux-amd64.tar.gz | sudo tar -xz -C /usr/local/
2023-06-16 13:49:38 +00:00
# Install buf
BIN="/usr/local/bin" && \
sudo curl -sSL \
"https://github.com/bufbuild/buf/releases/latest/download//buf-$(uname -s)-$(uname -m)" \
-o "${BIN}/buf" && \
sudo chmod +x "${BIN}/buf"
2023-06-16 09:05:24 +00:00
# kubectl
command -v kubectl &> /dev/null || sudo curl -o /usr/local/bin/kubectl -L "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" && sudo chmod +x /usr/local/bin/kubectl
2023-06-16 09:05:24 +00:00
# dotnet
curl -L https://dot.net/v1/dotnet-install.sh | sudo bash -s -- --channel LTS --install-dir /usr/local/dotnet
curl -L https://dot.net/v1/dotnet-install.sh | sudo bash -s -- --channel STS --install-dir /usr/local/dotnet
2023-06-15 20:18:44 +00:00
if $(which dnf 2>&1 > /dev/null); then
2023-06-16 06:36:55 +00:00
sudo dnf config-manager --add-repo https://rpm.releases.hashicorp.com/fedora/hashicorp.repo
sudo dnf install -y \
zoxide \
2023-06-16 06:36:55 +00:00
terraform \
2023-06-16 13:38:24 +00:00
helm \
2023-06-16 11:46:55 +00:00
ansible \
2023-06-16 13:38:24 +00:00
python3-kubernetes \
fontawesome-fonts \
fontawesome5-free-fonts
2023-06-15 20:18:44 +00:00
fi
# Git
cp home/config/git/gitconfig ~/.gitconfig
# ZSH
2023-06-15 19:57:11 +00:00
cp home/zshrc ~/.zshrc
mkdir -p ~/.config/zsh
rsync -avz home/config/zsh/ ~/.config/zsh
2023-06-15 19:57:11 +00:00
# Starship
cp home/config/starship.toml ~/.config/