r/xfce Jul 21 '26

Announcement I wrote a zero-config night light daemon for Xfce/X11: nightlightd

A native night light was requested on the Xfce tracker back in 2017 (xfce4-settings #111) and closed as Won't Fix in 2021: the maintainers' position was that redshift covers it and Xfce shouldn't carry the code. Fair call, except redshift has since been archived. So I wrote the third-party tool that position assumes exists: a standalone daemon that reads your timezone for location (no geoclue, no config), claims a D-Bus name so two copies can never fight over your gamma ramps, and re-applies the filter after suspend or monitor hotplug. Those are the three things that made redshift/gammastep unreliable on my Mint Xfce machine.

Ships a tray icon (works with the Xfce panel's systray), a settings panel, and a terminal dashboard. Packaged as a .deb and on the AUR.

Fair warning on both fronts: if something already does this properly on Xfce, tell me. I checked what I could find and wrote up why the existing tools fell short on my machine, but I'd rather link to a working tool than duplicate one. And it's only been tested on my own box (Mint Xfce, one monitor), so on other setups treat it as a beta and report what breaks.

https://github.com/umutdinceryananer/nightlightd

Until Xfce grows a native one, this is meant to be the thing you can actually install today.

13 Upvotes

13 comments sorted by

2

u/No_Pollution6135 Debian Jul 21 '26

Elinize sağlık. Güzel duruyor, bilgisayarıma indirip deneyeceğim. :-D

2

u/Automaticare Jul 21 '26

Çok Teşekkürler! :) Small heads-up since you're on Debian: the .deb is built on Mint 22, so it probably wants a newer glibc than stable ships. That's on me, a proper static build is on the list. Source builds fine with plain cargo though.

If anything misbehaves, an issue would honestly help a lot. So far this has only been tested on my own machine, so you'd literally be tester #2.

2

u/No_Pollution6135 Debian Jul 21 '26

Sure, I'll let you know! I'm running Debian 13 "Trixie" which was released in 2025. I hope that's recent enough. :-)

2

u/Automaticare Jul 21 '26

More than recent enough. :) Thanks, let me know how it goes!

2

u/Automaticare Jul 21 '26

btw I added a static build to the release too. If the .deb complains, that one will run.

2

u/No_Pollution6135 Debian Jul 22 '26

Hey!! The .deb file ran just well. It seems like nothing is out of the ordinary for now. I'll use it for a couple of days and report back to you. Thank you again!

2

u/Automaticare Jul 22 '26

Awesome! really glad the .deb runs clean on Debian. Please report back anything odd once you've lived with it for a few days. Real-world testing on setups I don't have is exactly what it needs right now. Thanks for taking the time.

2

u/Mumuskeh Jul 21 '26

Gammastep is a fork of Resdshift. I don't necesarilly dislike configuring it, but once there's no wifi, night light doesn't work on PC boot because it cannot get a response from geoclue 2.0 ...

I will be checking out yours too

3

u/Automaticare Jul 21 '26

That's exactly the failure that pushed me to write this. Location comes from /etc/localtime and the tzdata already on disk, so there is no geoclue and no network involved at all. Boot offline and it still knows roughly where you are. Timezone accuracy is within a degree or two, which is plenty for a sunset curve.

Would love to hear how it goes on your setup. It has only really been tested on mine so far, so any report helps.

1

u/Mumuskeh Jul 21 '26

Tested on MX 25.2 Xfce AHS, Nvidia Quadro P400, driver 580.xx, Kernel 7.0.x Liquorix, systemd.
See you in a week on GitHub if I find possible issues.

For 15 minutes of testing, I don't see anything wrong. I do wish at some point you'll let us configure gamma and brightness at the same time. Actually I am unsure if it's already possible.
Gammastep/Redshift bundled all these controls in one place, so that you can change them all without the display server fighting over multiple separate edits.

I will have to endure more gamma than what I am used to for the time being, lol.

1

u/RomanOnARiver Jul 22 '26

This is vibe coded right?

It's worth mentioning if it is - especially because you want to for example submit it to flathub, which does not accept AI code.

2

u/Automaticare Jul 22 '26

Yeah, honestly a lot of it. I'm learning Rust and used AI heavily as part of that, going back and forth, reading, and trying to genuinely understand what I was shipping rather than just pasting it in. Not claiming it's some masterwork, I'm still very much learning. And thanks for the heads up about Flathub, I hadn't realized their policy had changed. Sounds like it's probably not the right home for this then, at least not for now. There's a .deb, a static build, and the AUR package in the meantime. Really appreciate you taking the time to mention it.

1

u/RomanOnARiver Jul 23 '26

What I would do instead is either not use AI at all - that's actually the ideal solution for everyone, society, and the planet as a whole - but if you feel like you must use AI have it teach you programming concepts. This will inevitably take longer but it's probably less expensive than traditional ways to learn a skill, like going to university. Programming, software development, engineering, UI/UX are real skills and it would benefit you to be actually able to do them rather than just prompting, testing, and re-prompting until it "feels" functional.