A newbie tutorial for git

Source: Internet
Author: User
Tags how to use git
Let's talk a little bit about it.

As a chicken in the industry, I feel ashamed to use code hosting only after one year of work. Today, I am not the focus. Here I want to talk about the advantages of using git, some common methods, and some common problems.

Whether in school or in the workplace, we will encounter a problem when writing programs:

"Hey, how can the code be compiled?" "Where can I change it? Why are there errors everywhere?" "It's bad. I can't change it back"

I think people who have just entered the coding industry will encounter more or less such problems. Of course, I also met. Let's take a look at my initial solution:

  

At first, I used this file name to back up and update my code. However, after that, a project on the hard disk was a large folder, and all of them were eye-catching. I just want to change the method. This method is not easy to use.

I started to use the cloud Disk Synchronization feature. It will be automatically synchronized, and there will also be a History version function. You can switch back.

Although I have a previous version of the onedrive and nut cloud I am using, I sometimes go back to the system when I encounter an error. Because there is no prompt, I can only go back to the System Based on my fuzzy memory, it is also hard to solve, and occasionally it will be synchronized or not synchronized,

  

It's embarrassing that I only saw this in March of this year. I have heard of GitHub before and used resources on it, but there is a wall in it, in addition, the company's network has added a wall, and the company has never been able to use GitHub, so it has no in-depth understanding.

I will not introduce it if I have never understood it abroad. The csdn code hosting service also stopped in May, so there are currently two most widely used products in China, I will not talk about the differences between them. There is no big difference in my own use. Here we will talk about how to use git with the code cloud, an open-source Chinese hosting platform.

Git download and installation 1. Git download link

Https://git-scm.com/downloads

 

Simply select the appropriate version. Click Next for installation, and you can configure it as needed.

Emmmmmmm, half written, du Niang a moment, found that a write is good, I will not duplicate the wheel, then directly reference

80273534

    

Let's just talk about something different.

The GIT platform I use is a domestic code cloud. GitHub companies are vulnerable to various attacks and often cannot connect to the Internet.

If you use git init to create a local project

 

During initialization, remember not to select any initialization. Otherwise, the local. Git file content is inconsistent with the. Git Internal Cylinder on the platform. A message indicating a conflict is prompted During the submission and uploading.

If it is initialized when a new project is created on the platform, you do not need to use the GIT init command locally. Just use the GIT clone command directly.

It's been a year since the first mix. It's also a chicken dish. Welcome to the discussion.

A newbie tutorial for git

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.