Skip to content

Instantly share code, notes, and snippets.

@JuenTingShie
Last active December 4, 2022 22:48
Show Gist options
  • Save JuenTingShie/3c3615885364118a2e37bcebdc1ab67f to your computer and use it in GitHub Desktop.
Save JuenTingShie/3c3615885364118a2e37bcebdc1ab67f to your computer and use it in GitHub Desktop.
My brand-new linux startup
#!/usr/bin/env bash
# Check APT
echo ==============
echo = apt update =
echo ==============
sudo apt update && sudo apt upgrade -y
# Install git
echo ===============
echo = git install =
echo ===============
sudo apt install -y git
# Install regular use
## Tools
echo ===============
echo = regular use =
echo ===============
sudo apt install -y wget curl tmux
## Monitoring
echo ==============
echo = monitoring =
echo ==============
sudo apt install -y net-tools nload mtr htop
# Install tools
## Oh-my-bash
echo ==============
echo = Oh-my-bash =
echo ==============
bash -c "$(curl -fsSL https://raw.githubusercontent.com/ohmybash/oh-my-bash/master/tools/install.sh)"
exec $SHELL
## .tmux
echo =========
echo = .tmux =
echo =========
cd
git clone https://github.com/gpakosz/.tmux.git
ln -s -f .tmux/.tmux.conf
cp .tmux/.tmux.conf.local .
## tmuxp
echo =========
echo = tmuxp =
echo =========
sudo apt install -y python3-pip
pip3 install --user tmuxp
## tldr
echo ========
echo = tldr =
echo ========
if [ "$(uname -m)" = "x86_64" ]; then
VENDER="amd64"
elif [ "$(uname -m)" = "armv7l" ]; then
VENDER="arm"
fi
curl -s https://api.github.com/repos/isacikgoz/tldr/releases/latest \
| grep "linux_${VENDER}.tar.gz" \
| cut -d : -f 2,3 \
| tr -d \" \
| xargs wget -qO - --show-progress \
| sudo tar -zxvf - -C /usr/bin
## cheatsheet.sh
echo =================
echo = cheatsheet.sh =
echo =================
cd
echo $'' >> .bashrc
curl -L https://gist.github.com/JuenTingShie/96285b88ba2a6646ed230a1c5d411b77/raw/145b6cf7b5579a315a9cf75a58370b18b64f2ea6/how \
>> .bashrc
exec $SHELL
@JuenTingShie
Copy link
Author

To run this script:

curl <raw-script-url> -o - | bash

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