@ninjabreadman said in How to update the master branch?:
@PaulB First, make a backup of your install with cp -r ~/MagicMirror ~/MM-Backup
.
Noo! Not a good idea if you’re running on a RPi with small SD card. That is a huge directory: du -sh ./
~1.3GB, already for a quite small install. You might need that space for the update itself. Never good idea to max out your SD card.
Rather use tar
, and try one of these:
cd ~
# remove `v` flag to avoid huge verbose output
tar --exclude={.git,node_modules} -zcvf MM_BAK.tgz ./MagicMirror
tar --exclude='node_modules' --exclude='.git' -zcvf MM_BAK.tgz ./MagicMirror
# This may require you to have the bash shell option globstar' set.
# Check with: 'shopt -s globstar'
tar --exclude='**/.git/*' --exclude='**/node_modules/*' -zcvf MM_BAK.tgz ./MagicMirror
This will avoid getting the huge node_modules and .git directories.
(You can always git init and reset your git origin url to git fetch from the resp directories if needed to re-instate.)