Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to use git to upload a project to github

2025-03-12 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly introduces the relevant knowledge of "how to use git to upload a project to github". The editor shows you the operation process through an actual case. The operation method is simple, fast and practical. I hope this article "how to use git to upload a project to github" can help you solve the problem.

1. Go to the home page of Github and click New repository to create a new project

two。 After filling in the relevant information, click create.

Repository name: warehouse name

Description (optional): warehouse description details

Public, Private: repository permissions (public sharing, private or specified collaborator)

Initialize this repository with a README: add a README.md

Gitignore: the type of repository that does not require version management, corresponding to the generated file. Gitignore

License: certificate type, corresponding to the generated file LICENSE

4. Click Clone or dowload and an address will appear. Copy is an alternate address.

5. Then to the local operation, first of all, right-click your project, if you installed git successfully, right-click will appear two new options, respectively, Git Gui Here,Git Bash Here, here we choose Git Bash Here, enter the following interface, Test_Bluetooth is my project name.

6. Next, enter the following code (key steps) to clone the warehouse on github to the local

Git clone CKTim/BlueTooth.git (replace CKTim/BlueTooth.git with the address you copied earlier)

7. After this step, there will be an extra folder under your local project folder. The folder name is the project name above your github. As shown in the picture, I have an extra Test folder. We copy all the files under the local project folder (except the new one) to that new extra folder.

8. Then continue to enter the command cd Test and enter the Test folder

9. Then enter the following code in turn to complete the rest of the operation:

Git add. (note: don't forget the following. This operation adds all the files under the Test folder.)

Git commit-m "submission information" (Note: replace "submission information" with what you need, such as "first commit")

Git push-u origin master (Note: the purpose of this operation is to push the local warehouse to github, this step requires you to enter your account number and password)

This is the end of the content about "how to upload a project to github using git". Thank you for reading. If you want to know more about the industry, you can follow the industry information channel. The editor will update different knowledge points for you every day.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report