Announcement

Collapse
No announcement yet.

How to save current plasma desktop/theme configuration?

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [PLASMA 5] How to save current plasma desktop/theme configuration?

    I got a nasty surprise when I booted the system this afternoon -- my whole desktop had changed to a black screen with a bunch of icons, most of my settings gone. I have no idea what happened. So I had to reload the whole system from backup to fix what was probably a kde/plasma problem.

    Is there a way to save all the current settings -- icons, colors, decorations, the whole shot -- as basically a new theme that could just be reloaded with a single click? Seems there used to be a setting for something like "save current desktop as new theme" but that is no longer. I did find a widget called "PlasmaConfSaver" but there's a warning that it might be fake and deletes all settings. Any ideas?
    We only have to look at ourselves to see how intelligent life might develop into something we wouldn't want to meet. -- Stephen Hawking

    #2
    Originally posted by doctordruidphd View Post
    I did find a widget called "PlasmaConfSaver" but there's a warning that it might be fake and deletes all settings. Any ideas?
    Where did you find this widget?
    Where did you see the warning?

    Are you referring to https://github.com/paju1986/PlasmaConfSaver and https://store.kde.org/p/1298955/ ?

    Mentioned here: https://www.reddit.com/r/kde/comment..._a_kde_config/

    And https://github.com/paju1986/PlasmaCo...cripts/save.sh seems to list files being saved.
    Last edited by chimak111; Feb 24, 2020, 06:52 AM.
    Kubuntu 20.04

    Comment


      #3
      Where did you find this widget?
      Where did you see the warning?
      Both are here: https://store.kde.org/p/1298955

      Basically the same thing you mentioned

      In spite of the warning message (one never knows about the legitimacy of messages like this) I tried it and could not get it to work, just comes up with error messages about it's own qml file. Do you use this? I did not try the github download.
      We only have to look at ourselves to see how intelligent life might develop into something we wouldn't want to meet. -- Stephen Hawking

      Comment


        #4
        Originally posted by doctordruidphd View Post
        Both are here: https://store.kde.org/p/1298955

        Basically the same thing you mentioned

        In spite of the warning message (one never knows about the legitimacy of messages like this) I tried it and could not get it to work, just comes up with error messages about it's own qml file. Do you use this? I did not try the github download.
        I don't. I just read up on these things. One of the "requirements" it mentions doesn't seem to exist by that name in Kubuntu 18.04: Qt.labs.platform.

        By the way, on the KDE Store page, someone else reported a qml error but the solution was not to run as root or with sudo.
        Last edited by chimak111; Feb 24, 2020, 06:58 PM.
        Kubuntu 20.04

        Comment


          #5
          See https://packages.ubuntu.com/search?k...-labs-platform
          Windows no longer obstructs my view.
          Using Kubuntu Linux since March 23, 2007.
          "It is a capital mistake to theorize before one has data." - Sherlock Holmes

          Comment


            #6
            1. This is 19.10, and yes the qt.labs.platform package does exist, but did not fix the errors. All of the other listed requirements are installed.

            2. I am not running as root or sudo.
            We only have to look at ourselves to see how intelligent life might develop into something we wouldn't want to meet. -- Stephen Hawking

            Comment


              #7
              From my reading of https://github.com/paju1986/PlasmaCo...cripts/save.sh, this is what the widget currently stores:

              Code:
              #plasma config files
              $HOME/.config/plasma-org.kde.plasma.desktop-appletsrc
              $HOME/.config/plasmarc
              $HOME/.config/plasmashellrc
              $HOME/.config/kdeglobals
              
              #kwin
              $HOME/.config/kwinrc
              $HOME/.config/kwinrulesrc
              
              #dolphin config
              $HOME/.config/dolphinrc
              
              #config session desktop
              $HOME/.config/ksmserverrc
              
              #config input devices
              $HOME/.config/kcminputrc
              
              #shortcuts
              $HOME/.config/kglobalshortcutsrc
              
              #klipper config
              $HOME/.config/klipperrc
              
              #konsole config
              $HOME/.config/konsolerc
              
              #kscreenlocker config
              $HOME/.config/kscreenlockerrc
              
              #krunner config
              $HOME/.config/krunnerrc
              
              #plasma themes and widgets
              $HOME/.local/share/plasma
              
              #wallpapers
              $HOME/.local/share/wallpapers/
              
              #autostart
              $HOME/.config/autostart/
              
              #icons
              $HOME/.local/share/icons/
              
              #color-schemes
              $HOME/.local/share/color-schemes/
              It also records a couple of latte-dock entries which I haven't included in the list above.

              (I still haven't got around to trying the widget out myself.)
              Kubuntu 20.04

              Comment


                #8
                Okay, just tried it and got this:

                Error loading QML file: file:///home/dkb/.local/share/plasma/plasmoids/com.pajuelo.plasmaConfSaver/contents/ui/main.qml:40:34: Type FullRepresentation unavailable
                file:///home/dkb/.local/share/plasma/plasmoids/com.pajuelo.plasmaConfSaver/contents/ui/FullRepresentation.qml:22:1: module "Qt.labs.platform" is not installed
                The same error appears after installing qml-module-qt-labs-platform.

                Doh! I just needed to log out and log back in. I removed the widget and reinstalled it for good measure. It now works.

                The data is stored in ~/.config/plasmaConfSaver



                I'm guessing it wouldn't be too difficult to modify ~/.local/share/plasma/plasmoids/com.pajuelo.plasmaConfSaver/contents/scripts/save.sh to include/exclude stuff. For example, if a user has a css file for styling konsole's tabs, and a conky or so in ~/.config/conky and so on.

                I still haven't looked at this and so don't know how well it'll restore stuff.
                Last edited by chimak111; Feb 25, 2020, 03:07 AM.
                Kubuntu 20.04

                Comment


                  #9
                  Thanks for your info. Given the list of files, it might just be easiest to write a bash script to save and restore them, which would also allow saves of different setups.
                  We only have to look at ourselves to see how intelligent life might develop into something we wouldn't want to meet. -- Stephen Hawking

                  Comment


                    #10
                    You might try rsync. I use it to backup my data files. The pattern would be rsync -auv <from source directory> <to target directory> and save my stuff to an external drive. A USB thumb drive would work fine for this.
                    The next brick house on the left
                    Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



                    Comment


                      #11
                      Originally posted by jglen490 View Post
                      You might try rsync. I use it to backup my data files. The pattern would be rsync -auv <from source directory> <to target directory> and save my stuff to an external drive. A USB thumb drive would work fine for this.
                      Yes, I do that to make an entire backup. The idea is to identify the specific files that need to be backed/restored so as to not zap other things in the process. Right now I am saving ~/.config/k* and ~/.config/plasma* but that still captures a lot of stuff that probably shouldn't be overwritten.
                      We only have to look at ourselves to see how intelligent life might develop into something we wouldn't want to meet. -- Stephen Hawking

                      Comment


                        #12
                        Originally posted by doctordruidphd View Post
                        Yes, I do that to make an entire backup. The idea is to identify the specific files that need to be backed/restored so as to not zap other things in the process. Right now I am saving ~/.config/k* and ~/.config/plasma* but that still captures a lot of stuff that probably shouldn't be overwritten.
                        So, by "shouldn't be overwritten", is it fair to assume that you are talking about being overwritten by a restore? If yes, then whatever is in the other "stuff" has already been set by some other configuration process and presumably works. That being the case, restoring those objects would simply restore the configuration state that has already been defined. No harm, no foul. But maybe I'm missing something ...
                        The next brick house on the left
                        Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



                        Comment


                          #13
                          Originally posted by doctordruidphd View Post
                          ...Right now I am saving ~/.config/k* and ~/.config/plasma* ...
                          But there are quite a few files not covered by ~/.config/k*
                          Just to name a few:
                          baloofilerc
                          breezerc
                          dolphinrc
                          falkonrc
                          gwenviewrc
                          okularrc
                          plasma-org.kde.plasma.desktop-appletsrc
                          plasmarc
                          Kubuntu 20.04

                          Comment


                            #14
                            Originally posted by chimak111 View Post
                            But there are quite a few files not covered by ~/.config/k*
                            Just to name a few:
                            baloofilerc
                            breezerc
                            dolphinrc
                            falkonrc
                            gwenviewrc
                            okularrc
                            plasma-org.kde.plasma.desktop-appletsrc
                            plasmarc
                            Right, and that is the point -- the idea behind my original post is to restore just the theme settings to the way I have customized them, not to restore settings on individual applications (okular, etc) that are independent of desktop appearance, and may get changed on a use-by-use basis. That's why just backing up and restoring .config is not a satisfactory solution. One could just restore the entire system for that matter, but in the process one would lose other settings and updates that are not directly related to the theme.

                            Of course the more fundamental question is why the desktop theme got whacked in the first place, but having had to restore the system from backup leaves the cause of that gone forever (I hope) .
                            We only have to look at ourselves to see how intelligent life might develop into something we wouldn't want to meet. -- Stephen Hawking

                            Comment


                              #15
                              Do you frequently update configs? And, the converse, do you frequently need to restore configs?

                              I'm just asking because frequency may determine what SHOULD be saved which may lead to a better/refined solution.
                              The next brick house on the left
                              Intel i7 11th Gen | 16GB | 1TB | KDE Plasma 5.27.11​| Kubuntu 24.04 | 6.8.0-31-generic



                              Comment

                              Working...
                              X