-
Notifications
You must be signed in to change notification settings - Fork 0
/
install.sh
executable file
·46 lines (38 loc) · 1020 Bytes
/
install.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
# Installing base packages
echo ">>> Installing packages"
sudo pacman --noconfirm -S \
xorg xorg-xinit nvidia kitty picom polybar dmenu ttf-cascadia-code \
# Ensure cargo is installed
echo ">>> Checking rust installation"
if ! command -v cargo &> /dev/null
then
echo ">>> Installing"
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
source "$HOME/.cargo/env"
else
echo ">>> Rust is present"
fi
# Install and configure rtde
echo ">>> Installing rtwm"
cd rtde-wm
cargo build
sudo cp -f ./target/debug/rtwm /usr/local/bin
# Copy help script
echo ">>> Copying scripts"
cd ..
sudo cp ./scripts/* /usr/local/bin/
# create rtde dir and add autostart file
echo ">>> Creating config directory"
mkdir ~/.rtde
touch ~/.rtde/out.log
touch ~/.rtde/err.log
# create autostart config
echo -e '#!/bin/bash
picom &
polybar &
' > ~/.rtde/autostart.sh
chmod +x ~/.rtde/autostart.sh
# Backup xinitrc and create new
echo ">>> Updating xinitrc"
mv ~/.xinitrc ~/.xinitrc.old
echo -e "exec rtwm" > ~/.xinitrc