Initial commit: sway + uwsm desktop dotfiles

Nord-themed Wayland setup on sway (via uwsm), including:

- sway/swayidle/swaylock/swaddle — WM, idle/lock/inhibit
- waybar, rofi — bar and launcher
- dunst — notifications
- foot — terminal
- zsh (+fzf, syntax highlighting, autosuggestions) — shell
- mpd/rmpc/mpc, mpv — music and video
- nvim — editor (lazy.nvim)
- ly — login manager
- rbw + pinentry-rofi wrapper — Bitwarden/Vaultwarden CLI
- per-window-layout, clipvault — helper systemd services
This commit is contained in:
2026-08-11 10:30:07 +04:00
commit a213b10a88
35 changed files with 2775 additions and 0 deletions
+29
View File
@@ -0,0 +1,29 @@
@import "config.rasi"
window {
children: [ mainbox ];
}
mainbox {
background-color: transparent;
children: [ inputbar, listview, message ];
}
element {
children: [ element-icon, element-text ];
}
element-icon {
size: 0px;
margin: 0;
}
message {
background-color: @NORD1;
padding: 6px 0 12px 12px;
}
textbox {
text-color: @NORD6;
background-color: transparent;
}
+166
View File
@@ -0,0 +1,166 @@
configuration {
me-select-entry: "MouseSecondary";
me-accept-entry: "MousePrimary";
scroll-method: 1;
show-icons: true;
sidebar-mode: true;
modi: "drun,internet:~/.config/rofi/rofi-filter internet,dev:~/.config/rofi/rofi-filter dev,games:~/.config/rofi/rofi-filter games,system:~/.config/rofi/rofi-filter system,media:~/.config/rofi/rofi-filter media,notifications:~/.config/rofi/rofi-filter notifications,clipboard:~/.config/rofi/rofi-filter clipboard";
display-drun: "ALL";
display-internet: "NET";
display-dev: "DEV";
display-games: "GMS";
display-system: "SYS";
display-media: "MED";
display-notifications: "NTF";
display-clipboard: "CLP";
kb-remove-to-eol: "";
kb-mode-complete: "";
kb-remove-char-back: "BackSpace,Shift+BackSpace";
kb-row-down: "Down,Control+j";
kb-row-up: "Up,Control+k";
kb-accept-entry: "Control+m,Return,KP_Enter";
}
* {
NORD0: #2e3440;
NORD1: #3b4252;
NORD2: #434c5e;
NORD3: #4c566a;
NORD4: #d8dee9;
NORD5: #e5e9f0;
NORD6: #eceff4;
NORD7: #8fbcbb;
NORD8: #88c0d0;
NORD9: #81a1c1;
NORD10: #5e81ac;
NORD11: #bf616a;
NORD12: #d08770;
NORD13: #ebcb8b;
NORD14: #a3be8c;
NORD15: #b48ead;
font: "Noto Sans Mono 10";
}
window {
background-color: @NORD0;
location: north west;
anchor: north west;
width: 540px;
height: 550px;
x-offset: 5px;
y-offset: 5px;
padding: 0px;
border: 0px;
border-radius: 0px;
children: [ sb-mainbox ];
}
sb-mainbox {
orientation: horizontal;
spacing: 0px;
children: [ left-bar-container, vertibox ];
}
left-bar-container {
background-color: @NORD0;
orientation: vertical;
width: 40px;
expand: false;
children: [ mode-switcher ];
}
mode-switcher {
orientation: vertical;
spacing: 0px;
padding: 0px;
}
button {
text-color: @NORD4;
background-color: transparent;
border-color: transparent;
horizontal-align: 0.5;
vertical-align: 0.5;
padding: 6px 0px;
border: 0px 0px 0px 2px;
font: "Noto Sans Mono Bold 8";
}
button selected {
text-color: @NORD6;
background-color: @NORD1;
border-color: @NORD8;
}
vertibox {
background-color: @NORD0;
orientation: vertical;
spacing: 0px;
padding: 0px;
children: [ inputbar, listview ];
}
inputbar {
background-color: transparent;
children: [ entry ];
}
entry {
text-color: @NORD6;
background-color: transparent;
placeholder-color: @NORD4;
padding: 6px;
placeholder: " [search...]";
}
listview {
background-color: transparent;
margin: 0px;
spacing: 0px;
columns: 1;
lines: 10;
border: 0px;
cycle: false;
dynamic: true;
scrollbar: false;
}
element {
background-color: transparent;
padding: 8px;
children: [ element-icon, element-text ];
}
element normal.normal,
element normal.urgent,
element normal.active {
text-color: @NORD6;
background-color: transparent;
}
element alternate.normal,
element alternate.urgent,
element alternate.active {
text-color: @NORD6;
background-color: transparent;
}
element selected.normal,
element selected.urgent,
element selected.active {
text-color: @NORD4;
background-color: @NORD1;
border: 0px 0px 0px 2px;
border-color: @NORD8;
}
element-icon {
background-color: transparent;
size: 14px;
margin: 0 8px 0 6px;
}
element-text {
text-color: inherit;
background-color: transparent;
}
+28
View File
@@ -0,0 +1,28 @@
@import "config.rasi"
window {
width: 540px;
height: 60px;
children: [ vertibox ];
}
vertibox {
children: [ label-box, inputbar ];
}
label-box {
background-color: @NORD1;
children: [ prompt ];
}
prompt {
text-color: @NORD4;
background-color: @NORD1;
border-color: @NORD8;
padding: 6px;
border: 0px 0px 0px 2px;
}
entry {
placeholder: " [password...]";
}
+75
View File
@@ -0,0 +1,75 @@
#!/usr/bin/env bash
set -uo pipefail
tmp_dir="/tmp/cliphist"
mkdir -p "$tmp_dir"
mode="${1:-}"
selection="${2:-}"
if [[ -n "$selection" ]]; then
if [[ "$mode" == "clipboard" ]]; then
id="${selection%% *}"
printf '%s' "$id" | clipvault get | wl-copy
elif [[ "$mode" == "notifications" ]]; then
body="${selection#*— }"
printf '%s' "$body" | wl-copy
else
target_app=$(grep -rl "^Name=${selection}\$" /usr/share/applications/*.desktop 2>/dev/null | head -n1)
if [[ -n "$target_app" ]]; then
exec_cmd=$(awk -F= '/^Exec=/{print $2; exit}' "$target_app" | sed 's/%[uUfFck]//g')
setsid $exec_cmd >/dev/null 2>&1 &
disown
fi
fi
exit 0
fi
case "$mode" in
clipboard)
find "$tmp_dir" -type f -mmin +30 -delete 2>/dev/null
while IFS=$'\t' read -r id rest; do
[[ "$id" =~ ^[0-9]+$ ]] || continue
[[ "$rest" == *"meta http-equiv"* ]] && continue
if [[ "$rest" == *"binary data"* ]]; then
ext=""
case "$rest" in
*jpeg*|*jpg*) ext="jpg" ;;
*png*) ext="png" ;;
*bmp*) ext="bmp" ;;
*) continue ;;
esac
img="$tmp_dir/$id.$ext"
[[ -s "$img" ]] || printf '%s\n' "$id" | clipvault get > "$img" 2>/dev/null
[[ -s "$img" ]] && printf '%s [IMG]\0icon\x1f%s\n' "$id" "$img"
else
printf '%s %s\n' "$id" "$rest"
fi
done < <(clipvault list)
;;
notifications)
dunstctl history | jq -r '
.data[0][] |
"\(.appname.data): \(.summary.data) — \(.body.data)"
'
;;
internet|dev|media|games|system)
case "$mode" in
internet) category="Network" ;;
dev) category="Development" ;;
media) category="AudioVideo" ;;
games) category="Game" ;;
system) category="System" ;;
esac
awk -v cat="$category" '
BEGINFILE { name=""; icon=""; match_cat=0 }
/^Categories=/ { if (index($0, cat)) match_cat=1 }
/^Name=/ && name=="" { sub(/^Name=/, ""); name=$0 }
/^Icon=/ && icon=="" { sub(/^Icon=/, ""); icon=$0 }
ENDFILE {
if (match_cat && name != "") {
if (icon != "") printf "%s\x00icon\x1f%s\n", name, icon
else printf "%s\n", name
}
}
' /usr/share/applications/*.desktop 2>/dev/null
;;
esac