os/arch: rewrite install script & add yaourt

This commit is contained in:
Henrik Lissner 2016-10-31 15:32:02 +01:00
parent ea5446105d
commit 1bc46b484a

View file

@ -2,45 +2,57 @@
PWD=$(dirname $0) PWD=$(dirname $0)
sudo pacman --noconfirm -S \ sudo pacman --needed --noconfirm -S git
wget curl make tmux rsync tree the_silver_searcher bc \
wpa_supplicant wpa_actiond dhcpcd netctl dialog \
xorg-init xorg-server xorg-xandr xorg-xrdb xorg-xmodmap xorg-fonts-75dpi xorg-xfd xdotool \
lightdm bspwm sxhkd compton feh \
rofi rxvt-unicode firefox mpd ncmpcpp \
obs-studio youtube-dl
install() { if ! command -v yaourt >/dev/null
local cmd="$1"
local repo="$2"
local dest=$(basename -s .git "$repo")
command -v "$cmd" >/dev/null && return
TEMP=$(mktemp -d)
cd "$TEMP"
if [ ! -d "$dest" ]
then then
git clone "$repo" "$dest" TEMP=$(mktemp -d)
pushd "$dest" pushd $TEMP
makepkg -sri --noconfirm git clone https://aur.archlinux.org/package-query.git && cd package-query && makepkg -si
git clone https://aur.archlinux.org/yaourt.git && cd yaourt && makepkg -si
popd popd
fi
rm -rf "$TEMP" rm -rf "$TEMP"
fi
# Install from AUR
aur() {
if ! command -v $1 >/dev/null
then
shift
yaourt --noconfirm -S ${*:-$1}
fi
} }
# Bar utilities pacman="sudo pacman --needed --noconfirm -S"
install lemonbar https://aur.archlinux.org/lemonbar-xft-git.git
install xtitle https://aur.archlinux.org/xtitle.git
install clock https://aur.archlinux.org/sutils-git.git
install xdo https://aur.archlinux.org/xdo-git.git
install siji https://aur.archlinux.org/siji-git.git
# WM Greeter # Essential X things
if [ ! -d /usr/share/lightdm-webkit ] $pacman xorg-init xorg-server xorg-xandr xorg-xrdb xorg-xmodmap \
then xorg-fonts-75dpi xorg-xfd xdotool
install "" https://aur.archlinux.org/lightdm-webkit-greeter.git
fi # For wifi
$pacman wpa_supplicant wpa_actiond dhcpcd netctl dialog
# Window manager
$pacman lightdm lightdm-webkit2-greeter bspwm sxhkd compton
# Essential shell utilities
$pacman wget curl make tmux rsync tree the_silver_searcher bc xsel
# Applications
$pacman rxvt-unicode firefox obs-studio chromium
# Utilities # Utilities
install git-crypt https://aur.archlinux.org/git-crypt.git $pacman feh youtube-dl rofi mpd ncmpcpp redshift
install fasd https://aur.archlinux.org/fasd-git.git aur git-crypt
aur fasd
# Taskbar
aur lemonbar lemonbar-xft-git siji-git
aur xdo-git
aur clock sutils-git
# Fonts
$pacman ttf-dejavu ttf-inconsolata ttf-liberation ttf-ubuntu-font-family terminus-font
# GTK theme
aur '[[ -d /usr/share/themes/Arc-Dark ]]' gtk-theme-arc