Skip to content

Instantly share code, notes, and snippets.

@pomo-mondreganto
Last active September 24, 2024 19:40
Show Gist options
  • Save pomo-mondreganto/b36cffb0df03768e77b0509528135b65 to your computer and use it in GitHub Desktop.
Save pomo-mondreganto/b36cffb0df03768e77b0509528135b65 to your computer and use it in GitHub Desktop.
Script to install zsh & docker on a new Ubuntu machine
#!/bin/bash -e
CUR_USER=$(whoami)
cd "${HOME}"
echo "Installing for USER=${CUR_USER}, HOME=${HOME}"
sudo DEBIAN_FRONTEND=noninteractive apt-get update
sudo DEBIAN_FRONTEND=noninteractive apt install -y git zsh curl tmux tree zip unzip p7zip-full
# Install fzf
git clone --depth 1 https://github.com/junegunn/fzf.git "$HOME/.fzf"
"$HOME/.fzf/install" --no-bash --no-zsh --no-fish
# Install mise
curl https://mise.jdx.dev/install.sh | sh
# Change current user shell
sudo chsh -s /bin/zsh "$CUR_USER"
# Install rust.
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- --default-toolchain nightly --profile default -y
sh -c "$(curl -fsLS get.chezmoi.io/lb)" -- init --apply https://github.com/pomo-mondreganto/dotfiles-public
# Install mise-managed tools (Go and Node).
"$HOME/.local/bin/mise" install
sudo bash -c 'curl -fsSL https://get.docker.com | sh'
sudo usermod -aG docker "$CUR_USER"
echo "Don't forget to reopen the shell!"

Script to setup zsh + zsnap + p10k + docker on a new (ubuntu-like) machine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment