diff options
| author | pml68 <contact@pml68.dev> | 2024-12-13 00:41:46 +0100 |
|---|---|---|
| committer | pml68 <contact@pml68.dev> | 2024-12-13 01:40:45 +0100 |
| commit | 1e566ea3b67e1e58ec62a662690902e4d9596560 (patch) | |
| tree | cc1ba0026c9db2bbfb74930df954096d7e19d9b3 /install.sh | |
| parent | fix(laptop): patch file (diff) | |
| download | suckless-setup-1e566ea3b67e1e58ec62a662690902e4d9596560.tar.gz | |
feat: better install script
Diffstat (limited to 'install.sh')
| -rwxr-xr-x | install.sh | 34 |
1 files changed, 31 insertions, 3 deletions
@@ -1,6 +1,34 @@ #!/bin/sh -dirs=("dwm" "dmenu" "slstatus" "st") +dirs="dwm dmenu slstatus st" -for dir in "${dirs[@]}"; do - (cd "$dir" && sudo make clean install) +command_exists() { + command -v "$1" >/dev/null 2>&1 +} + +for dir in $dirs; do + (cd "$dir" && echo "starting $dir installation" && make clean install && echo "$dir installation complete") done + +if command_exists feh; then + feh --bg-fill wallpaper.jpg + echo "~/.fehbg &" >> ~/.xinitrc +fi + +if command_exists picom; then + cp picom.conf /etc/xdg/picom.conf + echo "picom &" >> ~/.xinitrc +fi + +command_exists flameshot && echo "flameshot &" >> ~/.xinitrc + +command_exists neofetch && cp neofetch -r ~/.config/ + +command_exists vis && cp vis -r ~/.config/ + +if command_exists tmux; then + git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm + cp tmux -r ~/.config/ +fi + +echo "slstatus &" >> ~/.xinitrc +echo "exec dwm" >> ~/.xinitrc |
