-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinstall.sh
More file actions
167 lines (139 loc) · 4.24 KB
/
install.sh
File metadata and controls
167 lines (139 loc) · 4.24 KB
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
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
#!/bin/sh
set -e
echo "==> BoringWM testing setup (Debian 13 / minimal)"
# --------------------------------------------------
# Base system
# --------------------------------------------------
echo "==> Installing base system packages"
sudo apt update
sudo apt install -y \
xorg \
xinit \
dbus-x11 \
git \
curl \
build-essential
# --------------------------------------------------
# Audio
# --------------------------------------------------
echo "==> Installing audio packages"
sudo apt install -y \
pipewire \
pipewire-audio \
pipewire-pulse \
wireplumber \
alsa-utils \
pavucontrol
# --------------------------------------------------
# Rust (user-local)
# --------------------------------------------------
if ! command -v cargo >/dev/null 2>&1; then
echo "==> Installing Rust (user-local)"
curl https://sh.rustup.rs -sSf | sh -s -- -y
fi
# shellcheck source=/dev/null
. "$HOME/.cargo/env"
# --------------------------------------------------
# Build and install BoringWM
# --------------------------------------------------
echo "==> Building BoringWM"
if [ ! -d boringwm ]; then
git clone https://github.com/dennishilk/boringwm.git
fi
cd boringwm
cargo build --release
echo "==> Installing BoringWM to /usr/local/bin"
sudo install -Dm755 target/release/boringwm /usr/local/bin/boringwm
# --------------------------------------------------
# Desktop tools
# --------------------------------------------------
echo "==> Installing desktop tools"
sudo apt install -y \
kitty \
picom \
feh \
thunar \
firefox-esr \
rofi \
network-manager
# --------------------------------------------------
# Rofi scripts
# --------------------------------------------------
echo "==> Installing BoringWM rofi helpers"
sudo install -Dm755 assets/scripts/boringwm-rofi /usr/local/bin/boringwm-rofi
sudo install -Dm755 assets/scripts/boringwm-networkmanager /usr/local/bin/boringwm-networkmanager
# --------------------------------------------------
# Wallpaper
# --------------------------------------------------
echo "==> Installing default wallpaper"
if [ -f assets/wallpaper/boringwm-wallpaper.png ]; then
cp assets/wallpaper/boringwm-wallpaper.png "$HOME/.wallpaper"
else
echo "!! Wallpaper not found, skipping"
fi
# --------------------------------------------------
# Picom configuration (safe, no GL)
# --------------------------------------------------
echo "==> Writing picom config"
mkdir -p "$HOME/.config/picom"
cat > "$HOME/.config/picom/picom.conf" << 'EOF'
backend = "xrender";
vsync = true;
active-opacity = 0.95;
inactive-opacity = 0.95;
frame-opacity = 0.95;
fading = true;
fade-in-step = 0.03;
fade-out-step = 0.03;
blur-method = "none";
EOF
# --------------------------------------------------
# Kitty configuration (transparency)
# --------------------------------------------------
echo "==> Writing kitty config"
mkdir -p "$HOME/.config/kitty"
cat > "$HOME/.config/kitty/kitty.conf" << 'EOF'
background_opacity 0.90
enable_audio_bell no
EOF
# --------------------------------------------------
# Autostart (safe)
# --------------------------------------------------
echo "==> Setting up autostart"
mkdir -p "$HOME/.config/boringwm"
cat > "$HOME/.config/boringwm/autostart.sh" << 'EOF'
#!/bin/sh
feh --bg-fill "$HOME/.wallpaper" &
picom &
EOF
chmod +x "$HOME/.config/boringwm/autostart.sh"
# --------------------------------------------------
# X11 start configuration (loop-safe)
# --------------------------------------------------
echo "==> Writing ~/.xinitrc"
cat > "$HOME/.xinitrc" << 'EOF'
exec boringwm || xterm
EOF
# --------------------------------------------------
# Auto startx on tty1 (OPTIONAL, DEV UNSAFE)
# --------------------------------------------------
echo
echo "==> Enable automatic startx on tty1? (y/N)"
read -r answer
if [ "$answer" = "y" ] || [ "$answer" = "Y" ]; then
echo "==> Enabling auto-start X on tty1 (DEV MODE WARNING)"
cat >> "$HOME/.bash_profile" << 'EOF'
# Auto-start X on tty1 (BoringWM)
if [ -z "$DISPLAY" ] && [ "$(tty)" = "/dev/tty1" ]; then
exec startx
fi
EOF
else
echo "==> Skipping auto-start X (recommended for dev)"
fi
# --------------------------------------------------
# Done
# --------------------------------------------------
echo
echo "==> Setup complete."
echo "==> Start with: startx"