## Fast guide to upload and update your repo to the GIT repo of Fab Academy
* * *
## SETUP GIT (to do only the first time)
1. Install Git
* GitBash for windows users [Gitbash](https://gitforwindows.org/)
* Open command line for MacOSX user(Git is usually preinstalled on Mac and Linux.) [command line](https://blog.teamtreehouse.com/introduction-to-the-mac-os-x-command-line)
> **cat ~/.ssh/id_rsa.pub** (If you see a long string starting with ssh-rsa, you can skip the ssh-keygen step)
5. Generate your SSH key
> **ssh-keygen -t rsa -C "$your_email"**
6. Now let´s see your keygen
> **cat ~/.ssh/id_rsa.pub**
7. Copy your key
> Windows: **clip < ~/.ssh/id_rsa.pub**
> Mac:**pbcopy < ~/.ssh/id_rsa.pub**
> Linux **xclip -sel clip < ~/.ssh/id_rsa.pub**
8. Finally add the copied key to GIT on the web version
[Video on how to do it](https://www.youtube.com/watch?v=54mxyLo3Mqk)
## COPY YOUR ACADEMY PERSONAL REPO.
1. Navigate to the folder where you want to put or create your repo. If you don´t know how to follow this [guide](https://www.digitalcitizen.life/command-prompt-how-use-basic-commands)(We recommend to create it in the desktop so you don´t have to dive into million of folders each time)
> **git pull** (for downloading the last copy of the repository)
3. To have a working copy of your repo
> **git merge** (to have a working copy)
4. Now name your update, so you know what you changed with this push.
> **git commit -m ‘change you did’**
5. Upload to the Repository
> **git push**
## Other commands used frecuently
> **git rm** (in case you need to remove a tracked file)
> **git mv** move or rename a file ,a directory or a symlinkgit
> **git status** to see what changed
## Terminal commands you will use to get to your archive folder
**dir** To view the contents of a directory, type "dir"
**ls** To view the files as a list
**cd** It is frequently useful to know in which directory you are currently working To move between directories, use the cd command with the name of a directory example go to desktop is "cd Desktop"
**mkdir** To create a new directory
**del** Subsequently, you might want to clean up useless files
*Capital letters matter here*
* * *
## PROBLEMS
* Run to the extended GIT CHEAT SHEET [TUTORIAL](git_cheat_sheet.md)
[MORE INFO](http://www.git-scm.com/book)
**Original tutorial by:**
*[Eduardo Chamorro](http://eduardochamorro.github.io/beansreels/index.html), Fab Lab Barcelona 01.2019