Update .scripts/install_base.sh

This commit is contained in:
V 2022-12-01 17:22:28 +04:00
parent b86467a66f
commit 6a2cac3864
1 changed files with 17 additions and 6 deletions

View File

@ -2,12 +2,16 @@
# Never ever curl some remote shit straight to shell, like:
# curl --proto '=https' --tlsv1.2 -sSf https://inex.dev/v/dotfiles/raw/branch/main/dot_scripts/executable_install_base.sh | sh
# seriously, don't do this, it's insecure!
#
# Pacman packages
sudo pacman --needed --noconfirm -Syu base-devel htop ranger git screen ncdu neovim pipewire sway swaybg xorg-server xorg-xwayland chezmoi foot polkit openssh firefox-developer-edition gnome-keyring xdg-utils qpwgraph qt6-wayland man-db udisks2 ttf-cascadia-code ponysay
## Pacman
# Workaround for keyring nonsense, see https://bugs.archlinux.org/task/75574
sudo pacman -Sy --needed archlinux-keyring
sudo pacman -Su
# Install packages
sudo pacman --needed --noconfirm -S base-devel htop ranger git screen ncdu neovim pipewire sway swaybg xorg-server xorg-xwayland chezmoi foot polkit openssh firefox-developer-edition gnome-keyring xdg-utils qpwgraph qt6-wayland man-db udisks2 ttf-cascadia-code ponysay
# Install Paru
## Paru (AUR helper)
# Install Paru from AUR if not installed
if pacman -Qs paru > /dev/null ; then
echo "'Paru' already installed."
else
@ -18,15 +22,18 @@ else
rm -rf paru-bin/
fi
# AUR Packages
## AUR Packages
paru --needed --noconfirm -Syua paru-bin bashmount ulauncher
# Chezmoi apply dotfiles
## Chezmoi
# Get and apply dotfiles
chezmoi init --apply https://inex.dev/v/dotfiles.git
cd .local/share/chezmoi/
git remote set-url origin git@inex.dev:v/dotfiles.git
cd $HOME
## SSH
# Generate key if not exist
if [ -f "$HOME/.ssh/id_ed25519.pub" ]; then
echo "id_ed25519.pub exist"
else
@ -36,6 +43,10 @@ else
ssh-add ~/.ssh/id_ed25519
fi
## Add user to useful groups
sudo usermod -aG wheel,input,audio,video,lp v
## Apply Firefox policies
sudo mkdir -p /etc/firefox/policies
sudo cp .local/share/chezmoi/dot_scripts/firefox_policies.json /etc/firefox/policies/policies.json