Wednesday, March 12, 2014

Create New Git Repo

Yep, this should be basic, but I always can't memorise the commands. Here, I am writing them down.

p.s. let's use for example.

On Git Server Side

  • mkdir heron-web.git
  • cd heron-web.git/
  • git init --bare

In My Local Code Directory

  • cd <path-to-the-code>
  • git init
  • vim .gitignore
  • git add -A
  • git commit -a -m "init commit"
  • git remote add original
  • git push -u original master

Clone in Other Place

  • git clone
  • cd heron-web

No comments:

Post a Comment