Skip to content

Add Framework Desktop ARGB fan RGB theme syncing#4593

Open
chipkoziara wants to merge 4 commits intobasecamp:devfrom
chipkoziara:framework-desktop-rgb-support
Open

Add Framework Desktop ARGB fan RGB theme syncing#4593
chipkoziara wants to merge 4 commits intobasecamp:devfrom
chipkoziara:framework-desktop-rgb-support

Conversation

@chipkoziara
Copy link

@chipkoziara chipkoziara commented Feb 13, 2026

Add Framework Desktop ARGB Fan RGB Theme Syncing

Summary

Adds automatic RGB theme synchronization for Framework Desktop ARGB fans. The fan colors now automatically match Omarchy theme's accent color. Inspired by PR #4524.

What's Changed

Core Functionality

  • Automatic theme syncing: Fan RGB colors update when a user changes themes
  • Startup integration: Fan colors apply automatically on login/startup
  • Per-theme overrides: Optional custom 8-color patterns per theme via ~/.config/omarchy/fan-colors/<theme-name>.txt

Implementation Details

New Commands:

  • omarchy-hw-framework-desktop - Hardware detection for Framework Desktop
  • omarchy-theme-set-fan - Unified fan RGB setter (extensible for future hardware) similar to the pattern used in PR #4524
  • omarchy-theme-set-fan-framework-desktop - Framework-specific RGB implementation

Integration Points:

  • Hooks into omarchy-theme-set for automatic theme changes
  • Added to default/hypr/autostart.conf for startup synchronization
  • Uses framework_tool from framework-system package

Configuration:

  • Auto-generates themed color file: ~/.config/omarchy/current/theme/framework-desktop-fan.rgb
  • Supports user overrides in ~/.config/omarchy/fan-colors/ directory
  • Passwordless sudo configuration via /etc/sudoers.d/framework-tool (this is necessary for framework-tool usage to set fan colors)

Migration

  • Installs framework-system package on Framework Desktop hardware
  • Configures sudoers for passwordless framework_tool access
  • Only runs on Framework Desktop systems (gracefully skips on other hardware)

Hardware Support

Currently Supported:

  • Framework Desktop with ARGB fan module

Graceful Degradation:

  • Automatically detects Framework Desktop hardware via DMI
  • Silently exits on non-Framework systems (no errors, no performance impact)
  • Architecture is extensible for future RGB fan implementations

Testing

Tested on Framework Desktop with ARGB fan:

  • ✅ Theme changes apply fan colors immediately
  • ✅ Fan colors persist on system startup/login
  • ✅ Per-theme color overrides work correctly

Files Changed

  • bin/omarchy-hw-framework-desktop - Hardware detection
  • bin/omarchy-theme-set - Added fan RGB call
  • bin/omarchy-theme-set-fan - Unified dispatcher
  • bin/omarchy-theme-set-fan-framework-desktop - Framework implementation
  • default/hypr/autostart.conf - Added startup RGB sync
  • default/themed/framework-desktop-fan.rgb.tpl - Theme color template
  • install/config/all.sh - Config installation hook
  • install/config/hardware/framework-desktop-argb.sh - Hardware-specific config
  • install/packaging/all.sh - Package installation hook
  • install/packaging/framework-desktop.sh - Framework package list
  • migrations/1770478375.sh - Migration for existing users

Documentation

For Users:

The fan colors will automatically sync with your theme. To customize colors for a specific theme:

  1. Create ~/.config/omarchy/fan-colors/<theme-name>.txt
  2. Add 8 hex colors (one per line), e.g.:
    #ff0000
    #00ff00
    #0000ff
    #ffff00
    #ff00ff
    #00ffff
    #ffffff
    #000000
    

To Extend for Additional Hardware:

The architecture supports adding RGB support for other hardware. To add support for new RGB fans:

  1. Create bin/omarchy-theme-set-fan-<hardware>
  2. Add hardware detection with omarchy-hw-<hardware>
  3. Call from bin/omarchy-theme-set-fan
  4. Follow the graceful degradation pattern (exit 0 if hardware not present)

This is my first non-trivial PR, and I used OpenCode heavily to get this built out... please let me know if there's anything I need to adjust!

Adds omarchy-theme-set-fan to autostart.conf so fan colors sync with
the active theme automatically on login. Gracefully handles systems
without RGB fan hardware (exits silently with no side effects).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant