Update 'setup' script
parent
f858f7374b
commit
a83d0fd28f
59
.bin/setup
59
.bin/setup
|
@ -1,5 +1,18 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Packages to install from Arch repositories
|
||||||
|
pac_list=(
|
||||||
|
git
|
||||||
|
vim
|
||||||
|
)
|
||||||
|
|
||||||
|
# Packages to install from AUR
|
||||||
|
aurpac_list=(
|
||||||
|
ttf-iosevka-term-ss08
|
||||||
|
vim-plug
|
||||||
|
xbanish
|
||||||
|
)
|
||||||
|
|
||||||
install() {
|
install() {
|
||||||
if pacman -Qi "$1" &> /dev/null; then
|
if pacman -Qi "$1" &> /dev/null; then
|
||||||
echo ""$1" is already installed"
|
echo ""$1" is already installed"
|
||||||
|
@ -9,20 +22,9 @@ install() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# Packages to install from Arch repositories
|
aurpac() {
|
||||||
pac_list=(
|
git clone "https://aur.archlinux.org/$1.git" "$HOME/.build/$1"
|
||||||
git
|
}
|
||||||
vim
|
|
||||||
)
|
|
||||||
|
|
||||||
# Packages to install from AUR
|
|
||||||
aurpac_list=(
|
|
||||||
xbanish
|
|
||||||
ttf-iosevka-term-ss08
|
|
||||||
)
|
|
||||||
|
|
||||||
# Suckless software to build
|
|
||||||
suckless_list=( $(ls -1 "$HOME/.suckless/") )
|
|
||||||
|
|
||||||
count=0
|
count=0
|
||||||
|
|
||||||
|
@ -37,37 +39,34 @@ for pac in "${pac_list[@]}" ; do
|
||||||
install "$pac";
|
install "$pac";
|
||||||
done
|
done
|
||||||
|
|
||||||
|
origin="https://git.hektormisplon.xyz/hektor/dots"
|
||||||
|
git clone "$origin" "$HOME/dots"
|
||||||
|
cp -r "$HOME/dots/.git" "$HOME/.git"
|
||||||
|
git --git-dir="$HOME/.git" config --local status.showUntrackedFiles no
|
||||||
|
git --git-dir="$HOME/.git" stash -m "[dots]"
|
||||||
|
git --git-dir="$HOME/.git" stash apply
|
||||||
|
git --git-dir="$HOME/.git" restore "$HOME"
|
||||||
|
|
||||||
echo " "
|
echo " "
|
||||||
echo "Installing aur packages"
|
echo "Installing aur packages"
|
||||||
echo " "
|
echo " "
|
||||||
|
|
||||||
# [ ] Create aurpac installer function
|
# [ ] Create aurpac installer function
|
||||||
for aurpac in "${aurpac_list[@]}" ; do
|
for package in "${aurpac_list[@]}" ; do
|
||||||
if pacman -Qi "$1" &> /dev/null; then
|
if pacman -Qi "$1" &> /dev/null; then
|
||||||
echo "$1 is already installed"
|
echo "$1 is already installed"
|
||||||
else
|
else
|
||||||
count=$[count+1]
|
count=$[count+1]
|
||||||
("$HOME/.bin/aurpac" "$aurpac" && cd "$aurpac" && makepkg -si)
|
aurpac "$package" && makepkg -si -D "$HOME/.build/$package"
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
echo " "
|
echo " "
|
||||||
echo "Setting up suckless tools"
|
echo "Setting up NeoVim"
|
||||||
echo " "
|
echo " "
|
||||||
|
|
||||||
printf '%s\n' "${suckless_list[@]}"
|
git clone --depth=1 https://github.com/savq/paq-nvim.git \
|
||||||
|
"${XDG_DATA_HOME:-$HOME/.local/share}"/nvim/site/pack/paqs/start/paq-nvim
|
||||||
# for tool in "${suckless_list[@]}" ; do
|
|
||||||
# count=$[count+1]
|
|
||||||
# (cd "$HOME/.suckless/$tool/" && sudo make clean install);
|
|
||||||
# done
|
|
||||||
|
|
||||||
# echo " "
|
|
||||||
# echo "Setting up vim"
|
|
||||||
# echo " "
|
|
||||||
|
|
||||||
# cp .vimrc $HOME/.vimrc
|
|
||||||
# vim +PlugInstall
|
|
||||||
|
|
||||||
## Bluetooth setup
|
## Bluetooth setup
|
||||||
# ___
|
# ___
|
||||||
|
|
Loading…
Reference in New Issue