Git User Manual

Source: Internet
Author: User

Install git:

? Http://www.kernel.org/pub/software/scm/git/

Installation Process:

? 1. $ tar xzvf git-1.6.5

? 2. $ CD git-1.6.5?

3. $./config -- prefix =/usr/local?

4. $ make

? 5. $ sudo make install

? 6. $ git -- version

If you need command help, you can type '-help' to display it? Operation Manual. You can also type 'git help command' to achieve the same purpose.

$ Git log -- Help

$ Git help log

Configuration

Go to your local git working folder and put it in G:/git.

Initialize git init and configure the user name

Git config -- global user. Name "XXXX"

Git config -- global user. Email XXXX @ XXXXX

The above XXXX is a replacement of your name.

Then, you can obtain the managed code from git and test it.

Git clone http://git.oschina.net/oschina/git-osc.git

Git pull updates code library remotely

Git add dirorfile

Git commit-a-m "comment"-A indicates that git first loads the changed file (stage) and then submits

Git remote add <Name> <URL> Add remote server name

Git push <name> Update to remote server (if not, skip this step)

Git Status view git Information

Git add-I [<path>] command to view all files modified or deleted but not submitted in <path>

The diff sub-Command (6: [d] IFF) can compare the differences between files in the index Library and the original version. Its operation is similar to the revert sub-command.

Git add-H command to view the help document of git add command


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.