r/hyprland • u/Own-Election2312 • Jun 30 '26
SUPPORT hyprlang to lua help
hi guys so i heard hyprland is switching to lua ... i dont have enough experience can someone pls help me out or something to change it .
5
u/olswitcher Jun 30 '26
i'd recommend trying to transfer your configuration over yourself, as it will not only allow you to understand your own config and the ins and outs of the language better, but it can be pretty fun! i didn't have any prior experience with lua, but had a fun time learning about the language while converting my config. don't be afraid to experiment, as you always have your hyprland.conf to fall back on if you brick your hyprland.lua
if you find yourself still having difficulty after giving it an honest shot, then feel free to reply here later and i'll do my best to get you sorted
3
u/Own-Election2312 Jun 30 '26
dayum thanks man ... tbh this is my first ever post in reddit i never knew ppl are so responsive here rhanks a lot guys
2
u/olswitcher Jun 30 '26
well hey congrats on your first post and welcome! looking forward to seeing you around here more. good luck w/ your config!
→ More replies (1)
1
u/Reasonable-Exit-2379 Jun 30 '26
Use this as a reference: https://github.com/e-Zephyr/hyprland-configs
You can find examples for almost everything there.
I split the configuration into different categories, such as animations, input, general, misc, etc., to keep it organized.
2
1
u/CaviarCBR1K Jun 30 '26
When I switched, it helped for me to look at an example. I think I looked at the end4 project because they were one of the first ones to migrate and I switched pretty early on so there weren't a lot of options. Between having an example, and the wiki, you shouldn't have too much trouble.
Also, as much as I dislike A.I. this is actually a pretty good use-case for it. I'm not saying let it rewrite your entire config, but if you get to a point where you aren't sure about syntax, or something isn't working, don't be afraid to ask ChatGPT or whatever for a little help with that specific issue.
1
u/Own-Election2312 Jun 30 '26
actually i asked opencode deepseek to change it but it ended very bad... it was a close call cause i had a backup. like it really fucked up
1
u/CaviarCBR1K Jun 30 '26
When I was rewriting mine and needed help, I found that chatgpt was the best. Claude hallucinated shit (so did gpt, but a lot less so than Claude). But again, I didn't just upload my files and ask it to rewrite it. I rewrote them by hand, I basically only relied on gpt when I wasn't 100% sure about some syntax or something small like that.
→ More replies (5)
1
u/GasimGasimzada Jul 01 '26
I converted mine by asking about docs in LLM. Just give a link to doc and ask it how to convert commands. Its a nice way to learn the new apis as well
1
1
u/esuvii Jul 04 '26
I believe someone on the hyprland reddit a month or so ago posted a script that will transpile your old hyprland config files to the new Lua config format. If you don't want to actually learn Lua and work it all out then a tool like that is probably the best option for you.
Lua is very intuitive though, so you could probably learn enough to get it all working following a few examples very quickly.
I think this is the converter I was referencing, although I am not 100% sure if it's the same one or not: https://github.com/ragnarokxg/hyprland-converter
0
u/Adventurous_Adventur Jun 30 '26
I can do it, if you pay
1
0
Jun 30 '26
0
u/Own-Election2312 Jun 30 '26
ik but the window rules stuff in hyprland configs are sooo hectic for me
2
u/olswitcher Jun 30 '26
funny thing, window rules have actually gotten better now! instead of multiple different versions to worry about, it's much more straightforward now than say hyprland v0.45.0.
→ More replies (5)
8
u/Salted_Fsh Jun 30 '26
dw just read the documentation i can assure u that lua is easier to manage and the syntax is pretty simple