From 51f4e9e16008ed43d9448e0b6603eee72302c941 Mon Sep 17 00:00:00 2001 From: Jordi De Poortere Date: Thu, 12 May 2016 23:39:11 +0200 Subject: [PATCH 1/5] Get the latest Node.js This will get the latest Node.js from the selected branch. I do recommend only using a stable and tested version as newer ones might break MM. Branch can be changed by simply editing the NODE_STABLE_BRANCH variable. By using this setup script, Node.js will be downloaded from the official repository provided by NodeSource. --- installers/raspberry.sh | 48 ++++++----------------------------------- 1 file changed, 7 insertions(+), 41 deletions(-) diff --git a/installers/raspberry.sh b/installers/raspberry.sh index 4eb6af72..b6e48538 100644 --- a/installers/raspberry.sh +++ b/installers/raspberry.sh @@ -70,47 +70,13 @@ fi # Install or upgare node if nessecery. if $NODE_INSTALL; then - - echo -e "\e[96mStart Node download ...\e[0m" - - #Fetch the latest version of Node.js. - #TODO: Is there a native way to fetch the latest node version? - echo -e "\e[39mRetrieving latest node version." - NODE_LATEST=$(curl -l http://api.jordidepoortere.com/nodejs-latest/ 2> /dev/null) - - if [ "$NODE_LATEST" == "" ]; then - echo -e "\e[91mCould not retreive latest node version." - echo -e "\e[91mPlease try again or open an issue on GitHub." - exit - fi - - echo -e "Latest node version: \e[1m$NODE_LATEST\e[0m" - - #Construct the download URL. - DOWNLOAD_URL="https://nodejs.org/dist/latest/node-$NODE_LATEST-linux-$ARM.tar.gz" - - #Create Download Directory - rm -Rf ~/.MagicMirrorNodeInstaller || exit - mkdir ~/.MagicMirrorNodeInstaller || exit - cd ~/.MagicMirrorNodeInstaller || exit - - #Download Installer - echo -e "\e[39mDownloading node ... \e[90m" - if wget $DOWNLOAD_URL --no-verbose --show-progress; then - echo -e "\e[39mDownload complete." - else - echo -e "\e[91mCould not download node." - exit; - fi - - #Unpack and copy. - echo -e "\e[96mStart Node installation ...\e[90m" - tar xvf node-$NODE_LATEST-linux-$ARM.tar.gz || exit - cd node* || exit - sudo cp -R * /usr/local || exit - - #Cleanup - rm -Rf ~/.MagicMirrorNodeInstaller || exit + + #Fetch the latest version of Node.js from the selected branch + #The NODE_STABLE_BRANCH variable will need to be manually adjusted when a new branch is released. (e.g. 7.x) + #Only tested (stable) versions are recommended as newer versions could break MagicMirror. + NODE_STABLE_BRANCH="6.x" + curl -sL https://deb.nodesource.com/setup_$NODE_STABLE_BRANCH | sudo -E bash - + sudo apt-get install -y nodejs fi #Install magic mirror From 05b7237add7ae88f623e3af7bde241559fb0726e Mon Sep 17 00:00:00 2001 From: Jordi De Poortere Date: Fri, 13 May 2016 00:02:36 +0200 Subject: [PATCH 2/5] Fixing various typo's in the installer --- installers/raspberry.sh | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/installers/raspberry.sh b/installers/raspberry.sh index b6e48538..824bf7cc 100644 --- a/installers/raspberry.sh +++ b/installers/raspberry.sh @@ -18,7 +18,7 @@ echo ' \$$$$$$ |' echo ' \______/' echo -e "\e[0m" -# Define the tested version of node. +# Define the tested version of Node.js. NODE_TESTED="v5.1.0" #Determine which Pi is running. @@ -39,7 +39,7 @@ function command_exists () { type "$1" &> /dev/null ;} echo -e "\e[96mInstalling helper tools ...\e[90m" sudo apt-get install curl wget git build-essential unzip || exit -# Check if we need to install or upgrade node. +# Check if we need to install or upgrade Node.js. echo -e "\e[96mCheck current Node installation ...\e[0m" NODE_INSTALL=false if command_exists node; then @@ -60,29 +60,33 @@ if command_exists node; then fi else - echo -e "\e[92mNo Node upgrade nessecery.\e[0m" + echo -e "\e[92mNo Node.js upgrade nessecery.\e[0m" fi else - echo -e "\e[93mNode is not installed.\e[0m"; + echo -e "\e[93mNode.js is not installed.\e[0m"; NODE_INSTALL=true fi # Install or upgare node if nessecery. if $NODE_INSTALL; then + echo -e "\e[96mInstalling Node.js ...\e[90m" + #Fetch the latest version of Node.js from the selected branch #The NODE_STABLE_BRANCH variable will need to be manually adjusted when a new branch is released. (e.g. 7.x) #Only tested (stable) versions are recommended as newer versions could break MagicMirror. + NODE_STABLE_BRANCH="6.x" curl -sL https://deb.nodesource.com/setup_$NODE_STABLE_BRANCH | sudo -E bash - sudo apt-get install -y nodejs + echo -e "\e[92mNode.js installation Done!\e[0m" fi #Install magic mirror cd ~ if [ -d "$HOME/MagicMirror" ] ; then - echo -e "\e[93mIt seems like MagicMirror is allready installed." + echo -e "\e[93mIt seems like MagicMirror is already installed." echo -e "To prevent overwriting, the installer will be aborted." echo -e "Please rename the \e[1m~/MagicMirror\e[0m\e[93m folder and try again.\e[0m" echo "" @@ -109,6 +113,6 @@ else fi echo " " -echo -e "\e[92mWe're ready! Run \e[1m\e[97mDISPLAY=:0 npm start\e[0m\e[92m from the ~/MagicMirror directory to start your MagicMirror." +echo -e "\e[92mWe're ready! Run \e[1m\e[97mDISPLAY=:0 npm start\e[0m\e[92m from the ~/MagicMirror directory to start your MagicMirror.\e[0m" echo " " echo " " From 0f8601110678f15959da212abdef19ec87ae5028 Mon Sep 17 00:00:00 2001 From: Michael Teeuw Date: Fri, 13 May 2016 09:10:54 +0200 Subject: [PATCH 3/5] Create CHANGELOG.md --- CHANGELOG.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 00000000..55ee51a0 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,22 @@ +# MagicMirror² Change Log +All notable changes to this project will be documented in this file. +This project adheres to [Semantic Versioning](http://semver.org/). + +## [Unreleased] +### Added +- Changelog + +### Changed +- Improve the installer by fetching the latest Node.js without any 3rd party interferences. + +## [2.0.0] - 2016-05-03 +### Initial release of MagicMirror² +It includes (but is not limited to) the following features: +- Modular system allowing 3rd party plugins. +- An Node/Electron based application taking away the need for external servers or browsers. +- A complete development API documentation. +- Small cute fairies that kiss you while you sleep. + +## [1.0.0] - 2014-02-16 +### Initial release of MagicMirror. +This was part of the blogpost: http://michaelteeuw.nl/post/83916869600/magic-mirror-part-vi-production-of-the From e0c1a58b849ed22f6363db8b2185b91a7a439a0c Mon Sep 17 00:00:00 2001 From: Michael Teeuw Date: Fri, 13 May 2016 22:01:51 +0200 Subject: [PATCH 4/5] Italian Translation --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 55ee51a0..4ea4f1e9 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ This project adheres to [Semantic Versioning](http://semver.org/). ## [Unreleased] ### Added - Changelog +- Italian Translation ### Changed - Improve the installer by fetching the latest Node.js without any 3rd party interferences. From b7fff6d4526bd8aa3296ab21407c7cf34dc531ac Mon Sep 17 00:00:00 2001 From: Michael Teeuw Date: Wed, 18 May 2016 11:03:19 +0200 Subject: [PATCH 5/5] Update CHANGELOG.md --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4ea4f1e9..311f2356 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,7 +2,7 @@ All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/). -## [Unreleased] +## [2.0.1] - 2016-05-18 ### Added - Changelog - Italian Translation