Setting up my Terminal

  1. Install sudo dnf install hyprland

  2. Remove autogenerated=1 from ./config/hypr/hyperland.conf to remove warning

  3. Chance scale to 1 monitor=,preferred,auto,1.5 The above is resolution, (something), scale

  4. Adding dependencies, packages: sudo dnf copr enable solopasha/hyprland

Then sudo dnf install wayland-devel wayland-protocols-devel hyprlang-devel pango-devel cairo-devel file-devel libglvnd-devel libglvnd-core-devel libjpeg-turbo-devel libwebp-devel libjxl-devel gcc-c++ hyprutils-devel hyprwayland-scanner

Installing waybar: sudo dnf install waybar

  1. Configuring binds

$mainMod = ALT #changes from the default windows key

For shortcuts

Basic: bind = MODS, key, dispatcher, params

for example,

bind = SUPER_SHIFT, Q, exec, firefox

Using https://github.com/cebem1nt/dotfiles/blob/main/.config/hypr/configs/environ.conf environment setup for graphics stuff.

Setting up the config in the following format:

.config/
    hypr/
        configs/
            ...
        scripts/
            ...
    hyprland.conf
    hypridle.conf

hyprland.conf should source the stuff in /hypr/configs/:

# https://wiki.hyprland.org/Configuring/Configuring-Hyprland/

monitor=eDP-1,1920x1080@144,0x0,1
monitor=,preferred,auto,1,mirror,eDP-1

# ==--==--==--==--==--==--==--==--==--==--==--== #

$CONFIGS = ~/.config/hypr/configs

source = $CONFIGS/environ.conf
source = $CONFIGS/exec.conf
source = $CONFIGS/binds.conf
source = $CONFIGS/settings.conf
source = $CONFIGS/animations.conf
source = $CONFIGS/rules.conf

Installing swaync for notifications:

https://github.com/ErikReider/SwayNotificationCenter

dnf copr enable erikreider/SwayNotificationCenter
# Or latest stable release or -git package
dnf install SwayNotificationCenter
dnf install SwayNotificationCenter-git

For /exec.conf#

exec-once = wl-paste --type text --watch cliphist -max-items=15 store
exec-once = wl-paste --type image --watch cliphist -max-items=5 store

This is Hyprland (Wayland compositor) startup configuration for clipboard management. Breaking down the low-level mechanics: Line 1-2: Clipboard History Monitoring bashwl-paste –type text –watch cliphist -max-items=15 store wl-paste –type image –watch cliphist -max-items=5 store wl-paste mechanics:

Opens a Wayland client connection via wl_display_connect() Registers with the compositor’s wl_data_device_manager protocol interface Creates a wl_data_device listener that receives data_offer events when clipboard content changes –watch polls the clipboard in a loop, blocking on wl_display_dispatch() waiting for selection events When the wl_data_source changes (new clipboard content), it reads the offered MIME type via wl_data_offer_receive() which creates a pipe Reads from pipe’s FD and writes to stdout

Why two separate invocations:

Wayland clipboard offers can contain multiple MIME types simultaneously –type text filters for text/* MIME types only –type image filters for image/* MIME types Running both ensures you capture the correct format without trying to store an image as text or vice versa

cliphist storage:

Receives clipboard data via stdin pipe Stores in SQLite database (typically ~/.cache/cliphist/db) -max-items implements LRU eviction via DELETE FROM clipboard WHERE rowid NOT IN (SELECT rowid FROM clipboard ORDER BY timestamp DESC LIMIT ?) 15 text vs 5 image limit because images are ~100-1000x larger in bytes

Line 3: Clipboard Persistence bashwl-clip-persist –clipboard regular Why this is necessary: In Wayland, clipboard content is not stored by the compositor. The wl_data_source is owned by the application that created it. When that app closes, its Wayland client connection dies, and the wl_data_source is destroyed → clipboard is empty. wl-clip-persist solution:

Acts as a daemon that intercepts clipboard changes When it detects new content, it reads the entire buffer into memory Becomes the new wl_data_source owner via wl_data_device_manager_create_data_source() When original app closes, the clipboard still works because wl-clip-persist owns a copy –clipboard regular specifies the selection buffer (as opposed to primary for middle-click paste)

Low-level flow:

App calls wl_data_device_set_selection() with its wl_data_source wl-clip-persist receives the data_device.selection event Calls wl_data_offer_receive() to get a pipe FD Reads entire buffer: read(fd, buf, size) Creates new wl_data_source with wl_data_source_offer() advertising same MIME types Calls wl_data_device_set_selection() with its own source When other apps request paste, serves from its buffer via write(fd, buf, size)

ROFI#

sudo dnf install rofi sudo dnf install papirus-icon-theme

Installation Instructions