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.

    Add JS Code to the Mirror

    Scheduled Pinned Locked Moved Solved Troubleshooting
    33 Posts 5 Posters 12.3k 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.
    • S Offline
      sdetweil @dnj0104
      last edited by

      @dnj0104 what MM version are you running on? this problem was fixed in 2.10
      do this
      from the MM folder

      cd ~/MagicMirror
      git checkout modules/node_modules/node_helper/index.js
      

      Sam

      How to add modules

      learning how to use browser developers window for css changes

      1 Reply Last reply Reply Quote 0
      • D Offline
        dnj0104
        last edited by

        I got version 20.13.0

        from your git command i get output

        pi@raspberrypi:~/MagicMirror $ git checkout modules/node_modules/node_helper/index.js
        error: pathspec 'modules/node_modules/node_helper/index.js' did not match any file(s) known to git
        
        S 1 Reply Last reply Reply Quote 0
        • S Offline
          sdetweil @dnj0104
          last edited by

          @dnj0104 can you do

          cd ~/MagicMirror
          grep version package.json
          

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          S 1 Reply Last reply Reply Quote 0
          • D Offline
            dnj0104
            last edited by

            yes and and result is

            pi@raspberrypi:~/MagicMirror $ grep version package.json
            	"version": "2.13.0",
            
            S 1 Reply Last reply Reply Quote 0
            • S Offline
              sdetweil @sdetweil
              last edited by

              @dnj0104 yeh, mess

              this module should be installed like this to make up for the name problem

              cd ~/ MagicMirror/modules
              git clone https://github.com/timjong93/MMM-MPD.git mpd_client
              cd mpd_client
              npm install
              

              then everything matches

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              D 1 Reply Last reply Reply Quote 0
              • S Offline
                sdetweil @dnj0104
                last edited by

                @dnj0104 thanks… so the git checkout would not have worked, sorry…

                try the install as I suggest above

                Sam

                How to add modules

                learning how to use browser developers window for css changes

                1 Reply Last reply Reply Quote 0
                • D Offline
                  dnj0104 @sdetweil
                  last edited by

                  @sdetweil

                  so then i throw mpd client folder in trash and follow your
                  install instructions?

                  because I believe there have been a problem when I first installed mpd_client, I did not been clear where the npm install should been placed, if you read in mpd-client readme.md maybe you understand, english is not my first language, and my linux-fu is below first grade :)

                  S 1 Reply Last reply Reply Quote 0
                  • S Offline
                    sdetweil @dnj0104
                    last edited by sdetweil

                    @dnj0104 is ok, he didn’t do the instructions correctly…

                    yes, start over

                    cd ~/MagicMirror/modules
                    rm -rf mod_client
                    

                    then do the install as I suggested

                    Sam

                    How to add modules

                    learning how to use browser developers window for css changes

                    1 Reply Last reply Reply Quote 0
                    • D Offline
                      dnj0104
                      last edited by

                      and then change folder name to mod-client ?

                      is it mod-client (folder) and mod_client in config.js in config array. do I also change name in mpd-client.js file?

                      S 1 Reply Last reply Reply Quote 0
                      • S Offline
                        sdetweil @dnj0104
                        last edited by

                        @dnj0104 everythign should be named mpd_client

                        look at the files list in the module
                        https://github.com/timjong93/MMM-MPD

                        all mpd_client

                        no, do NOT change the folder name, change the config.js to match

                        module: 'mpd_client',
                        

                        Sam

                        How to add modules

                        learning how to use browser developers window for css changes

                        D 1 Reply Last reply Reply Quote 0
                        • 1
                        • 2
                        • 3
                        • 4
                        • 3 / 4
                        • 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