migrate to lua for hyprland>=0.55
This commit is contained in:
4 files changed
+80
-67
No files matched your search
@@ -1,40 +0,0 @@
|
|||||||
# exec-once
|
|
||||||
exec-once = uwsm app -- python ~/.config/Modus/main.py
|
|
||||||
exec = pgrep -x "hypridle" > /dev/null || uwsm app -- hypridle
|
|
||||||
exec-once = uwsm app -- swww-daemon
|
|
||||||
exec-once = wl-paste --type text --watch cliphist store
|
|
||||||
exec-once = wl-paste --type image --watch cliphist store
|
|
||||||
|
|
||||||
|
|
||||||
# LAYER RULES FOR BLURS
|
|
||||||
layerrule = blur on, xray 0, blur_popups on, ignore_alpha 0, no_anim on, match:namespace ^modus-notifications$
|
|
||||||
layerrule = animation popin, match:namespace ^lockscreen$
|
|
||||||
layerrule = blur on, xray 0, blur_popups on, ignore_alpha 0, animation popin, match:namespace ^modus-launcher$
|
|
||||||
layerrule = blur on, ignore_alpha 0, xray 0, blur_popups on, match:namespace ^fabric$
|
|
||||||
layerrule = blur on, xray 0, blur_popups on, ignore_alpha 0, match:namespace ^modus$
|
|
||||||
layerrule = animation slide right, match:namespace ^notification-center$
|
|
||||||
|
|
||||||
# KEYBINDS
|
|
||||||
|
|
||||||
$fabricSend = fabric-cli exec modus
|
|
||||||
# Reload Modus
|
|
||||||
bind = SUPER ALT, B, exec, killall modus; uwsm-app $(python $HOME/.config/Modus/main.py)
|
|
||||||
# Message
|
|
||||||
bind = SUPER SHIFT, y, exec, $fabricSend 'app.set_css()' # Reload CSS
|
|
||||||
# # Application Switcher
|
|
||||||
bind = ALT, TAB, exec, $fabricSend 'switcher.show_switcher()'
|
|
||||||
# App Launcher
|
|
||||||
bind = SUPER, SPACE, exec, $fabricSend "launcher.show_launcher()"
|
|
||||||
# Clipboard History
|
|
||||||
bind = SUPER, V, exec, $fabricSend "launcher.show_launcher('clip')"
|
|
||||||
# Wallpapers
|
|
||||||
bind = SUPER, W, exec, $fabricSend "launcher.show_launcher('wall')"
|
|
||||||
# Random Wallpaper
|
|
||||||
bind = ALT SHIFT, W, exec, $fabricSend "launcher.show_launcher('wall random', external=True)"
|
|
||||||
# Emoji Picker
|
|
||||||
bind = SUPER, Period, exec, $fabricSend "launcher.show_launcher('em')"
|
|
||||||
# Power Menu
|
|
||||||
bind = SUPER, ESCAPE, exec, $fabricSend "launcher.show_launcher('power')"
|
|
||||||
# Toggle Caffeine
|
|
||||||
bind = SUPER SHIFT, M, exec, $fabricSend "launcher.show_launcher('caffeine on', external=True)"
|
|
||||||
|
|
||||||
@@ -0,0 +1,75 @@
|
|||||||
|
local modus = "$HOME/.config/Modus"
|
||||||
|
|
||||||
|
hl.on("hyprland.start", function()
|
||||||
|
local cmds = {
|
||||||
|
"uwsm app -- awww-daemon",
|
||||||
|
"wl-paste --type text --watch cliphist store",
|
||||||
|
"wl-paste --type image --watch cliphist store",
|
||||||
|
"pgrep -x hypridle >/dev/null || uwsm app -- hypridle",
|
||||||
|
"cd " .. modus .. " && uwsm app -- uv run start",
|
||||||
|
}
|
||||||
|
for i = 1, #cmds do
|
||||||
|
local cmd = cmds[i]
|
||||||
|
hl.exec_cmd(cmd)
|
||||||
|
end
|
||||||
|
end)
|
||||||
|
|
||||||
|
-- Layer Rules for Blurs and Animations
|
||||||
|
local layer_rules = {
|
||||||
|
{
|
||||||
|
match = { namespace = "modus-notifications" },
|
||||||
|
blur = true,
|
||||||
|
xray = 0,
|
||||||
|
blur_popups = true,
|
||||||
|
ignore_alpha = 0,
|
||||||
|
no_anim = true,
|
||||||
|
},
|
||||||
|
{ match = { namespace = "lockscreen" }, animation = "popin" },
|
||||||
|
{
|
||||||
|
match = { namespace = "modus-launcher" },
|
||||||
|
blur = true,
|
||||||
|
xray = 0,
|
||||||
|
blur_popups = true,
|
||||||
|
ignore_alpha = 0,
|
||||||
|
animation = "popin",
|
||||||
|
},
|
||||||
|
{
|
||||||
|
match = { namespace = "fabric" },
|
||||||
|
blur = true,
|
||||||
|
ignore_alpha = 0,
|
||||||
|
xray = 0,
|
||||||
|
blur_popups = true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
match = { namespace = "modus" },
|
||||||
|
blur = true,
|
||||||
|
xray = 0,
|
||||||
|
blur_popups = true,
|
||||||
|
ignore_alpha = 0,
|
||||||
|
},
|
||||||
|
{ match = { namespace = "notification-center" }, animation = "slide right" },
|
||||||
|
}
|
||||||
|
|
||||||
|
for _, rule in ipairs(layer_rules) do
|
||||||
|
hl.layer_rule(rule)
|
||||||
|
end
|
||||||
|
|
||||||
|
local fabricSend = "fabric-cli exec modus1"
|
||||||
|
|
||||||
|
-- Reload Modus
|
||||||
|
hl.bind("SUPER + ALT + B", hl.dsp.exec_cmd("killall modus; cd " .. modus .. " && uwsm app -- uv run start"))
|
||||||
|
|
||||||
|
-- Fabric Launcher Binds
|
||||||
|
for key, method in pairs({
|
||||||
|
["SUPER + SHIFT + Y"] = "app.set_css()", -- Reload CSS
|
||||||
|
["ALT + TAB"] = "switcher.show_switcher()", -- Application Switcher
|
||||||
|
["SUPER + SPACE"] = "launcher.show_launcher()", -- App Launcher
|
||||||
|
["SUPER + V"] = "launcher.show_launcher('clip')", -- Clipboard History
|
||||||
|
["SUPER + W"] = "launcher.show_launcher('wall')", -- Wallpapers
|
||||||
|
["ALT + SHIFT + W"] = "launcher.show_launcher('wall random', external=True)", -- Random Wallpaper
|
||||||
|
["SUPER + Period"] = "launcher.show_launcher('em')", -- Emoji Picker
|
||||||
|
["SUPER + ESCAPE"] = "launcher.show_launcher('power')", -- Power Menu
|
||||||
|
["SUPER + SHIFT + M"] = "launcher.show_launcher('caffeine on', external=True)", -- Toggle Caffeine
|
||||||
|
}) do
|
||||||
|
hl.bind(key, hl.dsp.exec_cmd(fabricSend .. " '" .. method .. "'"))
|
||||||
|
end
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
$wallpaper = {{image}}
|
|
||||||
$background = {{colors.background.default.hex_stripped}}
|
|
||||||
$foreground = {{colors.on_background.default.hex_stripped}}
|
|
||||||
|
|
||||||
$primary = {{colors.primary.default.hex_stripped}}
|
|
||||||
$secondary = {{colors.secondary.default.hex_stripped}}
|
|
||||||
$tertiary = {{colors.tertiary.default.hex_stripped}}
|
|
||||||
$surface = {{colors.surface.default.hex_stripped}}
|
|
||||||
$surface_bright = {{colors.surface_bright.default.hex_stripped}}
|
|
||||||
$outline = {{colors.outline.default.hex_stripped}}
|
|
||||||
$error = {{colors.error.default.hex_stripped | set_lightness: -20.0}}
|
|
||||||
|
|
||||||
$shadow = {{colors.shadow.default.hex_stripped}}
|
|
||||||
|
|
||||||
$red = {{colors.red.default.hex_stripped}}
|
|
||||||
$green = {{colors.green.default.hex_stripped}}
|
|
||||||
$yellow = {{colors.yellow.default.hex_stripped}}
|
|
||||||
$blue = {{colors.blue.default.hex_stripped}}
|
|
||||||
$magenta = {{colors.magenta.default.hex_stripped}}
|
|
||||||
$cyan = {{colors.cyan.default.hex_stripped}}
|
|
||||||
$white = {{colors.white.default.hex_stripped}}
|
|
||||||
$red_dim = {{colors.red.default.hex_stripped | set_lightness: -20.0}}
|
|
||||||
$green_dim = {{colors.green.default.hex_stripped | set_lightness: -20.0}}
|
|
||||||
$yellow_dim = {{colors.yellow.default.hex_stripped | set_lightness: -20.0}}
|
|
||||||
$blue_dim = {{colors.blue.default.hex_stripped | set_lightness: -20.0}}
|
|
||||||
$magenta_dim = {{colors.magenta.default.hex_stripped | set_lightness: -20.0}}
|
|
||||||
$cyan_dim = {{colors.cyan.default.hex_stripped | set_lightness: -20.0}}
|
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
return {
|
||||||
|
<* for name, value in colors *>
|
||||||
|
{{name}} = "rgb({{value.default.hex_stripped}})",
|
||||||
|
<* endfor *>
|
||||||
|
}
|
||||||
Reference in new issue
Block a user