7 ms·
Hyprland 0.55 announced the switch to Lua for its config files
- dietr1ch 2mo agoOld news? 0.56 is out now https://hypr.land/news/update56/ https://hypr.land/news/update56/
- cbarnes99 2mo agoThis is kinda really old news at this point. 0.56 just came out.
- kelvinjps10 2mo agoI might be a good change but I left hyprland because,y configuration kept breaking. It's a good window manager so I'll change back once it gets stable. By now i3
- m4xp 2mo agoI think the problem is with people downloading perfect configs from other people, I put the time to make my own, not overly complicated, basic window rules, nothing fancy. And it just werks, haven't changed it for 4 months (outside of rewriting it in lua, which took 30min and was quite fun). My first hyprland experience was with ML4W (nothing against the guy) but as soon as you download it you get 10 config errors and you don't know where to begin. I took the same philosophy as arch, I install only what I understand, and this way my config grew over time, my games where spawning in 2nd monitor? I look up manual and fix it, etc..
- kelvinjps10 2mo agoIt was my own config, I just felt annoying because a fundamental part of my system didn't work. I end upf fixing it later but it was veryannoying
- gchamonlive 2mo agoHyprland config break is usually syntax changes or reallocated features. Never had an instance where hyprland broke beyond repair or was hard to fix, even before LLMs were a thing. But yeah, its a 0.x software so if you aren't keen on fixing small stuff it's better to wait indeed. My point is that hyprland is easy to fix.
- colinsane 2mo agoi'm mildly annoyed by the project in general because i put in a sizable effort getting the whole sway stack to cross compile correctly in nixpkgs/NixOS, keeping that stable for a year so that people could build on it, and then suddenly hyprland forked every package in the stack with a fresh set of "works on my machine" nix expressions, and then much of the peripheral sway packages (e.g. status bars like nwg-panel, notification centers, etc) decided to become dual-stack and take a dependency on those fast-moving/beta packages. for a solid month any time i updated my machine there was a _new_ hypr-something dependency in my sway desktop that broke cross compilation. eventually i gave up and just set `hyprland = null; hyprutils = null;` in my personal config: mainline's been broken for a year now, sorry to anyone who was using that. it gives "rewrite it in rust" vibes in the way they rush in to re-do everything without understanding why things were the way they were or if, in fact, anyone was using that obscure feature. maybe they'll sort it all out in time; maybe not. wish they could at least take less of a "we don't care if we break your shit" attitude in the meantime. /rant
- mintflow 2mo agosame boat, tried hyprland and it's cool but seems a bit buggy, and switch back to i3 and settle there.
- Havoc 2mo agoTIL I'm on 0.56 and hadn't realized there is a change. Thinking I'll wait as long as I can and then just get an LLM to translate current config to lua once the internet has been seeded a bit with examples
- feelamee 2mo agothere is a converter: https://eiontusk.github.io/hyprlang2lua/ https://eiontusk.github.io/hyprlang2lua/
- Havoc 2mo agoNice. I'll give that a go. Pretty vanilla config so fair chance it'll work
- pynappo 2mo agothere are already converters online (i wrote a incomplete one as a neovim plugin for fun https://github.com/pynappo/hyprlang-to-lua.nvim https://github.com/pynappo/hyprlang-to-lua.nvim) and reportedly LLMs work fine at it too. At the time i wrote my converter there was already a couple hundred configs i could search through on github to see what people did
- tombert 2mo agoI have grown pretty negative opinions of “using a programming language as a config language” after semi-recently having to spend a lot of time screwing around with someone’s Gradle Groovy abomination. Not even to mention how quickly Nix can get annoying. I have to ask…why do people want a Turing complete language to configure stuff? I use Sway personally, which is very configurable but for any even remotely complicated logic I shell out to a set of Rust programs.
- mghackerlady 2mo agoI think it's only really useful for things you'd want to be able to control programmatically, like text editors or in this case window managers
- adw 2mo agoThe usual answer is "config macros", because if you don't give people something Turing complete they'll just m4 their way into Turing completeness and that isn't really an improvement. (Starlark in Bazel, etc.)
- mickeyp 2mo agoSo you don't like using programming languages as config languages, so you: 1. Use a declarative-style format for config, which is fine, I guess; 2. ... and when that inevitably fails, you... use a programming language? Some people -- not all, but some -- may prefer to skip the first step and go straight for the second option. Particularly if it's a complex thing indeed like a build system and not, y'know, configuring your blog.
- AlotOfReading 2mo agoThe theoretical difference in power between a non-Turing complete declarative language and a turing complete one is irrelevant in practice. Datalog is a decidable, declarative subset of Turing-complete Prolog. It's also EXPTIME complete. I don't think we exclude any real use cases by prohibiting super-exponential algorithms. The problem is shitty config languages. I wouldn't group xaml in the same category as dhall for example.
- JacobAsmuth 2mo agoHuh? This is from May. You guys should read the more recent notes. https://hypr.land/news/update56/ https://hypr.land/news/update56/
- stonogo 2mo agoNothing in those notes is interesting, but switching to Lua is. It doesn't matter that it happened a few weeks ago.
- ianm218 2mo agoRelated to Lua - I've been maintaining this project that has Lua 5.1-5.5 in one Rust project [1]. The main reason to use it over mlua or the normal C Lua is for something that plays nicely with WASM/ general cross compilation or wants to support several different versions of Lua. Seems like hyprland is on C++ so maybe not a direct use case but thought Lua people in general might be interested. [1] https://github.com/ianm199/omnilua https://github.com/ianm199/omnilua
- v3ss0n 2mo agoThat's why I love qtile, written in python, modify everything in python, can import any module of it and can install anything, extend existing layout without forking to support very interesting and customized WM layouts, all entirely in python, call any python code in WM.
- qiine 2mo agolua is love
- leephillips 2mo agoI think dwm has the best approach to configuration: change the program and recompile. This works for dwm because it compiles in two seconds and has minimal dependencies. I don’t know about hyprland. https://dwm.suckless.org/customisation/ https://dwm.suckless.org/customisation/
- drdexebtjl 2mo agoRequiring a C compiler, source code and header files to change your keybindings is just a different kind of bloat, and nothing can change my mind.
- leephillips 2mo agoThen I won’t try! And I understand your opinion. But like everyone else I have many programs using many different configuration syntaxes, some using more than one file, some files in nonstandard locations, and some combining configuration from one or more files in my user directory with others somewhere in /etc or who knows where. I find the dwm approach refreshing. Pontification added later: And it has a beneficial side-effect. I’m not much of a C programmer these days (if I ever was), but I found I was able to understand the dwm code well enough to make some small changes in behavior. So the dwm approach encouraged me to go beyond changing definitions in the headers. (This is aside from 3rd party patches. I was even able to contribute one of those.) This is really in the spirit of free software.
- IshKebab 2mo agoI wish there was something better than Lua and just as "obvious" a choice. Static types, real arrays, zero-based indexing, etc. Closest thing I've seen so far is Roto: https://roto.docs.nlnetlabs.nl/en/stable/index.html https://roto.docs.nlnetlabs.nl/en/stable/index.html Basically everything about this looks great - Rust-style syntax, static type checking, sane type system, easily embedded. The only slightly odd things are that it has built in types for IP addresses, AS numbers, and `filtermap`. But I guess you can just ignore those if you don't need them.
- eqvinox 2mo agoThe language is primarily used by Rotonda, the composable, programmable BGP routing engine. Not odd to have those data types at all…
- rdtsc 2mo agoIt's just part of what I call the config pendulum. Simple config -> (Need to do more complicated things) -> Add override levels -> (Need even more flexibility) -> Add a Turing complete language -> (Things get ridiculous, lots of spaghetti code outside of version control. Time for a reset) -> goto "Simple config" It's fine. I am not saying it's wrong or right. I've gone through the cycle a few times in some projects. On the other hand, think of it as your project is lucky to be used long enough to have these problems. To feel better about it think of it as a spiral. The next "Simple config" is a slightly better version of the first.
- PunchyHamster 2mo agoI haven't really seen program go back from "a programming language" to a simple config format.
- zetanor 2mo agoWirePlumber switched its config from Lua to a JSON variant not so long ago.
- serf 2mo agothere's a rare form of that where it goes from( simple -> programming language -> language with DSL support -> simple dsl ) ; emacs has followed this model a bit.
- rdtsc 2mo agoPython setup.py -> pyproject.toml? Make -> ninja. eBPF kernel modules from C to a custom language. Helm Go templates -> Kustomize. I am sure there are other projects picking up json from a previous xml + xpath + other ...xml junk.
- XorNot 2mo agoI'll die on the hill that Helm charts are more of a problem because text/templating is a weird looking templating language then anything else.
- PessimalDecimal 2mo agoLisp is the perfect family of languages for a config. Homoiconic for seamless config generation. S-expressions for shared human and machine readability.
- ivanjermakov 2mo agoLua too. Neovim and Factorio come to mind first.
- nickjj 2mo agoIt's neat that Hyprland lets you define layouts in its config but I like niri's approach. It uses KDL (an established document / config language) and slightly extends it to add useful things like being able to include files. For example, here's mine: https://github.com/nickjj/dotfriedrice/blob/master/.config/niri/config.kdl https://github.com/nickjj/dotfriedrice/blob/master/.config/n... What you end up with is a config file that's natural to read with no prior knowledge about anything and if you want to look something specific up, you know it's officially documented and not some home grown pattern someone created. There's a certain amount of comfort and stability you get with a "what you see is what you get" approach. I never felt like I needed variables, conditions, functions or loops with niri's config.
- WhyNotHugo 2mo agoI wouldn't call KDL "established"; it's honestly pretty niche. It looks _similar_ to pre-existing configuration formats, but KDL is very picky about syntax. I.e.: single word string MUST be quoted. In this same space, https://codeberg.org/emersion/scfg/ https://codeberg.org/emersion/scfg/ is pretty widely used. The curious thing about scfg is that it's not really a "new" format: the syntax described has been in use by different tools for decades. They just didn't call it scfg, and it's mostly the name itself that's new.
- eviks 2mo ago> picky about syntax. I.e.: single word string MUST be quoted. Seems like the opposite: Example from kdl website without quotes package { name my-pkg Example from scfg with quotes train "Shinkansen" {
- WhyNotHugo 2mo agoPerhaps it was a niri-specific thing (although they claim it's KDL), but it rejected simple strings without quotes.
- eviks 2mo ago
- trollied 2mo agoAuto play video when you scroll? Behave
- JCattheATM 2mo agoI wonder how this would make Hyprland compare to Pinnacle or Awesome? So far I haven't found anything better than Awesome for crafting a bespoke desktop experience.
- retrochameleon 2mo agoUggghhh, I hate Lua. I hate the syntax, everything being tables, and.... dun dun dun 1-indexed arrays. I wish we wouldn't keep going back to it. I understand the appeal for some use cases, but pleeeeeeease can we just move on to a new language that fulfills the same use cases but with more typical conventions?
- eviks 2mo agoWhat's your best alternative for this use case?
- sph 2mo agoI want to like Hyprland, but it truly is the embodiment of Jamie Zawinski’s “cascade of attention deficit teenagers” This is what happens when software is created by too-smart teenagers, that change their mind as fast as they improve at programming, and expect that everyone is spending 12 hours a day configuring their desktop environment while hanging out in ‘ricing’ discords (“what do you mean you have a day job?”) Worse, if you dare criticize it, the fanboys come out of the woodwork saying you should really just use an LLM to convert to Lua and that you are dumb trying to do it manually. The hubris is untenable. After 3 or 4 breaking changes over the years, I decided I’d rather use some other desktop environment honestly, until the core team literally grows up. Niri is great, and its author is much more… mature.
- hackeraccount 2mo agoYou're like a smarter more articulate version of me. I used to use Sway - switched to hyperland very briefly and it was so busy and a pain to work with. Niri on the other hand is as complicated as I want it to be.
- eviks 2mo agoWish there were a more widespread config system where you could use a wider range of languages and not be limited to a single bad ancient one.