Pushing Local Project to a Github Repo

Github is a tool that allows you to create a remote repository, a repository that’s hosted on somebody else’s server or computer.

You must create an account in order to follow the rest of the tutorial.

  1. In the top right corner of the Github interface, select the “+” icon, then select “New repository.”
  2. Give your new repository a Name and a Description. Choose to make your repository either Public or Private. DO NOT create a README.md file.
  3. After you press “Create repository,” Github will take you to a page with comprehensive instructions on how to create/push to a repository in the Command Line.

In Command Line:

cd your-project-directory
git init
git remote add origin https://github.com/your-username/RepositoryName.git
git add .
git commit -m "Initial commit"
git push -u origin master

You should be all set in Github!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s