This is the repository we will be using for the moment
Everybody should run through the following for some quick 'n dirty git action
- Create your local git repository
cd <location>
- go to your own project folder destination on your computergit init
- this creates the git repository
- Clone the repository
git clone git@github.com:btrebach/basic-git-tutorial.git
touch FirstnameLastname.txt
- Add files to index
git add FirstnameLastname.txt
- Moves the file to the Head
git commit -m 'FirstnameLastname initial commit'
git status
--> should show the file you just created
- This shows the difference between the Working Directory (your computer) and the Index (staging area)
- Push the file to the actual remote repository (on GitHub)
git push origin master
Boom, there's your basic workflow.
If you have already cloned the repo but run git status
and see people have added their own files run git pull origin master
to pull down the latest and greatest.