-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup-x.sh
executable file
·111 lines (87 loc) · 2.46 KB
/
setup-x.sh
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
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
#!/bin/bash
cleanup() {
rm /chroot.sh
}
update_pacman() {
echo "[multilib]" | sudo tee -a /etc/pacman.conf
echo "Include = /etc/pacman.d/mirrorlist" | sudo tee -a /etc/pacman.conf
echo "" | sudo tee -a /etc/pacman.conf
echo "[archlinuxfr]" | sudo tee -a /etc/pacman.conf
echo "SigLevel = Never" | sudo tee -a /etc/pacman.conf
echo "Server = http://repo.archlinux.fr/\$arch" | sudo tee -a /etc/pacman.conf
sudo pacman -Suy
}
set_yay() {
# Build yay package and install
git clone https://aur.archlinux.org/yay.git
cd yay
makepkg -si
# After install, remove the yay build folder
cd ..; rm -rf yay
# Sync yay
yay -Sy
}
set_timezone() {
sudo tzselect
}
set_thermald() {
yay -Sy thermald --needed --noconfirm
# Enable + start
sudo systemctl enable thermald.service
sudo systemctl start thermald.service
sudo systemctl enable thermald
}
set_network() {
# Install
yay -S networkmanager network-manager-applet nm-connection-editor --needed --noconfirm
# Enable + start
sudo systemctl enable NetworkManager
sudo systemctl start NetworkManager
}
set_sound() {
# Install pulseaudio packages
yay -S pulseaudio pulseaudio-alsa pulseaudio-bluetooth pulseaudio-ctl --needed --noconfirm
}
set_bluetooth() {
# Install
yay -S bluez bluez-utils bluez-tools --needed --noconfirm
# Enable + start
sudo systemctl enable bluetooth
sudo systemctl start bluetooth
# (optional) Install nice traybar utils
yay -S blueman blueberry --needed --noconfirm
}
set_tlp() {
# Install
yay -S tlp --needed --noconfirm
# Enable + start
sudo systemctl enable tlp
sudo systemctl start tlp
sudo systemctl enable tlp-sleep.service
}
set_xorg() {
yay -S xorg-server xorg-xev xorg-xinit xorg-xkill xorg-xmodmap xorg-xprop xorg-xrandr xorg-xrdb xorg-xset xinit-xsession --needed --noconfirm
sudo cp xorg/20-intel.conf /etc/X11/xorg.conf.d/20-intel.conf
sudo cp xorg/30-display.conf /etc/X11/xorg.conf.d/30-display.conf
sudo cp xorg/99-touchscreen.conf /etc/X11/xorg.conf.d/99-touchscreen.conf
yay -Sy xf86-video-intel --needed --noconfirm
}
set_i3() {
yay -Sy i3-gaps-next-git i3lock-fancy-git --needed --noconfirm
sudo cp .xinitrc ~/.xinitrc
}
set_terminal() {
yay -Sy alacritty --needed --noconfirm
}
# exec script
update_pacman
set_yay
set_timezone
set_thermald
set_network
set_sound
set_bluetooth
set_tlp
set_xorg
set_i3
set_terminal