I’ve made a tiny script that restores Cinnamon DE settings from a backup.
I have it as a part of a set of setup scripts, which are run as root.
It looks like this:
su -c "dconf load /org/cinnamon/ < ./cinnamon_desktop_backup" my_user
pkill -HUP -f "cinnamon --replace"
The first line works as expected.
My problem is with restating the Cinnamon after that, so it would pick up the changes immediately, without log-out.
When I do it manually with
right click to menu bar -> Troubleshoot -> Restart Cinnamon
or with
Alt + F2, then type 'r' and press 'Enter'
it works as expected. But it’s a manual approach which would be nice to avoid.
Mainly because I have as a part of larger pack of setup scripts, which I want to leave running unattended.
When I run the
pkill -HUP -f "cinnamon --replace"
which I found as a advice / solution on several places around the internet, it crashes the Cinnamon, which leads to the Cinnamon restarting itself, showing pop-up window
You are currently in fallback mode, do you want to restart Cinnamon YES/NO
And clicking YES will do the job.
Effectively, it cuts the amount of manual steps to half or third, but definitely isn’t elegant
pkill -HUP -f "cinnamon"
or just plain
pkill cinnamon
will kill the Cinnamon, which will restart and log you out, so you’ll lose the whole session.
Anyone know what the working approaches that require manual steps do under the hood, so I may replicate it?