Navigation

    MagicMirror Forum

    • Register
    • Login
    • Search
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • Donate
    • Discord
    MagicMirror² v2.15.0 is available! For more information about this release, check out this topic.

    How do I edit config, I see every new module starts whit going to config.js

    Troubleshooting
    4
    10
    3530
    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.
    • K
      KMH0 last edited by

      I dont know what to do now … 😞

      1. Duplicate config/config.js.sample to config/config.js.
      2. Modify your required settings.

      The following properties can be configured:

      strawberry 3.141 1 Reply Last reply Reply Quote 0
      • strawberry 3.141
        strawberry 3.141 Project Sponsor Module Developer @KMH0 last edited by

        @KMH0

        1. open a terminal type in cd ~/MagicMirror/config to change directory
        2. nano config.js
        3. After you made your changes press ctrl+x and confirm
        4. change directory to parent directory cd ..
        5. start the mirror npm start
        K 1 Reply Last reply Reply Quote 3
        • K
          KMH0 last edited by

          Thanks! It worked 😃 Made my day

          1 Reply Last reply Reply Quote 0
          • K
            KMH0 last edited by

            This post is deleted!
            1 Reply Last reply Reply Quote 0
            • K
              KMH0 @strawberry 3.141 last edited by

              @strawberry-3.141 So I was playing around, thinking I knew everything now and my mirror is blank… I was trying to add a module in the config, and now I messed up. Any suggestions?

              broberg 1 Reply Last reply Reply Quote 0
              • broberg
                broberg Project Sponsor @KMH0 last edited by

                @KMH0 post your config, this will help to indentify the issues

                K 1 Reply Last reply Reply Quote 1
                • K
                  KMH0 @broberg last edited by yawns

                  @broberg

                  var config = {
                          port: 8080,
                          ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"],
                  
                          language: 'en',
                          timeFormat: 24,
                          units: 'metric',
                  
                          modules: [
                                  {
                                          module: 'alert',
                                  },
                                  {
                                          module: "updatenotification",
                                          position: "top_bar"
                                  },
                                  {
                                          module: 'clock',
                                          position: 'top_left'
                                  },
                                  {
                                          module: 'calendar',
                                          header: 'US Holidays',
                                          position: 'top_left',
                                          config: {
                                                  calendars: [
                                                          {
                                                                  symbol: 'calendar-check-o ',
                                                                  url: 'webcal://www.calendarlabs.com/templates/ical/US-Holidays.ics'
                                                          }
                                                  ]
                                          }
                                  },
                                  {
                                          module: 'compliments',
                                          position: 'lower_third'
                                  },
                                  {
                                          module: 'currentweather',
                                          position: 'top_right',
                                          config: {
                                                  location: 'New York',
                                                  locationID: '',  //ID from http://www.openweathermap.org
                                                  appid: 'YOUR_OPENWEATHER_API_KEY'
                                          }},
                                  {
                                          module: 'newsfeed',
                                          position: 'bottom_bar',
                                          config: {
                                                  feeds: [
                                                          {
                                                                  title: "New York Times",
                                                                  url: "http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml"
                                                          }
                                                  ],
                                                  showSourceTitle: true,
                                                  showPublishDate: true
                                          }
                                  },
                          };
                  
                  /*************** DO NOT EDIT THE LINE BELOW ***************/
                  if (typeof module !== 'undefined') {module.exports = config;}
                  
                  1 Reply Last reply Reply Quote 0
                  • yawns
                    yawns Moderator last edited by

                    You missed one ] which I added on 4th line from bottom

                    var config = {
                            port: 8080,
                            ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"],
                    
                            language: 'en',
                            timeFormat: 24,
                            units: 'metric',
                    
                            modules: [
                                    {
                                            module: 'alert',
                                    },
                                    {
                                            module: "updatenotification",
                                            position: "top_bar"
                                    },
                                    {
                                            module: 'clock',
                                            position: 'top_left'
                                    },
                                    {
                                            module: 'calendar',
                                            header: 'US Holidays',
                                            position: 'top_left',
                                            config: {
                                                    calendars: [
                                                            {
                                                                    symbol: 'calendar-check-o ',
                                                                    url: 'webcal://www.calendarlabs.com/templates/ical/US-Holidays.ics'
                                                            }
                                                    ]
                                            }
                                    },
                                    {
                                            module: 'compliments',
                                            position: 'lower_third'
                                    },
                                    {
                                            module: 'currentweather',
                                            position: 'top_right',
                                            config: {
                                                    location: 'New York',
                                                    locationID: '',  //ID from http://www.openweathermap.org
                                                    appid: 'YOUR_OPENWEATHER_API_KEY'
                                            }
                                    },
                                    {
                                            module: 'newsfeed',
                                            position: 'bottom_bar',
                                            config: {
                                                    feeds: [
                                                            {
                                                                    title: "New York Times",
                                                                    url: "http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml"
                                                            }
                                                    ],
                                                    showSourceTitle: true,
                                                    showPublishDate: true
                                            }
                                    },
                              ]
                            };
                    
                    /*************** DO NOT EDIT THE LINE BELOW ***************/
                    if (typeof module !== 'undefined') {module.exports = config;}
                    
                    K 1 Reply Last reply Reply Quote 3
                    • K
                      KMH0 @yawns last edited by

                      @yawns Thank you so much! But how do I add modules ? Do I just copy paste in to the config?

                      yawns 1 Reply Last reply Reply Quote 0
                      • yawns
                        yawns Moderator @KMH0 last edited by

                        @KMH0
                        Actually it is always the same thing.

                        1. Find yourself a module you like, for example: MMM-IP
                        2. Top right on the github repository you see a green button saying “clone or download”. If you click it you get the url for this repository. In this case it is https://github.com/fewieden/MMM-ip.git
                        3. Open a terminal on your pi (either directly or using SSH) and type cd ~/MagicMirror/modules
                        4. Clone the module to your pi by typing git clone https://github.com/fewieden/MMM-ip.git. This downloads the repository and extracts it into a new folder.
                        5. Enter the new directory cd MMM-ip and run npm install (in this case it is not required … the readme should tell you to do so)
                        6. Edit your config file and add the code for the new module as the readme instructs to.
                        7. Restart your magic mirror process and check what happened.

                        Sidenote: If you run into trouble with your config file, you can always paste the content into http://jshint.com/. If everything is fine it will only show this which is fine:

                        One undefined variable
                        64	module
                        
                        1 Reply Last reply Reply Quote 1
                        • 1 / 1
                        • First post
                          Last post
                        Enjoying MagicMirror? Please consider a donation!
                        MagicMirror created by Michael Teeuw.
                        Forum managed by Paul-Vincent Roll and Rodrigo Ramírez Norambuena.
                        This forum is using NodeBB as its core | Contributors
                        Contact | Privacy Policy