Use Lua for config

Signed-off-by: Slendi <slendi@socopon.com>
This commit is contained in:
2025-08-10 07:25:01 +03:00
parent 4e23877697
commit 146c4e27cf
8 changed files with 504 additions and 21 deletions

15
lunarwm/init.lua Normal file
View File

@@ -0,0 +1,15 @@
function main(kbd)
return "Super-" .. kbd
end
return {
input = {
keyboard = {
xkb_options = { "altwin:swap_lalt_lwin" },
},
},
keybindings = {
{ bind = main("Escape"), action = lunar.quit_compositor },
{ bind = main("Shift-R"), action = lunar.reload_config },
},
}

View File

@@ -1,17 +0,0 @@
fn lib = {
input = {
keyboard = {
xkb_options = [ "altwin:swap_lalt_lwin" ]
}
}
modifier_aliases = {
Main = "Super"
}
keybindings = [
{ bind = "Main-Escape" action = (lib.quit_compositor) }
{ bind = "Main-Shift-R" action = (lib.reload_config) }
]
}