Automatically build and apply Bibata cursor themes that match your Omarchy theme colors.
When you switch Omarchy themes, this tool:
- Reads colors from the theme's
alacritty.toml - Computes aesthetically pleasing cursor colors (base, outline, watch background)
- Builds a custom Bibata cursor theme using
cbmp+ctgen - Installs it to
~/.local/share/icons/ - Applies it to Hyprland, XCursor, and GTK apps
Cached themes switch instantly (~0.1s). First-time builds take ~15-20 seconds.
- π¨ Intelligent color selection - Picks vibrant, contrasting colors from your theme
- β‘ Smart caching - Only rebuilds when theme colors actually change
- π Auto-sync - Integrates with Omarchy's theme hook system
- π₯οΈ Full stack support - Works with Hyprland, XWayland, and GTK apps
- βοΈ Configurable - Customize colors, sizes, and behavior
- OS: Arch-based with Hyprland (Omarchy)
- Python: 3.10+
- Node.js: 18+ (for
npx) - Dependencies:
- Bibata Cursor repo
- Python packages:
clickgen,toml
git clone https://github.com/yourusername/omarchy-cursor-sync.git
cd omarchy-cursor-syncgit clone https://github.com/ful1e5/Bibata_Cursor.git ~/src/Bibata_Cursor
cd ~/src/Bibata_Cursor && npm installpython3 -m venv ~/.local/bibata-venv
~/.local/bibata-venv/bin/pip install clickgen toml# Copy main script
cp omarchy-sync-cursor ~/.local/bin/
cp cursor-sync ~/.local/bin/
chmod +x ~/.local/bin/omarchy-sync-cursor ~/.local/bin/cursor-sync
# Create config directory and copy config
mkdir -p ~/.config/bibata-omarchy-sync
cp config.example.toml ~/.config/bibata-omarchy-sync/config.toml
# Install the theme-set hook for automatic syncing
cp hooks/theme-set.example ~/.config/omarchy/hooks/theme-set
chmod +x ~/.config/omarchy/hooks/theme-setAdd this line to your ~/.config/hypr/hyprland.conf:
source = ~/.config/hypr/cursor-auto.confLaunch the interactive color picker with full preset support:
cursor-sync --pickerGUI Features:
- π¨ HSV Color Controls - Hue bar + saturation/value pad
- π€ Hex Input - Direct hex color entry
- π― Persistent Presets - Save and reuse favorite colors (right-click to remove)
- π² Random Color - Generate vibrant random colors
- ποΈ Live Cursor Preview - See cursor in real-time with selected color
- β‘ Transparency Presets - Select glass, neon, shadow, or classic effects
# Sync cursor to a specific theme (auto-detects transparency)
cursor-sync catppuccin-mocha
# Preview what colors would be used (no changes)
cursor-sync one-dark-pro --dry-run
# Force rebuild even if cached
cursor-sync crimson --force
# Use specific transparency preset
cursor-sync gruvbox --transparency glass
cursor-sync tokyo-night --transparency neon
cursor-sync nord --transparency classicOnce the hook is installed, cursors sync automatically when you change themes:
omarchy-theme-set velvetnight
# Cursor automatically updates to match!Edit ~/.config/bibata-omarchy-sync/config.toml:
[paths]
# Path to Bibata cursor source
bibata_source_dir = "~/src/Bibata_Cursor"
# Cache directory for built themes
cache_dir = "~/.local/share/bibata-omarchy-cache"
[cursor]
# Cursor size (24, 32, 48, etc.)
size = 24
# SVG style: "modern" (rounded) or "original" (sharp)
style = "modern"
[color_mapping]
# Which theme color to use for cursor base
# Options: "cursor", "magenta", "cyan", "blue", "accent"
base_color_source = "cursor"
base_color_fallback = "magenta"
# Outline color source
# Options: "background", "black", "auto_contrast"
outline_color_source = "background"
[transparency]
# "auto" (default), "glass", "shadow", "neon", or "classic"
preset = "auto"The tool uses an intelligent algorithm to select aesthetically pleasing cursor colors:
- Uses the theme's cursor color if defined and distinct
- Falls back to vibrant accent colors (magenta β cyan β blue)
- Prefers colors with good contrast against the background
- For monochrome themes, uses foreground color
- Uses background color by default
- Automatically adjusts for minimum contrast ratio (3.5:1)
- Darkens/lightens as needed for visibility
- Uses a darkened version of background
- Ensures good visibility for animation states
The tool includes an intelligent theme-aware transparency system that automatically adapts cursor effects to match your theme.
All presets are cached independently, so switching between them is instant:
cursor-sync catppuccin-mocha # ~15s first build with auto-detected preset
cursor-sync catppuccin-mocha --transparency neon # ~15s first time, then instant on future use
cursor-sync catppuccin-mocha --transparency glass # ~15s first time, then instant on future use
cursor-sync catppuccin-mocha # Instant - uses cached versionEach theme + preset combination is cached separately in ~/.local/share/icons/, so:
Bibata-Omarchy-catppuccin-mocha(no preset suffix = default/classic)Bibata-Omarchy-catppuccin-mocha-glass(glass preset)Bibata-Omarchy-catppuccin-mocha-neon(neon preset)Bibata-Omarchy-catppuccin-mocha-shadow(shadow preset)
-
GLASS (default for dark themes): 75% opacity, polished semi-transparent look
- Best for modern, colorful dark themes
- Creates a clean, sophisticated aesthetic
- Slight transparency makes the underlying content subtly visible
-
SHADOW (alternative): 95% opacity, nearly opaque
- Best for minimal or high-contrast dark themes
- Maintains maximum cursor definition and visibility
- Subtle shadow-like appearance without transparency
-
NEON (dark vibrant themes): 60% opacity, more transparent with glow effect
- Best for dark themes with vibrant colors
- Gaming-oriented and cyberpunk aesthetic
- More pronounced transparency for futuristic look
-
CLASSIC (light themes & accessibility): 100% opacity, fully opaque
- Always used for light themes (transparency breaks visibility)
- Falls back for accessibility requirements
- Maximum cursor contrast and visibility
By default, the preset is automatically selected based on theme properties:
Dark theme + Highly saturated background β NEON
Dark theme (most cases) β GLASS
Light theme β CLASSIC
Set in config.toml:
[transparency]
# "auto" (default), "glass", "shadow", "neon", or "classic"
preset = "auto"Or override via CLI:
cursor-sync my-theme --transparency glass
cursor-sync my-theme --transparency neon| Feature | CLI | GUI |
|---|---|---|
| Color Selection | --base-color, --outline-color, --watch-color |
β Full HSV + hex input |
| Transparency Presets | --transparency auto/glass/neon/shadow/classic |
β Preset buttons |
| Theme Selection | <theme_name> positional arg |
β Use CLI instead |
| Random Color | --random flag |
β Random button |
| Color Presets | Config file only | β Persistent swatch grid |
| Dry-run Mode | --dry-run flag |
β Use CLI instead |
| Force Rebuild | --force flag |
β Use CLI instead |
| Current Theme | --current flag |
β Use CLI instead |
| Cursor Preview | Log output only | β Live preview |
Recommended Usage:
- GUI (
--picker): Perfect for picking colors with live preview and transparency effects - CLI: For automation, theme-based workflows, and advanced options
| File | Purpose |
|---|---|
~/.local/bin/omarchy-sync-cursor |
Main Python script |
~/.local/bin/cursor-sync |
Bash wrapper |
~/.config/bibata-omarchy-sync/config.toml |
Configuration |
~/.config/omarchy/hooks/theme-set |
Auto-sync hook |
~/.config/hypr/cursor-auto.conf |
Generated Hyprland config |
~/.local/share/bibata-omarchy-cache/ |
Build cache |
~/.local/share/icons/Bibata-Omarchy-* |
Installed cursor themes |
- Check if the hook ran:
cat ~/.local/share/bibata-omarchy-cache/hook.log - Verify Hyprland sources the config:
grep cursor-auto ~/.config/hypr/hyprland.conf - Try manual sync:
cursor-sync <theme-name>
- Ensure Bibata repo is set up:
ls ~/src/Bibata_Cursor/svg/ - Check npm dependencies:
cd ~/src/Bibata_Cursor && npm install - Verify Python venv:
~/.local/bibata-venv/bin/pip list | grep clickgen
- Check theme colors:
cat ~/.config/omarchy/themes/<theme>/alacritty.toml - Preview computed colors:
cursor-sync <theme> --dry-run - Adjust
config.tomlcolor mapping settings
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β omarchy-theme-set β
β β β
β βΌ β
β ~/.config/omarchy/hooks/theme-set β
β β β
β βΌ β
β cursor-sync <theme> β
β β β
β ββββββββββββββββββΌβββββββββββββββββ β
β βΌ βΌ βΌ β
β Parse colors Check cache Build if needed β
β from theme β β β
β β βΌ βΌ β
β β Hit? β Apply cbmp β ctgen β
β β β β
β βββββββββββββββββββββββββββββββββββ β
β β β
β βΌ β
β Apply cursor everywhere: β
β β’ hyprctl setcursor β
β β’ HYPRCURSOR_THEME env β
β β’ XCURSOR_THEME env β
β β’ gsettings (GTK) β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
- Bibata Cursor by @ful1e5
- Omarchy - The Arch + Hyprland distribution
MIT License - See LICENSE for details.