aboutsummaryrefslogtreecommitdiff
path: root/install.sh
diff options
context:
space:
mode:
authorbozo.kopic <bozo@kopic.xyz>2021-02-08 21:42:09 +0100
committerbozo.kopic <bozo@kopic.xyz>2021-02-08 21:42:09 +0100
commit4914d7fc7626fff2d96d2cc4f01677cb04ea013d (patch)
treed24ec85f8a86d82073365934d89a8bf2e6b9bef7 /install.sh
parenta510034216ce37ac0f82afabe77c38aa058cc3fb (diff)
.
Diffstat (limited to 'install.sh')
-rwxr-xr-xinstall.sh12
1 files changed, 9 insertions, 3 deletions
diff --git a/install.sh b/install.sh
index 3226105..2846c57 100755
--- a/install.sh
+++ b/install.sh
@@ -6,11 +6,17 @@ symlink () {
ln -sfT "$@"
}
+install_packages() {
+ yay -S --needed --noconfirm \
+ $(cat $1 | \
+ xargs -I{} sh -c \
+ "(pacman -Q {} &> /dev/null) || echo {}")
+}
+
mkdir -p ~/bin
symlink $(cd $(dirname "$0"); pwd -P) ~/.dotfiles
-
-# yay
-~/.dotfiles/yay/install.sh
+yay --save --sudo doas
+install_packages ~/.dotfiles/packages.txt
# alacritty
symlink ~/.dotfiles/alacritty ~/.config/alacritty