MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    updating without losing settings in config, and js files?

    Scheduled Pinned Locked Moved General Discussion
    10 Posts 6 Posters 5.4k Views 5 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • N Offline
      ninjabreadman @navyvette87
      last edited by

      @navyvette87 @Cyberwrights is right, and where possible you should migrate your changes into config.js, custom.css, etc.

      When updating, git insists that your files not have changes that conflict with those of the repository. Use git stash as outlined here to store your local changes, pull updates from the repo, then restore your own changes.

      Problem with config or JavaScript? Copy/paste it into JSHint.
      Check out the detailed walkthroughs on install, config, modules, etc.

      1 Reply Last reply Reply Quote 2
      • MichMichM Offline
        MichMich
        last edited by

        Just curious, why would you modify any file other than the config.js and the custom.css file?

        1 Reply Last reply Reply Quote 1
        • N Offline
          Nneuland @navyvette87
          last edited by

          @navyvette87

          I am not aware of how to implement “everything” into config.js.
          Custom MMM-remotecontrol buttons, cache options, MMM-spotify buttons…

          S N 2 Replies Last reply Reply Quote 0
          • S Do not disturb
            sdetweil @Nneuland
            last edited by sdetweil

            @Nneuland ALL module and MagicMirror config goes in config.js

            the design is anything in config.js is used before the defaults from system and modules

            ALL css goes in css/custom.css

            anything in css/custom.css overrides anything specified by modules or system settings

            IF you edit any other file, you risk blocking updates AND losing your changes when you force update

            the override design means you never have your lose anything

            this is why my upgrade script is 2 pass, to warn you of changes(that you may have forgotten) that WILL be lost.

            Sam

            How to add modules

            learning how to use browser developers window for css changes

            1 Reply Last reply Reply Quote 0
            • N Offline
              Nneuland @Nneuland
              last edited by

              Just to play devils advocate. Wouldn’t some modifications need to take place before electron launches?

              I’d love to clean up my set up. is there any way to single out modified files that need to be implemented into config.js

              S N 2 Replies Last reply Reply Quote 0
              • S Do not disturb
                sdetweil @Nneuland
                last edited by sdetweil

                @Nneuland no, we read config. js for electron options and
                commandline switches too

                to detect changes to base files, in each place (MagicMirror snd module folders ) do

                git status

                if there are modified files do

                git diff filename
                to see the actual changes

                once you migrate those to config.js
                git stash the changed files in that location

                run MagicMirror and test that

                then git stash pop
                to restore from stash

                the git checkout filename
                to restore from the repository (hidden in .git folder)

                repeat til no changed files and MagicMirror and modules run as expected

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                1 Reply Last reply Reply Quote 0
                • N Offline
                  Nneuland @Nneuland
                  last edited by

                  This is gold. Thank you Sam!

                  1 Reply Last reply Reply Quote 0
                  • 1 / 1
                  • First post
                    Last post
                  Enjoying MagicMirror? Please consider a donation!
                  MagicMirror created by Michael Teeuw.
                  Forum managed by Sam, technical setup by Karsten.
                  This forum is using NodeBB as its core | Contributors
                  Contact | Privacy Policy