first try

This commit is contained in:
starlord 2024-08-31 08:37:03 -07:00
commit 3d45eea1cf

54
rpi_init.sh Executable file
View file

@ -0,0 +1,54 @@
sudo nano init.sh && sudo chmod +x init.sh && sudo ./init.sh && source ~/.bashrc && echo "------- INIT COMPLETE -------"
#!/bin/bash
function status () {
LBB='\033[1;30;44m'
NOC='\033[0m'
echo
echo -e "${LBB}------- ${1} -------${NOC}"
echo
}
status "DESTROYING CHROMIUM"
sudo apt remove --auto-remove --purge chromium-browser -y
status "UPDATING LIBRARIRES AND KEYS"
# update and get gpg/keys
sudo apt update
sudo apt install -y gpg
sudo mkdir -p /etc/apt/keyrings
wget -qO- https://raw.githubusercontent.com/eza-community/eza/main/deb.asc | sudo gpg --dearmor -o /etc/apt/keyrings/gierens.gpg
echo "deb [signed-by=/etc/apt/keyrings/gierens.gpg] http://deb.gierens.de stable main" | sudo tee /etc/apt/sources.list.d/gierens.list
sudo chmod 644 /etc/apt/keyrings/gierens.gpg /etc/apt/sources.list.d/gierens.list
status "GETTING EZA AND BAT"
# refresh and install
sudo apt update
sudo apt install -y eza bat
status "UPDATING ~/.BASHRC"
# add to .rc's
USRBASHRC=~/.bashrc
read -r -d '' usrb <<- EOM
### CUSTOM ALIASES ###
alias nano="nano -lqSa"
alias la='eza -alg'
alias lt='eza -lgT'
alias lta='eza -lgaT'
alias bat='batcat'
EOM
echo -e "$usrb" >> $USRBASHRC
status "FULL UPDATE AND UPGRADE"
sudo apt update && sudo apt upgrade -y