ifreund changed the topic of #river to: river - a dynamic tiling wayland compositor || https://github.com/ifreund/river || channel logs: https://libera.irclog.whitequark.org/river/
waleee has quit [Ping timeout: 250 seconds]
snakedye has quit [Ping timeout: 258 seconds]
leon-p has joined #river
novakane has joined #river
novakane has quit [Read error: Connection reset by peer]
novakane has joined #river
<novakane> damn pressing poweroff instead of backspace, the struggle of a laptop
<novakane> I should disable this one day
dnkl has quit [Ping timeout: 252 seconds]
<novakane> anyway rivercarro should be ready for when river-layout-v3 is merge in master
dnkl has joined #river
<leon-p> novakane: if you are using systemd, you can configure the behaviour of the power button in /etc/systemd/logind.conf
<novakane> leon-p: I'm not using systemd, I think it's acpid that handle that on my setup
hspak has quit [Ping timeout: 258 seconds]
<novakane> well at least the power command, not sure about the power button events
snakedye has joined #river
<novakane> ifreund: with the new quoting around spawn, how variable gonna works, should something like '$EDITOR' be quote with single quotes or double quotes
<ifreund> novakane: the normal rules of your shell apply, so if you want variables to be expanded use double quotes
<ifreund> note that `/bin/sh -c` will also expand variables if they are present in the river's environment
<novakane> ifreund: allright cool, not a breaking changes for me then, everything is already surrounded by single or double quotes
<novakane> I really like the 3 last PR!
<novakane> unrelated but are you guys good in Germany with the floods?
Erik59 has joined #river
Erik59 has quit [Client Quit]
<leon-p> novakane: it's mostly western germany. Here in Lower Saxony we just had medium rain alternating with days as hot as hell.
dbuckley has quit [Remote host closed the connection]
dbuckley has joined #river
<leon-p> the states closer to the coast are mostly prepared for floods. since we have a few rivers here that directly lead to the ocean all our dams are pretty high
<novakane> yeah makes sense, glad to hear that
<leon-p> but we had floods here too. Back when I was in school, me and a few friends helped fill sand-bags (early 2010s, I think). Apparently the state though it was worth a medal, so I got a nice wall-hanger out of the deal :D
<novakane> damn we have a hero with us :P
<leon-p> we mostly did it to skip a day of school, there where more than enough sand-bags alread. But don't tell anyone :P
<novakane> haha that I can unserstand! :P
<novakane> you need to delete the log now though :P
leon-p has quit [Quit: leaving]
<ifreund> novakane: I'm in aachen, so not too far away from the flooding but far enough away that I shouldn't be directly impacted
<ifreund> looks like the rain has stopped here for now though, which is great because there are a bunch of outdoor concerts this weekend I'll be at
novakane has quit [Ping timeout: 258 seconds]
novakane has joined #river
<ifreund> what do y'all think of getting rid of the /etc/river/init or $PREFIX/etc/river/init default init path?
<ifreund> I don't like the complexity of making the resulting binary dependant on the install prefix it was built with
<ifreund> yes other compositors like sway do this, but that doesn't mean it's good
<yyp> Wait, it saves prefix in the binary?
<ifreund> yup
<ifreund> so if you install to ~/.local it will use ~/.local/etc/init as the fallback
<novakane> you mean not having a default config?
<yyp> Oh
<yyp> I actually have it broken in the package because it will try to load from $pkgdir which doesn't exist anymore
<ifreund> novakane: yeah, I'd instead install the example init to /usr/share/examples/river/init on void
<ifreund> and let other distros handle it like they do examples
<ifreund> My issue with the status quo is that it's not *meant* to be a default config but an example config
<novakane> fine for me, I do have it installed in ~/.local/etc/ and it kinda bother me since this is the only thing here
<novakane> though what about when you launch river for the first time
<yyp> Fine, I would install it into /usr/share/river/init.example on Alpine
<yyp> Would be also great for Zig to have an option to override the install root, not just the prefix (e.g. --destdir /tmp --prefix /usr)
<ifreund> novakane: It will just display a solid blue screen, then you can switch ttys, killall river, and read the man page
<ifreund> yyp: set $DESTDIR
* yyp sighs
<yyp> Where is it documented?
<ifreund> in the source code :P
<yyp> bruh
<novakane> I don't know how people would react without a keybind to at least launch a terminal tbh
<yyp> I can finally remove that awful /usr/etc fixup from Alpine package :)
<ifreund> novakane: how would they know what that keybind is?
<ifreund> and they'd need foot installed anyways
<ifreund> yyp: see my PR here for advanced zig integration into distro packaging: https://github.com/void-linux/void-packages/pull/29288
<ifreund> even cross compiling works
<novakane> ifreund: I do agree with you, I just think we'll see some issues opened for this lol
<novakane> maybe like in the doc something, for an exemple init `cp /usr/share/... config/river/...`
<ifreund> yeah, I'll probably write something like that
<novakane> it reminds me, I was thinking this morning about when we discussed about installing river protocol in /usr/share/, it would need to be changed in zig-wayland scanner too right?
<ifreund> novakane: no, we can still use the xml we have in the protocol/ directory of the repo to build river
<novakane> ah yeah just installing it in /usr/share but building it with the ones in the repo?
<ifreund> yept
<ifreund> though other zig wayland projects wanting to depend on river's protocols could then use the versions in /usr/share
<novakane> but `scanner.addProtocolPath()` would works?
<ifreund> yep
<ifreund> addSystemProtocol() only works for protocols provided by the wayland-protocols package
<novakane> ah yeah that was I though the path is hard coded in the scanner
snakedye has quit [*.net *.split]
snakedye has joined #river
snakedye has quit [Ping timeout: 255 seconds]
snakedye has joined #river
novakane has quit [Quit: WeeChat 3.2]
novakane has joined #river
leon-p has joined #river
<leon-p> +1 for getting rid of those paths for init
<leon-p> I have begone to think that having a default configuration for a compositor is a bad thing anyway
<novakane> isn't that great we always all agree to remove things :P
<leon-p> people just take it as gospel instead of reading the man pages, which leads to both wrong assumptions and questions that can be answered by going through the documentation
<novakane> leon-p: I agree with you but do you think people would read the doc even with no defaut config
<novakane> sometimes I doubt that
<leon-p> my personal pet peave, both in #sway and here, is people having it set in ther mind that workspaces/tags always correspond to the Super+{1..9} keybinds instead of realizing that in reality they are a lot more flexible.
<leon-p> novakane: I have freed myself of the idea of making software nice for people who don't read the docs.
<leon-p> at least the introduction paragraph of the man page should always be read when using something.
<novakane> yeah for me that like the other way around too, if I come around to a software with no README or no doc even if it is the software of my dream it's a big no
<leon-p> absolutely. A README is your first and best chance to leave a great impression. If it is missing, that is usually a decent sign for the general effort that has gone into the project.
<leon-p> snakedye: any plans of adding support for randomly shuffling through all pictures in a directory to your wallpaper daemon? That is the one thing I am missing in swaybg.
<snakedye> That would be a nice feature
<snakedye> I'll add it
<leon-p> extra points for a smooth fading animation :P
<snakedye> If river also keeps fading. Non negotiable!
<novakane> since the subject comes, any reason to use your project instead of swaybg snakedye?
<snakedye> Borders rn and random shuffle once it's implement
<novakane> allright cool thanks
<leon-p> anyone know a strtok() alterntative for C in the standard libs? Working on contrib/layout.c right now and strtok just sucks.
<leon-p> I miss slices :( with C you either copy the string, modify it to have nulls in between words and then strcmpt it, or you are on you have to write a strcmp alternative...
<snakedye> leon-p: try the --dir or -d flag :p
<leon-p> snakedye: nice :D
<leon-p> ifreund: PR'd a first draft of the contrib layout update. Not too happy about the parsing code and I did not have had time to actually test it yet, so I'll probably touch it up later a bit.
<leon-p> I'll probably reqrite my layout in zig. String parsing in C sucks.
<novakane> yeah string is always complicated in programming, I like zig's approach on this
<snakedye> +1 zig
<snakedye> I should start writing clients in it but I kinda feel like I've pigeon holed myself with rust
<novakane> too bad you have a lot of interesting wayland project but I don't really want to read your code in rust :P
<snakedye> From a rust pov zig is not that hard to read. It's kinda-ish like rust except you don't have stuff like ::<&¢, $>()
andrea has joined #river
novakane has quit [Quit: WeeChat 3.2]
waleee has joined #river
andrea has quit [Quit: Quit]
st4ll1 has joined #river
<ifreund> switching from rust to zig for my projects was one of the best choices I've ever made
<ifreund> I've gotten sooo much more done since then
<ifreund> and yeah string parsing in C is horrible
<ifreund> RE: README importance, I spent a bit of time early today tweaking river's but haven't pushed yet
<ifreund> that was when I convinced myself that we should remove the default config path
notzmv has quit [Ping timeout: 268 seconds]
<leon-p> ifreund: I think you borked something in river with layout-v3. It says I did not push the right amount of view dimensions, but that part of the contrib layout is unchanged.
<ifreund> leon-p: I don't think I touched that part of the code at all
<ifreund> rivertile seems to work fine...
<ifreund> brb, making foot
<ifreund> *food
notzmv has joined #river
<leon-p> well, according to WAYLNAD_DEBUG output, river isn't counting right: https://paste.rs/eSp
<leon-p> oh
<leon-p> I think you swapped the order of the parameter
<leon-p> serial is no longer first, so river was ignoring the pushes
<leon-p> :D
<ifreund> oh yeah, I made the position of the serial arg consistent for all the requests/events when I added the layout name arg to commit
<ifreund> guess C's weak type system strikes again
<ifreund> I got a compile error for rivertile due to that change
<leon-p> nice, turns out my command parsing code actually works first try. Hopefully I won't have to touch it again anytime soon. Give me a minute to push and squash the PR and it should be ready to merge.
<ifreund> cool, thanks for taking that on
<ifreund> I think it's probably best if I don't do any code review right now, will try and have a look in the morning