#!/bin/bash

source common.sh

DOTCONFIG="/home/$USER/.config"

if [ -d "$DOTCONFIG" ]; 
then 
	echo "$DOTCONFIG existst and will not be created"
else
	mkdir $DOTCONFIG
fi

sudo $installCMD $common_programs

if [[ $system == *"arch"* ]] 
	then
		echo "###############"
		echo "Installing Arch"
		echo "###############"
		installCMD="pacman -S"
		sudo cp $main_dir/systemConf/nobeep.conf /etc/modprobe.d/
		localectl set-x11-keymap ch

		$main_dir/programs/yay.sh
		$main_dir/programs/tmux.sh
		$main_dir/programs/installFonts.sh
		$main_dir/programs/xmonad.sh
		$main_dir/programs/wallpaper.sh
		$main_dir/programs/sddm.sh
		$main_dir/programs/alacritty.sh
		$main_dir/programs/vim.sh
		$main_dir/programs/brave.sh
		$main_dir/programs/keyboardEnable.sh
elif [[ $system == *"debian"* ]] 
	then
		echo "#################"
		echo "Installing Debian"
		echo "#################"
		installCMD="apt install"
		$main_dir/programs/tmux.sh
		$main_dir/programs/installFonts.sh
		$main_dir/programs/xmonad.sh
		$main_dir/programs/wallpaper.sh
		$main_dir/programs/sddm.sh
		$main_dir/programs/vim.sh
fi


