Creating my own copy of the magic mirror code

Getting the smart mirror software to browse around.

Advertisements

Well, i’m still waiting for my Raspberry Pi to arrive.  It wasn’t that expensive, and waiting is the price i’ll have to pay I guess.

In the mean time i’m really curious on how this thing actually works.  I want to know exactly how it works so I can make the most of adapting the code to my own needs.

The first thing I want to do is create a copy of the code, so it’s no longer attached to the GitHub of Michael Teeuw, but to my own.

The way I did this is make a copy of the code into a new folder in my GitHub directory called “Smartmirrorproject”.

smartmirrorproject copy.png

Cool, so now to add it to my GitHub desktop.  I went ahead a created a brand new repository.

add smp to github dekstop.png

Just make sure the local path is correctly set to the folder you put your code.

At the bottom of the screen you have to provide a title and some kind of description.

github desktop smp description.png

Click publish at the top right of the screen.

Github desktop publish.png

Provide a name for the repository & publish.

Github desktop publish name.png

If I now go to the GitHub website to my personal repositories, it’s up there for anyone to download.

smp on github website.png

Great.  I’m not satisfied yet.  I don’t want to claim ownership of all this, so I will adapt the readme file to reflect the fact that I copied the source to adjust it.

Open atom.io from GitHub desktop by right-clicking the repository and selecting “Open in Atom”.

After navigating to the README.md file, I added the following lines of text :

readme adaptation.png

The README.md file name turns yellow at the left hand side of the screen, and at the bottom I see that some lines of code have not been committed.

notcommited atom.png

If I check with the GitHub desktop application, I can see there is 1 uncommitted change.  I can provide some info with my change, commit to master, and sync it all up (top right hand side of the screen).

Committing to master means, it will apply the changes to the so called “master” branch.  Branching is a popular concept in version control. Check here for more info :

 

uncommitted change.png

I also removed the section on the automated installation, as it uses the ‘cURL’ tool to run a script to pull the GitHub repository and install all the prerequisites.  cURL is a command line tool for getting or sending files using URL syntax.

You can easily find more info, if you also own a mac.  The back end of the mac is just a linux distribution, so you can use all of those linux commands on your mac as well.  Just open a terminal window (just open spotlight, and type ‘terminal’) and in the window that appears, just type ‘man curl’.  It gives you the manual on the curl command.  Press ‘q’ to cancel out of the manual.

 

man curl.png

I won’t be creating a script for my mirror project…yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s