Git uploads project to GitHub tutorial

Source: Internet
Author: User

1 Download git locally

2 Go to your project location

3 git init

4 git Add.

5 git commit-m ' first commit '

6 Creating an SSH KEY

Take a look at your C-drive user directory there is no. ssh directory, some words to see if there is no Id_rsa and id_rsa.pub these two files, have jumped to the next step, did not create by the following command

  $ ssh-keygen-t rsa-c "[Email protected]"

7 into your GitHub.

Find Settings-ssh-and-gpgkeys

8 Open your computer's C drive. Locate the. ssh. Copy the contents of the id_rsa.pub into the key content box below the title, and finally click Add SSH key

9 and then we can associate the local warehouse with GitHub.

10 Copy the address of a new item on GitHub

git remote add URL on Origin GitHub

11 Finally, we can push all the contents of the local repository to the remote repository (GitHub).

Git push-u Origin Master

12 after the success of the code is like this

Git uploads project to GitHub tutorial

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.