hyprland-dotfiles/3-dotfiles.sh

118 lines
4.2 KiB
Bash
Raw Permalink Normal View History

2023-09-04 19:21:39 +00:00
#!/bin/bash
# _ _ __ _ _
# __| | ___ | |_ / _(_) | ___ ___
# / _` |/ _ \| __| |_| | |/ _ \/ __|
# | (_| | (_) | |_| _| | | __/\__ \
# \__,_|\___/ \__|_| |_|_|\___||___/
#
# by Stephan Raabe (2023)
# ------------------------------------------------------
# Install Script for dotfiles and configuration
# yay must be installed
# ------------------------------------------------------
# ------------------------------------------------------
# Load Library
# ------------------------------------------------------
source $(dirname "$0")/scripts/library.sh
clear
echo " _ _ __ _ _ "
echo " __| | ___ | |_ / _(_) | ___ ___ "
echo " / _' |/ _ \| __| |_| | |/ _ \/ __| "
echo "| (_| | (_) | |_| _| | | __/\__ \ "
echo " \__,_|\___/ \__|_| |_|_|\___||___/ "
echo " "
echo "by Stephan Raabe (2023)"
echo "-------------------------------------"
echo ""
2023-09-04 20:08:28 +00:00
echo "The script will ask for permission to remove existing folders and files."
2023-09-04 19:21:39 +00:00
echo "But you can decide to keep your local versions by answering with No (Nn)."
echo "Symbolic links will be created from ~/dotfiles into your home and .config directories."
echo ""
# ------------------------------------------------------
# Confirm Start
# ------------------------------------------------------
while true; do
read -p "DO YOU WANT TO START THE INSTALLATION NOW? (Yy/Nn): " yn
case $yn in
[Yy]* )
echo "Installation started."
break;;
[Nn]* )
exit;
break;;
* ) echo "Please answer yes or no.";;
esac
done
# ------------------------------------------------------
# Create .config folder
# ------------------------------------------------------
echo ""
2023-09-04 20:08:28 +00:00
echo "-> Check if .config folder exists"
2023-09-04 19:21:39 +00:00
if [ -d ~/.config ]; then
echo ".config folder already exists."
else
mkdir ~/.config
echo ".config folder created."
fi
# ------------------------------------------------------
# Create symbolic links
# ------------------------------------------------------
2023-09-04 20:08:28 +00:00
# name symlink source target
echo ""
echo "-------------------------------------"
echo "-> Install general dotfiles"
echo "-------------------------------------"
echo ""
_installSymLink alacritty ~/.config/alacritty ~/dotfiles/alacritty/ ~/.config
_installSymLink ranger ~/.config/ranger ~/dotfiles/ranger/ ~/.config
_installSymLink vim ~/.config/vim ~/dotfiles/vim/ ~/.config
_installSymLink nvim ~/.config/nvim ~/dotfiles/nvim/ ~/.config
_installSymLink starship ~/.config/starship.toml ~/dotfiles/starship/starship.toml ~/.config/starship.toml
_installSymLink rofi ~/.config/rofi ~/dotfiles/rofi/ ~/.config
_installSymLink dunst ~/.config/dunst ~/dotfiles/dunst/ ~/.config
_installSymLink wal ~/.config/wal ~/dotfiles/wal/ ~/.config
2023-09-25 12:16:36 +00:00
wal -i screenshots/
echo "Pywal templates initiated!"
echo ""
2023-09-04 20:08:28 +00:00
echo "-------------------------------------"
echo "-> Install GTK dotfiles"
echo "-------------------------------------"
2023-09-04 19:21:39 +00:00
echo ""
2023-09-04 20:08:28 +00:00
_installSymLink .gtkrc-2.0 ~/.gtkrc-2.0 ~/dotfiles/gtk/.gtkrc-2.0 ~/.gtkrc-2.0
_installSymLink gtk-3.0 ~/.config/gtk-3.0 ~/dotfiles/gtk/gtk-3.0/ ~/.config/
_installSymLink .Xresouces ~/.Xresources ~/dotfiles/gtk/.Xresources ~/.Xresources
_installSymLink .icons ~/.icons ~/dotfiles/gtk/.icons/ ~/
echo "-------------------------------------"
echo "-> Install Qtile dotfiles"
echo "-------------------------------------"
echo ""
_installSymLink qtile ~/.config/qtile ~/dotfiles/qtile/ ~/.config
_installSymLink polybar ~/.config/polybar ~/dotfiles/polybar/ ~/.config
_installSymLink picom ~/.config/picom ~/dotfiles/picom/ ~/.config
_installSymLink .xinitrc ~/.xinitrc ~/dotfiles/qtile/.xinitrc ~/.xinitrc
echo "-------------------------------------"
echo "-> Install Hyprland dotfiles"
echo "-------------------------------------"
echo ""
2023-09-04 19:44:31 +00:00
2023-09-04 20:08:28 +00:00
_installSymLink hypr ~/.config/hypr ~/dotfiles/hypr/ ~/.config
_installSymLink waybar ~/.config/waybar ~/dotfiles/waybar/ ~/.config
_installSymLink swaylock ~/.config/swaylock ~/dotfiles/swaylock/ ~/.config
_installSymLink wlogout ~/.config/wlogout ~/dotfiles/wlogout/ ~/.config
2023-09-04 19:21:39 +00:00
# ------------------------------------------------------
# DONE
# ------------------------------------------------------
echo "DONE! Please reboot your system!"