Installing Grunt

With some of the updates to the Magic Mirror program, I’ve found that it’s best to have the latest version of Grunt installed on your Pi as well. Grunt is basically a task manager and a build manager that integrates with Node.js. It has certain features that are helpful in the JavaScript environment, such as minification or the process of removing all unnecessary characters from source code without changing its functionality. On top of that, Grunt enables your program to reload as you make changes to your code during development. You’ll notice, when we start the Magic Mirror later on, that we’re going to call on Grunt usage with the npm start command. Grunt installation is very simple. We’re going to want to install Grunt’s command-line interface globally on the Pi. This way, we can readily call upon it when working from any directory:

sudo npm install –g grunt-cli

With Node.js and Grunt now downloaded, it’s time to finally clone into our repository:

  1. Make sure your Raspberry Pi is updated and upgraded. You can do this by typing  sudo apt-get update && sudo apt-get upgrade.
  2. Clone the repository with git clone https://github.com/MichMich/MagicMirror ~/MagicMirror.
  3. This will download the directory containing the Magic Mirror files directly to your /home/pi folder.
  4. You’re going to enter the repository with cd ~/MagicMirror.
  5. You are then going to install and run the application using npm install && npm start.

It will take a second or two, but you will then see the default screen for your Magic Mirror pop up on your screen (Teeuw).

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.147.104.230