Skip to content

Instantly share code, notes, and snippets.

@newfront
Created March 30, 2011 19:19
Show Gist options
  • Save newfront/895097 to your computer and use it in GitHub Desktop.
Save newfront/895097 to your computer and use it in GitHub Desktop.
github's directions for initializing a new Git repository
Global setup:
Download and install Git
git config --global user.name "<name>"
git config --global user.email <email>
Next steps:
mkdir dailyhacking
cd dailyhacking
git init
touch README
git add README
git commit -m 'first commit'
git remote add origin [email protected]:<github_username>/<github_repo_name>.git
git push -u origin master
Existing Git Repo?
cd existing_git_repo
git remote add origin [email protected]:<github_username>/<github_repo_name>.git
git push -u origin master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment