Skip to content

Latest commit

 

History

History
19 lines (15 loc) · 906 Bytes

git-workflow.md

File metadata and controls

19 lines (15 loc) · 906 Bytes

Basic Git/Github Workflow

Starting a new project

  1. Create project directory on local machine
  2. In terminal, navigate to newly created directory
  3. Create a new git repo: git init
  4. Add a readme.md file that states what the project is all about: touch readme.md
  5. Add files to staging git add . (taking a snapshot)
  6. Add files (snapshot) to local repo: git commit -m "commit message"
  7. Go to Github and add a new repository
  8. After you create repo, copy the "remote add" line, then paste back within your project directory in your terminal
  9. Now push your local repo to Github: git push origin master

Updating an existing project

  1. After you make your updates, add files to staging git add . (taking a snapshot)
  2. Add files (snapshot) to local repo: git commit -m "commit message"
  3. Now push your local repo to Github: git push origin master