One of git and one of git's _ PHP tutorials

Source: Internet
Author: User
Git. Git 1. git 1. what is Git? Git is a free and open-source distributed version control system for agile and efficient processing of any small or large project. Git is one of the open-source git.

1. what is Git?
Git is a free and open-source distributed version control system for agile and efficient processing of any small or large projects.

Git is an open-source distributed version control system for efficient and high-speed processing of Project version management from very small to very large. Git is an open-source version control software developed by Linus Torvalds to help manage Linux kernel development.

2. Git features
The biggest difference between distributed and centralized systems is that developers can submit data locally. each developer copies a complete git repository on a local machine by cloning (Git clone.

1) directly record snapshots, rather than comparing differences: Git records changed files in a micro file system after taking snapshots.
2) almost all operations are performed locally: most operations in Git only need to access local files and resources without connecting to the network.
3) Keep data integrity at all times: before saving to Git, all data must undergo content checksum calculation and use this result as the unique identifier and index of the data.
4) most operations only add data: Most common Git operations only add data to the database.

3. centralized version control
Both CVS and SVN are centralized version control systems, while Git is a distributed version control system.

In a centralized version control system, the version Library is centrally stored on the central server. people working together must use their computers to synchronously update or upload their own modifications from the server.
However, all version data is stored on the server, and the user's local device only has the version that he has previously synchronized. if it is not connected to the Internet, the user will not be able to see the historical version, you cannot switch the version verification issue or work in different branches ..

Moreover, if all data is stored on a single server, there is a high risk that the server will be damaged. in this way, all data will be lost, and of course regular backup can be performed.

4. distributed version control
What is the difference between the distributed version control system and the centralized version control system?

The distributed version control system does not have a central server. each user's computer is a complete version library and can work without being connected to the Internet. Since each person has a complete version library on his/her computer, how can many people collaborate? For example, if you and your colleagues modify the same file on their respective computers, you only need to push the modifications to the other party to view the changes.

The security of the distributed version control system is much higher, because every computer has a complete version Library. Mutual replication is supported.

A distributed version control system usually has a computer that acts as a "central server". However, this server serves only to facilitate the "exchange" of changes, and everyone can do the same without it, it is not convenient to modify the exchange.

5. install Git
Git was first developed on Linux and can only run on Linux and Unix systems for a long time. However, someone transplanted it to Windows. Now, Git can run properly on Linux, Unix, Mac, and Windows platforms.

Install Git on Linux:

First, you can try to enter git to see if the system has installed Git:

1 $ git

Like the above commands, many Linux users will tell you that Git is not installed and how to install Git.

If you happen to use Debian or Ubuntu LinuxSudo apt-get install gitYou can directly install Git, which is very simple. If you want to check whether the installation is successfulGit -- version.

For other Linux versions, you can directly install them through the source code. Download the source code from the Git official website, decompress it, and enter the following in sequence:./Config, make, sudo make installInstall these commands.

After the installation is complete, you also need to set the last step. in the command line, enter:

1 $ git config --global user.name "Your Name"2 $ git config --global user.email "email@example.com"


Because Git is a distributed version control system, every machine must report your name and Email address.

Note that the git config command-- Global parameter. this parameter is used to indicate that all Git repositories on your machine use this configuration.You can also specify different user names and Email addresses for a repository.

Example 1. what is Git? Git is a free and open-source distributed version control system for agile and efficient processing of any small or large project. Git is an open source...

Related Article

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.