A clean Sway desktop configuration for a fast Wayland workflow. This setup includes Sway, Waybar, Mako, Swaylock, MIME defaults, screenshot shortcuts, and a macOS-style Wi-Fi popup with a native GTK toggle switch, driven directly by NetworkManager (no polling).
The images below are visible placeholders. Replace them with real screenshots or GIFs when you record your setup.
| Desktop | Network Popup |
|---|---|
![]() |
![]() |
| Lock Screen | Notifications |
|---|---|
![]() |
![]() |
- Sway configuration with
Mod4keybindings and Vim-style focus movement. - Optional SwayFX support (rounded corners, blur, shadows) -
swayfx.confis only loaded when the swayfx binary is actually installed, so plain sway still works. - Waybar top panel with workspaces, active window title, tray, audio, network, CPU, memory, and clock modules.
- macOS-style Wi-Fi popup (
waybar/wifi-popup/): GTK3 + libnm, native toggle switch, Known/Other Networks sections, inline password prompt, right-click to forget a saved network. Fully signal-driven off NetworkManager's own D-Bus events, not polling. A Wofi/nmclifallback popup is kept inwaybar/scripts/network-popup.sh. - Searchable keybindings cheat sheet on
Mod + h(reads this repo's ownsway/configand greps everybindsym). - Mako notification styling with translucent dark colors and accent borders.
- Swaylock theme with image background and visible lock states.
- MIME defaults for Firefox, MPV, Dolphin, and IMV.
- Screenshot bindings using
grim,slurp, andwl-copy.
sway/
├── README.md
├── LICENSE
├── sway/
│ ├── config
│ ├── swayfx.conf # corner_radius/blur/shadows - only used if swayfx is installed
│ ├── idle.sh
│ ├── lock.sh
│ └── show_keybindings.sh # Mod+h searchable keybindings popup
├── waybar/
│ ├── config
│ ├── style.css
│ ├── network-popup.css
│ ├── scripts/
│ │ └── network-popup.sh # fallback Wofi/nmcli popup
│ └── wifi-popup/ # macOS-style GTK Wi-Fi popup (default on-click)
│ ├── wifi_popup.py
│ ├── ui.py
│ ├── network.py
│ ├── animations.py
│ ├── config.py
│ └── styles.css
├── assets/
│ └── preview/
│ ├── desktop.svg
│ ├── desktop.png
│ ├── network-popup.svg
│ ├── network-popup.png
│ ├── lockscreen.svg
│ ├── lockscreen.png
│ ├── notifications.svg
│ └── notifications.png
├── mako/
│ └── config
├── swaylock/
│ └── config
└── applications/
├── mimeapps.list
└── imv-image-viewer.desktop
Install the core packages before applying the configuration.
sudo pacman -S --needed \
sway waybar mako swaylock swayidle \
kitty wofi firefox dolphin thunderbird code discord \
networkmanager nm-connection-editor \
pipewire pipewire-pulse pavucontrol \
brightnessctl grim slurp wl-clipboard cliphist jq \
imv mpv ttf-jetbrains-mono-nerd \
python-gobject gtk-layer-shell libnmpython-gobject, gtk-layer-shell, and libnm are only needed for the Wi-Fi popup (waybar/wifi-popup/). swayfx itself is AUR-only and optional - sway/swayfx.conf is simply skipped if it isn't installed.
sudo dnf install \
sway waybar mako swaylock swayidle \
kitty wofi firefox dolphin thunderbird code discord \
NetworkManager-applet nm-connection-editor \
pavucontrol brightnessctl grim slurp wl-clipboard cliphist \
imv mpv jetbrains-mono-fonts-allSome package names can differ by distribution. Make sure NetworkManager, PipeWire, and your display manager or TTY session are set up for Wayland.
Clone the repository:
git clone https://github.com/ravindran-dev/sway.git
cd swayBack up your existing configuration:
mkdir -p ~/.config-backup
cp -r ~/.config/sway ~/.config-backup/sway 2>/dev/null || true
cp -r ~/.config/waybar ~/.config-backup/waybar 2>/dev/null || true
cp -r ~/.config/mako ~/.config-backup/mako 2>/dev/null || true
cp -r ~/.config/swaylock ~/.config-backup/swaylock 2>/dev/null || true
cp ~/.config/mimeapps.list ~/.config-backup/mimeapps.list 2>/dev/null || trueCopy the dotfiles:
mkdir -p ~/.config
cp -r sway waybar mako swaylock ~/.config/
cp applications/mimeapps.list ~/.config/mimeapps.list
mkdir -p ~/.local/share/applications
cp applications/imv-image-viewer.desktop ~/.local/share/applications/
chmod +x ~/.config/waybar/scripts/network-popup.shReload Sway:
swaymsg reloadRestart Waybar if needed:
pkill -x waybar
waybar -c ~/.config/waybar/config -s ~/.config/waybar/style.cssThe current config references local files under /home/ravi:
/home/ravi/Pictures/wallpaper.png
/home/ravi/Pictures/iron.png
/home/ravi/.config/waybar/config
/home/ravi/.config/waybar/style.css
/home/ravi/.config/swaylock/config
If your username or wallpaper paths are different, update these files:
nvim ~/.config/sway/config
nvim ~/.config/swaylock/config| Binding | Action |
|---|---|
Mod + Return |
Open Kitty |
Mod + d |
Open Wofi launcher |
Mod + q |
Close focused window |
Mod + Shift + c |
Reload Sway |
Mod + Shift + e |
Exit Sway |
Mod + Left/j/k/l |
Move focus (left/down/up/right) |
Mod + Shift + Left/j/k/l |
Move window |
Mod + 1..5 |
Switch workspace |
Mod + Shift + 1..5 |
Move window to workspace |
Mod + f |
Toggle fullscreen |
Mod + v |
Split vertical |
Mod + Shift + b |
Split horizontal |
Mod + s |
Stacking layout |
Mod + w |
Tabbed layout |
Mod + Shift + Space |
Toggle floating |
Mod + h |
Searchable keybindings popup |
Print |
Full screenshot |
Shift + Print |
Area screenshot |
Ctrl + Print |
Copy area screenshot |
Mod + Shift + s |
Area screenshot: save + copy to clipboard |
Mod + b |
Open Firefox |
Mod + e |
Open Dolphin |
Mod + Shift + m |
Open Thunderbird |
Mod + Shift + v |
Open VS Code |
Mod + Shift + d |
Open Discord |
Clicking the Waybar network module launches the macOS-style GTK popup:
python3 ~/.config/waybar/wifi-popup/wifi_popup.pyIt reads NetworkManager directly through libnm's GObject introspection binding and reacts to its D-Bus signals - there's no polling loop anywhere. Shows the connected network under "Known Network" with a checkmark, lists nearby APs under "Other Networks" with signal/lock icons, and has a real Gtk.Switch toggle for radio on/off. Right-click a known network to forget it; click one you're not on to connect (secured + not-yet-saved networks get an inline password prompt instead of failing silently). Clicking the module again, pressing Escape, or clicking anywhere else closes it.
The older Wofi/nmcli popup is still in the repo as a lighter-weight fallback:
~/.config/waybar/scripts/network-popup.shUse wf-recorder to create the GIF source video:
mkdir -p assets/preview
wf-recorder -f /tmp/sway-preview.mp4Convert it to a GIF:
ffmpeg -i /tmp/sway-preview.mp4 \
-vf "fps=15,scale=1280:-1:flags=lanczos" \
assets/preview/desktop.gifRecord focused previews for:
assets/preview/desktop.gif
assets/preview/network-popup.gif
assets/preview/lockscreen.gif
assets/preview/notifications.gif
After recording real GIFs, update the preview image paths in this README from .png to .gif.
Check Sway configuration:
sway -C -c ~/.config/sway/configCheck Waybar directly:
waybar -l trace -c ~/.config/waybar/config -s ~/.config/waybar/style.cssCheck Mako:
makoctl mode
notify-send "Mako" "Notification test"Check Swaylock:
swaylock -f -C ~/.config/swaylock/configCheck MIME defaults:
xdg-mime query default image/png
xdg-mime query default video/mp4
xdg-mime query default text/htmlDeveloper • ML Enthusiast • Neovim Customizer • Linux Power User
Hi! I'm Ravindran S, an engineering student passionate about:
- Linux & System Engineering
- AIML (Artificial Intelligence & Machine Learning)
- Full-stack Web Development
- Hackathon-grade project development
R NVIM is my personal Neovim distribution - built to be fast, beautiful, and productive.
You can reach me here:
This project is licensed under the MIT License.



