Pywal explantion, updated README, some specific changes in hyprland.conf

This commit is contained in:
duma97
2025-11-22 00:00:40 +04:00
parent aaf629dc1d
commit cd05b2d333
5 changed files with 278 additions and 241 deletions
+101
View File
@@ -0,0 +1,101 @@
# Pywal Colors Integration for Hyprland & Caelestia
This setup automatically applies pywal-generated colors to both Hyprland borders and Caelestia shell.
## Files Created
1. **`~/.config/wal/templates/hyprland-colors.conf`** - Template for Hyprland border colors
2. **`~/.config/wal/templates/caelestia-scheme.json`** - Template for Caelestia color scheme
3. **`~/.config/hypr/apply-pywal-colors.sh`** - Script to apply colors to both systems
## How It Works
- When you run `wal -i /path/to/wallpaper`, pywal automatically processes the templates
- The generated files are placed in `~/.cache/wal/`
- Hyprland sources `~/.cache/wal/hyprland-colors.conf` for border colors
- Caelestia reads from `~/.local/state/caelestia/scheme.json` for its color scheme
## Usage
### First Time Setup
Already done! Your Hyprland config now sources pywal colors automatically.
### Generate Colors from a Wallpaper
```bash
# Generate colors from a wallpaper
wal -i /path/to/your/wallpaper.png
# Apply colors to Hyprland and Caelestia
~/.config/hypr/apply-pywal-colors.sh
```
### Regenerate from Current Wallpaper
```bash
# Regenerate colors from the current cached wallpaper
wal -R
# Apply colors
~/.config/hypr/apply-pywal-colors.sh
```
### Quick Apply
```bash
# One-liner to generate and apply colors
wal -i /path/to/wallpaper.png && ~/.config/hypr/apply-pywal-colors.sh
```
## What Gets Colored
### Hyprland
- Active window border (gradient using colors 4 and 6)
- Inactive window border (using color 8)
### Caelestia Shell
- All Material Design 3 colors
- Terminal colors (term0-term15)
- Background, surface, and accent colors
- Complete color scheme based on wallpaper
## Customization
### Modify Border Colors
Edit `~/.config/wal/templates/hyprland-colors.conf` to use different pywal colors:
- Available variables: `{color0}` through `{color15}`, `{background}`, `{foreground}`, `{cursor}`
### Modify Caelestia Colors
Edit `~/.config/wal/templates/caelestia-scheme.json` to adjust color mappings.
After editing templates, run `wal -R` to regenerate colors.
## Automation
To automatically apply pywal colors on wallpaper change, you can add this to your autostart:
```bash
# In your ~/.config/hypr/hyprland.conf
exec-once = ~/.config/hypr/apply-pywal-colors.sh
```
Or create a wallpaper script that calls pywal automatically.
## Troubleshooting
### Colors not updating in Hyprland
```bash
# Reload Hyprland config
hyprctl reload
```
### Colors not updating in Caelestia
```bash
# Restart Caelestia shell
pkill caelestia && sleep 0.5 && caelestia shell -d &
```
### Check generated files
```bash
# View generated Hyprland colors
cat ~/.cache/wal/hyprland-colors.conf
# View generated Caelestia scheme
cat ~/.cache/wal/caelestia-scheme.json
```
+23 -217
View File
@@ -5,13 +5,15 @@ Personal Hyprland configuration focused on productivity and ergonomics.
## Features
### Enhanced Keybindings
- See in KEYBINDS.md (link below)
- **[KEYBINDS.md](KEYBINDS.md)** - Complete keybindings reference
### Visual & UX
- Minimal gaps (10px/40px) for space efficiency
- Blur effects and transparency
- Minimal gaps (3.5px/4.5px) for space efficiency
- Blur effects on waybar (in progress)
- Smooth custom animations with bezier curves
- **Pywal integration** - Dynamic colors from wallpaper (optional)
- Automatic floating for file pickers and dialogs (in progress)
- Picture-in-Picture auto-positioning (in progress)
### Input
- 3-finger gestures (horizontal: workspace, vertical: fullscreen)
@@ -22,30 +24,25 @@ Personal Hyprland configuration focused on productivity and ergonomics.
### Display Setup
- Dual monitor configuration (HDMI-A-1 flipped + eDP-1)
- Workspaces 1-4 on external monitor
- Workspaces 5-10 on laptop screen
- Workspace 5 on laptop screen
---
## Complete Installation Guide
Follow these steps in order to install the complete setup from scratch.
### Step 1: Install Required Packages
## Quick Start
### Requirements
```bash
# Core Hyprland components
sudo pacman -S hyprland hyprlock hyprshot wlogout
# Terminal emulator
# Terminal & Shell
sudo pacman -S kitty
# Status bar & Wallpaper manager
sudo pacman -S waybar swww waypaper hyprpaper
# Status bar & Wallpaper
sudo pacman -S waybar swww waypaper
# Application launcher
sudo pacman -S wofi
# File manager
# File manager (GNOME)
sudo pacman -S nautilus
# Audio control (PipeWire)
@@ -57,223 +54,32 @@ sudo pacman -S brightnessctl
# Media player control
sudo pacman -S playerctl
# Optional applications (adjust in config)
sudo pacman -S telegram-desktop spotify code # Telegram, Spotify, VSCode
yay -S google-chrome # Browser (AUR)
# Cursor theme
sudo pacman -S adwaita-cursors
# Pywal for dynamic colors (optional but recommended)
sudo pacman -S python-pywal
# Install rust/cargo if you don't have it (needed for Caelestia)
sudo pacman -S rust
```
### Step 2: Install Optional Applications
### Installation
```bash
# Applications referenced in config (adjust to your preference)
sudo pacman -S telegram-desktop spotify code
# Backup existing config
mv ~/.config/hypr ~/.config/hypr.backup
# AUR packages (requires yay or another AUR helper)
yay -S google-chrome zen-browser-bin # or your preferred browser
```
### Step 3: Install Caelestia Shell (Optional)
Caelestia is a modern shell with AI features that integrates with the pywal theming system.
```bash
# Install Caelestia via cargo
cargo install caelestia
# Start Caelestia daemon (it will auto-restart when pywal colors change)
caelestia shell -d &
```
**Note:** Caelestia runs as a background service and integrates with pywal for dynamic color theming.
### Step 4: Clone This Repository
```bash
# Clone to a temporary location
cd ~/Downloads
git clone https://github.com/yourusername/hyprduma-config.git
cd hyprduma-config
```
### Step 5: Backup Existing Configs (If Any)
```bash
# Backup existing Hyprland config
[ -d ~/.config/hypr ] && mv ~/.config/hypr ~/.config/hypr.backup
# Backup existing waybar config
[ -d ~/.config/waybar ] && mv ~/.config/waybar ~/.config/waybar.backup
# Backup existing wlogout config
[ -d ~/.config/wlogout ] && mv ~/.config/wlogout ~/.config/wlogout.backup
```
### Step 6: Install Hyprland Configuration
```bash
# Create Hypr config directory
# Create directory (if do not have already) and copy config
mkdir -p ~/.config/hypr
# Copy main config
cp hyprland.conf ~/.config/hypr/
# Create screenshots directory (used by config)
mkdir -p ~/Pictures/Screenshots
```
### Step 7: Configure Your Applications
**IMPORTANT:** Edit the config file to set your preferred applications.
```bash
# Open the config file
# Adjust your apps (lines 26-32) HIGHLY RECOMMENDED!!!
nvim ~/.config/hypr/hyprland.conf
# Find lines 27-34 and adjust these variables:
# $terminal = kitty # Your terminal
# $fileManager = dolphin # Your file manager
# $menu = wofi --show drun # Your app launcher
# $telegram = Telegram # Path to Telegram
# $spotify = spotify # Path to Spotify
# $vscode = code # Path to VSCode
# $browser = your-browser # Your browser command
# Reload or restart Hyprland
```
### Step 8: Install Pywal Integration (Optional but Recommended)
Pywal provides dynamic color theming based on your wallpaper.
```bash
# Install pywal templates
mkdir -p ~/.config/wal/templates
cp -r wal/templates/* ~/.config/wal/templates/
# Copy the color application script
cp apply-pywal-colors.sh ~/.config/hypr/
chmod +x ~/.config/hypr/apply-pywal-colors.sh
# Test pywal with a wallpaper
wal -i /path/to/your/wallpaper.png
# Apply colors to Hyprland and Caelestia
~/.config/hypr/apply-pywal-colors.sh
```
**What this does:**
- Generates a color scheme from your wallpaper
- Applies colors to Hyprland window borders
- Applies colors to Caelestia shell (if installed)
- Restarts necessary services to apply changes
### Step 9: Install Waybar Config (If You Have It)
```bash
# If you have waybar configs in this repo
mkdir -p ~/.config/waybar
cp -r waybar/* ~/.config/waybar/
```
### Step 10: Install Wlogout Config (If You Have It)
```bash
# If you have wlogout configs in this repo
mkdir -p ~/.config/wlogout
cp -r wlogout/* ~/.config/wlogout/
```
### Step 11: Start Hyprland
```bash
# If you're in a TTY, start Hyprland
Hyprland
# If already in Hyprland, reload the config
# Press SUPER + SHIFT + R (or restart Hyprland session)
```
### Step 12: Set Up Autostart for Caelestia (Optional)
If you want Caelestia to start automatically with Hyprland:
```bash
# Edit your Hyprland config
nvim ~/.config/hypr/hyprland.conf
# Add this line in the Autostart section (around line 21-25):
# exec-once = caelestia shell -d
```
---
## Post-Installation
### Setting Wallpaper with Pywal
```bash
# Generate colors and apply them
wal -i /path/to/wallpaper.png && ~/.config/hypr/apply-pywal-colors.sh
# Or use waypaper GUI to select wallpapers
waypaper
```
### Monitor Configuration
If you have different monitors, adjust lines 4-18 in `~/.config/hypr/hyprland.conf`:
```bash
nvim ~/.config/hypr/hyprland.conf
# Edit monitor configuration:
# monitor = eDP-1, 1920x1080@144, 1920x0, 1
# monitor = HDMI-A-1, 1920x1080@144, 0x0, 1, transform, 2
```
### Keyboard Layout
Default is US/RU with ALT+SHIFT toggle. To change, edit `~/.config/hypr/hyprland.conf` line 42:
```
kb_layout = us, ru # Change to your layouts
```
---
## Documentation
- **[KEYBINDS.md](KEYBINDS.md)** - Complete keybindings reference
- **[PYWAL-SETUP.md](PYWAL-SETUP.md)** - Detailed pywal integration guide
---
## Troubleshooting
### Hyprland won't start
- Check if all required packages are installed
- Review error logs: `journalctl -b | grep hyprland`
### Applications don't launch
- Make sure you edited the app variables in `hyprland.conf` (lines 27-34)
- Check if the applications are actually installed
### Pywal colors not applying
- Ensure the script is executable: `chmod +x ~/.config/hypr/apply-pywal-colors.sh`
- Check if pywal cache exists: `ls ~/.cache/wal/`
- Manually reload: `~/.config/hypr/apply-pywal-colors.sh`
### Caelestia colors not updating
```bash
# Restart Caelestia daemon
pkill caelestia && sleep 0.5 && caelestia shell -d &
```
---
## Note
Everything is still in progress. Feel free to customize and adjust to your needs!
Everything is still in progress.
+6
View File
@@ -1,19 +1,25 @@
#!/bin/bash
# Script to apply pywal colors to Hyprland and Caelestia shell
# Generate pywal colors (this assumes you've already run 'wal -i /path/to/wallpaper')
# The templates will be automatically processed
echo "Applying pywal colors to Hyprland and Caelestia..."
# Copy the generated Caelestia scheme to the proper location
if [ -f ~/.cache/wal/caelestia-scheme.json ]; then
mkdir -p ~/.local/state/caelestia
cp ~/.cache/wal/caelestia-scheme.json ~/.local/state/caelestia/scheme.json
echo "✓ Caelestia colors updated"
fi
# Reload Hyprland configuration
if command -v hyprctl &> /dev/null; then
hyprctl reload
echo "✓ Hyprland configuration reloaded"
fi
# Restart Caelestia shell to apply new colors
if pgrep -x "caelestia" > /dev/null; then
pkill caelestia
sleep 0.5
+38 -24
View File
@@ -19,7 +19,7 @@ workspace = 9, monitor:eDP-1
workspace = 10, monitor:eDP-1
# Autostart
exec-once = waybar
exec-once = caelestia shell -d # Caelestia shell (replaces waybar)
exec-once = hyprpaper
exec-once = hyprctl setcursor Adwaita 24 # Needed on NixOS
exec-once = mkdir -p $HOME/Pictures/Screenshots
@@ -57,9 +57,10 @@ input {
}
# Gestures
gesture = 3, horizontal, workspace
gesture = 3, vertical, fullscreen
#gesture = 3, horizontal, workspace
#gesture = 3, vertical, fullscreen
# Source pywal colors for borders
source = ~/.cache/wal/hyprland-colors.conf
# General settings
@@ -74,6 +75,8 @@ general {
layout = dwindle
# Border colors are now sourced from pywal (see above)
# If pywal colors not generated yet, fallback colors will be used
}
# Decoration settings (borders)
@@ -84,15 +87,15 @@ decoration {
active_opacity = 0.985
inactive_opacity = 0.85
shadow {
enabled = true
range = 4
render_power = 3
color = rgba(1a1a1aee)
}
#shadow {
# enabled = true
# range = 4
# render_power = 3
# color = rgba(1a1a1aee)
#}
blur {
enabled = true
enabled = false # Disabled for 144Hz performance
size = 3
passes = 1
@@ -110,21 +113,21 @@ animations {
bezier = emphasizedDecel, 0.05, 0.7, 0.1, 1
bezier = standard, 0.2, 0, 0, 1
# Animation configs
animation = layersIn, 1, 5, emphasizedDecel, slide
animation = layersOut, 1, 4, emphasizedAccel, slide
animation = fadeLayers, 1, 5, standard
# Animation configs - optimized for 144Hz
animation = layersIn, 1, 3, emphasizedDecel, slide
animation = layersOut, 1, 2, emphasizedAccel, slide
animation = fadeLayers, 1, 3, standard
animation = windowsIn, 1, 5, emphasizedDecel
animation = windowsOut, 1, 3, emphasizedAccel
animation = windowsMove, 1, 7, standard
animation = workspaces, 1, 5, standard
animation = windowsIn, 1, 3, emphasizedDecel
animation = windowsOut, 1, 2, emphasizedAccel
animation = windowsMove, 1, 3, standard
animation = workspaces, 1, 3, standard
animation = specialWorkspace, 1, 4, specialWorkSwitch, slidefadevert 15%
animation = specialWorkspace, 1, 3, specialWorkSwitch, slidefadevert 15%
animation = fade, 1, 6, standard
animation = fadeDim, 1, 6, standard
animation = border, 1, 6, standard
animation = fade, 1, 3, standard
animation = fadeDim, 1, 3, standard
animation = border, 1, 3, standard
}
# Layouts
@@ -141,6 +144,7 @@ misc {
disable_splash_rendering = true
key_press_enables_dpms = true
mouse_move_enables_dpms = true
vfr = true # Enable for proper 144Hz rendering
vrr = 0
}
@@ -184,8 +188,11 @@ windowrule = pin, title:^(Picture-in-Picture)$
windowrule = move 69.5% 4%, title:^(Picture-in-Picture)$
# Layer Rules
layerrule = blur, waybar
layerrule = ignorealpha 0.5, waybar
# Caelestia shell layer rules
layerrule = animation fade, caelestia-(drawers|background)
layerrule = blur, caelestia-drawers
layerrule = ignorealpha 0.57, caelestia-drawers
layerrule = noanim, caelestia-(border-exclusion|area-picker)
layerrule = blur, wofi
layerrule = ignorealpha 0.2, wofi
@@ -196,6 +203,12 @@ $mainMod = SUPER # Sets "Windows" key as main modifier
$mainMod2 = ALT # Secondary modifier for window management (ALT Button)
$shiftMod = SHIFT
# Caelestia launcher (Super key tap)
#bindi = Super, Super_L, global, caelestia:launcher
#bindin = Super, catchall, global, caelestia:launcherInterrupt
#bindin = Super, mouse:272, global, caelestia:launcherInterrupt
#bindin = Super, mouse:273, global, caelestia:launcherInterrupt
# System binds
bind = $mainMod, C, killactive,
bind = $mainMod, M, exit, # Safer exit combination
@@ -205,6 +218,7 @@ bind = $mainMod, L, exec, hyprlock
bind = $mainMod, O, togglesplit, # Toggle split direction
bind = $mainMod, P, exec, poweroff
bind = $mainMod, RETURN, exec, wlogout
bind = $mainMod SHIFT, B, exec, hyprctl keyword decoration:blur:enabled toggle # Toggle blur on/off
# App launcher
bind = $mainMod, R, exec, $menu
+110
View File
@@ -0,0 +1,110 @@
$primary_paletteKeyColor = 6f72ac
$secondary_paletteKeyColor = 75758e
$tertiary_paletteKeyColor = 9d648f
$neutral_paletteKeyColor = 78767b
$neutral_variant_paletteKeyColor = 777680
$background = 131317
$onBackground = e5e1e7
$surface = 131317
$surfaceDim = 131317
$surfaceBright = 39393d
$surfaceContainerLowest = 0e0e11
$surfaceContainerLow = 1b1b1f
$surfaceContainer = 1f1f23
$surfaceContainerHigh = 2a292e
$surfaceContainerHighest = 353438
$onSurface = e5e1e7
$surfaceVariant = 46464f
$onSurfaceVariant = c7c5d1
$inverseSurface = e5e1e7
$inverseOnSurface = 303034
$outline = 918f9a
$outlineVariant = 46464f
$shadow = 000000
$scrim = 000000
$surfaceTint = bfc1ff
$primary = bfc1ff
$onPrimary = 282b60
$primaryContainer = 6f72ac
$onPrimaryContainer = 000028
$inversePrimary = 565992
$secondary = c5c4e0
$onSecondary = 2e2f44
$secondaryContainer = 44455c
$onSecondaryContainer = b3b3ce
$tertiary = f4b2e2
$onTertiary = 4e1e45
$tertiaryContainer = ba7eaa
$onTertiaryContainer = 000000
$error = ffb4ab
$onError = 690005
$errorContainer = 93000a
$onErrorContainer = ffdad6
$primaryFixed = e0e0ff
$primaryFixedDim = bfc1ff
$onPrimaryFixed = 12144a
$onPrimaryFixedVariant = 3e4278
$secondaryFixed = e1e0fd
$secondaryFixedDim = c5c4e0
$onSecondaryFixed = 191a2e
$onSecondaryFixedVariant = 44455c
$tertiaryFixed = ffd7f1
$tertiaryFixedDim = f4b2e2
$onTertiaryFixed = 35082f
$onTertiaryFixedVariant = 67355d
$term0 = 353434
$term1 = a875ff
$term2 = 44def5
$term3 = ffdcf2
$term4 = 97aad7
$term5 = b29feb
$term6 = 9dceff
$term7 = e8d3de
$term8 = ac9fa9
$term9 = bd95ff
$term10 = 89ecff
$term11 = fff0f6
$term12 = b4c1dc
$term13 = c8b5f5
$term14 = bae0ff
$term15 = ffffff
$rosewater = f7eff9
$flamingo = e8def3
$pink = e1d8ff
$mauve = bdb9ff
$red = bfa6fe
$maroon = c7b6ed
$peach = e0c2f9
$yellow = ffecf3
$green = c8e3ff
$teal = d2e0ff
$sky = cedaff
$sapphire = b5c5ff
$blue = aeb8ff
$lavender = c6c8ff
$klink = 7083d2
$klinkSelection = 6f83d2
$kvisited = 7e73db
$kvisitedSelection = 7d73db
$knegative = 9d69ff
$knegativeSelection = 9b6aff
$kneutral = c794ff
$kneutralSelection = c794ff
$kpositive = 60adff
$kpositiveSelection = 60adff
$text = e5e1e7
$subtext1 = c7c5d1
$subtext0 = 918f9a
$overlay2 = 7e7c86
$overlay1 = 6b6972
$overlay0 = 595860
$surface2 = 48474e
$surface1 = 37373d
$surface0 = 25252a
$base = 131317
$mantle = 131317
$crust = 121216
$success = B5CCBA
$onSuccess = 213528
$successContainer = 374B3E
$onSuccessContainer = D1E9D6