hyprland.lua: some cleaning up

This commit is contained in:
2026-09-20 20:50:20 +02:00
parent a083e0d470
commit 431b491ed6
+10 -109
View File
@@ -7,35 +7,12 @@ local var_fileManager = "dolphin"
local var_menu = "wofi --show drun"
local var_screenshot_folder = "~/Bilder/Screenshots/"
-- #######################################################################################
-- AUTOGENERATED HYPRLAND CONFIG.
-- EDIT THIS CONFIG ACCORDING TO THE WIKI INSTRUCTIONS.
-- #######################################################################################
-- This is an example Hyprland config file.
-- Refer to the wiki for more information.
-- https://wiki.hypr.land/Configuring/
-- Please note not all available settings / options are set here.
-- For a full list, see the wiki
-- You can split this configuration into multiple files
-- Create your files separately and then link them to this file like this:
-- source = ~/.config/hypr/myColors.conf
require("env")
hl.exec_cmd("bash ~/.config/hypr/env.sh")
-- ###############
-- ## MONITORS ###
-- ###############
require("monitor_setup")
@@ -47,33 +24,13 @@ hl.config({
})
-- ##################
-- ## MY PROGRAMS ###
-- ##################
-- See https://wiki.hypr.land/Configuring/Keywords/
-- Set programs that you use
-- $menu = hyprlauncher
-- ################
-- ## AUTOSTART ###
-- ################
-- Autostart necessary processes (like notifications daemons, status bars, etc.)
-- Or execute your favorite apps at launch like this:
-- exec = bash ~/.config/wpaperd/link_wallpapers.sh
hl.on("hyprland.start", function()
hl.exec_cmd("waybar &")
end)
-- exec-one = hyprpaper &
hl.on("hyprland.start", function()
hl.exec_cmd("wpaperd &")
hl.exec_cmd("swaync &")
@@ -83,20 +40,8 @@ hl.on("hyprland.start", function()
hl.exec_cmd("sh ~/.config/hypr/scripts/ensure-mime-defaults.sh")
end)
-- exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP XDG_SESSION_DESKTOP XDG_SESSION_TYPE XDG_MENU_PREFIX
-- exec-once = systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP XDG_SESSION_DESKTOP XDG_SESSION_TYPE XDG_MENU_PREFIX
-- exec = gsettings set org.gnome.desktop.interface gtk-theme "Breeze-Dark" # for GTK3 apps
-- exec = gsettings set org.gnome.desktop.interface color-scheme "prefer-dark" # for GTK4 apps
-- env = QT_QPA_PLATFORMTHEME,qt6ct # for Qt apps
-- ############################
-- ## ENVIRONMENT VARIABLES ###
-- ############################
-- See https://wiki.hypr.land/Configuring/Environment-variables/
@@ -111,49 +56,20 @@ hl.env("GTK_THEME", "Adwaita:dark")
hl.env("QT_WAYLAND_DISABLE_WINDOWDECORATION", "1")
hl.env("QT_QPA_PLATFORMTHEME", "kde")
-- env = QT_AUTO_SCREEN_SCALE_FACTOR,0.75
-- env = QT_SCALE_FACTOR,0.75
-- env = GDK_SCALE,1.5
-- env = GDK_DPI_SCALE,0.75
-- ##################
-- ## PERMISSIONS ###
-- ##################
-- See https://wiki.hypr.land/Configuring/Permissions/
-- Please note permission changes here require a Hyprland restart and are not applied on-the-fly
-- for security reasons
-- ecosystem {
-- enforce_permissions = 1
-- }
-- permission = /usr/(bin|local/bin)/grim, screencopy, allow
-- permission = /usr/(lib|libexec|lib64)/xdg-desktop-portal-hyprland, screencopy, allow
-- permission = /usr/(bin|local/bin)/hyprpm, plugin, allow
-- ####################
-- ## COLOR SCHEMES ###
-- ####################
require("themes.mocha")
-- ####################
-- ## LOOK AND FEEL ###
-- ####################
-- Refer to https://wiki.hypr.land/Configuring/Variables/
@@ -412,9 +328,7 @@ hl.config({
})
-- ############
-- ## INPUT ###
-- ############
-- https://wiki.hypr.land/Configuring/Variables/#input
@@ -450,9 +364,7 @@ hl.device({
})
-- ##################
-- ## KEYBINDINGS ###
-- ##################
-- See https://wiki.hypr.land/Configuring/Keywords/
@@ -473,21 +385,13 @@ hl.bind(var_mainMod .. " + SHIFT + J", hl.dsp.layout("togglesplit"))
hl.bind(var_mainMod .. " + I", hl.dsp.exec_cmd("firefox &"))
hl.bind(var_mainMod .. " + n", hl.dsp.exec_cmd("~/.local/bin/hyprltm-net"))
-- Move focus with mainMod + WASD or Vim-style
hl.bind(var_mainMod .. " + a", hl.dsp.focus({ direction = "left" }))
hl.bind(var_mainMod .. " + d", hl.dsp.focus({ direction = "right" }))
hl.bind(var_mainMod .. " + w", hl.dsp.focus({ direction = "up" }))
hl.bind(var_mainMod .. " + s", hl.dsp.focus({ direction = "down" }))
hl.bind(var_mainMod .. " + h", hl.dsp.focus({ direction = "left" }))
hl.bind(var_mainMod .. " + l", hl.dsp.focus({ direction = "right" }))
hl.bind(var_mainMod .. " + k", hl.dsp.focus({ direction = "up" }))
hl.bind(var_mainMod .. " + j", hl.dsp.focus({ direction = "down" }))
-- Move focus with mainMod or Vim-style
hl.bind(var_mainMod .. " + CTRL + h", hl.dsp.focus({ direction = "left" }))
hl.bind(var_mainMod .. " + CTRL + l", hl.dsp.focus({ direction = "right" }))
hl.bind(var_mainMod .. " + CTRL + k", hl.dsp.focus({ direction = "up" }))
hl.bind(var_mainMod .. " + CTRL + j", hl.dsp.focus({ direction = "down" }))
-- Move windows with mainMod + WASD or Vim-style
hl.bind(var_mainMod .. " + SHIFT + a", hl.dsp.window.move({ direction = "left" }))
hl.bind(var_mainMod .. " + SHIFT + d", hl.dsp.window.move({ direction = "right" }))
hl.bind(var_mainMod .. " + SHIFT + w", hl.dsp.window.move({ direction = "up" }))
hl.bind(var_mainMod .. " + SHIFT + s", hl.dsp.window.move({ direction = "down" }))
-- Move windows with mainMod or Vim-style
hl.bind(var_mainMod .. " + SHIFT + h", hl.dsp.window.move({ direction = "left" }))
hl.bind(var_mainMod .. " + SHIFT + l", hl.dsp.window.move({ direction = "right" }))
hl.bind(var_mainMod .. " + SHIFT + k", hl.dsp.window.move({ direction = "up" }))
@@ -599,14 +503,11 @@ hl.bind("SHIFT + PRINT", hl.dsp.exec_cmd("hyprshot -m active --output-folder " .
})
-- Screenlock
hl.bind("CTRL + ALT + L", hl.dsp.exec_cmd("hyprlock"), {
locked = true,
})
hl.bind("CTRL + ALT + L", hl.dsp.exec_cmd("hyprlock"), {locked = true,})
hl.bind(var_mainMod .. " + L", hl.dsp.exec_cmd("hyprlock"), {locked = true,})
-- #############################
-- ## WINDOWS AND WORKSPACES ###
-- #############################
-- See https://wiki.hypr.land/Configuring/Window-Rules/ for more