Skip to main content

Customization Guide

Config-Sway is designed to be highly customizable while maintaining a consistent and coherent configuration structure. This guide covers common customization scenarios and best practices.

Configuration File Locations

All configuration files are located in ~/.config/:
Files managed by the theme system (theme.conf, Waybar colors, Kitty colors) will be overwritten when you switch themes. Make theme-specific customizations in the theme directories instead.

Customizing Keybindings

Adding New Keybindings

Edit ~/.config/sway/config and add your keybindings:
Group related keybindings together with comments for better organization. The default config groups bindings by category (Applications, Windows, Menus, etc.).

Changing Existing Keybindings

Find and modify existing bindings:

Using Different Modifier Keys

Change the modifier key in ~/.config/sway/config:5:

Vim-Style Navigation Alternatives

If you prefer arrow keys over HJKL:
You can keep both HJKL and arrow key bindings by adding duplicate bindings with arrow keys. This provides flexibility without losing Vim-style navigation.

Customizing Appearance

Window Borders and Gaps

These settings are in ~/.config/sway/theme.conf (managed by theme system):
To make permanent changes across themes, edit each theme’s sway/theme.conf:

Custom Window Colors

Edit theme color variables in ~/.config/sway/theme.conf:

Font Configuration

Change the system font in theme files:

Customizing Waybar

Adding New Modules

Edit ~/.config/waybar/config-sway.jsonc to add modules:
See the Waybar wiki for a complete list of available modules and their configuration options.

Customizing Waybar Style

Edit ~/.config/waybar/style.css for visual customization:

Customizing Terminal (Kitty)

Font and Size

Edit ~/.config/kitty/kitty.conf:

Opacity and Blur

Custom Key Mappings

Customizing Rofi Menus

Changing Rofi Theme

Rofi styles are located in ~/.config/rofi/styles/. The color palette is controlled by:
The palette file is automatically generated when you switch themes, but you can manually edit it for custom colors that persist until the next theme change.

Custom Rofi Scripts

Create custom Rofi menus in ~/.config/rofi/scripts/:
Make it executable and bind to a key:

Customizing Autostart Applications

Editing Autostart Script

Edit ~/.config/scripts/autostart.sh to control which applications launch on startup:

Adding Services to Sway Config

Edit ~/.config/sway/config to add services that should start immediately:
Use exec for commands that should run once on startup. Use exec_always for commands that should run on every config reload.

Input Device Customization

Keyboard Layout

Edit keyboard settings in ~/.config/sway/config:140-143:

Touchpad Customization

Mouse Customization

Find specific input device names with swaymsg -t get_inputs and configure them individually using input "device-name" { ... }

Monitor Configuration

Display Output Settings

Add output configuration to ~/.config/sway/config:
Find output names:

Workspace to Output Binding

Assign specific workspaces to specific monitors:

Window Rules

Floating Windows

Make specific applications float by default:

Window Size and Position

Workspace Assignment

Assign applications to specific workspaces:
Find application app_id values by running: swaymsg -t get_tree | grep app_id

Notification Customization (Mako)

Edit ~/.config/mako/config to customize notifications:
Reload Mako after changes:

Creating Configuration Backups

Before making significant changes, create backups:
The update.sh script creates automatic backups before applying changes, but manual backups before experiments are recommended.

Testing Configuration Changes

After making changes:
  1. Check syntax (for Sway config):
  2. Reload configuration:
  3. Check for errors:
Test configuration changes in a nested Sway session first: sway -c ~/.config/sway/config from within your current Sway session.