summaryrefslogtreecommitdiff
path: root/install.sh
blob: dd8f5a14e8b1d03600028b0ed3c4da16757e0e1a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
#!/bin/sh

sudo pacman -S --needed dialog

# Sets the folder names
dwm="dwm-6.2"
dmenu="dmenu-5.0"
st="st"
dwmblocks="dwmblocks"

dialog --title "sarc stable" --msgbox "Welcome to the sarc installer!" 0 0
dialog --title "sarc stable" --inputbox "What theme would you like? Choose from green, blue, and red" 0 0 2> /tmp/.theme_sel
clear

theme="$(cat /tmp/.theme_sel)"

	echo "Your theme is $theme"
	sudo pacman -Sy --needed webkit2gtk dialog wpa_supplicant iw dhcpcd adobe-source-code-pro-fonts falkon libnotify xorg xorg-xinit light picom feh dunst pulseaudio
	
	echo "Setting up config folders"
	mkdir -p ~/.config/sarc
	cp -r * ~/.config/sarc/
	cd ~/.config/sarc/

	cd $dwm
	cp ./themes/$theme ./config.h
	make
	sudo make -s install 

	cd ../$st
	make
	sudo make -s install

	cd ../$dmenu
	make
	sudo make -s install 

	cd ../$dwmblocks
	make
	sudo make -s install 
	cd ..

	echo "Copying files"
	
	mkdir ~/.dwm

	sudo cp etc/ns.conf /etc
	etc/cursor
	cp ./etc/.xinitrc ~
	cp ./etc/$theme.wallpaper.jpg ~/.config/
	mv ~/.config/$theme.wallpaper.jpg ~/.config/wallpaper.jpg

	cp ./etc/autostart.sh ~/.dwm/
	sudo cp ./bin/* /usr/local/bin

	dialog --title "sarc" --msgbox "The installation is complete! Type *startx* to launch dwm." 0 0
	clear