jonls / redshift

Redshift adjusts the color temperature of your screen according to your surroundings. This may help your eyes hurt less if you are working in front of the screen at night.
http://jonls.dk/redshift
GNU General Public License v3.0
5.91k stars 429 forks source link

Redshift not reading the config file #820

Open Augusto7743 opened 3 years ago

Augusto7743 commented 3 years ago

Hello Redshift creator. all right with you ? I have installed redshift both redshift_1.12-4_amd64.deb and the gtk version. I have created an redshift config file using the information from https://github.com/jonls/redshift/releases and using the path /home/USERNAME/.config/redshift/redshift.conf. The problem is redshift start and not use the settings from created redshift.conf. I need to use redshift command line to use some settings , but when happen internet access the screen changes temperature in each second from default to setting used in command line how if 2 redshift are working at same time and when closing redshift gtk or the binary automatically another redshift will be started thus need to restart the system disabling autostart redshift-gtk or try close very fast all redshift running tasks in htop.

How is possible fix it ? How configure to avoid redshift to access internet ? Thanks very much for your reply. Have an nice week.

jpSimkins commented 3 years ago

Mine loads the config fine but my config is located: ~/.config/redshift.conf. See if the fallback works for you

tomlbh commented 3 years ago

came to report this as well, the README.md incorrectly states that redshift.conf needs to be in a subdirectory.

Linux/macOS: ~/.config/redshift/redshift.conf (if the environment variable XDG_CONFIG_HOME is undefined) or ${XDG_CONFIG_HOME}/redshift/redshift.conf (if XDG_CONFIG_HOME is defined).

redshift looks for config at /.config/redshift.conf

br4nnigan commented 3 years ago

not true, my config currently is in ~/.config/redshift/redshift.conf and it's definitely being used (I put coords in there and there is no internet request for them). But I also definitely remember that I also had problems with the config not being used, so I explicitly used the -c path/to/use/config paramter. But after some time I omitted that and it seemed to work. Idk what's going on there...

tomlbh commented 3 years ago

Thanks for replying, it prompted me to look further into this. You're right, redshift works as intended, turns out that my issue was with the default configuration of apparmor on my distro (Debian). There's a bug report here https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=988068

tldr - apparmor was blocking redshift from reading the config file, I can confirm that redshift now picks up my config from ~/.config/redshift/redshift.conf