twodogsdave

Cinnamon_Settings_how-it-works

Jun 1st, 2025
16
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.84 KB | None | 0 0
  1. I wasn't expecting that script. Lol, a little bit above what I do, but I'm still looking at it and I'm probably going to insert some bits into my setup. This is how I have been doing it...
  2.  
  3. I like three setups.
  4. 1. a night theme (dark)
  5. 2. a day theme (light)
  6. 3. a side theme (dark and panel on left side vertically, like MX Linux)
  7.  
  8. I have three aliases that I use to save my settings at that very moment. The only time I really use these aliases is when I make changes to my desktop or my keybinds. That is important, because if I don't do a 'alias' after changing keybinds and then change mode, I lose my keybinds. Ex. I'm in night mode and I add some keybinds and then go to day mode, my keybinds are lost because I didn't do a 'alias' before changing.
  9.  
  10. my three aliases for changing mode are...
  11. alias day="dconf dump / > /home/dave/Documents/Cinnamon_Settings/day-desktop"
  12. alias night="dconf dump / > /home/dave/Documents/Cinnamon_Settings/night-desktop"
  13. alias side="dconf dump / > /home/dave/Documents/Cinnamon_Settings/side-desktop"
  14.  
  15. I had thought about applying the aliases to keybinds but decided against it as I have LOTS of custom keybinds already. It's so easy to pop in a terminal and just type 'day.' I have a special terminal setup (furminal) and all I do is super+return, type 'day' and 'q' to exit.
  16.  
  17. ---------------------------------------------------------------------------------------------------
  18.  
  19. next, I have three files in ~/bin for this to work (this is for my 3 keybinds I use to change modes quickly.
  20. the three files look like this...
  21.  
  22. #!/bin/bash
  23. dconf load / < ~/Documents/Cinnamon_Settings/day-desktop
  24.  
  25. ---------
  26.  
  27. #!/bin/bash
  28. dconf load / < ~/Documents/Cinnamon_Settings/night-desktop
  29.  
  30. ---------
  31. #!/bin/bash
  32. dconf load / < ~/Documents/Cinnamon_Settings/side-desktop
  33.  
  34. don't forget to make them executable.
  35.  
  36. ---------------------------------------------------------------------------------------------------
  37.  
  38. this part is where the 3 aliases save the config files...
  39.  
  40. in ~/Documents I have a folder called 'Cinnamon_Settings' and in this folder I keep this text file so I can remember some commands.
  41.  
  42. text file...
  43. install dconf-editor.
  44. open a terminal in this folder.
  45.  
  46. To backup your current Linux desktop settings..
  47. dconf dump / > my-cinnamon-desktop
  48. dconf dump / > my-cinnamon-desktop_"$(date -I)"
  49.  
  50. You can view this file using any text editors or cat command
  51. cat my-cinnamon-desktop
  52.  
  53. Now reset your desktop settings to the factory defaults with command..
  54. dconf reset -f /
  55.  
  56. Or, to restore your saved settings, simply do..
  57. dconf load / < my-cinnamon-desktop
  58.  
  59. In this folder (~/Documents/Cinnamon_Settings) I have these 5 files..
  60. README (text file above)
  61. my-cinnamon-desktop (created this when I had my system setup with all my keybinds. For backup)
  62.  
  63. day-desktop
  64. night-desktop
  65. side-desktop
  66. * and a folder called 'backup' to save old configs (I don't really ever use it)
  67.  
  68. ---------------------------------------------------------------------------------------------------
  69.  
  70. Keybinds. I only use three keybinds to change modes.
  71.  
  72. 1. name: cinnamon day desktop
  73. command: /home/dave/bin/cinnamon-day-desktop
  74. my keybind: Shift+Ctrl+Super+D (day)
  75.  
  76. 2. name: cinnamon night desktop
  77. command: /home/dave/bin/cinnamon-night-desktop
  78. my keybind: Shift+Ctrl+Super+N (night)
  79.  
  80. 3. name: cinnamon side desktop
  81. command: /home/dave/bin/cinnamon-side-desktop
  82. my keybind: Shift+Ctrl+Super+S (side)
  83.  
  84. ---------------------------------------------------------------------------------------------------
  85.  
  86. This is really a simple setup and I like it. I've been using it for a long time, too. I remember when I was first setting this up and I tried doing the mode change automatically with Cron but I didn't like it. Instead, I just use keybinds and when I want to change the mode it only takes 2 seconds to do.
  87.  
  88. If you would like to try this, this is how I suggest setting it up..
  89.  
  90. 1. create the three aliases
  91. 2. create the three executable files and put them in ~/bin
  92. 3. create the folder ~/Documents/Cinnamon_Settings (put the README file in this folder)
  93. 4. open a terminal in the folder above and do this in terminal to save your current desktop settings...
  94. dconf dump / > my-cinnamon-desktop
  95. 5. do 'day' first. setup your desktop with the light themes you like and change all settings you want for your day desktop. In terminal just type 'day'
  96. 6. now do 'night'. Repeat step 5 and setup your desktop for night.
  97. 7. finally do 'side'. This is optional, but it does work nicely. The panel moves to the side and I even move some of the applets around and it still works. When you go from 'side' back to 'night' all the original applet positions I saved in 'night' mode will work correctly.
  98.  
  99. If you go into ~/Documents/Cinnamon_Settings you will see your 4 new files and it's now time to test your keybinds. Have fun!
  100.  
Advertisement
Add Comment
Please, Sign In to add comment