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.

    Trouble With config file

    Scheduled Pinned Locked Moved Troubleshooting
    5 Posts 3 Posters 1.9k Views 2 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.
    • P Offline
      paddyhughes
      last edited by

      Hi I copied the sample config.js file and renamed it config.js

      MM2 works with default locations and feeds… Alls good.

      OK so my issues is always with the titles

      Calender
      url change is ok and MM2 displays from my location but once i change the
      header: “US Holidays”, to header: “Irish Holidays”,
      I get the message Please create a config file. so i change the header back to the US.

      moving on to Weather forcast
      Location ID change works and my Appid WORK.
      But again change the Location: “New York” to Dublin i get that message again.

      then in the news feed my URL works but change the title name and the same issues happens again

      /* Magic Mirror Config Sample
       *
       * By Michael Teeuw http://michaelteeuw.nl
       * MIT Licensed.
       *
       * For more information how you can configurate this file
       * See https://github.com/MichMich/MagicMirror#configuration
       *
       */
      
      var config = {
      	address: "localhost", // Address to listen on, can be:
      	                      // - "localhost", "127.0.0.1", "::1" to listen on loopback interface
      	                      // - another specific IPv4/6 to listen on a specific interface
      	                      // - "", "0.0.0.0", "::" to listen on any interface
      	                      // Default, when address config is left out, is "localhost"
      	port: 8080,
      	ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], // Set [] to allow all IP addresses
      	                                                       // or add a specific IPv4 of 192.168.1.5 :
      	                                                       // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"],
      	                                                       // or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
      	                                                       // ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],
      
      	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/ical-calendar/ics/51/Ireland_Holidays.ics"
      					}
      				]
      			}
      		},
      		{
      			module: "compliments",
      			position: "lower_third"
      		},
      		{
      			module: "currentweather",
      			position: "top_right",
      			config: {
      				location: "New York",
      				locationID: "",  //ID from http://www.openweathermap.org/help/city_list.txt
      				appid: "YOUR_OPENWEATHER_API_KEY"
      			}
      		},
      		{
      			module: "weatherforecast",
      			position: "top_right",
      			header: "Weather Forecast",
      			config: {
      				location: "New York",
      				locationID: "2964574",  //ID from http://www.openweathermap.org/help/city_list.txt
      				appid: "MYKEYMYKEY*************************"
      			}
      		},
      		{
      			module: "newsfeed",
      			position: "bottom_bar",
      			config: {
      				feeds: [
      					{
      						title: “RTE News”,
      						url: "https://www.rte.ie/news/rss/news-headlines.xml"
      					}
      				],
      				showSourceTitle: true,
      				showPublishDate: true
      			}
      		},
      	]
      
      };
      
      /*************** DO NOT EDIT THE LINE BELOW ***************/
      if (typeof module !== "undefined") {module.exports = config;}
      

      Thanks for all the help :)

      Mykle1M 1 Reply Last reply Reply Quote 0
      • Mykle1M Offline
        Mykle1 Project Sponsor Module Developer @paddyhughes
        last edited by

        @paddyhughes

        Most likely you’re getting syntax errors because of a missing quote or incorrect quote, or missing comma when you make your changes. By this I mean that all quotes are not valid within the code. I noticed this in your example above. title: “RTE News”,. Those quotes are enough to make your config fail. They should look like this title: "RTE News",. It’s a small detail, but as you are finding out, a very important one.

        I tried your Irish Holidays url and changed my header and it works fine. I’m sure this is where your problem lies. So, check your edits carefully for the proper syntax. :-)

        0_1517187489230_Capture.PNG

        Create a working config
        How to add modules

        P 1 Reply Last reply Reply Quote 0
        • P Offline
          paddyhughes @Mykle1
          last edited by

          @Mykle1

          Thanks Mike i am using CyberDuck on IMac when i do a live edit it changes the ‘’ to " for some reason thanks i would have not spotted that at all.

          Mykle1M 1 Reply Last reply Reply Quote 0
          • Mykle1M Offline
            Mykle1 Project Sponsor Module Developer @paddyhughes
            last edited by

            @paddyhughes

            You’re welcome, mate. It’s common enough. Perhaps there’s an option within CyberDuck that will use the necessary quotes or maybe consider another text editor that doesn’t use them. There are plenty of free editors

            Create a working config
            How to add modules

            1 Reply Last reply Reply Quote 0
            • cruunnerrC Offline
              cruunnerr
              last edited by

              Try Xcode ;)

              In cyberduck do a right click and say “edit with --> Xcode”

              For ssh i use “terminus”

              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