diff --git a/hypr/.luarc.json b/hypr/.luarc.json deleted file mode 100644 index babfd90..0000000 --- a/hypr/.luarc.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "workspace": { - "library": ["/usr/share/hypr/stubs"] - }, - "diagnostics": { - "globals": ["hl"] - } -} diff --git a/hypr/colors.lua b/hypr/colors.lua deleted file mode 120000 index 9004841..0000000 --- a/hypr/colors.lua +++ /dev/null @@ -1 +0,0 @@ -/home/baobeld/.cache/wal/colors.lua \ No newline at end of file diff --git a/hypr/hyprland.conf b/hypr/hyprland.conf new file mode 100644 index 0000000..42cd3a1 --- /dev/null +++ b/hypr/hyprland.conf @@ -0,0 +1,78 @@ +# See https://wiki.hyprland.org/Configuring/Keywords/ for more + +# Programs +$terminal = alacritty +$fileManager = nautilus +$lockScreen = hyprlock + +# See https://wiki.hyprland.org/Configuring/Keywords/ for more +$mainMod = SUPER + +# See https://wiki.hyprland.org/Configuring/Monitors/ +# PC +monitor=DP-1,2560x1440@144,auto,auto + +# Laptop +monitor=eDP-1,1920x1080@60,auto,1.20 + +# For all categories, see https://wiki.hyprland.org/Configuring/Variables/ +input { + kb_layout = us + kb_variant = + kb_model = + kb_options = + kb_rules = + + follow_mouse = 1 + + touchpad { + natural_scroll = no + } + + sensitivity = 0 # -1.0 - 1.0, 0 means no modification. +} + +general { + # See https://wiki.hyprland.org/Configuring/Variables/ for more + + gaps_in = 10 + gaps_out = 10 + border_size = 3 + + layout = dwindle + + # Please see https://wiki.hyprland.org/Configuring/Tearing/ before you turn this on + allow_tearing = true +} + +dwindle { + # See https://wiki.hyprland.org/Configuring/Dwindle-Layout/ for more + pseudotile = yes # master switch for pseudotiling. Enabling is bound to mainMod + P in the keybinds section below + preserve_split = yes # you probably want this +} + +master { + # See https://wiki.hyprland.org/Configuring/Master-Layout/ for more +} + +misc { + # See https://wiki.hyprland.org/Configuring/Variables/ for more + force_default_wallpaper = -1 # Set to 0 or 1 to disable the anime mascot wallpapers +} + +# Example per-device config +# See https://wiki.hyprland.org/Configuring/Keywords/#executing for more +device { + name = epic-mouse-v1 + sensitivity = -0.5 +} + +$hypr = ~/.config/hypr/hyprland + +source = $hypr/animations.conf +source = $hypr/colours.conf +source = $hypr/decorations.conf +source = $hypr/env.conf +source = $hypr/execs.conf +source = $hypr/keybinds.conf +source = $hypr/rules.conf diff --git a/hypr/hyprland.lua b/hypr/hyprland.lua deleted file mode 100644 index 47dfcdd..0000000 --- a/hypr/hyprland.lua +++ /dev/null @@ -1,96 +0,0 @@ -require("hyprland.bindings") -require("hyprland.env") -require("hyprland.rules") -local M = require("colors") - --- monitors https://wiki.hypr.land/Configuring/Basics/Monitors/ -hl.monitor({ - output = "DP-1", - mode = "2560x1440@144", - position = "auto", - scale = "auto", -}) - -hl.monitor({ - output = "eDP-1", - mode = "1920x1080@60", - position = "auto", - scale = 1.20, -}) - -hl.on("config.reloaded", function() - hl.notification.create({ text = "Config Reloaded" }) -end) - -hl.on("hyprland.start", function() - hl.exec_cmd("gnome-keyring-daemon --start --components=secrets") - hl.exec_cmd("hypridle") - hl.exec_cmd("swww-daemon") - hl.exec_cmd("quickshell") - hl.exec_cmd("xsetroot -cursor_name left_ptr") - - hl.exec_cmd("thunderbird", { workspace = "1 silent" }) - hl.exec_cmd('proton-mail --password-store="gnome-libsecret"', { workspace = "1 silent" }) - hl.exec_cmd("discord --enable-features=UseOzonePlatform --ozone-platform=wayland", { workspace = "2 silent" }) - hl.exec_cmd('signal-desktop --password-store="gnome-libsecret"', { workspace = "2 silent" }) - hl.exec_cmd("zen-browser", { workspace = "3 silent" }) - hl.exec_cmd("alacritty", { workspace = "4 silent" }) - hl.exec_cmd("steam", { workspace = "5 silent" }) - hl.exec_cmd("alacritty", { workspace = "special:terminal silent" }) - hl.exec_cmd( - "tidal-hifi --enable-features=UseOzonePlatform --ozone-platform=wayland", - { workspace = "special:music silent" } - ) -end) - --- bindings - --- input https://wiki.hypr.land/Configuring/Basics/Variables/#input --- hl.input({ --- kb_layout = "us", --- follow_mouse = 1, --- sensitivity = 0, -- -1.0 - 1.0, 0 means no modification. --- }) - --- hl.input.touchpad({ --- natural_scroll = "no", --- }) - --- config https://wiki.hypr.land/Configuring/Basics/Variables -hl.config({ - general = { - gaps_in = 10, - gaps_out = 10, - border_size = 3, - layout = "dwindle", - allow_tearing = true, - col = { - active_border = { colors = { M.color4, M.color13 }, angle = 45 }, - inactive_border = { colors = { M.color0 } }, - }, - }, - decoration = { - rounding = 6, - blur = { - enabled = true, - size = 6, - passes = 1, - ignore_opacity = true, - }, - shadow = { - enabled = true, - range = 4, - render_power = 3, - color = "#1a1a1aee", - }, - }, - dwindle = { - preserve_split = true, - }, - misc = { - force_default_wallpaper = 0, - }, - cursor = { - no_hardware_cursors = true, - }, -}) diff --git a/hypr/hyprland/bindings.lua b/hypr/hyprland/bindings.lua deleted file mode 100644 index b3595a1..0000000 --- a/hypr/hyprland/bindings.lua +++ /dev/null @@ -1,68 +0,0 @@ -hl.bind("SUPER + mouse:272", hl.dsp.window.drag(), { mouse = true }) -hl.bind("SUPER + mouse:273", hl.dsp.window.resize(), { mouse = true }) - -hl.bind( - "SUPER + F10", - hl.dsp.send_shortcut({ mods = "CTRL", key = "F10", window = "class:^(com\\.obsproject\\.Studio)$" }) -) - -hl.bind("SUPER + ESCAPE", hl.dsp.global("lux:power-menu")) -hl.bind("SUPER + R", hl.dsp.global("lux:launcher")) -hl.bind("SUPER + M", hl.dsp.global("lux:pomodoro")) -hl.bind("SUPER + W", hl.dsp.global("lux:storybook")) -hl.bind("SUPER + grave", hl.dsp.global("lux:configuration")) - -hl.bind("SUPER + T", hl.dsp.exec_cmd("alacritty")) -hl.bind("SUPER + X", hl.dsp.window.close()) -hl.bind("SUPER + E", hl.dsp.exec_cmd("nautilus")) -hl.bind("SUPER + F", hl.dsp.window.float()) -hl.bind("SUPER + CTRL + F", hl.dsp.window.fullscreen()) -hl.bind("SUPER + P", hl.dsp.window.pseudo()) --- hl.bind("SUPER + V", hl.dsp.window.) -hl.bind("SUPER + L", hl.dsp.exec_cmd("hyprlock")) -hl.bind("SUPER + period", hl.dsp.exec_cmd("gnome-characters")) -hl.bind("SUPER + B", hl.dsp.exec_cmd("zen-browser")) -hl.bind("PRINT", hl.dsp.exec_cmd('grim -g "$(slurp)" - | swappy -f -')) - -hl.bind("CTRL + ALT + left", hl.dsp.focus({ workspace = "e-1" })) -hl.bind("CTRL + ALT + right", hl.dsp.focus({ workspace = "e+1" })) -hl.bind("SUPER + mouse_up", hl.dsp.focus({ workspace = "e-1" })) -hl.bind("SUPER + mouse_down", hl.dsp.focus({ workspace = "e+1" })) - -hl.bind("SUPER + 1", hl.dsp.focus({ workspace = "1" })) -hl.bind("SUPER + 2", hl.dsp.focus({ workspace = "2" })) -hl.bind("SUPER + 3", hl.dsp.focus({ workspace = "3" })) -hl.bind("SUPER + 4", hl.dsp.focus({ workspace = "4" })) -hl.bind("SUPER + 5", hl.dsp.focus({ workspace = "5" })) -hl.bind("SUPER + 6", hl.dsp.focus({ workspace = "6" })) -hl.bind("SUPER + 7", hl.dsp.focus({ workspace = "7" })) -hl.bind("SUPER + 8", hl.dsp.focus({ workspace = "8" })) -hl.bind("SUPER + 9", hl.dsp.focus({ workspace = "9" })) -hl.bind("SUPER + 0", hl.dsp.focus({ workspace = "10" })) - -hl.bind("SUPER + SHIFT + 1", hl.dsp.window.move({ workspace = "1" })) -hl.bind("SUPER + SHIFT + 2", hl.dsp.window.move({ workspace = "2" })) -hl.bind("SUPER + SHIFT + 3", hl.dsp.window.move({ workspace = "3" })) -hl.bind("SUPER + SHIFT + 4", hl.dsp.window.move({ workspace = "4" })) -hl.bind("SUPER + SHIFT + 5", hl.dsp.window.move({ workspace = "5" })) -hl.bind("SUPER + SHIFT + 6", hl.dsp.window.move({ workspace = "6" })) -hl.bind("SUPER + SHIFT + 7", hl.dsp.window.move({ workspace = "7" })) -hl.bind("SUPER + SHIFT + 8", hl.dsp.window.move({ workspace = "8" })) -hl.bind("SUPER + SHIFT + 9", hl.dsp.window.move({ workspace = "9" })) -hl.bind("SUPER + SHIFT + 0", hl.dsp.window.move({ workspace = "10" })) - -hl.bind("SUPER + left", hl.dsp.focus({ direction = "l" })) -hl.bind("SUPER + right", hl.dsp.focus({ direction = "r" })) -hl.bind("SUPER + up", hl.dsp.focus({ direction = "u" })) -hl.bind("SUPER + down", hl.dsp.focus({ direction = "d" })) - -hl.bind("CTRL + SHIFT + T", hl.dsp.workspace.toggle_special("terminal")) -hl.bind("CTRL + SHIFT + M", hl.dsp.workspace.toggle_special("music")) - -hl.bind("XF86AudioRaiseVolume", hl.dsp.exec_cmd("wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%+")) -hl.bind("XF86AudioLowerVolume", hl.dsp.exec_cmd("wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%-")) -hl.bind("XF86AudioMute", hl.dsp.exec_cmd("wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle")) -hl.bind("XF86AudioPlay", hl.dsp.exec_cmd("playerctl play-pause")) --- hl.bind("XF86AudioStop", hl.dsp.exec_cmd("")) -hl.bind("XF86AudioPrev", hl.dsp.exec_cmd("playerctl previous")) -hl.bind("XF86AudioNext", hl.dsp.exec_cmd("playerctl next")) diff --git a/hypr/hyprland/colours.conf b/hypr/hyprland/colours.conf new file mode 100644 index 0000000..caa84ef --- /dev/null +++ b/hypr/hyprland/colours.conf @@ -0,0 +1,7 @@ +# PyWal Colors +source = ~/.cache/wal/colors-hyprland.conf + +general { + col.active_border = $color4 $color13 45deg + col.inactive_border = $color0 +} diff --git a/hypr/hyprland/decorations.conf b/hypr/hyprland/decorations.conf new file mode 100644 index 0000000..ed6c1df --- /dev/null +++ b/hypr/hyprland/decorations.conf @@ -0,0 +1,19 @@ +decoration { + # See https://wiki.hyprland.org/Configuring/Variables/ for more + + rounding = 6 + + blur { + enabled = true + size = 6 + passes = 1 + ignore_opacity = true + } + + shadow { + enabled = true + range = 4 + render_power = 3 + color = rgba(1a1a1aee) + } +} diff --git a/hypr/hyprland/env.conf b/hypr/hyprland/env.conf new file mode 100644 index 0000000..5901fc9 --- /dev/null +++ b/hypr/hyprland/env.conf @@ -0,0 +1,46 @@ +# ----------------------------------------------------- +# Environment Variables +# ----------------------------------------------------- + +# General +env = XDG_SESSION_TYPE,wayland +env = QT_QPA_PLATFORM,wayland + +# Nvidia +# https://wiki.hyprland.org/Nvidia/ +env = LIBVA_DRIVER_NAME,nvidia +env = __GLX_VENDOR_LIBRARY_NAME,nvidia +env = NVD_BACKEND,direct + +env = GBM_BACKEND,nvidia-drm +env = __GL_VRR_ALLOWED,1 + +# Electron +env = ELECTRON_OZONE_PLATFORM_HINT,auto + +# Themes +env = GTK_THEME,WhiteSur-Dark +env = ICON_THEME,WhiteSur-Dark +env = COLOR_SCHEME,prefer-dark + +#Cursors +cursor { + no_hardware_cursors = true +} +# env = XCURSOR_THEME,Volantes Cursors +# env = XCURSOR_SIZE,24 +env = HYPRCURSOR_THEME,Volantes Cursors +env = HYPRCURSOR_SIZE,24 +exec-once = hyprctl setcursor $cursorTheme $cursorSize +# exec-once = gsettings set org.gnome.desktop.interface cursor-theme '$cursorTheme' +# exec-once = gsettings set org.gnome.desktop.interface cursor-size $cursorSize + +# Fonts +env = FONT_NAME,JetBrainsMono Nerd Font 24 +env = DOCUMENT_FONT_NAME,Cantarell 24 +env = MONOSPACE_FONT_NAME,JetBrainsMono Nerd Font 5 +env = FONT_ANTIALIASING,rgba +env = FONT_HINTING,full + +# uwsm/app2unit +env = APP2UNIT_SLICES,'a=app-graphical.slice b=background-graphical.slice s=session-graphical.slice' diff --git a/hypr/hyprland/env.lua b/hypr/hyprland/env.lua deleted file mode 100644 index 720cf5e..0000000 --- a/hypr/hyprland/env.lua +++ /dev/null @@ -1,28 +0,0 @@ -hl.env("XDG_SESSION_TYPE", "wayland") -hl.env("QT_QPA_PLATFORM", "wayland") - -hl.env("LIBVA_DRIVER_NAME", "nvidia") -hl.env("__GLX_VENDOR_LIBRARY_NAME", "nvidia") -hl.env("NVD_BACKEND", "direct") -hl.env("GBM_BACKEND", "nvidia-drm") -hl.env("__GL_VRR_ALLOWED", "1") - -hl.env("ELECTRON_OZONE_PLATFORM_HINT", "auto") - -hl.env("GTK_THEME", "WhiteSur-Dark") -hl.env("ICON_THEME", "WhiteSur-Dark") -hl.env("COLOR_SCHEME", "prefer-dark") - -hl.env("XCURSOR_PATH", "/usr/share/icons/:$XDG_DATA_HOME/icons") -hl.env("XCURSOR_THEME", "default") -hl.env("XCURSOR_SIZE", 24) -hl.env("HYPRCURSOR_THEME", "Volantes Cursors") -hl.env("HYPRCURSOR_SIZE", 24) - -hl.env("FONT_NAME", "JetBrainsMono Nerd Font 24") -hl.env("DOCUMENT_FONT_NAME", "Cantarell 24") -hl.env("MONOSPACE_FONT_NAME", "JetBrainsMono Nerd Font 24") -hl.env("FONT_ANTIALIASING", "rgba") -hl.env("FONT_HINTING", "full") - -hl.env("APP2UNIT_SLICES", "a=app-graphical.slice b=background-graphical.slice s=session-graphical.slice") diff --git a/hypr/hyprland/execs.conf b/hypr/hyprland/execs.conf new file mode 100644 index 0000000..31396b6 --- /dev/null +++ b/hypr/hyprland/execs.conf @@ -0,0 +1,22 @@ +# Key ring +exec-once = gnome-keyring-daemon --start --components=secrets + +# Idle Daemon +exec-once = hypridle +# Lux-shell +exec-once = quickshell +# Emotes +exec-once = emote +# Wallpaper Daemon +exec-once = swww-daemon + +exec-once = [workspace 1 silent] thunderbird +exec-once = [workspace 1 silent] proton-mail --password-store="gnome-libsecret" +exec-once = [workspace 2 silent] discord --enable-features=UseOzonePlatform --ozone-platform=wayland +exec-once = [workspace 2 silent] signal-desktop --password-store="gnome-libsecret" +exec-once = [workspace 3 silent] zen-browser +exec-once = [workspace 4 silent] alacritty +exec-once = [workspace 5 silent] steam +exec-once = [workspace special:terminal silent] alacritty +exec-once = [workspace special:music silent] tidal-hifi --enable-features=UseOzonePlatform --ozone-platform=wayland + diff --git a/hypr/hyprland/keybinds.conf b/hypr/hyprland/keybinds.conf new file mode 100644 index 0000000..1f816ac --- /dev/null +++ b/hypr/hyprland/keybinds.conf @@ -0,0 +1,93 @@ + +# Lux Keybinds +bind = $mainMod, ESCAPE, global, lux:power-menu +bind = $mainMod, R, global, lux:launcher +bind = $mainMod, M, global, lux:pomodoro +bind = $mainMod, W, global, lux:storybook +bind = $mainMod, grave, global, lux:configuration + +# Example binds, see https://wiki.hyprland.org/Configuring/Binds/ for more + +# Global +bind = SUPER, F10, sendshortcut, CTRL, F10, class:^(com\.obsproject\.Studio)$ + +# Programs +bind = $mainMod, T, exec, $terminal +bind = $mainMod, X, killactive, +bind = $mainMod, E, exec, $fileManager +bind = $mainMod, F, togglefloating, +bind = $mainMod, P, pseudo, # dwindle +bind = $mainMod, V, togglesplit, # dwindle +bind = $mainMod, L, exec, $lockScreen # hyprlock +bind = $mainMod, period, exec, gnome-characters +bind = $mainMod, B, exec, zen-browser +bind = $mainMod CTRL, F, fullscreen +bind = , PRINT, exec, grim -g "$(slurp)" - | swappy -f - + +# Move focus with mainMod + arrow keys +bind = $mainMod, left, movefocus, l +bind = $mainMod, right, movefocus, r +bind = $mainMod, up, movefocus, u +bind = $mainMod, down, movefocus, d + +# Switch workspaces with mainMod + [0-9] +bind = $mainMod, 1, workspace, 1 +bind = $mainMod, 2, workspace, 2 +bind = $mainMod, 3, workspace, 3 +bind = $mainMod, 4, workspace, 4 +bind = $mainMod, 5, workspace, 5 +bind = $mainMod, 6, workspace, 6 +bind = $mainMod, 7, workspace, 7 +bind = $mainMod, 8, workspace, 8 +bind = $mainMod, 9, workspace, 9 +bind = $mainMod, 0, workspace, 10 + +# Move active window to a workspace with mainMod + SHIFT + [0-9] +bind = $mainMod SHIFT, 1, movetoworkspace, 1 +bind = $mainMod SHIFT, 2, movetoworkspace, 2 +bind = $mainMod SHIFT, 3, movetoworkspace, 3 +bind = $mainMod SHIFT, 4, movetoworkspace, 4 +bind = $mainMod SHIFT, 5, movetoworkspace, 5 +bind = $mainMod SHIFT, 6, movetoworkspace, 6 +bind = $mainMod SHIFT, 7, movetoworkspace, 7 +bind = $mainMod SHIFT, 8, movetoworkspace, 8 +bind = $mainMod SHIFT, 9, movetoworkspace, 9 +bind = $mainMod SHIFT, 0, movetoworkspace, 10 + +############################################################################### +# Special workspaces +############################################################################### +# Scratchpad +bind = CTRL SHIFT, S, togglespecialworkspace, magic +bind = CTRL $mainMod, S, movetoworkspace, special:magic + +# Terminal +bind = CTRL SHIFT, T, togglespecialworkspace, terminal + +# Music +bind = CTRL SHIFT, M, togglespecialworkspace, music + +# Scroll through existing workspaces with mainMod + scroll +bind = $mainMod, mouse_down, workspace, e+1 +bind = $mainMod, mouse_up, workspace, e-1 + +# Switch workspaces +bind = CTRL ALT, right, workspace, e+1 +bind = CTRL ALT, left, workspace, e-1 + +# Move/resize windows with mainMod + LMB/RMB and dragging +bindm = $mainMod, mouse:272, movewindow +bindm = $mainMod, mouse:273, resizewindow + +# Audio keybinds +bind = , XF86AudioRaiseVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%+ +bind = , XF86AudioLowerVolume, exec, wpctl set-volume @DEFAULT_AUDIO_SINK@ 2%- +bind = , XF86AudioMute, exec, wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle +bind = , XF86AudioPlay, exec, playerctl play-pause +bind = , XF86AudioStop, exec, +bind = , XF86AudioPrev, exec, playerctl previous +bind = , XF86AudioNext, exec, playerctl next + +# Gestures +# https://wiki.hypr.land/Configuring/Gestures/ +gesture = 4, horizontal, workspace diff --git a/hypr/hyprland/rules.conf b/hypr/hyprland/rules.conf new file mode 100644 index 0000000..e2c4fa9 --- /dev/null +++ b/hypr/hyprland/rules.conf @@ -0,0 +1,28 @@ +# See https://wiki.hyprland.org/Configuring/Window-Rules/ for more +windowrule = match:class .*, no_max_size true + +# Apps +windowrule = match:class ^(*)$, idle_inhibit fullscreen true +windowrule = match:title ^(*)$, idle_inhibit fullscreen true +windowrule = match:fullscreen true, idle_inhibit fullscreen +windowrule = match:modal true, float 0, center 0 + +# windowrule = workspace special:terminal, kitty +windowrule = match:initial_class tidal-hifi, workspace special:music + +windowrule = match:class thunderbird, workspace 1, no_initial_focus true +windowrule = match:class discord, workspace 2, no_initial_focus true +windowrule = match:class signal, workspace 2, opacity 0.999, no_initial_focus true +windowrule = match:class firefox, workspace 3, opacity 0.999, no_initial_focus true +windowrule = match:class steam, workspace 5, float true, no_initial_focus true +windowrule = match:class ^(steam_app_*)$, workspace 5, no_initial_focus true + +windowrule = match:class org.gnome.Calculator, float true + +# Workspaces +workspace = 1, persistent:true +workspace = 2, persistent:true +workspace = 3, persistent:true +workspace = 4, persistent:true +workspace = 5, persistent:true + diff --git a/hypr/hyprland/rules.lua b/hypr/hyprland/rules.lua deleted file mode 100644 index 54890e8..0000000 --- a/hypr/hyprland/rules.lua +++ /dev/null @@ -1,18 +0,0 @@ -hl.window_rule({ match = { modal = true }, float = true, center = true }) -hl.window_rule({ idle_inhibit = "fullscreen" }) - -hl.window_rule({ match = { initial_class = "tidal-hifi" }, workspace = "special:music" }) - -hl.window_rule({ match = { initial_class = "thunderbird" }, workspace = "1" }) -hl.window_rule({ match = { initial_class = "discord" }, workspace = "2" }) -hl.window_rule({ match = { initial_class = "signal" }, workspace = "2" }) -hl.window_rule({ match = { initial_class = "zen-browser" }, workspace = "3" }) -hl.window_rule({ match = { initial_class = "steam" }, workspace = "5" }) - -hl.window_rule({ match = { class = "org.gnome.Calculator" }, float = true }) - -hl.workspace_rule({ workspace = "1", persistent = true }) -hl.workspace_rule({ workspace = "2", persistent = true }) -hl.workspace_rule({ workspace = "3", persistent = true }) -hl.workspace_rule({ workspace = "4", persistent = true }) -hl.workspace_rule({ workspace = "5", persistent = true })