Git Cheat Sheet

From Nearline Storage
Revision as of 22:53, 31 December 2019 by Dlk (talk | contribs) (Created page with "===Create A New Project Repository=== # Go to [https://github.com/new https://github.com/new] and create a new repository (project) # Create a directory on the local workstat...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Jump to navigation Jump to search

Create A New Project Repository

  1. Go to https://github.com/new and create a new repository (project)
  2. Create a directory on the local workstation and populate it with the source files, then in that directory do:
    1. $ git init
    2. $ git add .
    3. $ git commit -m "first commit"
    4. $ git remote add origin git@github.com:dlk3/projectname.git
    5. $ git push -u origin master

Pull Down Changes Made At Remote Repository

$ git pull origin master

Push Local Changes Up To Remote Repository

$ git commit -a -m "Description"
$ git push